:root {
    --bg-dark: #050505;          /* Obsidian Black */
    --bg-card: #0c0c0c;          /* Deep Charcoal */
    --primary: #d4af37;          /* Premium Gold */
    --primary-light: #ffdf00;    /* Radiant Gold */
    --accent: #c5a021;           /* Muted Gold */
    --text-primary: #f5f5f5;     /* Arctic White */
    --text-secondary: #a0a0a0;   /* Steel Gray */
    --border: rgba(212, 175, 55, 0.15); /* Gold Silk Border */
    --glass: rgba(12, 12, 12, 0.85);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.8);
    --gold-gradient: linear-gradient(135deg, #d4af37 0%, #ffdf00 50%, #c5a021 100%);
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Outfit', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.5;
    background-image: 
        radial-gradient(circle at 10% 10%, rgba(212, 175, 55, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 90% 90%, rgba(212, 175, 55, 0.05) 0%, transparent 40%);
}

/* Layout Grid */
.app-container {
    display: grid;
    grid-template-columns: 280px 1fr 320px;
    grid-template-rows: auto 1fr;
    height: 100vh;
    overflow: hidden;
}

@media (max-width: 1200px) {
    .app-container {
        grid-template-columns: 240px 1fr;
    }
    .right-sidebar {
        display: none;
    }
}

@media (max-width: 900px) {
    .app-container {
        grid-template-columns: 1fr;
    }
    .left-sidebar {
        display: none;
    }
}

/* Header */
.main-header {
    grid-column: 1 / -1;
    background: #000;
    border-bottom: 1px solid var(--border);
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
}

.logo {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-family: var(--font-heading);
    font-weight: 900;
    font-size: 2.2rem;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #D4AF37 0%, #FFF3B0 40%, #FFF3B0 60%, #D4AF37 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
    filter: drop-shadow(0 4px 12px rgba(212, 175, 55, 0.3));
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    animation: textShine 4s linear infinite;
}

.logo:hover {
    transform: scale(1.02);
    filter: drop-shadow(0 8px 25px rgba(212, 175, 55, 0.6));
}

.logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.8));
}

.logo:hover .logo-icon {
    transform: rotate(15deg) scale(1.15);
}

@keyframes textShine {
    to {
        background-position: 200% center;
    }
}

.nav-sports {
    display: flex;
    gap: 1.5rem;
}

.nav-item {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    transition: var(--transition);
    position: relative;
}

.nav-item:hover, .nav-item.active {
    color: var(--primary);
}

.nav-item.active {
    color: var(--primary);
    border-bottom: 3px solid var(--primary);
}

/* Language Switcher */
.lang-switch {
    display: flex;
    gap: 0.5rem;
    margin-left: 2rem;
}

.lang-btn {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: var(--font-main);
}

.lang-btn:hover {
    border-color: var(--primary);
    color: var(--text-primary);
}

.lang-btn.active {
    background: var(--primary) !important;
    border-color: var(--primary) !important;
    color: var(--bg-dark) !important;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

/* Sidebar Styling */
.sidebar {
    background: #080808;
    border-right: 1px solid var(--border);
    padding: 1.5rem;
    overflow-y: auto;
}

.sidebar-title {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary);
    margin-bottom: 1.25rem;
    font-weight: 700;
    opacity: 0.8;
}

.league-list {
    list-style: none;
}

.league-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.league-item:hover {
    background: var(--hover);
    color: var(--text-primary);
}

.flag-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.flag-icon.sm {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
}

.flag-icon.xs {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
}

.group-badge {
    width: 22px;
    height: 22px;
    background: #DC2626; /* Consistent Vibrant Red */
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.75rem;
    border-radius: 4px;
    margin-right: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.league-item.favorite {
    color: var(--text-primary);
}

/* Main Content area */
.main-content {
    padding: 1.5rem;
    overflow-y: auto;
    background: var(--bg-dark);
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.current-date {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary);
    font-weight: 700;
    opacity: 0.8;
}

.view-tabs, .view-mode-tabs {
    display: flex;
    background: var(--surface-dark);
    padding: 0.25rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    gap: 0.25rem;
}

.tab-btn, .mode-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 0.6rem 1.25rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    outline: none !important;
}

