:root {
    --bg-main: #05070c;
    --bg-card: #0b0f19;
    --bg-card-hover: #121826;
    --border-card: #162032;
    --border-card-hover: #38bdf8;
    
    --royal-blue: #2563eb;
    --electric-blue: #38bdf8;
    --neon-cyan: #06b6d4;
    --gold: #f59e0b;
    --gold-glow: rgba(245, 158, 11, 0.35);
    --emerald-green: #10b981;
    --crimson-red: #f43f5e;
    --vivid-purple: #a855f7;
    
    --text-white: #ffffff;
    --text-blue-light: #e2e8f0;
    --text-muted: #64748b;
    
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --font-display: 'Syne', sans-serif;
    --font-main: 'Space Grotesk', -apple-system, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-main);
}

html {
    overflow-y: auto;
    overflow-x: hidden;
    width: 100%;
    background-color: #05070c;
}

body {
    background-color: #05070c;
    color: var(--text-white);
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    position: relative;
}

/* Fullscreen Left Side Emblem Background Watermark (Massive Scale) */
.side-graphic-overlay {
    position: fixed;
    top: 50%;
    left: 0;
    transform: translateY(-50%) translateX(-50%);
    width: clamp(750px, 70vw, 1300px);
    height: clamp(750px, 70vw, 1300px);
    background-image: url('/side_emblem_transparent.png');
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    opacity: 0.16;
    pointer-events: none;
    z-index: 0;
    filter: drop-shadow(0 0 70px rgba(255, 255, 255, 0.2));
}

@media (max-width: 900px) {
    .side-graphic-overlay {
        opacity: 0.22;
        width: 680px;
        height: 680px;
        transform: translateY(-50%) translateX(-40%);
        filter: drop-shadow(0 0 50px rgba(255, 255, 255, 0.3));
    }
}

/* Navbar - Fixed solid background to eliminate blur repaint jitter */
.nav-bar {
    position: relative;
    top: 0;
    z-index: 50;
    background: #030508;
    border-bottom: 1px solid #141b29;
    padding: 14px 28px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
}

.nav-inner {
    max-width: 1260px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-logo-img {
    width: clamp(50px, 5vw, 64px);
    height: clamp(50px, 5vw, 64px);
    object-fit: contain;
    filter: drop-shadow(0 0 16px rgba(255, 255, 255, 0.55));
    transition: transform 0.25s ease;
}

.nav-brand:hover .nav-logo-img {
    transform: scale(1.08);
}

.footer-logo-img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    opacity: 0.85;
}

.nav-title {
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #fff;
}

.nav-title strong {
    color: var(--electric-blue);
    background: linear-gradient(135deg, var(--electric-blue) 0%, #60a5fa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-search-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-field {
    display: flex;
    align-items: center;
    background: rgba(16, 25, 46, 0.85);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    padding: 0 12px;
}

.header-field input {
    background: none;
    border: none;
    outline: none;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 8px 0;
    width: 180px;
}

.submit-btn-sm {
    background: linear-gradient(135deg, var(--royal-blue) 0%, var(--electric-blue) 100%);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}

.submit-btn-sm:hover { opacity: 0.9; }

/* Main Content Workspace */
.main-content {
    max-width: 1260px;
    width: 100%;
    margin: 24px auto 60px;
    padding: 0 24px;
    flex: 1;
    position: relative;
    z-index: 5;
}

.hidden { display: none !important; }

/* Minimalist Typography Hero Stage */
.epic-hero-stage {
    position: relative;
    width: 100%;
    border-radius: var(--radius-lg);
    background: #020408;
    border: 1px solid #162032;
    padding: 70px 20px 48px 20px;
    margin-bottom: 40px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-typography-canvas {
    width: 100%;
    max-width: 100%;
    margin-bottom: 32px;
    padding: 0 10px;
    box-sizing: border-box;
}

.hero-headline-caps {
    font-family: var(--font-display);
    font-size: clamp(2.2rem, 6vw, 4.4rem);
    font-weight: 900;
    color: #ffffff;
    line-height: 1.15;
    margin: 0;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: clamp(8px, 2vw, 20px);
}

.headline-text {
    letter-spacing: clamp(3px, 0.8vw, 8px);
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.15);
}

.headline-bolt {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    line-height: 1;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
    user-select: none;
}

.headline-bolt svg {
    display: block;
    width: clamp(22px, 3.8vw, 38px);
    height: clamp(34px, 5.8vw, 58px);
    stroke: #ffffff;
    fill: none;
}

@media (max-width: 600px) {
    .hero-headline-caps {
        flex-direction: column;
        gap: 8px;
    }
    
    .headline-bolt svg {
        width: 24px;
        height: 38px;
    }

    .headline-text {
        letter-spacing: 3px;
        font-size: 2.1rem;
    }
}

.hero-subheadline-caps {
    font-size: clamp(0.78rem, 2vw, 0.98rem);
    font-weight: 700;
    letter-spacing: clamp(2px, 0.6vw, 5px);
    color: #64748b;
    text-transform: uppercase;
}

/* Integrated Search Dock */
.hero-floating-dock {
    width: 100%;
    max-width: 680px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    z-index: 10;
}

.center-search-form {
    display: flex;
    gap: 10px;
    width: 100%;
}

@media (max-width: 650px) {
    .epic-hero-stage { padding: 48px 16px 36px 16px; }
    .center-search-form { flex-direction: column; }
    .hero-floating-dock { width: 100%; }
}

.hero-search-box {
    flex: 1;
    display: flex;
    align-items: center;
    background: #000000;
    border: 1.5px solid #222d42;
    border-radius: var(--radius-sm);
    padding: 0 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    transition: all 0.25s;
}

.hero-search-box:focus-within {
    border-color: #ffffff;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.2);
    background: #000000;
}

.hero-hash {
    color: #ffffff;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.3rem;
    margin-right: 8px;
}

.hero-search-box input {
    width: 100%;
    background: none;
    border: none;
    outline: none;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    padding: 16px 0;
}

.hero-search-box input::placeholder { color: var(--text-muted); font-weight: 500; }

.clear-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.3rem;
    cursor: pointer;
}

