/* ═══════════════════════════════════════════════════════════
   CLAWTOPIA — Trading Terminal UI
   ═══════════════════════════════════════════════════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }
.hidden { display: none !important; }

:root {
    --bg: #06080d;
    --bg-surface: #0c1018;
    --bg-card: rgba(12, 16, 24, 0.75);
    --bg-card-solid: #0f1420;
    --bg-card-hover: rgba(20, 28, 42, 0.8);
    --border: rgba(34, 46, 68, 0.5);
    --border-solid: #1a2340;
    --text: #e2e8f0;
    --text-dim: #5a6a80;
    --text-muted: #3a4a60;

    /* Accent palette */
    --cyan: #00e5ff;
    --green: #16c784;
    --red: #ea3943;
    --yellow: #ffea00;
    --blue: #448aff;
    --purple: #b388ff;
    --orange: #ff9100;
    --gold: #ffd740;
    --magenta: #ff4081;

    /* Fonts */
    --font-display: 'Orbitron', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Effects */
    --glass-blur: blur(16px);
    --glow-cyan: 0 0 20px rgba(0, 229, 255, 0.15);
    --glow-gold: 0 0 16px rgba(255, 215, 64, 0.2);
    --glow-green: 0 0 12px rgba(22, 199, 132, 0.15);
    --glow-red: 0 0 12px rgba(234, 57, 67, 0.15);
    --radius: 8px;
    --radius-lg: 12px;
}

html { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 13px;
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
    /* Subtle dot grid background */
    background-image: radial-gradient(rgba(34, 46, 68, 0.3) 1px, transparent 1px);
    background-size: 24px 24px;
}

::selection {
    background: rgba(0, 229, 255, 0.25);
    color: #fff;
}

/* ─── SCROLLBARS ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(90, 106, 128, 0.25); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(90, 106, 128, 0.45); }

/* ─── LUCIDE ICONS ───────────────────────────────────────── */
.lucide { display: inline-block; vertical-align: middle; width: 16px; height: 16px; flex-shrink: 0; }
.icon-sm { width: 14px; height: 14px; }
.icon-champ { width: 32px; height: 32px; color: var(--gold); }
.icon-breaking { width: 16px; height: 16px; }
.icon-award-title { width: 16px; height: 16px; color: var(--gold); }
.icon-gold { color: var(--gold); }
.icon-silver { color: #78909c; }
.icon-bronze { color: #a1887f; }
.icon-green { color: var(--green); }
.icon-red { color: var(--red); }
.icon-dim { color: var(--text-dim); }
.icon-purple { color: var(--purple); }
.icon-orange { color: var(--orange); }

/* ─── BOT AVATARS ────────────────────────────────────────── */
.bot-avatar { display: inline-block; border-radius: 50%; object-fit: cover; vertical-align: middle; flex-shrink: 0; }
.avatar-lb { width: 24px; height: 24px; border: 1px solid rgba(255,255,255,0.08); }
.avatar-feed { width: 16px; height: 16px; }
.avatar-sm { width: 18px; height: 18px; }
.avatar-champ {
    width: 64px; height: 64px;
    border: 2px solid var(--gold);
    box-shadow: var(--glow-gold), 0 0 32px rgba(255, 215, 64, 0.1);
}

/* ═══════════════════════════════════════════════════════════
   INTRO SEQUENCE OVERLAY
   ═══════════════════════════════════════════════════════════ */
#intro-sequence {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #020408;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#intro-sequence.done {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

#intro-lines {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 0 24px;
    max-width: 600px;
    width: 100%;
}

.intro-line {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--green);
    white-space: nowrap;
    overflow: hidden;
    text-shadow: 0 0 8px rgba(22, 199, 132, 0.4);
    min-height: 1.5em;
    display: none;
}

.intro-line.typing {
    display: block;
}

.intro-line.typing::after {
    content: '\2588';
    animation: blinkCursor 0.5s step-end infinite;
    margin-left: 1px;
}

.intro-line.done::after {
    display: none;
}

.intro-line.intro-ready {
    color: var(--cyan);
    font-size: 1rem;
    font-weight: 700;
    margin-top: 8px;
    text-shadow: 0 0 12px rgba(0, 229, 255, 0.5);
}

@keyframes blinkCursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Scanline overlay on intro */
#intro-sequence::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 229, 255, 0.015) 2px,
        rgba(0, 229, 255, 0.015) 4px
    );
    pointer-events: none;
    z-index: 1;
}

/* Flicker on the whole overlay */
#intro-sequence::before {
    content: '';
    position: absolute;
    inset: 0;
    background: transparent;
    animation: introFlicker 0.15s infinite;
    pointer-events: none;
    z-index: 2;
    opacity: 0.03;
}

@keyframes introFlicker {
    0% { background: transparent; }
    50% { background: rgba(0, 229, 255, 0.04); }
    100% { background: transparent; }
}

@media (max-width: 480px) {
    .intro-line { font-size: 0.7rem; }
    .intro-line.intro-ready { font-size: 0.85rem; }
}

/* ═══════════════════════════════════════════════════════════
   LANDING PAGE
   ═══════════════════════════════════════════════════════════ */
#landing {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--bg);
    background-image: radial-gradient(rgba(34, 46, 68, 0.3) 1px, transparent 1px);
    background-size: 24px 24px;
    transition: opacity 0.6s ease, visibility 0.6s ease;
    overflow-y: auto;
    overflow-x: hidden;
}

#landing.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* ─── FLOATING PARTICLES ────────────────────────────────── */
#particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    border-radius: 50%;
    opacity: 0;
    animation: particleFloat linear infinite;
}