.tab-btn:hover, .mode-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.tab-btn.active, .mode-btn.active {
    background: var(--primary) !important;
    color: #000 !important;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
}

.date-divider {
    padding: 1.5rem 0 1rem 0;
    margin-top: 1rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    position: relative;
}

.date-divider span:first-child {
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary);
    white-space: nowrap;
}

.upcoming-badge {
    font-size: 0.6rem;
    background: #00ff88;
    color: black;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-left: 1rem;
    box-shadow: 0 0 12px rgba(0,255,136,0.3);
}

.date-divider::after {
    content: '';
    height: 1px;
    flex: 1;
    background: linear-gradient(to right, var(--border), transparent);
}

/* Match Cards - Universal Adaptive Layout */
.match-card {
    background: var(--surface-light);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    display: grid;
    grid-template-columns: 80px 1fr 60px;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.match-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.match-status {
    display: flex;
    flex-direction: column;
    gap: 4px;
    border-right: 1px solid var(--border);
    padding-right: 1.5rem;
}

.m-date {
    font-size: 0.65rem;
    color: var(--text-secondary);
    font-weight: 800;
    text-transform: uppercase;
}

.m-time {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

.m-time.live {
    color: #ff7e00;
}

.match-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex: 1;
}

.team-v-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.team-v-item.away {
    justify-content: flex-end;
    text-align: right;
}

.team-v-item .flag-icon {
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255,255,255,0.1);
}

.team-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.match-score-v {
    background: rgba(255,255,255,0.05);
    padding: 0.5rem 1.25rem;
    border-radius: 8px;
    min-width: 100px;
    text-align: center;
}

.s-val {
    font-size: 1.1rem;
    font-weight: 900;
    color: var(--primary);
    letter-spacing: 1px;
}

.match-action {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

/* Match Cards */
.match-group {
    margin-bottom: 2rem;
}

.competition-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: var(--surface-dark);
    border: 1px solid var(--border);
    border-radius: 12px 12px 0 0;
    font-weight: 700;
}

.match-list {
    background: rgba(18, 18, 18, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 12px 12px;
}

.match-card {
    display: grid;
    grid-template-columns: 80px 1fr 100px 1fr 50px;
    align-items: center;
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: var(--transition);
}

.match-card:last-child {
    border-bottom: none;
}

.match-card:hover {
    background: rgba(255, 255, 255, 0.03);
    transform: scale(1.005);
}

.match-time {
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 700;
    text-align: center;
    background: var(--primary-glow);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    width: fit-content;
    margin: 0 auto;
}

.match-time.live {
    background: var(--accent-green-glow);
    color: var(--accent-green);
    animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
    0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.team-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.team-name {
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: -0.01em;
}

.score-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 800;
    font-family: var(--font-heading);
    background: rgba(0, 0, 0, 0.2);
    padding: 0.5rem;
    border-radius: 8px;
}

.score {
    width: 35px;
    text-align: center;
}

.featured-match {
    background: linear-gradient(135deg, var(--surface-light) 0%, var(--bg-dark) 100%);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    margin-top: 0.5rem;
    position: relative;
    overflow: hidden;
}

.featured-match::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 91, 1, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.score.new {
    color: var(--primary);
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: var(--surface-dark);
    width: 90%;
    max-width: 600px;
    border-radius: 20px;
    border: 1px solid var(--border);
    position: relative;
    padding: 2rem;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    animation: modalIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.modal-tab {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 1rem 1.5rem;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    position: relative;
    transition: var(--transition);
}

.modal-tab:hover {
    color: var(--text-primary);
}

.modal-tab.active {
    color: var(--primary);
}

.modal-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary);
}

.match-fav {
    display: flex;
    justify-content: center;
    color: var(--text-secondary);
}

.match-fav.active {
    color: var(--primary);
}

/* Scrollbar Styles */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* Close Button Styling */
.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border);
    color: var(--text-primary);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 100;
    transition: var(--transition);
    backdrop-filter: blur(8px);
}