.hero-cta-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--royal-blue) 0%, var(--electric-blue) 100%);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    padding: 0 28px;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35);
    transition: all 0.2s;
}

.hero-cta-btn:hover {
    box-shadow: 0 10px 28px rgba(56, 189, 248, 0.45);
    transform: translateY(-1px);
}

.quick-tags-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.quick-lbl {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
}

.quick-tag-pill {
    background: rgba(14, 22, 42, 0.75);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-blue-light);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.quick-tag-pill:hover {
    background: rgba(56, 189, 248, 0.15);
    color: #fff;
    border-color: var(--electric-blue);
}

.cta-bolt { font-size: 1.1rem; }

/* Seamless Leaderboard Decks Section (Pure Dark Monochrome) */
.seamless-decks-section {
    margin-top: 48px;
    width: 100%;
}

.leaderboard-decks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 20px;
    margin-top: 18px;
}

@media (max-width: 768px) {
    .leaderboard-decks-grid {
        grid-template-columns: 1fr;
    }
}

.leaderboard-deck-card {
    background: #000000;
    border: 1px solid #1a1a1a;
    border-radius: 10px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    transition: border-color 0.2s, background 0.2s;
}

.leaderboard-deck-card:hover {
    border-color: #ffffff;
    background: #050505;
}

.deck-top-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.deck-identity {
    display: flex;
    align-items: center;
    gap: 12px;
}

.deck-rank-badge {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 900;
    color: #000000;
    background: #ffffff;
    padding: 3px 8px;
    border-radius: 4px;
    line-height: 1;
}

.deck-title {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 800;
    color: #ffffff;
    margin: 0;
    letter-spacing: 0.5px;
}

.deck-sub-type {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: #888888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.deck-metrics {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.deck-winrate-tag {
    font-family: var(--font-mono);
    font-size: 0.76rem;
    font-weight: 800;
    color: #ffffff;
    background: #111111;
    border: 1px solid #2a2a2a;
    padding: 2px 8px;
    border-radius: 4px;
}

.deck-elixir-tag {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: #888888;
}

.deck-card-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.deck-card-slot {
    position: relative;
    background: #080808;
    border: 1px solid #1a1a1a;
    border-radius: 6px;
    padding: 8px 4px 6px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
    transition: border-color 0.15s, background 0.15s;
}

.deck-card-slot:hover {
    border-color: #444444;
    background: #0e0e0e;
}

.deck-card-slot img {
    width: 46px;
    height: 56px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.8));
}

.card-slot-name {
    font-family: var(--font-main);
    font-size: 0.68rem;
    font-weight: 600;
    color: #aaaaaa;
    margin-top: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90%;
    line-height: 1.1;
}

.card-elixir-pill {
    position: absolute;
    top: 4px;
    left: 4px;
    background: #ffffff;
    color: #000000;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 900;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.deck-card-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.deck-action-btn {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 800;
    color: #ffffff;
    background: #0a0a0a;
    border: 1px solid #222222;
    padding: 6px 14px;
    border-radius: 5px;
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: background 0.2s, border-color 0.2s;
    display: inline-block;
}

.deck-action-btn:hover {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

/* Hub Grid (Top Players & Clans) - Seamless, No Boxy Cards */
.hub-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 36px;
    margin-top: 10px;
}

@media (max-width: 850px) {
    .hub-grid { grid-template-columns: 1fr; gap: 28px; }
}

.seamless-hub-col {
    display: flex;
    flex-direction: column;
}

.col-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid #1a2233;
}

.col-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.col-title-group h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 1px;
}

.col-sub {
    font-size: 0.72rem;
    color: #64748b;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-top: 2px;
}

.hub-player-list, .hub-clan-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.list-placeholder {
    color: #475569;
    font-size: 0.85rem;
    padding: 24px 0;
    text-align: center;
}