@keyframes particleFloat {
    0% {
        transform: translateY(100vh) translateX(0) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
        transform: translateY(90vh) translateX(10px) scale(1);
    }
    90% {
        opacity: 0.3;
    }
    100% {
        transform: translateY(-10vh) translateX(-10px) scale(0.5);
        opacity: 0;
    }
}

/* ─── TICKER TAPE ───────────────────────────────────────── */
#ticker-tape {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 5;
    overflow: hidden;
    background: rgba(6, 8, 13, 0.7);
    border-top: 1px solid rgba(34, 46, 68, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    height: 28px;
}

.ticker-track {
    display: flex;
    align-items: center;
    gap: 40px;
    white-space: nowrap;
    animation: tickerScroll 20s linear infinite;
    padding: 5px 0;
}

.ticker-item {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    flex-shrink: 0;
}

.ticker-item.green { color: var(--green); }
.ticker-item.red { color: var(--red); }
.ticker-item small {
    font-size: 0.58rem;
    opacity: 0.7;
    margin-left: 4px;
}

@keyframes tickerScroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ─── ANIMATED CANDLES BACKGROUND ────────────────────────── */
#candles-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
    opacity: 0.15;
}

.candle {
    position: absolute;
    bottom: 0;
    left: var(--x);
    width: 12px;
    height: var(--h);
    border-radius: 2px;
    animation: candleFloat var(--dur) ease-in-out infinite alternate;
    animation-delay: var(--delay);
}

.candle::before,
.candle::after {
    content: '';
    position: absolute;
    left: 50%;
    width: 2px;
    transform: translateX(-50%);
    border-radius: 1px;
}

/* Top wick */
.candle::before {
    bottom: 100%;
    height: var(--wick);
}

/* Bottom wick */
.candle::after {
    top: 100%;
    height: calc(var(--wick) * 0.6);
}

.candle.green {
    background: var(--green);
    box-shadow: 0 0 12px rgba(22, 199, 132, 0.3);
}
.candle.green::before,
.candle.green::after {
    background: var(--green);
}

.candle.red {
    background: var(--red);
    box-shadow: 0 0 12px rgba(234, 57, 67, 0.3);
}
.candle.red::before,
.candle.red::after {
    background: var(--red);
}

@keyframes candleFloat {
    0% {
        transform: translateY(0) scaleY(1);
        opacity: 0.6;
    }
    50% {
        transform: translateY(-40px) scaleY(1.15);
        opacity: 1;
    }
    100% {
        transform: translateY(20px) scaleY(0.85);
        opacity: 0.5;
    }
}

/* ─── LANDING NAV ────────────────────────────────────────── */
#landing-nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 28px;
    z-index: 10;
    background: transparent;
}

.nav-logo {
    display: flex;
    align-items: center;
}

.nav-logo-img {
    height: 100px;
    width: auto;
    margin: -30px 0;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-dim);
    text-decoration: none;
    font-family: var(--font-display);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: all 0.2s;
}

.nav-link:hover {
    border-color: var(--cyan);
    color: var(--cyan);
    background: rgba(0, 229, 255, 0.06);
}

.nav-link .lucide {
    width: 14px;
    height: 14px;
}

#landing-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 24px;
    max-width: 720px;
    position: relative;
    z-index: 1;
}

.landing-logo {
    height: 280px;
    width: auto;
    display: block;
    margin: -20px 0 -20px;
    animation: logoFloat 4s ease-in-out infinite, logoGlow 3s ease-in-out infinite alternate;
    filter: drop-shadow(0 0 20px rgba(0, 229, 255, 0.15));
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes logoGlow {
    0% { filter: drop-shadow(0 0 12px rgba(0, 229, 255, 0.1)); }
    100% { filter: drop-shadow(0 0 30px rgba(0, 229, 255, 0.3)) drop-shadow(0 0 60px rgba(0, 229, 255, 0.1)); }
}

.landing-tagline {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.06em;
    line-height: 1.4;
    margin-bottom: 12px;
    text-transform: uppercase;
    animation: fadeSlideUp 0.8s ease-out 0.2s both;
}

@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(25px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ─── FULL-PAGE GLITCH EFFECT ──────────────────────────────── */

/* RGB split layers over the entire landing */
#landing::before,
#landing::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 999;
    background: inherit;
    opacity: 0;
}

#landing::before {
    animation: glitchLayerCyan 8s infinite;
    mix-blend-mode: screen;
    background: rgba(0, 229, 255, 0.06);
}

#landing::after {
    animation: glitchLayerRed 8s infinite 0.05s;
    mix-blend-mode: screen;
    background: rgba(234, 57, 67, 0.06);
}

/* Main container jitter */
#landing-inner {
    animation: glitchJitter 6s infinite;
}

/* Scanline overlay */
.landing-scanlines {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 998;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.08) 2px,
        rgba(0, 0, 0, 0.08) 4px
    );
    animation: glitchScanlines 0.1s infinite;
}

/* Screen tear bar */
.landing-tear {
    position: absolute;
    left: 0;
    right: 0;
    height: 0;
    pointer-events: none;
    z-index: 1000;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(0, 229, 255, 0.1) 20%,
        rgba(234, 57, 67, 0.08) 50%,
        rgba(0, 229, 255, 0.1) 80%,
        transparent 100%
    );
    animation: glitchTear 6s infinite;
}