.league-tag.active {
    background: var(--gold-gradient);
    color: #000;
    border-color: transparent;
    font-weight: 800;
}

.close-modal:hover {
    background: var(--primary);
    color: black;
    transform: rotate(90deg);
}

.close-modal i {
    width: 20px;
    height: 20px;
}

/* Tactical Pitch View */
.pitch-container {
    background: #1a2a1a;
    width: 100%;
    max-width: 500px;
    height: 700px;
    margin: 1.5rem auto;
    border: 2px solid var(--primary);
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    padding: 20px;
}

.pitch-line {
    position: absolute;
    border: 1px solid rgba(212, 175, 55, 0.4);
}

.center-circle {
    width: 100px;
    height: 100px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.center-line {
    width: 100%;
    height: 1px;
    top: 50%;
    left: 0;
    position: absolute;
    border-top: 1px solid rgba(212, 175, 55, 0.4);
}

.penalty-area-top {
    width: 60%;
    height: 12%;
    top: 0;
    left: 20%;
    position: absolute;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-top: none;
}

.penalty-area-bottom {
    width: 60%;
    height: 12%;
    bottom: 0;
    left: 20%;
    position: absolute;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-bottom: none;
}

.player-node {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    width: 80px;
    z-index: 5;
    transform: translate(-50%, -50%);
}

.player-circle {
    width: 24px;
    height: 24px;
    background: var(--primary);
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 800;
    border: 1px solid #fff;
}

.player-name {
    font-size: 0.65rem;
    font-weight: 700;
    color: #fff;
    text-align: center;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    white-space: nowrap;
}

.formation-banner {
    background: #1a1a1a;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
    border: 1px solid var(--primary);
}

/* Polymarket Flow */
.market-card {
    background: #111111;
    border: 1px solid var(--primary);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    margin-top: 1rem;
}

.market-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: #000;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    transition: var(--transition);
}

.market-option:hover {
    border-color: var(--primary);
    background: #1a1a1a;
}

.market-price {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary);
}