.hub-row-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #000000;
    border: 1px solid #141b29;
    border-radius: var(--radius-sm);
    padding: 12px 18px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.hub-row-item:hover {
    border-color: #ffffff;
    background: #080b12;
    transform: translateX(4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
}

.hub-item-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.hub-rank-badge {
    font-size: 0.82rem;
    font-weight: 800;
    font-family: var(--font-mono);
    color: #64748b;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #090d16;
    border: 1px solid #141b29;
}

.hub-rank-badge.top-1 { background: #ffffff; color: #000000; border: 1px solid #ffffff; font-weight: 900; }
.hub-rank-badge.top-2 { background: #1a2233; color: #ffffff; border: 1px solid #334155; }
.hub-rank-badge.top-3 { background: #121824; color: #cbd5e1; border: 1px solid #222d42; }

.hub-item-meta { display: flex; flex-direction: column; }
.hub-item-name { font-size: 0.95rem; font-weight: 700; color: #ffffff; }
.hub-item-sub { font-size: 0.76rem; color: #64748b; font-weight: 500; margin-top: 1px; }

.hub-trophy-val {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.2px;
}

/* Glass Card */
.glass-card {
    background: #000000;
    border: 1px solid #141b29;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7);
}

.glass-card:last-child { margin-bottom: 0; }

/* Results Dashboard */
.hero-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding: 28px 32px;
    border: 1px solid #1c2433;
    background: #07090e;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.8);
}

.hero-left { display: flex; align-items: center; gap: 20px; }

.king-avatar {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: #ffffff;
    color: #000000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.2);
    border: 2px solid #ffffff;
}

.hero-meta { display: flex; flex-direction: column; gap: 4px; }
.name-row { display: flex; align-items: center; gap: 12px; }
.name-row h2 { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.4px; }

.arena-tag {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--gold);
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 3px 12px;
    border-radius: 20px;
}

.tag-actions { display: flex; align-items: center; gap: 8px; }
.mono-tag { font-family: var(--font-mono); color: var(--electric-blue); font-size: 0.9rem; font-weight: 600; }

.pill-btn {
    background: rgba(56, 189, 248, 0.15);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.pill-btn:hover { background: var(--electric-blue); color: #000; }

/* Clan Cell */
.clan-cell {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(14, 22, 42, 0.8);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    padding: 14px 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.clan-cell:hover {
    border-color: var(--electric-blue);
    background: rgba(28, 43, 76, 0.9);
    box-shadow: 0 4px 16px rgba(56, 189, 248, 0.25);
}

.clan-icon { font-size: 1.8rem; }
.clan-text { display: flex; flex-direction: column; }
.clan-text .caption { font-size: 0.72rem; color: var(--electric-blue); text-transform: uppercase; font-weight: 700; }
.clan-title { font-size: 1.1rem; font-weight: 800; color: #fff; }
.clan-role-label { font-size: 0.8rem; color: var(--gold); font-weight: 600; }
.clan-chevron { font-size: 1.2rem; color: var(--electric-blue); margin-left: 8px; }

/* Metrics Row */
.metrics-row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 14px;
    margin-bottom: 20px;
}

@media (max-width: 950px) { .metrics-row { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) { .metrics-row { grid-template-columns: repeat(2, 1fr); } }

.metric-box {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 0;
    border-top: 3px solid var(--royal-blue);
}

.metric-label { font-size: 0.75rem; color: var(--text-blue-light); font-weight: 700; text-transform: uppercase; }
.metric-number { font-size: 1.6rem; font-weight: 900; letter-spacing: -0.3px; }
.metric-sub { font-size: 0.75rem; color: var(--emerald-green); font-weight: 700; }

.accent-gold { color: var(--gold); }
.accent-green { color: var(--emerald-green); }
.accent-red { color: var(--crimson-red); }

/* Deck Row */
.card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.card-head h3 { font-size: 1.15rem; font-weight: 800; color: #fff; }

.elixir-pill {
    font-size: 0.85rem;
    color: #e9d5ff;
    background: rgba(168, 85, 247, 0.2);
    border: 1px solid rgba(168, 85, 247, 0.4);
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 600;
}

.elixir-pill strong { color: #fff; }

.deck-row {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 10px;
    width: 100%;
}

@media (max-width: 1050px) { .deck-row { grid-template-columns: repeat(4, 1fr); gap: 10px; } }

.deck-slot {
    position: relative;
    background: rgba(14, 22, 42, 0.8);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    padding: 14px 6px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.25s;
}

.deck-slot:hover {
    border-color: var(--electric-blue);
    box-shadow: 0 6px 18px rgba(56, 189, 248, 0.25);
}

.deck-drop {
    position: absolute;
    top: 6px;
    left: 6px;
    background: var(--vivid-purple);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 900;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(168, 85, 247, 0.5);
}

.deck-img { width: 72px; height: 90px; object-fit: contain; filter: drop-shadow(0 4px 8px rgba(0,0,0,0.5)); }
.deck-meta { margin-top: 8px; text-align: center; width: 100%; }
.deck-name { font-size: 0.78rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.deck-lvl { font-size: 0.72rem; color: var(--gold); font-weight: 800; }

/* Split Columns (Chests & Recent Battles) */
.content-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    width: 100%;
}

@media (max-width: 1100px) {
    .content-split {
        grid-template-columns: 1fr;
    }
}
.split-panel { margin-bottom: 0; }

/* Chests & Battles */
.chest-track {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
    width: 100%;
}

@media (max-width: 900px) {
    .chest-track {
        grid-template-columns: repeat(4, 1fr);
    }
}

.chest-pill {
    background: rgba(14, 22, 42, 0.8);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    padding: 10px 4px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}
.chest-pill.next { border-color: var(--gold); background: rgba(245, 158, 11, 0.12); box-shadow: 0 0 12px var(--gold-glow); }
.c-ico { font-size: 1.8rem; margin-bottom: 4px; }
.c-index { font-size: 0.85rem; font-weight: 800; color: var(--gold); }
.c-title { font-size: 0.72rem; color: var(--text-blue-light); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; width: 100%; margin-top: 2px; }

.battle-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.battle-card {
    background: #060910;
    border: 1px solid #141b29;
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.2s ease;
}

.battle-card:hover {
    border-color: #334155;
    background: #080d16;
}

.battle-card.expanded {
    border-color: #ffffff;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7);
}

.battle-card-hidden {
    display: none !important;
}

.battles-toggle-wrap {
    display: flex;
    justify-content: center;
    padding-top: 10px;
    width: 100%;
}

.btn-more-battles {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: #ffffff;
    background: #000000;
    border: 1px solid #262626;
    padding: 12px 28px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    width: 100%;
    max-width: 320px;
}

.btn-more-battles:hover {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

.battle-summary-row {
    padding: 14px 20px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    cursor: pointer;
    user-select: none;
    gap: 16px;
    transition: background 0.15s ease;
}

.battle-summary-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* Left Side (Player) */
.b-player-side {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.b-side-left {
    justify-content: flex-start;
}

.b-player-name {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 800;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
}

.b-trophy-tag {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
}

.b-trophy-tag.pos {
    color: #4ade80;
    background: rgba(74, 222, 128, 0.12);
}

.b-trophy-tag.neg {
    color: #f87171;
    background: rgba(248, 113, 113, 0.12);
}

/* Center Result & Score (Red / Green) */
.b-center-score {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.b-score-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px;
    border-radius: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    border: 1px solid transparent;
}

.b-score-badge.win {
    background: rgba(22, 101, 52, 0.35);
    border-color: #22c55e;
    color: #4ade80;
}

.b-score-badge.win .b-score-numbers {
    color: #ffffff;
}

.b-score-badge.win .b-score-status {
    color: #4ade80;
}

.b-score-badge.loss {
    background: rgba(153, 27, 27, 0.35);
    border-color: #ef4444;
    color: #f87171;
}

.b-score-badge.loss .b-score-numbers {
    color: #ffffff;
}

.b-score-badge.loss .b-score-status {
    color: #f87171;
}

.b-score-badge.draw {
    background: rgba(51, 65, 85, 0.35);
    border-color: #64748b;
    color: #cbd5e1;
}

.b-score-numbers {
    font-family: var(--font-mono);
    font-size: 1.15rem;
    font-weight: 900;
    letter-spacing: 1px;
    line-height: 1;
}

.b-score-status {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1;
}

.b-game-mode {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: #71717a;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

/* Right Side (Opponent - Clickable) */
.b-side-right {
    justify-content: flex-end;
    gap: 12px;
}

.b-opp-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    min-width: 0;
}

.b-opp-profile-btn {
    background: transparent;
    border: none;
    padding: 4px 6px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    border-radius: 6px;
    transition: background 0.15s, transform 0.15s;
    text-align: right;
    max-width: 100%;
}

.b-opp-profile-btn:hover {
    background: #141414;
}

.b-opp-profile-btn:hover .b-opp-name {
    color: #ffffff;
    text-decoration: underline;
}

.b-opp-name {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 800;
    color: #e4e4e7;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
    transition: color 0.15s;
}

.b-opp-tag-sub {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 700;
    color: #888888;
    letter-spacing: 0.5px;
}

.b-opp-tag-link {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 700;
    color: #ffffff;
    background: #111111;
    border: 1px solid #333333;
    padding: 3px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.b-opp-tag-link:hover {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

.btn-toggle-battle {
    background: #0d0d0d;
    border: 1px solid #222222;
    color: #888888;
    cursor: pointer;
    font-size: 0.75rem;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    flex-shrink: 0;
}

.btn-toggle-battle:hover,
.battle-card:hover .btn-toggle-battle {
    color: #ffffff;
    border-color: #555555;
    background: #1a1a1a;
}

@media (max-width: 650px) {
    .battle-summary-row {
        grid-template-columns: 1fr;
        gap: 12px;
        text-align: center;
    }
    .b-side-left, .b-side-right {
        justify-content: center;
    }
    .b-opp-info {
        align-items: center;
    }
    .b-opp-profile-btn {
        align-items: center;
        text-align: center;
    }
}

/* Expandable Deck Comparison Pane */
.battle-details-pane {
    padding: 16px 20px 20px 20px;
    background: #020408;
    border-top: 1px solid #141b29;
    animation: fadeIn 0.2s ease-out;
}

.battle-decks-comparison {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: center;
}

.b-vs-divider {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 900;
    color: #334155;
    text-align: center;
}

.b-deck-column {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.b-deck-col-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2px;
}

.b-deck-user {
    font-size: 0.85rem;
    font-weight: 800;
    color: #ffffff;
}

.b-trophy-diff {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
}

.b-trophy-diff.pos {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.b-trophy-diff.neg {
    background: #141b29;
    color: #64748b;
}

.b-deck-tag.mono {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: #64748b;
}

.b-deck-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.mini-card-slot {
    position: relative;
    background: #060910;
    border: 1px solid #141b29;
    border-radius: 8px;
    padding: 6px 4px 4px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, border-color 0.15s ease;
}

.mini-card-slot:hover {
    transform: scale(1.06);
    border-color: #ffffff;
    z-index: 5;
}

.mini-card-slot img {
    width: 100%;
    max-height: 58px;
    object-fit: contain;
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.7));
}

.mini-card-lvl {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 800;
    color: #cbd5e1;
    margin-top: 3px;
    line-height: 1;
}

.b-deck-empty {
    font-size: 0.8rem;
    color: #64748b;
    padding: 10px 0;
}

@media (max-width: 800px) {
    .battle-decks-comparison {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    
    .b-vs-divider {
        display: none;
    }

    .b-summary-row {
        padding: 12px 14px;
    }
}

/* ========================================================
   Dedicated Clan View Page Styling
   ======================================================== */
.clan-page {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
    animation: fadeIn 0.25s ease-out;
}

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

.page-nav-bar {
    display: flex;
    align-items: center;
    margin-bottom: 4px;
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(14, 22, 42, 0.85);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #fff;
    padding: 8px 18px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-back:hover {
    background: rgba(37, 99, 235, 0.25);
    border-color: var(--electric-blue);
    transform: translateX(-3px);
}

.back-arrow {
    font-size: 1.1rem;
    color: var(--electric-blue);
}

.clan-hero-banner {
    padding: 28px 32px;
    background: linear-gradient(135deg, rgba(17, 26, 46, 0.95) 0%, rgba(10, 15, 29, 0.98) 100%);
    border: 1px solid rgba(56, 189, 248, 0.25);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}

.clan-hero-top {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 14px;
}

.clan-emblem-wrap {
    font-size: 3rem;
    filter: drop-shadow(0 0 16px rgba(56, 189, 248, 0.5));
}

.clan-titles {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.clan-title-badge-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.clan-title-badge-row h2 {
    font-size: 2rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.5px;
}

.clan-type-tag {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--electric-blue);
    background: rgba(56, 189, 248, 0.15);
    border: 1px solid rgba(56, 189, 248, 0.3);
    padding: 3px 12px;
    border-radius: 20px;
    text-transform: capitalize;
}

.clan-description {
    font-size: 0.95rem;
    color: var(--text-blue-light);
    line-height: 1.5;
    margin-bottom: 22px;
    max-width: 900px;
}

.clan-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

@media (max-width: 768px) {
    .clan-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .clan-title-badge-row h2 { font-size: 1.5rem; }
    .clan-hero-banner { padding: 18px 16px; }
}

.clan-stat-tile {
    background: rgba(14, 22, 42, 0.85);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.c-stat-lbl {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
}

.c-stat-val {
    font-size: 1.35rem;
    font-weight: 800;
    color: #fff;
}

/* Roster Member Cards List */
.clan-roster-section {
    display: flex;
    flex-direction: column;
}

.clan-roster-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}

.member-roster-card {
    background: rgba(14, 22, 42, 0.75);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.member-roster-card:hover {
    border-color: var(--electric-blue);
    background: rgba(23, 37, 68, 0.9);
    box-shadow: 0 6px 20px rgba(56, 189, 248, 0.15);
    transform: translateY(-1px);
}

.m-card-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    min-width: 0;
}

.m-rank-badge {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    flex-shrink: 0;
}

.m-rank-badge.top-1 { background: rgba(245, 158, 11, 0.25); color: var(--gold); border: 1px solid var(--gold); }
.m-rank-badge.top-2 { background: rgba(203, 213, 225, 0.25); color: #fff; border: 1px solid #cbd5e1; }
.m-rank-badge.top-3 { background: rgba(180, 83, 9, 0.25); color: #f97316; border: 1px solid #f97316; }

.m-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.m-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.m-name {
    font-size: 1.05rem;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.m-role-badge {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(56, 189, 248, 0.12);
    color: var(--electric-blue);
}

.m-role-badge.leader {
    background: rgba(245, 158, 11, 0.2);
    color: var(--gold);
    border: 1px solid rgba(245, 158, 11, 0.35);
}

.m-role-badge.coleader {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

.m-tag {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
}

.m-card-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}

.m-stats {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.m-trophies {
    font-size: 1rem;
    font-weight: 800;
    color: var(--gold);
}

.m-donations {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.btn-inspect {
    background: linear-gradient(135deg, var(--royal-blue) 0%, var(--electric-blue) 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 0.82rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    transition: all 0.2s ease;
}

.btn-inspect:hover {
    box-shadow: 0 6px 18px rgba(56, 189, 248, 0.5);
    transform: scale(1.03);
}

.state-pane { text-align: center; padding: 60px 0; }
.apple-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(56, 189, 248, 0.15);
    border-top-color: var(--electric-blue);
    border-radius: 50%;
    margin: 0 auto 16px;
    animation: rotate 0.8s linear infinite;
}
@keyframes rotate { to { transform: rotate(360deg); } }
#loader-message { color: var(--electric-blue); font-size: 0.95rem; font-weight: 600; }
.error-toast {
    background: rgba(244, 63, 94, 0.15);
    border: 1px solid rgba(244, 63, 94, 0.35);
    color: #fda4af;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    margin-bottom: 24px;
    font-size: 0.92rem;
    font-weight: 600;
}

/* ========================================================
   Dedicated iPhone & Mobile Responsive Optimizations
   (iPhone SE, 11/12/13/14/15/16 Pro, Pro Max & notch safe-area)
   ======================================================== */

@media (max-width: 768px) {
    /* Navbar compact & safe area */
    .nav-bar {
        padding: 12px 16px;
        padding-top: max(12px, env(safe-area-inset-top));
    }

    .nav-title {
        font-size: 1.2rem;
    }

    .header-field input {
        width: 105px;
        font-size: 0.85rem;
    }

    .submit-btn-sm {
        padding: 7px 12px;
        font-size: 0.8rem;
    }

    /* Main Container Padding */
    .main-content {
        margin: 14px auto 40px;
        padding: 0 14px;
        padding-bottom: max(30px, env(safe-area-inset-bottom));
    }

    /* Epic Hero on iPhone: Artwork da solo, tutto il resto (cerca) sotto */
    .epic-hero-stage {
        border-radius: 16px;
        margin-bottom: 24px;
        display: flex;
        flex-direction: column;
        background: transparent;
        border: none;
        box-shadow: none;
    }

    .hero-art-canvas {
        height: auto;
        aspect-ratio: 16 / 9;
        border-radius: 16px;
        overflow: hidden;
        border: 1px solid rgba(56, 189, 248, 0.2);
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
    }

    .hero-art-backdrop {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center center;
    }

    .hero-gradient-overlay {
        display: none;
    }

    /* Floating dock diventa un blocco naturale sotto l'immagine */
    .hero-floating-dock {
        position: static;
        transform: none;
        width: 100%;
        margin-top: 14px;
        gap: 10px;
    }

    .center-search-form {
        flex-direction: column;
        gap: 8px;
    }

    .hero-search-box {
        padding: 0 14px;
        border-radius: 12px;
        background: rgba(14, 22, 42, 0.95);
    }

    /* 16px font-size prevents iOS Safari auto-zoom on input tap */
    .hero-search-box input {
        font-size: 16px;
        padding: 13px 0;
    }

    .hero-cta-btn {
        width: 100%;
        justify-content: center;
        padding: 13px 0;
        font-size: 0.95rem;
        border-radius: 12px;
    }

    .quick-tags-strip {
        gap: 6px;
        margin-top: 2px;
    }

    .quick-lbl {
        font-size: 0.72rem;
    }

    .quick-tag-pill {
        font-size: 0.72rem;
        padding: 4px 10px;
    }

    /* Leaderboards on iPhone */
    .hub-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .col-header-bar {
        margin-bottom: 12px;
        padding-bottom: 8px;
    }

    .col-title-group h3 {
        font-size: 1.1rem;
    }

    .hub-row-item {
        padding: 10px 14px;
    }

    .hub-item-left {
        gap: 10px;
    }

    .hub-rank-badge {
        width: 24px;
        height: 24px;
        font-size: 0.8rem;
    }

    .hub-item-name {
        font-size: 0.88rem;
    }

    .hub-item-sub {
        font-size: 0.72rem;
    }

    .hub-trophy-val {
        font-size: 0.88rem;
    }

    /* Player Profile Dashboard on iPhone */
    .dashboard {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    .hero-card {
        padding: 16px 14px;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        width: 100%;
    }

    .hero-left {
        width: 100%;
        gap: 12px;
    }

    .hero-meta {
        width: calc(100% - 64px);
    }

    .king-avatar {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
        border-radius: 12px;
        flex-shrink: 0;
    }

    .name-row {
        flex-wrap: wrap;
        gap: 8px;
    }

    .name-row h2 {
        font-size: 1.35rem;
        word-break: break-word;
    }

    .tag-actions {
        flex-wrap: wrap;
        gap: 6px;
    }

    .clan-cell {
        width: 100%;
        justify-content: space-between;
        padding: 12px 14px;
    }

    .metrics-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        width: 100%;
    }

    .metric-box {
        padding: 14px 12px;
    }

    .metric-number {
        font-size: 1.3rem;
    }

    /* Deck 8 Cards into responsive 4x2 on iPhone without any overflow */
    .deck-card {
        padding: 16px 12px;
        width: 100%;
    }

    .deck-row {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
        width: 100%;
    }

    .deck-slot {
        padding: 8px 2px 6px;
        width: 100%;
    }

    .deck-img {
        width: 48px;
        height: 60px;
    }

    .deck-drop {
        width: 16px;
        height: 16px;
        font-size: 0.62rem;
        top: 3px;
        left: 3px;
    }

    .deck-name {
        font-size: 0.65rem;
        max-width: 95%;
    }

    .deck-lvl {
        font-size: 0.62rem;
    }

    /* Upcoming Chests: grid invece di scroll orizzontale su mobile */
    .content-split {
        grid-template-columns: 1fr;
        gap: 16px;
        width: 100%;
    }

    .split-panel {
        padding: 16px 14px;
        width: 100%;
    }

    .chest-track {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
        overflow-x: visible;
        padding-bottom: 0;
        width: 100%;
    }

    .chest-pill {
        flex: none;
        width: 100%;
        padding: 8px 4px;
    }

    .c-ico {
        font-size: 1.3rem;
        margin-bottom: 2px;
    }

    .c-index {
        font-size: 0.75rem;
    }

    .c-title {
        font-size: 0.65rem;
    }

    /* Recent Battles */
    .battle-list {
        width: 100%;
        gap: 8px;
    }

    .battle-row {
        padding: 10px 12px;
        font-size: 0.8rem;
        width: 100%;
    }

    .b-start {
        gap: 8px;
    }

    .b-score-txt {
        font-size: 0.95rem;
    }

    .b-opp-txt {
        max-width: 110px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* Clan Modal on iPhone: Native Mobile Sheet & Card-based Roster */
    .modal-backdrop {
        padding: 0;
        align-items: flex-end;
    }

    .modal-surface {
        max-height: 88vh;
        height: 88vh;
        border-radius: 20px 20px 0 0;
        width: 100%;
        max-width: 100%;
        border-bottom: none;
    }

    .modal-head {
        padding: 16px 18px 12px;
    }

    .modal-head h3 {
        font-size: 1.25rem;
    }

    .modal-bio {
        font-size: 0.78rem;
    }

    .modal-close {
        font-size: 1.6rem;
        padding: 6px;
    }

    .modal-meta-bar {
        padding: 10px 16px;
        gap: 12px;
        font-size: 0.75rem;
        display: flex;
        justify-content: space-between;
    }

    /* Mobile member roster card layout */
    .member-roster-card {
        padding: 12px 14px;
        gap: 12px;
    }

    .m-card-left {
        gap: 12px;
    }

    .m-name {
        font-size: 0.95rem;
        max-width: 140px;
    }

    .m-card-right {
        gap: 12px;
    }

    .m-trophies {
        font-size: 0.9rem;
    }

    .btn-inspect {
        padding: 6px 12px;
        font-size: 0.78rem;
    }
}

/* ==========================================================================
   Navigation Links & Boosting Button
   ========================================================================== */
.nav-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #000000;
    color: #ffffff;
    border: 1px solid #334155;
    padding: 8px 18px;
    border-radius: 9999px;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link-btn .bolt-icon {
    font-size: 1rem;
    color: #ffffff;
}

.nav-link-btn:hover {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.25);
}

.nav-link-btn:hover .bolt-icon {
    color: #000000;
}

/* ==========================================================================
   Boosting Price List Page Styles (Full Black & White Minimalist)
   ========================================================================== */
.boosting-page {
    width: 100%;
    max-width: 900px;
    margin: 0 auto 60px auto;
    padding: 0 16px;
    animation: fadeIn 0.3s ease-out;
}

.price-list-showcase {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
    width: 100%;
}

.price-list-frame {
    width: 100%;
    max-width: 650px;
    background: #000000;
    border: 1px solid #1e293b;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
}

.price-list-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

.price-list-action {
    display: flex;
    justify-content: center;
    width: 100%;
}

.boosting-badge {
    display: inline-block;
    padding: 5px 14px;
    background: #0a0a0a;
    border: 1px solid #334155;
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    border-radius: 9999px;
    margin-bottom: 14px;
}

.boosting-title {
    font-family: var(--font-display);
    font-size: 2.3rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: #ffffff;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.boosting-subtitle {
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: 2.5px;
    color: #8892b0;
    text-transform: uppercase;
}

.boosting-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.boost-card {
    background: #07090e;
    border: 1px solid #1c2433;
    border-radius: var(--radius-md);
    padding: 22px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.boost-card:hover {
    transform: translateY(-4px);
    border-color: #ffffff;
    box-shadow: 0 12px 30px rgba(255, 255, 255, 0.08);
}

.boost-card.emote-card {
    border-color: #222a38;
    background: #07090e;
}

.boost-card.emote-card:hover {
    border-color: #ffffff;
    box-shadow: 0 12px 30px rgba(255, 255, 255, 0.08);
}

.boost-card-top {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
    border-bottom: 1px solid #171d2a;
    padding-bottom: 12px;
}

.boost-num {
    font-size: 1rem;
    font-weight: 900;
    font-family: var(--font-mono);
    color: #000000;
    background: #ffffff;
    padding: 3px 8px;
    border-radius: 6px;
    border: 1px solid #ffffff;
}

.boost-card.emote-card .boost-num {
    color: #000000;
    background: #ffffff;
    border-color: #ffffff;
}

.boost-category {
    font-size: 0.92rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.5px;
}

.boost-items-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.boost-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 14px;
    background: #000000;
    border: 1px solid #19202c;
    border-radius: var(--radius-sm);
    transition: border-color 0.2s ease;
}

.boost-item:hover {
    border-color: #334155;
}

.boost-item.highlight-item {
    background: #05070c;
    border-color: #2a3447;
}

.boost-item .item-name {
    font-size: 0.92rem;
    font-weight: 600;
    color: #ffffff;
}

.boost-item .item-price {
    font-family: var(--font-mono);
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffffff;
}

.boost-card.emote-card .boost-item .item-price {
    color: #ffffff;
    text-shadow: none;
}

/* Call to action card - Pure B&W */
.boost-cta-box {
    background: #07090e;
    border: 1px solid #222a38;
    border-radius: var(--radius-md);
    padding: 28px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
}

.boost-cta-info h3 {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 6px;
}

.boost-cta-info p {
    font-size: 0.9rem;
    color: #8892b0;
}

.boost-ticket-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #ffffff;
    color: #000000;
    font-weight: 900;
    font-size: 0.92rem;
    letter-spacing: 0.5px;
    text-decoration: none;
    padding: 14px 28px;
    border-radius: 9999px;
    transition: all 0.25s ease;
    border: 1px solid #ffffff;
}

.boost-ticket-btn:hover {
    background: #000000;
    color: #ffffff;
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.35);
}

.boost-ticket-btn .ticket-arrow {
    font-size: 1.2rem;
    font-weight: 900;
}

/* ==========================================================================
   Footer Component
   ========================================================================== */
.site-footer {
    width: 100%;
    background: #020408;
    border-top: 1px solid #0f172a;
    padding: 34px 20px 28px 20px;
    margin-top: auto;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 18px;
}

.footer-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-logo {
    font-size: 1.2rem;
}

.footer-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffffff;
}

.footer-title strong {
    color: var(--electric-blue);
}

.footer-tagline {
    font-size: 0.85rem;
    color: #64748b;
    max-width: 480px;
}

.footer-links-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
}

.footer-link {
    color: #94a3b8;
    font-size: 0.82rem;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: #ffffff;
}

.footer-dot {
    color: #334155;
    font-size: 0.75rem;
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding-top: 16px;
    border-top: 1px solid #0f172a;
    width: 100%;
}

.footer-copy {
    font-size: 0.75rem;
    color: #475569;
    max-width: 600px;
    line-height: 1.4;
}

.footer-developer {
    font-size: 0.78rem;
    color: #64748b;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.dev-credit-link {
    color: #94a3b8;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.dev-credit-link:hover {
    color: #ffffff;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
}

/* Responsive Footer & Boosting */
@media (max-width: 768px) {
    .boosting-hero-card {
        padding: 24px 16px;
    }

    .boosting-title {
        font-size: 1.6rem;
    }

    .boosting-subtitle {
        font-size: 0.8rem;
        letter-spacing: 1.5px;
    }

    .boosting-grid {
        grid-template-columns: 1fr;
    }

    .boost-cta-box {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 20px 16px;
    }

    .boost-ticket-btn {
        justify-content: center;
        width: 100%;
    }
}

/* ==========================================================================
   Full Card Collection & Levels (Pure Dark & Minimal)
   ========================================================================== */
.collection-section {
    margin-top: 24px;
    background: #000000;
    border: 1px solid #141b29;
}

.collection-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 22px;
}

.collection-sub {
    font-size: 0.76rem;
    color: #64748b;
    font-weight: 500;
    margin-top: 2px;
}

.collection-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.card-search-input {
    background: #080b12;
    border: 1px solid #1e293b;
    color: #ffffff;
    font-size: 0.85rem;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    outline: none;
    transition: border-color 0.2s ease;
    width: 160px;
}

.card-search-input:focus {
    border-color: #ffffff;
}

.card-sort-dropdown {
    background: #080b12;
    border: 1px solid #1e293b;
    color: #ffffff;
    font-size: 0.85rem;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    outline: none;
    cursor: pointer;
}

.card-sort-dropdown option {
    background: #000000;
    color: #ffffff;
}

/* Quick Level Pills Strip */
.level-pills-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: none;
}

.level-pills-strip::-webkit-scrollbar {
    display: none;
}

.level-pill {
    background: #080b12;
    border: 1px solid #1e293b;
    color: #94a3b8;
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.level-pill:hover {
    color: #ffffff;
    border-color: #38bdf8;
}

.level-pill.active {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
    font-weight: 800;
}

/* RoyaleAPI Style Grouped Container */
.collection-groups {
    display: flex;
    flex-direction: column;
    gap: 28px;
    width: 100%;
}

.level-group-block {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 20px;
    border-bottom: 1px solid #141c2c;
}

.level-group-block:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.level-group-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 4px 2px;
}

.lvl-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.lvl-title {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.5px;
}

.lvl-max-tag {
    font-size: 0.68rem;
    font-weight: 800;
    background: #ffffff;
    color: #000000;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 0.8px;
}

.lvl-header-stats {
    font-size: 0.82rem;
    color: #64748b;
}

.lvl-stat-item strong {
    color: #ffffff;
}

/* Compact Card Grid matching RoyaleAPI */
.level-compact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(58px, 1fr));
    gap: 8px;
    width: 100%;
}

.compact-card-tile {
    position: relative;
    background: #060910;
    border: 1px solid #141c2c;
    border-radius: 8px;
    padding: 4px 2px 2px 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, border-color 0.15s ease;
    cursor: pointer;
}

.compact-card-tile:hover {
    transform: translateY(-3px) scale(1.05);
    border-color: #ffffff;
    z-index: 10;
}

.compact-card-tile img {
    width: 100%;
    height: auto;
    max-height: 72px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.7));
}

.tile-elixir-badge {
    position: absolute;
    top: 2px;
    left: 2px;
    background: rgba(0, 0, 0, 0.75);
    color: #cbd5e1;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 800;
    padding: 1px 4px;
    border-radius: 3px;
    line-height: 1;
}

.collection-empty {
    text-align: center;
    color: #64748b;
    padding: 40px 0;
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    .collection-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .collection-controls {
        width: 100%;
    }
    
    .card-search-input, .card-sort-dropdown {
        width: 100%;
    }

    .level-compact-grid {
        grid-template-columns: repeat(auto-fill, minmax(46px, 1fr));
        gap: 6px;
    }

    .compact-card-tile img {
        max-height: 58px;
    }

    .lvl-title {
        font-size: 1.1rem;
    }
}