@keyframes glitchLayerCyan {
    0%, 100% { opacity: 0; transform: translate(0); clip-path: none; }
    15% { opacity: 0; }
    15.5% { opacity: 1; transform: translate(-4px, 0); clip-path: inset(10% 0 75% 0); }
    16% { opacity: 1; transform: translate(3px, 0); clip-path: inset(40% 0 30% 0); }
    16.5% { opacity: 0; transform: translate(0); clip-path: none; }
    45% { opacity: 0; }
    45.3% { opacity: 1; transform: translate(-3px, 0); clip-path: inset(60% 0 10% 0); }
    45.8% { opacity: 1; transform: translate(5px, 0); clip-path: inset(5% 0 80% 0); }
    46.3% { opacity: 0; transform: translate(0); clip-path: none; }
    72% { opacity: 0; }
    72.4% { opacity: 1; transform: translate(4px, 0); clip-path: inset(25% 0 55% 0); }
    72.8% { opacity: 1; transform: translate(-2px, 0); clip-path: inset(70% 0 5% 0); }
    73.3% { opacity: 0; transform: translate(0); clip-path: none; }
}

@keyframes glitchLayerRed {
    0%, 100% { opacity: 0; transform: translate(0); clip-path: none; }
    15.2% { opacity: 0; }
    15.7% { opacity: 1; transform: translate(4px, 0); clip-path: inset(20% 0 60% 0); }
    16.2% { opacity: 1; transform: translate(-3px, 0); clip-path: inset(50% 0 25% 0); }
    16.7% { opacity: 0; transform: translate(0); clip-path: none; }
    45.1% { opacity: 0; }
    45.5% { opacity: 1; transform: translate(3px, 0); clip-path: inset(15% 0 65% 0); }
    46% { opacity: 1; transform: translate(-4px, 0); clip-path: inset(45% 0 35% 0); }
    46.5% { opacity: 0; transform: translate(0); clip-path: none; }
    72.2% { opacity: 0; }
    72.6% { opacity: 1; transform: translate(-5px, 0); clip-path: inset(35% 0 45% 0); }
    73% { opacity: 1; transform: translate(3px, 0); clip-path: inset(80% 0 0% 0); }
    73.5% { opacity: 0; transform: translate(0); clip-path: none; }
}

@keyframes glitchJitter {
    0%, 100% { transform: translate(0); filter: none; }
    15.3% { transform: translate(0); }
    15.5% { transform: translate(-3px, 1px) skewX(-0.5deg); }
    15.8% { transform: translate(2px, -1px) skewX(0.3deg); }
    16.2% { transform: translate(0); }
    45.2% { transform: translate(0); }
    45.5% { transform: translate(2px, 0) skewX(0.4deg); }
    45.7% { transform: translate(-1px, 2px) skewX(-0.3deg); }
    46.1% { transform: translate(0); }
    72.3% { transform: translate(0); }
    72.5% { transform: translate(-2px, -1px) skewX(-0.6deg); }
    72.9% { transform: translate(3px, 1px) skewX(0.2deg); }
    73.2% { transform: translate(0); }
}

@keyframes glitchTear {
    0%, 100% { top: 0; height: 0; opacity: 0; }
    15% { top: 0; height: 0; opacity: 0; }
    15.5% { top: 30%; height: 3px; opacity: 1; transform: scaleX(1.02); }
    16% { top: 55%; height: 2px; opacity: 0.7; transform: scaleX(0.98); }
    16.5% { height: 0; opacity: 0; }
    45.3% { top: 0; height: 0; opacity: 0; }
    45.6% { top: 65%; height: 4px; opacity: 1; transform: scaleX(1.03); }
    46% { top: 20%; height: 2px; opacity: 0.6; transform: scaleX(0.97); }
    46.5% { height: 0; opacity: 0; }
    72.2% { top: 0; height: 0; opacity: 0; }
    72.6% { top: 45%; height: 3px; opacity: 0.9; transform: scaleX(1.01); }
    73% { top: 80%; height: 2px; opacity: 0.5; transform: scaleX(0.99); }
    73.4% { height: 0; opacity: 0; }
}

@keyframes glitchScanlines {
    0% { opacity: 0.4; }
    50% { opacity: 0.35; }
    100% { opacity: 0.4; }
}

.landing-desc {
    font-family: var(--font-body);
    font-size: 0.92rem;
    color: var(--text-dim);
    line-height: 1.6;
    max-width: 540px;
    margin-bottom: 32px;
    animation: fadeSlideUp 0.8s ease-out 0.4s both;
}

#enter-arena-btn {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--cyan);
    background: transparent;
    border: 2px solid var(--cyan);
    border-radius: 8px;
    padding: 14px 48px;
    cursor: pointer;
    transition: all 0.25s ease;
    animation: ctaPulse 2.5s ease-in-out infinite;
}

#enter-arena-btn:hover {
    background: rgba(0, 229, 255, 0.1);
    box-shadow: 0 0 24px rgba(0, 229, 255, 0.25), 0 0 48px rgba(0, 229, 255, 0.1);
    transform: translateY(-1px);
}

#enter-arena-btn:active {
    transform: translateY(0);
}

@keyframes ctaPulse {
    0%, 100% { box-shadow: 0 0 8px rgba(0, 229, 255, 0.1); }
    50% { box-shadow: 0 0 20px rgba(0, 229, 255, 0.2), 0 0 40px rgba(0, 229, 255, 0.08); }
}

/* ─── SCROLL HINT ───────────────────────────────────────── */
.landing-scroll-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 32px;
    color: var(--text-muted);
    font-family: var(--font-display);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    animation: hintBounce 2s ease-in-out infinite, fadeSlideUp 0.8s ease-out 0.6s both;
    cursor: default;
}

.landing-scroll-hint .lucide {
    width: 20px;
    height: 20px;
    color: var(--cyan);
    opacity: 0.5;
}

@keyframes hintBounce {
    0%, 100% { transform: translateY(0); opacity: 0.5; }
    50% { transform: translateY(6px); opacity: 1; }
}

/* ─── LANDING SCROLL WRAPPER ─────────────────────────────── */
#landing-scroll {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    position: relative;
    z-index: 1;
}

#landing-inner {
    min-height: 100vh;
    justify-content: center;
}