.market-label {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Market History Chart */
.chart-container {
    width: 100%;
    height: 300px;
    margin-top: 2rem;
    position: relative;
    padding-bottom: 30px;
}

.chart-svg {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.chart-line {
    fill: none;
    stroke: #ffdf00; /* Silk Gold */
    stroke-width: 4;
    stroke-linecap: round;
    filter: drop-shadow(0 0 12px rgba(255, 223, 0, 0.5));
}

.chart-axis {
    stroke: rgba(255,255,255,0.1);
    stroke-width: 1;
}

.chart-label {
    font-size: 0.65rem;
    fill: var(--text-secondary);
    font-weight: 700;
}

.market-sum.match-badge {
    background: var(--gold-gradient);
    color: #000;
    padding: 0.3rem 0.8rem;
    border-radius: 6px;
    font-size: 0.6rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.chart-line-tie {
    fill: none;
    stroke: #00ff88; /* Emerald Green */
    stroke-width: 3;
    stroke-linecap: round;
    filter: drop-shadow(0 0 8px rgba(0, 255, 136, 0.4));
}

.chart-legend {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 2px;
}

.chart-tooltip {
    position: absolute;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(8px);
    border: 1px solid var(--primary);
    padding: 0.6rem 0.8rem;
    border-radius: 6px;
    pointer-events: none;
    display: none;
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0,0,0,0.8);
}

.chart-tooltip-val {
    font-size: 1rem;
    font-weight: 800;
    color: #00d1ff;
    display: block;
}

.chart-tooltip-day {
    font-size: 0.6rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 800;
    margin-bottom: 2px;
}

.chart-point {
    fill: transparent;
    cursor: crosshair;
    transition: all 0.2s;
}

.chart-point:hover {
    fill: rgba(0, 209, 255, 0.8);
    r: 4;
}

.chart-line-away {
    fill: none;
    stroke: #ff7e00; /* Sunset Orange */
    stroke-width: 3;
    stroke-linecap: round;
    filter: drop-shadow(0 0 8px rgba(255, 126, 0, 0.4));
}

/* Forecast Modules */
.forecast-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

.forecast-card {
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
}

.google-forecast {
    background: rgba(66, 133, 244, 0.05);
    border: 1px solid rgba(66, 133, 244, 0.2);
}

.ai-forecast {
    background: rgba(160, 32, 240, 0.05);
    border: 1px solid rgba(160, 32, 240, 0.2);
    box-shadow: 0 0 20px rgba(160, 32, 240, 0.1);
}

.forecast-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.forecast-reason {
    display: flex;
    gap: 0.75rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.reason-bullet {
    color: #a020f0;
    font-weight: 900;
}

/* ============================================================
   MOBILE RESPONSIVE OVERHAUL (768px & BELOW)
   ============================================================ */
@media (max-width: 768px) {
    .app-container {
        display: flex;
        flex-direction: column;
        height: auto;
        overflow-x: hidden;
    }

    .sidebar {
        width: 100% !important;
        height: auto;
        position: static;
        border: none;
        padding: 1rem;
    }

    .left-sidebar {
        order: 2; /* Move standings below matches */
    }

    .main-content {
        order: 1; /* Matches stay at top */
        padding: 1rem;
        width: 100%;
        overflow-x: hidden;
    }

    /* Modal Mobile Fixes */
    .modal-content {
        width: 95% !important;
        max-width: 95% !important;
        height: 90vh !important;
        margin: 5vh auto !important;
        padding: 1.5rem !important;
        position: relative !important;
        left: 0 !important;
        top: 0 !important;
        transform: none !important;
    }

    .close-modal {
        position: absolute !important;
        right: 15px !important;
        top: 15px !important;
        z-index: 1001;
        background: rgba(0,0,0,0.5);
        padding: 5px;
        border-radius: 50%;
    }

    .modal-tabs {
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 5px;
        scrollbar-width: none;
    }

    .modal-tabs::-webkit-scrollbar {
        display: none;
    }

    .modal-tab {
        padding: 0.8rem 1rem;
        font-size: 0.75rem;
        white-space: nowrap;
    }

    /* Chart & Pitch Scaling */
    .pitch-container {
        transform: scale(0.8);
        transform-origin: top center;
        margin-bottom: -50px; /* Offset scale height */
    }

    .charts-container {
        overflow-x: auto;
    }

    .forecast-grid {
        grid-template-columns: 1fr; /* Stack Google/AI forecasts */
    }

    /* Header Mobile Adjustments */
    .main-header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
        height: auto;
    }

    .content-header {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 1rem !important;
        padding: 0 1rem 1rem 1rem !important;
    }

    .view-tabs, .view-mode-tabs {
        width: 100% !important;
        justify-content: center !important;
    }

    .tab-btn, .mode-btn {
        flex: 1;
        text-align: center;
        padding: 0.6rem 0.5rem !important;
        font-size: 0.75rem !important;
    }

    .nav-links {
        width: 100%;
        justify-content: space-around;
    }

    .market-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .market-prices {
        width: 100%;
        justify-content: space-between;
    }

    .market-price {
        font-size: 1.4rem !important;
    }

    /* ============================================================
       UNIVERSAL ADAPTIVE OVERRIDES (MOBILE)
       ============================================================ */
    .match-card {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem !important;
        padding: 1.5rem !important;
    }

    .match-status {
        border-right: none !important;
        border-bottom: 1px solid var(--border);
        padding-right: 0 !important;
        padding-bottom: 0.75rem !important;
        width: 100% !important;
    }

    .match-main {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 1.25rem !important;
    }

    /* Predictions Tab Fix v2 */
    .market-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 1.5rem !important;
        margin-bottom: 2rem !important;
        padding-top: 1rem !important;
    }

    .market-prices {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 1.5rem !important;
        width: 100% !important;
    }

    .market-price-item {
        min-width: auto !important;
    }

    .market-price-val {
        font-size: 1.4rem !important;
    }

    .market-trend {
        border-left: none !important;
        border-top: 1px solid var(--border);
        padding-left: 0 !important;
        padding-top: 1.25rem !important;
        width: 100% !important;
        text-align: left !important;
    }

    .trend-indicator-v2 {
        font-size: 0.8rem !important;
        background: rgba(255,223,0,0.05);
        padding: 0.5rem;
        border-radius: 6px;
        display: inline-block;
    }

    .chart-container {
        padding: 0 0.5rem !important;
        width: 100% !important;
    }

    svg.chart-svg {
        height: 140px !important;
    }

    /* Modal Content Polish */
    .modal-body {
        padding: 1.25rem !important;
    }

    /* Info Tab Fix */
    .info-row {
        flex-direction: column !important;
        gap: 0.25rem !important;
        align-items: flex-start !important;
        margin-bottom: 0.5rem !important;
    }

    .forecast-grid {
        gap: 1rem !important;
    }

    .forecast-card {
        padding: 1rem !important;
    }

    .forecast-reason {
        font-size: 0.75rem !important;
    }

    .team-v-item {
        justify-content: flex-start !important;
        text-align: left !important;
        width: 100% !important;
        gap: 1.25rem !important;
    }

    .team-v-item.away {
        flex-direction: row !important; /* Flag always on left for mobile list */
    }

    .team-name {
        font-size: 1.2rem !important; /* Large, readable names */
        white-space: nowrap !important;
    }

    /* CRITICAL: NO RESIZING FLAGS */
    .flag-icon {
    }

    .match-score-v {
        width: 100% !important;
        background: rgba(255,255,255,0.03) !important;
        padding: 0.5rem !important;
        text-align: center !important;
    }

    /* Standings Mobile Grid & Overflow Fix */
    .standings-container {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 0 0 12px 12px;
    }

    .standings-row {
        grid-template-columns: 25px 32px 120px 25px 25px 25px 35px !important;
        gap: 0.5rem !important;
        padding: 0.75rem 0.5rem !important;
        width: max-content;
        min-width: 100%;
    }

    .standings-row .flag-icon {
        width: 32px !important;
        height: 32px !important;
        min-width: 32px !important;
    }

    .standings-row div[style*="font-weight: 700; font-size: 0.9rem"] {
        font-size: 0.8rem !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

@media (max-width: 480px) {
    .pitch-container {
        transform: scale(0.65);
        margin-bottom: -100px;
    }
    
    .flag-icon {
        width: 42px !important;
        height: 42px !important;
    }

    /* Standings Mobile Grid Fix */
    .standings-row {
        grid-template-columns: 25px 32px 1fr 25px 25px 25px 35px !important;
        gap: 0.4rem !important;
        padding: 0.75rem 0.4rem !important;
    }

    .standings-row .flag-icon {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
    }

    .standings-row div[style*="font-weight: 700; font-size: 0.9rem"] {
        font-size: 0.75rem !important;
    }
}

/* Venue Explorer Styles */
.venue-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
}

.venue-card {
    background: #111111;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.venue-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.5);
}

.venue-image {
    height: 200px;
    width: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: #000; /* Fallback */
    position: relative;
}

.venue-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.4), transparent, rgba(0,0,0,0.8));
}

.venue-capacity {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(4px);
    border: 1px solid var(--primary);
    color: var(--primary);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.venue-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.venue-city {
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.venue-name-text {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.venue-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: auto;
}

.venue-btn {
    padding: 0.75rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 800;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.venue-btn-primary {
    background: var(--gold-gradient);
    color: #000;
}

.venue-btn-primary:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
}

.venue-btn-secondary {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    color: var(--text-primary);
}

.venue-btn-secondary:hover {
    background: rgba(255,255,255,0.08);
    border-color: var(--primary);
}

@media (max-width: 768px) {
    .venue-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 600px) {
    .main-header {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        padding: 1.25rem 1rem;
    }

    .nav-sports {
        width: 100%;
        justify-content: center;
        gap: 1rem 1.5rem;
        flex-wrap: wrap;
    }

    .lang-switch {
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }

    .logo {
        font-size: 1.8rem;
    }
}

/* Live Sync Pulse Dot */
.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #00ff88;
    border-radius: 50%;
    box-shadow: 0 0 0 rgba(0, 255, 136, 0.4);
    animation: pulse-sync 2s infinite;
}

@keyframes pulse-sync {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 255, 136, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(0, 255, 136, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(0, 255, 136, 0);
    }
}