/* ─── LANDING CTA (bottom) ──────────────────────────────── */
#landing-cta {
    padding: 40px 24px 60px;
    text-align: center;
}

/* ═══════════════════════════════════════════════════════════
   BOT SHOWCASE
   ═══════════════════════════════════════════════════════════ */
#bot-showcase {
    width: 100%;
    max-width: 1100px;
    padding: 80px 24px 20px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.showcase-title {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 8px;
    background: linear-gradient(90deg, var(--cyan), #fff, var(--magenta), #fff, var(--cyan));
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmerText 4s ease-in-out infinite;
}

@keyframes shimmerText {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.showcase-sub {
    font-size: 0.85rem;
    color: var(--text-dim);
    line-height: 1.6;
    max-width: 560px;
    margin: 0 auto 36px;
}

/* ─── BOT GRID ──────────────────────────────────────────── */
.bot-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

/* ─── BOT CARD ──────────────────────────────────────────── */
.bot-card {
    background: #111827;
    border: 1px solid #1e293b;
    border-radius: 14px;
    padding: 24px 18px 16px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}

/* Top edge glow using bot color */
.bot-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--bot-color), transparent);
}

.bot-card:hover {
    border-color: #334155;
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5), 0 0 24px color-mix(in srgb, var(--bot-color) 15%, transparent);
}

/* ─── Scroll-reveal for bot cards ────────────────────── */
.bot-card {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.bot-card.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ─── Card Profile (centered avatar) ─────────────────── */
.bot-card-profile {
    margin-bottom: 12px;
    position: relative;
}

/* Pulsing ring around avatar */
.bot-card-profile::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    border: 1px solid var(--bot-color, #334155);
    opacity: 0;
    animation: avatarRingPulse 3s ease-out infinite;
}

@keyframes avatarRingPulse {
    0% { width: 100px; height: 100px; opacity: 0.5; }
    100% { width: 140px; height: 140px; opacity: 0; }
}

.bot-card-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--bot-color, #334155);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5), 0 0 30px color-mix(in srgb, var(--bot-color) 20%, transparent);
    display: block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bot-card:hover .bot-card-avatar {
    transform: scale(1.08);
    box-shadow: 0 0 24px rgba(0, 0, 0, 0.5), 0 0 40px color-mix(in srgb, var(--bot-color) 35%, transparent);
}

video.bot-card-avatar,
video.bot-avatar {
    pointer-events: none;
}

.bot-card-tags {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 8px;
}

.bot-tag {
    font-family: var(--font-mono);
    font-size: 0.58rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.bot-tag-model {
    color: var(--bot-color);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.bot-tag-strat {
    color: var(--text-dim);
    background: rgba(34, 46, 68, 0.4);
    border: 1px solid rgba(34, 46, 68, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-family: var(--font-display);
    font-size: 0.5rem;
}

/* ─── Card Body ───────────────────────────────────────── */
.bot-card-name {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.06em;
    margin-bottom: 6px;
    transition: text-shadow 0.3s ease;
}

.bot-card:hover .bot-card-name {
    text-shadow: 0 0 12px color-mix(in srgb, var(--bot-color) 50%, transparent);
}

.bot-card-motto {
    font-size: 0.72rem;
    color: var(--bot-color, var(--text-dim));
    font-style: italic;
    line-height: 1.4;
    margin-bottom: 8px;
    opacity: 0.8;
}

.bot-card-bio {
    font-size: 0.7rem;
    color: var(--text-dim);
    line-height: 1.55;
    margin-bottom: 14px;
    text-align: center;
    max-width: 280px;
}

/* ─── Stat Bars ───────────────────────────────────────── */
.bot-card-stats {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    margin-top: auto;
}

.bot-stat {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bot-stat-label {
    font-family: var(--font-display);
    font-size: 0.5rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    width: 65px;
    flex-shrink: 0;
}

.bot-stat-bar {
    flex: 1;
    height: 4px;
    background: #1e293b;
    border-radius: 2px;
    overflow: hidden;
}

.bot-stat-fill {
    height: 100%;
    border-radius: 2px;
    background: var(--bot-color);
    transition: width 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.3s;
}

/* Start at 0, animate when card is visible */
.bot-card:not(.visible) .bot-stat-fill {
    width: 0% !important;
}

/* ═══════════════════════════════════════════════════════════
   BOT PROFILE MODAL
   ═══════════════════════════════════════════════════════════ */
#bot-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: rgba(2, 4, 8, 0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: modalOverlayIn 0.3s ease;
}

#bot-modal-overlay.hidden { display: none !important; }

@keyframes modalOverlayIn { from { opacity: 0; } to { opacity: 1; } }

#bot-modal {
    background: #0f1420;
    border: 1px solid #1e293b;
    border-radius: 20px;
    padding: 40px 36px 32px;
    max-width: 420px;
    width: 100%;
    text-align: center;
    position: relative;
    animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.6);
    overflow: hidden;
}

#bot-modal::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--modal-color, var(--cyan)), transparent);
}

#bot-modal::after {
    content: '';
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--modal-color, var(--cyan)) 10%, transparent), transparent 70%);
    pointer-events: none;
    z-index: 0;
}

@keyframes modalSlideUp {
    from { opacity: 0; transform: translateY(40px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

#bot-modal-close {
    position: absolute;
    top: 12px; right: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid #1e293b;
    color: var(--text-dim);
    font-size: 1.3rem;
    cursor: pointer;
    line-height: 1;
    padding: 5px 10px;
    border-radius: 6px;
    transition: all 0.2s;
    z-index: 2;
}
#bot-modal-close:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--text-dim);
}

#bot-modal-profile {
    position: relative;
    z-index: 1;
    margin-bottom: 16px;
    display: flex;
    justify-content: center;
}

#bot-modal-profile video,
#bot-modal-profile img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--modal-color, #334155);
    box-shadow: 0 0 24px rgba(0, 0, 0, 0.5), 0 0 40px color-mix(in srgb, var(--modal-color, var(--cyan)) 25%, transparent);
}

#bot-modal-name {
    position: relative;
    z-index: 1;
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: 0.08em;
    margin-bottom: 10px;
}

#bot-modal-tags {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

#bot-modal-tags .bot-tag {
    font-size: 0.65rem;
    padding: 3px 10px;
}

#bot-modal-motto {
    position: relative;
    z-index: 1;
    font-size: 0.85rem;
    color: var(--modal-color, var(--text-dim));
    font-style: italic;
    line-height: 1.4;
    margin-bottom: 14px;
    opacity: 0.85;
}

#bot-modal-bio {
    position: relative;
    z-index: 1;
    font-size: 0.8rem;
    color: var(--text-dim);
    line-height: 1.65;
    margin-bottom: 20px;
    max-width: 340px;
    margin-left: auto;
    margin-right: auto;
}

#bot-modal-stats {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

#bot-modal-stats .bot-stat { gap: 10px; }
#bot-modal-stats .bot-stat-label { width: 75px; font-size: 0.55rem; }
#bot-modal-stats .bot-stat-bar { height: 5px; }

@media (max-width: 480px) {
    #bot-modal {
        padding: 32px 20px 24px;
        border-radius: 16px;
    }
    #bot-modal-profile video,
    #bot-modal-profile img {
        width: 110px;
        height: 110px;
    }
    #bot-modal-name { font-size: 1rem; }
    #bot-modal-bio { font-size: 0.75rem; }
}

#game-wrapper.hidden { display: none !important; }

@media (max-width: 768px) {
    .landing-logo { height: 200px; margin: -10px 0 -10px; }
    .landing-tagline { font-size: 1.4rem; }
    .landing-desc { font-size: 0.82rem; }
    #enter-arena-btn { padding: 12px 36px; font-size: 0.78rem; }
    .bot-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .showcase-title { font-size: 1.2rem; }
    #bot-showcase { padding: 40px 16px 20px; }
}

@media (max-width: 480px) {
    .landing-logo { height: 150px; margin: 0; }
    .landing-tagline { font-size: 1.1rem; }
    #enter-arena-btn { padding: 10px 28px; font-size: 0.72rem; }
    .bot-grid { grid-template-columns: 1fr; gap: 10px; }
    .showcase-title { font-size: 1rem; }
    .bot-card { padding: 16px 14px 12px; }
    .bot-card-avatar { width: 80px; height: 80px; }
}

/* ═══════════════════════════════════════════════════════════
   CENTERED BANNER
   ═══════════════════════════════════════════════════════════ */
#banner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
    background: var(--bg);
    line-height: 0;
}

.banner-img {
    height: 380px;
    width: auto;
    display: block;
    mix-blend-mode: lighten;
    margin: -110px 0;
}

/* ═══════════════════════════════════════════════════════════
   TOP BAR
   ═══════════════════════════════════════════════════════════ */
#top-bar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 42px;
    background: rgba(6, 8, 13, 0.92);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
}

.bar-left, .bar-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

#bar-status {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bar-divider {
    width: 1px;
    height: 18px;
    background: var(--border);
}

/* Animated neon glow line */
.glow-line {
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--cyan) 20%,
        var(--magenta) 50%,
        var(--cyan) 80%,
        transparent 100%
    );
    opacity: 0.6;
    animation: glowShift 4s ease-in-out infinite alternate;
}

@keyframes glowShift {
    0% { opacity: 0.4; filter: brightness(0.8); }
    100% { opacity: 0.7; filter: brightness(1.2); }
}

/* ─── BACK HOME BUTTON ───────────────────────────────────── */
#back-home-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: rgba(12, 16, 24, 0.6);
    color: var(--text-dim);
    cursor: pointer;
    transition: all 0.2s;
}
#back-home-btn:hover {
    border-color: var(--cyan);
    color: var(--cyan);
    background: rgba(0, 229, 255, 0.06);
}
#back-home-btn .lucide { width: 14px; height: 14px; }

/* ─── CA BOX ─────────────────────────────────────────────── */
#ca-box {
    padding: 4px 10px;
    background: rgba(12, 16, 24, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.7rem;
    cursor: pointer;
    transition: all 0.2s;
}
#ca-box:hover { border-color: var(--cyan); background: rgba(0, 229, 255, 0.04); }
.ca-label { color: var(--text-dim); font-family: var(--font-display); font-weight: 700; font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.06em; }
.ca-address { color: var(--text); font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.02em; user-select: all; }
.ca-copy-icon { width: 11px; height: 11px; color: var(--text-dim); transition: color 0.15s; }
#ca-box:hover .ca-copy-icon { color: var(--cyan); }
#ca-box.copied { border-color: var(--green); }
#ca-box.copied .ca-label { color: var(--green); }
#ca-box.copied .ca-label::after { content: " copied!"; }

/* ─── SOCIAL LINKS ───────────────────────────────────────── */
#social-links { display: flex; gap: 8px; }
.social-link {
    display: flex; align-items: center; justify-content: center;
    width: 30px; height: 30px; border-radius: 6px;
    border: 1px solid var(--border); color: var(--text-dim);
    text-decoration: none; transition: all 0.2s;
}
.social-link:hover { border-color: var(--cyan); color: var(--cyan); background: rgba(0, 229, 255, 0.06); }
.social-link .lucide { width: 14px; height: 14px; }

/* ─── LIVE INDICATOR ─────────────────────────────────────── */
#live-indicator {
    display: inline-flex; align-items: center; gap: 6px;
    color: var(--green); font-family: var(--font-display);
    font-size: 0.65rem; font-weight: 700;
    letter-spacing: 0.1em; text-transform: uppercase;
}
.live-dot {
    width: 7px; height: 7px; background: var(--green);
    border-radius: 50%; animation: livePulse 1.5s ease-in-out infinite;
}
@keyframes livePulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--green); }
    50% { opacity: 0.3; box-shadow: 0 0 12px var(--green); }
}

/* ─── ROUND & MOOD ───────────────────────────────────────── */
#round-display {
    font-family: var(--font-mono); font-weight: 600;
    font-size: 0.72rem; color: var(--text-dim);
    letter-spacing: 0.02em;
}
#mood-display {
    padding: 2px 8px; border-radius: 4px;
    font-family: var(--font-display); font-weight: 600;
    font-size: 0.6rem; letter-spacing: 0.04em;
    background: rgba(20, 28, 42, 0.6);
}
#mood-display.bullish { color: var(--green); border: 1px solid rgba(22, 199, 132, 0.25); }
#mood-display.bearish { color: var(--red); border: 1px solid rgba(234, 57, 67, 0.25); }
#mood-display.euphoric { color: var(--green); border: 1px solid rgba(22, 199, 132, 0.35); background: rgba(22, 199, 132, 0.06); text-shadow: 0 0 8px rgba(22, 199, 132, 0.3); }
#mood-display.panic { color: var(--red); border: 1px solid rgba(234, 57, 67, 0.35); background: rgba(234, 57, 67, 0.06); text-shadow: 0 0 8px rgba(234, 57, 67, 0.3); }
#mood-display.neutral { color: var(--text-dim); border: 1px solid var(--border); }

/* ═══════════════════════════════════════════════════════════
   ASSET NAME STRIP
   ═══════════════════════════════════════════════════════════ */
#asset-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 8px 16px;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border);
}

.asset-tag {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    color: var(--tag-color, var(--text));
    padding: 3px 14px;
    border-radius: 20px;
    border: 1px solid color-mix(in srgb, var(--tag-color, var(--text)) 25%, transparent);
    background: color-mix(in srgb, var(--tag-color, var(--text)) 6%, transparent);
    transition: all 0.2s;
}

.asset-tag:hover {
    background: color-mix(in srgb, var(--tag-color, var(--text)) 12%, transparent);
    border-color: color-mix(in srgb, var(--tag-color, var(--text)) 40%, transparent);
    box-shadow: 0 0 12px color-mix(in srgb, var(--tag-color, var(--text)) 15%, transparent);
}

.asset-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--text-muted);
    flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════
   BREAKING NEWS
   ═══════════════════════════════════════════════════════════ */
#breaking-news {
    text-align: center;
    padding: 8px 24px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.72rem;
    letter-spacing: 0.04em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transform: translateY(-100%);
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}
#breaking-news.show { transform: translateY(0); opacity: 1; }
#breaking-news.positive {
    background: linear-gradient(90deg, rgba(22, 199, 132, 0.06), rgba(22, 199, 132, 0.12), rgba(22, 199, 132, 0.06));
    color: var(--green);
    border-bottom: 1px solid rgba(22, 199, 132, 0.15);
    box-shadow: inset 0 -1px 20px rgba(22, 199, 132, 0.05);
}
#breaking-news.negative {
    background: linear-gradient(90deg, rgba(234, 57, 67, 0.06), rgba(234, 57, 67, 0.12), rgba(234, 57, 67, 0.06));
    color: var(--red);
    border-bottom: 1px solid rgba(234, 57, 67, 0.15);
    box-shadow: inset 0 -1px 20px rgba(234, 57, 67, 0.05);
}

/* ═══════════════════════════════════════════════════════════
   MAIN GAME GRID
   ═══════════════════════════════════════════════════════════ */
#game-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 0;
    min-height: calc(100vh - 86px);
}

#market-panel, #sidebar {
    padding: 14px;
    overflow-y: auto;
}

#market-panel {
    border-right: 1px solid var(--border);
}

/* ═══════════════════════════════════════════════════════════
   PANEL CARDS (Sidebar)
   ═══════════════════════════════════════════════════════════ */
.panel-card {
    background: var(--bg-card);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px;
    margin-bottom: 12px;
    position: relative;
    overflow: hidden;
}

/* Subtle top-edge gradient accent */
.panel-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 229, 255, 0.2), transparent);
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 10px;
}

.panel-header h3 {
    font-family: var(--font-display);
    font-size: 0.65rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.panel-icon {
    width: 13px;
    height: 13px;
    color: var(--cyan);
    opacity: 0.6;
}

/* ═══════════════════════════════════════════════════════════
   PRICE CLASSES
   ═══════════════════════════════════════════════════════════ */
.price-up { color: var(--green); }
.price-down { color: var(--red); }

/* ═══════════════════════════════════════════════════════════
   ARENA DESCRIPTION
   ═══════════════════════════════════════════════════════════ */
#arena-desc {
    margin-bottom: 16px;
    text-align: center;
}

#arena-desc h2 {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
    line-height: 1.3;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

#arena-desc p {
    font-size: 0.78rem;
    color: #6b7280;
    line-height: 1.55;
    max-width: 600px;
    margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════
   CHARTS — CoinGecko Style
   ═══════════════════════════════════════════════════════════ */
#charts-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.chart-card {
    background: #191b20;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 16px 16px 10px;
    transition: border-color 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
}

.chart-card:hover {
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

/* ─── Chart Header ─────────────────────────────────────── */
.chart-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 12px;
    padding: 0 2px;
}

.chart-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.chart-coin-icon {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    flex-shrink: 0;
}

.chart-coin-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.chart-sym {
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.01em;
    line-height: 1.2;
}

.chart-name {
    font-size: 0.62rem;
    color: #8b8e96;
    font-weight: 400;
    line-height: 1.2;
}

.chart-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.chart-price {
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: #fff;
    line-height: 1.2;
}

.chart-badge {
    font-family: var(--font-body);
    font-size: 0.68rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 6px;
    font-variant-numeric: tabular-nums;
    line-height: 1.3;
}

.chart-badge.up {
    color: #16c784;
    background: rgba(22, 199, 132, 0.12);
}

.chart-badge.down {
    color: #ea3943;
    background: rgba(234, 57, 67, 0.12);
}

/* ─── Canvas Area ──────────────────────────────────────── */
.chart-card canvas {
    width: 100% !important;
    height: 180px !important;
}

/* Last chart in odd count stretches full width */
.chart-card.chart-full {
    grid-column: 1 / -1;
}

.chart-card.chart-full canvas {
    height: 160px !important;
}

/* ═══════════════════════════════════════════════════════════
   EVENTS
   ═══════════════════════════════════════════════════════════ */
#events-panel { margin-bottom: 0; }

#events-list:empty::after {
    content: "No active events";
    color: var(--text-muted);
    font-size: 0.72rem;
    font-style: italic;
}

.event-card {
    background: rgba(12, 16, 24, 0.5);
    border-radius: var(--radius);
    padding: 10px 12px;
    margin-bottom: 6px;
    border-left: 2px solid var(--blue);
    font-size: 0.72rem;
    transition: transform 0.15s, background 0.15s;
}
.event-card:hover { transform: translateX(3px); background: rgba(20, 28, 42, 0.5); }
.event-card.positive { border-left-color: var(--green); background: rgba(22, 199, 132, 0.03); }
.event-card.negative { border-left-color: var(--red); background: rgba(234, 57, 67, 0.03); }
.event-card.positive:hover { background: rgba(22, 199, 132, 0.06); }
.event-card.negative:hover { background: rgba(234, 57, 67, 0.06); }

.event-name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.65rem;
    letter-spacing: 0.03em;
    margin-bottom: 2px;
}
.event-desc { color: var(--text-dim); line-height: 1.4; }
.event-meta { color: var(--text-muted); font-size: 0.62rem; margin-top: 3px; font-family: var(--font-mono); }

/* ═══════════════════════════════════════════════════════════
   LEADERBOARD
   ═══════════════════════════════════════════════════════════ */
#leaderboard { margin-bottom: 0; }

.lb-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: var(--radius);
    margin-bottom: 4px;
    background: rgba(12, 16, 24, 0.4);
    transition: all 0.2s ease;
    font-size: 0.76rem;
    font-variant-numeric: tabular-nums;
    border: 1px solid transparent;
}

.lb-row:hover {
    background: rgba(20, 28, 42, 0.6);
    transform: translateX(3px);
}

/* Podium: Gold / Silver / Bronze */
.lb-row:nth-child(1) {
    border-color: rgba(255, 215, 64, 0.2);
    background: linear-gradient(135deg, rgba(255, 215, 64, 0.06), rgba(255, 215, 64, 0.02));
    box-shadow: var(--glow-gold);
}
.lb-row:nth-child(2) {
    border-color: rgba(120, 144, 156, 0.15);
    background: linear-gradient(135deg, rgba(120, 144, 156, 0.05), transparent);
}
.lb-row:nth-child(3) {
    border-color: rgba(161, 136, 127, 0.15);
    background: linear-gradient(135deg, rgba(161, 136, 127, 0.05), transparent);
}

.lb-rank {
    width: 24px; text-align: center;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.72rem; font-weight: 700; flex-shrink: 0;
}
.lb-icon { display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lb-name {
    font-weight: 600; font-size: 0.72rem;
    flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.lb-nw {
    font-family: var(--font-mono);
    font-weight: 700; font-size: 0.74rem;
    text-align: right; font-variant-numeric: tabular-nums;
}
.lb-pnl {
    font-family: var(--font-mono);
    font-size: 0.66rem; text-align: right;
    width: 76px; font-variant-numeric: tabular-nums;
}
.lb-bar-wrap {
    width: 44px; height: 3px;
    background: rgba(34, 46, 68, 0.4);
    border-radius: 2px; overflow: hidden; flex-shrink: 0;
}
.lb-bar {
    height: 100%; border-radius: 2px;
    transition: width 0.4s ease;
    background: var(--green);
}
.lb-bar.negative { background: var(--red); }

/* ═══════════════════════════════════════════════════════════
   TRADE FEED
   ═══════════════════════════════════════════════════════════ */
#trade-feed-panel {
    max-height: 380px;
    display: flex;
    flex-direction: column;
}
#trade-feed {
    flex: 1;
    overflow-y: auto;
    max-height: 310px;
}

.feed-entry {
    padding: 6px 10px;
    border-radius: 6px;
    margin-bottom: 3px;
    font-size: 0.72rem;
    background: rgba(12, 16, 24, 0.35);
    border-left: 2px solid var(--border-solid);
    animation: slideIn 0.2s ease-out;
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
    transition: background 0.15s;
}
.feed-entry:hover { background: rgba(20, 28, 42, 0.4); }
.feed-entry.buy { border-left-color: var(--green); }
.feed-entry.sell { border-left-color: var(--red); }
.feed-entry.taunt { border-left-color: var(--purple); }
.feed-entry.sabotage { border-left-color: var(--orange); }
.feed-entry.hold { border-left-color: var(--text-muted); }

@keyframes slideIn {
    from { opacity: 0; transform: translateX(8px); }
    to { opacity: 1; transform: translateX(0); }
}

.feed-bot {
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.feed-action {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.68rem;
    margin-left: 2px;
}
.feed-entry.buy .feed-action { color: var(--green); }
.feed-entry.sell .feed-action { color: var(--red); }
.feed-entry.taunt .feed-action { color: var(--purple); }

.feed-comment {
    color: var(--text-dim);
    display: block;
    margin-top: 1px;
    font-style: italic;
    width: 100%;
    font-size: 0.65rem;
    line-height: 1.4;
}

/* ═══════════════════════════════════════════════════════════
   RESULTS OVERLAY
   ═══════════════════════════════════════════════════════════ */
#results-overlay {
    position: fixed; inset: 0;
    background: rgba(6, 8, 13, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    animation: overlayIn 0.4s ease;
    padding: 20px;
}
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }

#results-content {
    background: var(--bg-card-solid);
    border: 1px solid var(--border-solid);
    border-radius: 16px;
    padding: 32px;
    max-width: 660px;
    width: 100%;
    text-align: center;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    position: relative;
    animation: cardSlideUp 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.5), var(--glow-cyan);
}
@keyframes cardSlideUp {
    from { opacity: 0; transform: translateY(30px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Top accent line on results */
#results-content::before {
    content: '';
    position: absolute;
    top: 0; left: 16px; right: 16px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    border-radius: 1px;
}

.results-badge {
    font-family: var(--font-display);
    font-size: 0.55rem;
    letter-spacing: 0.2em;
    color: var(--cyan);
    text-transform: uppercase;
    margin-bottom: 4px;
}

#results-close {
    position: absolute;
    top: 12px; right: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    color: var(--text-dim);
    font-size: 1.2rem;
    cursor: pointer; line-height: 1;
    padding: 5px 9px; border-radius: 6px;
    transition: all 0.2s; z-index: 1;
}
#results-close:hover { color: var(--text); background: rgba(255, 255, 255, 0.08); border-color: var(--text-dim); }

#results-content h1 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--gold), #fff8e1, var(--gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
    flex-shrink: 0;
}

#results-scroll {
    flex: 1; overflow-y: auto;
    min-height: 0; padding-right: 6px;
}

#champion-box {
    background: linear-gradient(135deg, rgba(255, 215, 64, 0.06), rgba(255, 215, 64, 0.02));
    border: 1px solid rgba(255, 215, 64, 0.2);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 18px;
    box-shadow: var(--glow-gold);
}
#champion-box .champ-icon { display: flex; align-items: center; justify-content: center; }
#champion-box .champ-name {
    font-family: var(--font-display);
    font-size: 1rem; font-weight: 800;
    margin: 8px 0 4px; letter-spacing: 0.04em;
}
#champion-box .champ-stats { color: var(--text-dim); font-size: 0.76rem; font-family: var(--font-mono); }

#results-table { width: 100%; border-collapse: collapse; margin-bottom: 18px; text-align: left; }
#results-table th {
    color: var(--text-muted); font-family: var(--font-display);
    font-size: 0.58rem; text-transform: uppercase;
    letter-spacing: 0.06em; padding: 6px 8px;
    border-bottom: 1px solid var(--border-solid);
}
#results-table th.num, #results-table td.num { text-align: right; }
#results-table td {
    padding: 7px 8px;
    border-bottom: 1px solid rgba(34, 46, 68, 0.3);
    font-size: 0.75rem;
    font-variant-numeric: tabular-nums;
}
#results-table tr:hover td { background: rgba(255, 255, 255, 0.015); }

#awards-box { text-align: left; margin-bottom: 16px; }
#awards-box h3 {
    font-family: var(--font-display);
    font-size: 0.72rem; color: var(--gold);
    margin-bottom: 8px;
    display: flex; align-items: center; gap: 6px;
}
.award-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 5px 0;
    border-bottom: 1px solid rgba(34, 46, 68, 0.3);
    font-size: 0.72rem;
}
.award-label { color: var(--text-dim); }

#final-market { text-align: left; margin-bottom: 8px; }
#final-market h3 {
    font-family: var(--font-display);
    font-size: 0.72rem; color: var(--text-dim);
    margin-bottom: 6px;
    display: flex; align-items: center; gap: 6px;
}
.final-asset-row {
    display: flex; justify-content: space-between;
    padding: 3px 0; font-size: 0.75rem;
    font-family: var(--font-mono);
    font-variant-numeric: tabular-nums;
}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    #game-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    #game-grid { grid-template-columns: 1fr; }
    #market-panel { border-right: none; border-bottom: 1px solid var(--border); }
    #charts-container { grid-template-columns: 1fr; }
    .chart-card canvas { height: 140px !important; }
    .chart-card.chart-full canvas { height: 130px !important; }
    #top-bar { flex-wrap: wrap; height: auto; padding: 8px 14px; gap: 8px; }
    #bar-status { order: 3; width: 100%; justify-content: center; gap: 8px; }
    .banner-img { height: 260px; margin: -75px 0; }
    #banner { padding: 0 16px; }
    #asset-strip { gap: 10px; flex-wrap: wrap; }
    .asset-tag { font-size: 0.62rem; padding: 2px 10px; }
    #results-content { padding: 20px; border-radius: 12px; }
}

@media (max-width: 480px) {
    #ca-box { display: none; }
    .lb-pnl { display: none; }
    .lb-bar-wrap { display: none; }
    body { font-size: 12px; }
    .banner-img { height: 180px; margin: -50px 0; }
    #banner { padding: 0 12px; }
    .chart-card canvas { height: 120px !important; }
    #results-content { padding: 16px; }
    .asset-tag { font-size: 0.58rem; padding: 2px 8px; letter-spacing: 0.06em; }
    #asset-strip { gap: 6px; }
    .asset-dot { display: none; }
    .bar-divider { display: none; }
}
