﻿/* ============================================================
   20WICKT / BETHUB — MOBILE RESPONSIVE STYLES
   Dark Navy Theme (20wickets.com inspired)
   ============================================================
   Breakpoints:
     992px  Tablet / small desktop
     768px  Mobile landscape / large phone
     576px  Mobile portrait
   ============================================================ */

/* ── 1. GLOBAL TOUCH IMPROVEMENTS ── */
* {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

body {
    overflow-x: hidden;
}

/* ── 2. HEADER (Mobile) ── */
@media (max-width: 992px) {
    .main-header {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        padding: 8px 12px;
        gap: 6px;
        min-height: unset;
        background: #1a2c38 !important;
        color: #fff;
    }

    /* Logo stays left */
    .logo {
        flex: 0 0 auto;
        display: flex !important;
        flex-direction: row !important;
        align-items: center;
        gap: 8px;
    }

    .logo h1 { font-size: 18px; margin-bottom: 0; color: #ffc107; }
    .logo .tagline { display: none !important; }

    /* Header-right pushes to the right */
    .header-right {
        flex: 1;
        display: flex !important;
        flex-direction: row !important;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
        flex-wrap: nowrap;
    }

    .search-bar { display: none !important; }
    .time-display { display: none !important; }
    #last-sync-time { display: none !important; }

    /* LIVE badge stays visible */
    .header-status-box { display: flex; align-items: center; }
    .header-live-btn { font-size: 11px; padding: 3px 10px; }

    /* Logged-out: just login button */
    .btn-login { font-size: 12px; padding: 6px 14px; background: #dc3545; color: #fff; }

    /* Logged-in: user info compact row */
    .user-info {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-end !important;
        background: transparent !important;
        border: none !important;
        padding: 0 !important;
        font-size: 11px;
        gap: 1px;
        color: #fff;
    }

    .user-info > span { font-size: 10px; opacity: 0.85; }

    .balance-info {
        display: flex !important;
        flex-direction: column !important;
        gap: 1px !important;
        font-size: 10px;
        text-align: right;
        line-height: 1.4;
    }

    /* Hide action buttons — use bottom nav instead */
    .action-buttons { display: none !important; }

    /* FP Header overrides */
    .fp-header-inner {
        padding: 0 10px;
        height: 50px;
        gap: 8px;
    }

    .fp-logo-text { font-size: 18px; }

    /* Hide search bar on mobile, keep icon */
    .fp-search-bar { display: none !important; }

    /* Compact user info — 20wickets style: PTI + Exposure stacked */
    .fp-user-info {
        flex: 1;
        display: flex !important;
        flex-direction: row !important;
        align-items: center;
        justify-content: center;
        gap: 12px;
        background: transparent !important;
        border: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .fp-balance-block,
    .fp-exposure-block {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0;
    }

    .fp-balance-label {
        font-size: 9px;
        color: #b0bec5;
        text-transform: uppercase;
        letter-spacing: 0.3px;
    }

    .fp-balance-value {
        font-size: 13px;
        font-weight: 700;
        color: #fff;
    }

    .fp-exposure-label {
        font-size: 9px;
        color: #b0bec5;
        text-transform: uppercase;
        letter-spacing: 0.3px;
    }

    .fp-exposure-value {
        font-size: 13px;
        font-weight: 700;
        color: #dc3545;
    }

    /* Bets badge — style logout button as a compact bets icon */
    .fp-header-actions {
        display: flex !important;
        align-items: center;
        gap: 4px !important;
    }

    .fp-header-actions .fp-btn span { display: none; }
    .fp-header-actions .fp-btn {
        padding: 6px 8px;
        font-size: 14px;
        border-radius: 4px;
    }

    /* Bets button styling */
    .fp-btn-deposit {
        background: #1a5276 !important;
        color: #ffc107 !important;
        font-size: 11px !important;
        display: inline-flex;
        align-items: center;
        gap: 4px;
        padding: 4px 10px !important;
        border-radius: 4px;
    }
    .fp-btn-deposit::before {
        content: 'Bets';
        font-size: 10px;
        font-weight: 700;
        margin-right: 2px;
    }

    .fp-btn-withdraw {
        background: transparent !important;
        color: #8899a6 !important;
        padding: 4px 6px !important;
    }

    .fp-btn-logout {
        background: transparent !important;
        color: #8899a6 !important;
        padding: 4px 6px !important;
    }

    /* Settings gear icon area */
    .fp-settings-gear,
    .fp-search-toggle {
        color: #8899a6;
        font-size: 16px;
        padding: 4px;
        cursor: pointer;
        transition: color 0.2s;
    }

    .fp-settings-gear:hover,
    .fp-search-toggle:hover {
        color: #fff;
    }

    /* Inline login compact */
    .fp-login-input { width: 90px; padding: 6px 8px; font-size: 11px; }
    .fp-btn-login-submit { padding: 6px 12px; font-size: 11px; }

    /* FP Nav bar */
    .fp-nav-item a { padding: 8px 10px; font-size: 11px; }
}

@media (max-width: 576px) {
    .main-header { padding: 6px 10px; }

    .logo h1 { font-size: 16px; }

    .fp-header-inner { gap: 4px; height: 46px; }
    .fp-logo-text { font-size: 15px; }

    /* On very small screens, keep exposure but compact */
    .fp-exposure-block { display: flex !important; }
    .fp-balance-value { font-size: 12px; }
    .fp-exposure-value { font-size: 12px; }
    .fp-balance-label, .fp-exposure-label { font-size: 8px; }

    /* Bets button more compact */
    .fp-btn-deposit { padding: 3px 8px !important; font-size: 10px !important; }
    .fp-btn-deposit::before { font-size: 9px; }

    /* Inline login even more compact */
    .fp-login-input { width: 80px; padding: 5px 6px; font-size: 11px; }
    .fp-btn-login-submit { padding: 5px 10px; font-size: 11px; }

    /* Nav items tighter spacing */
    .fp-nav-item a { padding: 8px 10px; font-size: 11px; }
}

/* ── 3. MOBILE QUICK LINKS BAR ── */
.mobile-quick-links,
.quick-links-mobile {
    display: none;
    background: #1a2c38;
    padding: 10px 0;
    overflow-x: auto;
    scrollbar-width: none;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.mobile-quick-links::-webkit-scrollbar,
.quick-links-mobile::-webkit-scrollbar { display: none; }

.mobile-quick-links-inner {
    display: flex;
    justify-content: space-around;
    gap: 0;
    min-width: max-content;
    padding: 0 10px;
}

.quick-links-mobile {
    justify-content: space-around;
    gap: 0;
    min-width: max-content;
    padding: 0 10px;
}

.mobile-quick-link,
.quick-links-mobile a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    color: #8899a6;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    padding: 6px 14px;
    white-space: nowrap;
    transition: color 0.2s;
}

/* Circular icon container — 20wickets style */
.mobile-quick-link i,
.quick-links-mobile a i {
    font-size: 16px;
    color: #b0bec5;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.mobile-quick-link.active,
.mobile-quick-link:hover,
.quick-links-mobile a:hover { color: #ffc107; }
.mobile-quick-link.active i,
.mobile-quick-link:hover i,
.quick-links-mobile a:hover i {
    color: #ffc107;
    background: rgba(255,193,7,0.15);
}

@media (max-width: 768px) {
    .mobile-quick-links { display: none !important; }
    .quick-links-mobile { display: none !important; }
}

/* ── 4. INDEX / HOME PAGE LAYOUT (Mobile) ── */
@media (max-width: 992px) {
    .promo-banner {
        height: 140px !important;
        border-radius: 6px;
    }
    .promo-banner-content .promo-title { font-size: 1.6rem; letter-spacing: 2px; }
    .promo-banner-content .promo-subtitle { font-size: 0.9rem; letter-spacing: 3px; }
}

@media (max-width: 576px) {
    .promo-banner { height: 100px !important; }
    .promo-banner-content .promo-title { font-size: 1.2rem; letter-spacing: 1px; }
    .promo-banner-content .promo-subtitle { font-size: 0.7rem; letter-spacing: 2px; }
}

@media (max-width: 992px) {
    .main-container {
        flex-direction: column !important;
        padding: 8px !important;
        gap: 8px !important;
    }

    .left-sidebar,
    .sidebar-left {
        width: 100% !important;
        display: none !important;
    }

    /* FP Sidebar hidden on mobile */
    .fp-sidebar { display: none !important; }

    .content-area { width: 100% !important; }

    .banners-wrapper {
        height: 160px !important;
        margin-bottom: 10px;
        border-radius: 6px;
    }

    .banner-content h2 {
        font-size: 2.2rem;
        transform: skew(-6deg);
    }

    /* Right sidebar hidden on mobile */
    .right-sidebar,
    .sidebar-right {
        display: none !important;
    }
}

@media (max-width: 576px) {
    .banners-wrapper { height: 120px !important; }
    .banner-content h2 { font-size: 1.7rem; }

    .section-header { padding: 8px 12px; }
    .section-header h3 { font-size: 14px; }

    .sport-header {
        padding: 8px 10px;
        flex-wrap: wrap;
        gap: 6px;
    }

    .filters .badge {
        padding: 3px 6px;
        font-size: 10px;
        margin-left: 3px;
    }
}

/* ── 5. MOBILE SPORTS LIST ── */
.mobile-sports-list {
    display: none;
    background: var(--bg-content, #fff);
    padding: 0;
}

.mobile-sports-list-header {
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    background: #1a5276;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.mobile-sports-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #f0f0f0;
    color: #1a7a8a;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.15s;
}

.mobile-sports-item:hover,
.mobile-sports-item:active {
    background: #f9f9f9;
}

.mobile-sports-item i {
    width: 24px;
    text-align: center;
    color: #8899a6;
    margin-right: 12px;
}

.mobile-sports-item .chevron {
    color: #bbb;
    font-size: 14px;
}

@media (max-width: 768px) {
    .mobile-sports-list { display: block; }
}

/* ── 6. MOBILE MATCH CARDS (Homepage) ── */
@media (max-width: 992px) {
    .mobile-match-cards.mobile-only {
        display: flex !important;
    }

    .mobile-match-cards {
        display: flex;
        flex-direction: column;
        gap: 10px;
        padding: 8px;
    }

    .match-card {
        background: var(--bg-content, #fff);
        border-radius: var(--radius-md, 8px);
        padding: 12px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        border: 1px solid #f0f0f0;
    }

    .match-card-top {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 10px;
        padding-bottom: 8px;
        border-bottom: 1px solid #f5f5f5;
    }

    .match-card-status {
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .live-pulse {
        color: var(--accent-red, #dc3545);
        font-weight: 800;
        font-size: 10px;
        display: flex;
        align-items: center;
        gap: 4px;
        text-transform: uppercase;
    }

    .live-pulse::before {
        content: '';
        width: 5px;
        height: 5px;
        background: var(--accent-red, #dc3545);
        border-radius: 50%;
        animation: pulse-red 1.5s infinite;
    }

    .match-card-time {
        font-size: 10px;
        color: #999;
    }

    .match-card-teams {
        display: flex;
        flex-direction: column;
        gap: 6px;
        margin-bottom: 12px;
    }

    .match-card-team {
        font-size: 14px;
        font-weight: 700;
        color: var(--text-dark, #333);
    }

    .match-card-odds {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 6px;
    }

    .mobile-odds-btn {
        height: 44px;
        border-radius: var(--radius-sm, 4px);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        font-weight: 800;
        transition: transform 0.1s;
    }

    .mobile-odds-btn:active { transform: scale(0.95); }

    .mobile-odds-btn .val { font-size: 14px; }
    .mobile-odds-btn .label { font-size: 8px; opacity: 0.6; text-transform: uppercase; }

    .mobile-odds-btn.back { background: #a8e6cf; color: var(--text-dark, #333); }
    .mobile-odds-btn.lay { background: #f5c6d0; color: var(--text-dark, #333); }
    .mobile-odds-btn.draw-col { background: #f5f5f5; color: #999; }

    .match-card-badges {
        display: flex;
        gap: 3px;
        align-items: center;
    }

    .match-card-badges .badge-bm,
    .match-card-badges .badge-f,
    .match-card-badges .badge-s {
        width: 18px;
        height: 18px;
        border-radius: 3px;
        font-size: 8px;
        font-weight: 800;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        color: #fff;
    }

    .match-card-badges .badge-bm { background: #1565c0; }
    .match-card-badges .badge-f { background: #e65100; }
    .match-card-badges .badge-s { background: #2e7d32; }
}

@media (max-width: 576px) {
    /* Odds table on index page - Switch to Cards on mobile */
    .odds-table-container { padding: 5px; }
    .odds-table { display: none !important; }
}

@keyframes pulse-red {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(220,53,69,0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(220,53,69,0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(220,53,69,0); }
}

/* ── 7. MATCH PAGE (Mobile) ── */
@media (max-width: 992px) {
    .match-layout {
        flex-direction: column !important;
        gap: 10px;
    }

    .left-sidebar { display: none !important; }

    .center-content {
        order: 1;
        width: 100% !important;
        border-radius: 6px;
        overflow: hidden;
    }

    .right-sidebar {
        order: 2;
        width: 100% !important;
        margin-top: 0;
        border-radius: 6px;
        overflow: hidden;
        display: block !important;
    }

    /* Right sidebar: make credit grid more compact */
    .credit-grid { grid-template-columns: 1fr 1fr 1fr !important; }
    .balance-box { grid-column: 1 / 4 !important; }

    /* Betslip tabs horizontal scroll */
    .betslip-tabs { overflow-x: auto; scrollbar-width: none; }
    .betslip-tab { padding: 9px 14px; white-space: nowrap; flex-shrink: 0; }
}

@media (max-width: 768px) {
    /* Match title bar */
    .match-title-bar {
        padding: 8px 10px;
        flex-wrap: wrap;
        gap: 6px;
    }

    .match-title-left { font-size: 12px; gap: 6px; }
    .match-title-right { font-size: 10px; }

    /* Scorecard */
    .scorecard-bar {
        font-size: 10px;
        padding: 6px 10px;
        flex-wrap: wrap;
        gap: 4px;
    }

    /* Odds header */
    .odds-header {
        height: auto;
        flex-wrap: wrap;
        padding: 6px 8px;
        gap: 4px;
    }

    .odds-header-right { display: none; }

    .match-odds-title {
        padding: 0 12px 0 8px;
        font-size: 11px;
        clip-path: none;
    }

    /* Match odds table — 20wickets style: 1 Back + 1 Lay only */
    .match-odds-table tr {
        display: flex !important;
        align-items: center !important;
        padding: 8px 10px !important;
        gap: 8px;
    }

    .match-odds-table td {
        display: block !important;
        padding: 0 !important;
        border: none !important;
    }

    .team-name {
        flex: 1;
        font-size: 13px !important;
        font-weight: 700 !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        min-width: 0;
    }

    /* Hide extra odds boxes on mobile — show only 1 Back + 1 Lay */
    .odds-boxes { gap: 4px; flex-shrink: 0; }
    .odds-boxes .odds-box-lg:nth-child(n+3) { display: none !important; }

    .odds-box-lg {
        width: 64px !important;
        height: 44px !important;
        border-radius: 4px;
    }

    .odds-box-lg .val { font-size: 14px !important; font-weight: 800 !important; }
    .odds-box-lg .size { font-size: 9px !important; opacity: 0.65; }

    /* Back/Lay column headers for mobile */
    .odds-header-mobile-cols {
        display: flex !important;
        align-items: center;
        padding: 6px 10px;
        gap: 8px;
        background: #f5f5f5;
        border-bottom: 1px solid #e0e0e0;
    }
    .odds-header-mobile-cols .col-spacer { flex: 1; }
    .odds-header-mobile-cols .col-back {
        width: 64px;
        text-align: center;
        font-size: 10px;
        font-weight: 700;
        color: #fff;
        background: #72bbef;
        padding: 3px 0;
        border-radius: 3px;
        text-transform: uppercase;
    }
    .odds-header-mobile-cols .col-lay {
        width: 64px;
        text-align: center;
        font-size: 10px;
        font-weight: 700;
        color: #fff;
        background: #faa9ba;
        padding: 3px 0;
        border-radius: 3px;
        text-transform: uppercase;
    }

    /* Matched amount in odds header */
    .matched-inr {
        font-size: 10px;
        color: #888;
        margin-left: auto;
    }
    .matched-inr span { font-weight: 700; color: #555; }

    /* Bookmaker section */
    .bookmaker-subheader-right {
        width: 160px !important;
        gap: 30px !important;
        justify-content: center !important;
    }

    .bookmaker-odds-area { width: 160px !important; }

    .bm-box { font-size: 12px !important; height: 40px; }
    .bookmaker-team-name { font-size: 12px; padding: 8px; }

    /* Fancy section — 20wickets mobile style */
    .fancy-table-header-right { width: 100px !important; }
    .fancy-table-header-right > div { width: 48px !important; font-size: 10px; }
    .fancy-odds-group { width: 100px !important; }

    /* On mobile: show only single green odds box per row */
    .fancy-box { width: 64px !important; height: 40px !important; }
    .fancy-box.fancy-no { display: none !important; }
    .fancy-box.fancy-yes {
        background: var(--odds-green, #a8e6cf);
        border-radius: 4px;
    }
    .fancy-val { font-size: 13px !important; font-weight: 800 !important; }
    .fancy-vol { font-size: 9px !important; opacity: 0.65; }
    .fancy-title { font-size: 12px; padding: 8px 10px; }
    .fancy-limits { display: none; }

    /* Market header — compact on mobile */
    .market-header-dark {
        padding: 8px 10px;
        font-size: 12px;
    }
    .market-header-dark .market-meta { font-size: 10px; }
    .market-header-dark .market-meta .matched-amount { font-size: 11px; }

    /* Fancy category tabs — pill style for mobile */
    .fancy-category-tabs {
        overflow-x: auto;
        scrollbar-width: none;
        padding: 4px 6px;
        gap: 4px;
        background: #2c3e50;
    }

    .fancy-category-tabs::-webkit-scrollbar { display: none; }

    .fancy-cat-tab {
        padding: 5px 12px;
        font-size: 11px;
        flex-shrink: 0;
        border-radius: 20px;
        background: rgba(255,255,255,0.08);
        color: #b0bec5;
        transition: all 0.2s;
    }

    .fancy-cat-tab.active {
        background: #fff;
        color: #333;
        box-shadow: 0 1px 4px rgba(0,0,0,0.15);
    }

    /* Fancy main tabs — 20wickets style: green/orange */
    .fancy-tabs-container { overflow-x: auto; scrollbar-width: none; }

    .fancy-tab-main {
        padding: 8px 16px;
        font-size: 12px;
        clip-path: none !important;
        border-radius: 6px 6px 0 0;
        margin-left: 0 !important;
        flex-shrink: 0;
    }

    /* Green Fancy Bet tab */
    .fancy-tab-main.fancy-bet-tab {
        background: #2e7d32 !important;
        color: #fff !important;
        border-radius: 6px 6px 0 0;
    }
    .fancy-tab-main.fancy-bet-tab.inactive {
        background: #e0e0e0 !important;
        color: #666 !important;
    }

    /* Orange Sportsbook tab */
    .fancy-tab-main.sportsbook-tab {
        background: #e65100 !important;
        color: #fff !important;
        border-radius: 6px 6px 0 0;
    }
    .fancy-tab-main.sportsbook-tab.inactive {
        background: #e0e0e0 !important;
        color: #666 !important;
    }

    .fancy-tab-main.active { padding-right: 16px; }
    .fancy-tab-main.inactive { padding-left: 16px; }

    /* Fancy subnav — pill style */
    .fancy-subnav {
        padding: 4px 8px;
        gap: 6px;
        overflow-x: auto;
        scrollbar-width: none;
        background: #2c3e50;
    }

    .fancy-subnav::-webkit-scrollbar { display: none; }

    .fancy-subnav-btn {
        font-size: 11px;
        white-space: nowrap;
        padding: 4px 12px;
        border-radius: 20px;
        background: rgba(255,255,255,0.08);
        color: #b0bec5;
        border: none;
    }

    .fancy-subnav-btn.active {
        background: #fff;
        color: #333;
        border-color: #fff;
    }

    /* Sportsbook odds grid — 20wickets mobile style */
    .sportsbook-market-header {
        background: #2e5d3a;
        padding: 8px 10px;
        font-size: 12px;
    }
    .sportsbook-market-header .sb-meta { font-size: 10px; }
    .sportsbook-market-header .sb-meta .matched-amount { font-size: 11px; color: #ffc107; }

    .sportsbook-odds-grid {
        grid-template-columns: 1fr 1fr;
        gap: 6px;
        padding: 8px;
    }

    .sportsbook-odds-box {
        padding: 8px 10px;
        min-height: 50px;
        background: var(--odds-green, #a8e6cf);
        border-radius: 4px;
    }

    .sportsbook-odds-box .sb-team { font-size: 11px; }
    .sportsbook-odds-box .sb-odds { font-size: 16px; font-weight: 900; }
    .sportsbook-odds-box .sb-volume { font-size: 9px; }

    /* Sportsbook 3-col: Tie option centered below */
    .sportsbook-odds-grid.three-col {
        grid-template-columns: 1fr 1fr;
    }
    .sportsbook-odds-grid.three-col .sportsbook-odds-box:last-child {
        grid-column: 1 / -1;
        max-width: 50%;
        margin: 0 auto;
    }

    /* Fancy market header — orange full-width on mobile */
    .fancy-market-header {
        padding: 8px 10px;
        font-size: 12px;
    }
    .fancy-market-header .fancy-header-right {
        font-size: 10px;
    }

    /* SUSPENDED overlay — 20wickets mobile style: red dashed border */
    .market-suspended {
        border: 2px dashed #dc3545;
        position: relative;
    }

    .market-suspended::after {
        content: 'SUSPENDED';
        font-size: 18px;
        letter-spacing: 3px;
        color: #dc3545;
        font-weight: 900;
        text-shadow: 0 0 8px rgba(220,53,69,0.3);
    }

    .suspended-overlay {
        border: 2px dashed #dc3545;
    }

    .suspended-overlay .suspended-text {
        font-size: 18px;
        letter-spacing: 3px;
        color: #dc3545;
    }
}

@media (max-width: 576px) {
    /* Inline bet slip in match page */
    .inline-betslip-container { padding: 8px !important; }

    .bs-layout-row {
        flex-direction: row !important;
        gap: 6px !important;
    }

    .bs-quick-stakes {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 4px !important;
    }

    .bs-quick-stakes button {
        font-size: 10px !important;
        padding: 5px 2px !important;
    }

    /* Numpad */
    .bs-numpad-btn {
        padding: 10px 0 !important;
        font-size: 15px !important;
    }

    /* Right sidebar credit panel */
    .credit-info { padding: 10px; }
    .credit-box .label { font-size: 9px; }
    .credit-box .value { font-size: 12px; }

    .one-click-bet {
        padding: 8px 10px;
        font-size: 12px;
        gap: 8px;
    }

    /* My Bets table in sidebar */
    .betslip-content .my-bets-container table { font-size: 10px !important; }
    .betslip-content .my-bets-container th,
    .betslip-content .my-bets-container td { padding: 4px !important; }

    /* Number game */
    .ng-number-grid {
        grid-template-columns: repeat(5, 1fr) !important;
        gap: 4px !important;
    }

    .ng-num-btn {
        height: 44px !important;
        font-size: 18px !important;
    }

    /* Live over history balls */
    .ball { width: 18px; height: 18px; font-size: 9px; }
    .over-label { font-size: 10px; }

    /* Sportsbook 3-col goes to 2-col + 1-col on very small screens */
    .sportsbook-odds-grid.three-col {
        grid-template-columns: 1fr 1fr;
    }

    .sportsbook-odds-grid.three-col .sportsbook-odds-box:last-child {
        grid-column: 1 / -1;
        max-width: 50%;
        margin: 0 auto;
    }

    /* ── 576px Match Odds refinements ── */
    .odds-boxes .odds-box-lg:nth-child(n+3) { display: none !important; }
    .odds-box-lg {
        width: 56px !important;
        height: 40px !important;
    }
    .odds-box-lg .val { font-size: 13px !important; }

    .team-name { font-size: 12px !important; }

    /* Matched amount compact */
    .matched-inr { font-size: 9px; }

    /* ── 576px Fancy section refinements ── */
    .fancy-tab-main { padding: 6px 12px; font-size: 11px; }
    .fancy-cat-tab { padding: 4px 10px; font-size: 10px; }
    .fancy-box { width: 56px !important; height: 36px !important; }
    .fancy-title { font-size: 11px; padding: 6px 8px; }

    /* ── 576px Sportsbook refinements ── */
    .sportsbook-odds-box {
        padding: 6px 8px;
        min-height: 44px;
    }
    .sportsbook-odds-box .sb-odds { font-size: 14px; }
    .sportsbook-market-header { padding: 6px 8px; font-size: 11px; }

    /* ── 576px Suspended overlay ── */
    .market-suspended::after {
        font-size: 14px;
        letter-spacing: 2px;
    }
    .suspended-overlay .suspended-text {
        font-size: 14px;
        letter-spacing: 2px;
    }

    /* ── 576px Bottom nav refinements ── */
    .mobile-bottom-nav-item.center-item .center-icon-wrap,
    .fp-bottom-nav-center .fp-center-icon-wrap {
        width: 46px;
        height: 46px;
        bottom: 26px;
    }
    .mobile-bottom-nav-item.center-item .center-icon-wrap i,
    .fp-bottom-nav-center .fp-center-icon-wrap i {
        font-size: 18px;
    }
    .mobile-bottom-nav-item { font-size: 8px; padding: 0 2px 8px; }
    .fp-bottom-nav-item { font-size: 8px; padding: 0 2px 8px; }
    .fp-bottom-nav-center { padding-bottom: 8px !important; }
    .fp-center-handle { bottom: 74px; }
}

/* ── 8. LOGIN MODAL (Mobile) ── */
@media (max-width: 576px) {
    .modal-content {
        margin: 5% auto !important;
        padding: 24px 20px !important;
        width: 90% !important;
        max-width: 360px;
    }

    #loginModal .modal-content {
        padding: 24px 20px;
        border-radius: 16px;
    }

    .modal-header-logo h2 { font-size: 24px; }
    .modal-header-logo { margin-bottom: 20px; }

    .form-group { margin-bottom: 12px; }
    .form-group input { padding: 11px 12px; font-size: 14px; }
    .btn-block { padding: 11px; font-size: 15px; }
}

/* ── 9. ACCOUNT DRAWER (Mobile Slide-up) ── */
@media (max-width: 576px) {
    .account-drawer {
        position: fixed;
        bottom: -100%;
        left: 0;
        width: 100%;
        height: 80%;
        background: var(--bg-content, #fff);
        border-top: 3px solid var(--accent-gold, #ffc107);
        z-index: 1000;
        transition: bottom 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        padding-bottom: env(safe-area-inset-bottom, 0px);
        box-shadow: 0 -10px 25px rgba(0,0,0,0.3);
        border-radius: 15px 15px 0 0;
        overflow-y: auto;
    }

    .account-drawer.active {
        bottom: 56px;
    }

    .account-drawer-header {
        padding: 16px 20px;
        background: var(--navy, #1a2c38);
        color: var(--text-light, #fff);
        font-size: 16px;
        font-weight: 700;
        display: flex;
        justify-content: space-between;
        align-items: center;
        border-bottom: 1px solid rgba(255,255,255,0.08);
        position: sticky;
        top: 0;
        z-index: 10;
    }

    .account-drawer-header .user-name-box {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .balance-info-card {
        padding: 16px;
        margin: 12px;
        background: var(--bg-content, #fff);
        border: 1px solid #f0f0f0;
        border-radius: var(--radius-md, 8px);
        box-shadow: 0 2px 6px rgba(0,0,0,0.04);
    }

    .balance-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 12px;
        color: #888;
        font-size: 12px;
    }

    .balance-main {
        font-size: 22px;
        font-weight: 800;
        color: var(--accent-green, #4caf50);
        margin-bottom: 12px;
    }

    .balance-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
        margin-bottom: 16px;
    }

    .balance-small-box .label {
        font-size: 10px;
        color: #888;
        text-transform: uppercase;
        margin-bottom: 4px;
    }

    .balance-small-box .value {
        font-size: 15px;
        font-weight: 700;
        color: var(--text-dark, #333);
    }

    .drawer-action-btns {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .drawer-btn {
        padding: 12px;
        border-radius: var(--radius-sm, 4px);
        border: none;
        color: #fff;
        font-weight: 700;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        font-size: 14px;
        text-decoration: none;
    }

    .drawer-btn.deposit { background: var(--accent-green, #4caf50); }
    .drawer-btn.withdraw { background: var(--accent-red, #dc3545); }

    .drawer-section-title {
        padding: 10px 16px;
        font-size: 11px;
        color: #888;
        font-weight: 700;
        text-transform: uppercase;
        background: #fafafa;
        letter-spacing: 0.5px;
    }

    .account-drawer-item {
        padding: 14px 16px;
        display: flex;
        align-items: center;
        gap: 15px;
        color: var(--text-dark, #333);
        text-decoration: none;
        font-size: 14px;
        font-weight: 500;
        border-bottom: 1px solid #f5f5f5;
        transition: all 0.15s;
    }

    .account-drawer-item i {
        font-size: 18px;
        width: 24px;
        color: #8899a6;
    }

    .account-drawer-item:active {
        background: #f0f0f0;
        padding-left: 22px;
    }

    .drawer-overlay {
        position: fixed;
        top: 0; left: 0; width: 100%; height: 100%;
        background: rgba(0,0,0,0.6);
        backdrop-filter: blur(4px);
        display: none;
        z-index: 999;
    }

    .drawer-overlay.active { display: block; }
}

/* ── 10. ACCOUNT SIDEBAR (Slide-in from right) ── */
@media (max-width: 576px) {
    .account-sidebar {
        width: 100% !important;
        max-width: 320px !important;
    }
}

/* ── 11. BOTTOM NAVIGATION BAR ── */
/* (fp-bottom-nav styles are in footer.php inline, but we add supporting CSS here) */

.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1a2c38;
    border-top: 1px solid rgba(255,255,255,0.06);
    z-index: 900;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.3);
}

.mobile-bottom-nav-items {
    display: flex;
    align-items: flex-end;
    max-width: 500px;
    margin: 0 auto;
}

.mobile-bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding: 8px 4px 10px;
    color: #8899a6;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    gap: 3px;
    cursor: pointer;
    text-decoration: none;
    transition: color 0.2s;
    position: relative;
}

.mobile-bottom-nav-item i { font-size: 20px; }

.mobile-bottom-nav-item.active { color: #ffc107; }

.mobile-bottom-nav-item:hover {
    color: #fff;
}

/* Elevated center Sports icon — 20wickets style: white circular */
.mobile-bottom-nav-item.center-item {
    position: relative;
}

.mobile-bottom-nav-item.center-item .center-icon-wrap {
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: -25px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.3);
    border: 2px solid rgba(255,255,255,0.1);
}

.mobile-bottom-nav-item.center-item .center-icon-wrap i {
    font-size: 20px;
    color: #1a5276;
}

/* fp-bottom-nav center icon override — white circular with trophy */
.fp-bottom-nav-center .fp-center-icon-wrap {
    width: 52px;
    height: 52px;
    background: #fff !important;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 4px 14px rgba(0,0,0,0.35);
    border: none;
    z-index: 2;
}

/* Small dark handle/bar above the center icon */
.fp-center-handle {
    width: 28px;
    height: 4px;
    background: #1a2c38;
    border-radius: 0 0 4px 4px;
    position: absolute;
    bottom: 82px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.fp-bottom-nav-center .fp-center-icon-wrap i {
    font-size: 22px;
    color: #1a2c38 !important;
}

.fp-bottom-nav-center:hover .fp-center-icon-wrap,
.fp-bottom-nav-center.active .fp-center-icon-wrap {
    transform: translateX(-50%) translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.35);
}

@media (max-width: 768px) {
    .mobile-bottom-nav,
    .fp-bottom-nav { display: block; }

    body { padding-bottom: 80px; }

    /* Active state for bottom nav items */
    .fp-bottom-nav-item.active {
        color: #fff;
    }
    .mobile-bottom-nav-item.active {
        color: #ffc107;
    }
}

@media (min-width: 769px) {
    .mobile-bottom-nav,
    .fp-bottom-nav { display: none !important; }
}

/* ── 12. SUB-NAV SCROLLABLE INDICATOR ── */
.sub-nav ul,
.fp-nav-list {
    scrollbar-width: none;
}

.sub-nav ul::-webkit-scrollbar,
.fp-nav-list::-webkit-scrollbar {
    display: none;
}

@media (max-width: 992px) {
    .sub-nav ul {
        justify-content: flex-start;
        gap: 0;
        padding: 0;
        overflow-x: auto;
    }

    .sub-nav li a {
        padding: 10px 12px;
        font-size: 11px;
        white-space: nowrap;
        border-bottom: 2px solid transparent;
    }

    .sub-nav li.active a {
        border-bottom-color: var(--accent-green, #4caf50);
        color: var(--accent-green, #4caf50);
    }
}

/* ── 13. IMPROVED TOUCH TARGETS ── */
@media (max-width: 768px) {
    .odds-box-lg,
    .bm-box,
    .fancy-box,
    .sportsbook-odds-box {
        min-height: 40px;
    }

    /* Betslip action buttons */
    .inline-betslip-container button[onclick="placeBet()"],
    .inline-betslip-container button[onclick="closeInlineBetSlip()"],
    #inline-fancy-betslip-row button[onclick="placeFancyBet()"] {
        min-height: 44px;
    }

    /* All clickable cells minimum 44px */
    .odds-cell,
    .mobile-odds-btn {
        min-height: 44px;
    }
}

/* ── 14. ODDS FLASH ANIMATIONS (Mobile) ── */
@media (max-width: 768px) {
    .flash-up,
    .flash-down {
        animation-duration: 0.6s;
    }
}

/* ── 15. SAFE AREA INSETS (iOS Notch) ── */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .main-header,
    .fp-header {
        padding-top: max(8px, env(safe-area-inset-top));
    }

    .mobile-bottom-nav,
    .fp-bottom-nav {
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }
}

/* ── 16. LANDSCAPE ORIENTATION ADJUSTMENTS ── */
@media (max-width: 992px) and (orientation: landscape) {
    .banners-wrapper { height: 100px !important; }
    .banner-content h2 { font-size: 1.5rem; }

    .match-card-odds { gap: 4px; }
    .mobile-odds-btn { height: 36px; }
}

/* ── 17. PRINT STYLES (hide nav, dark backgrounds) ── */
@media print {
    .fp-header,
    .fp-nav-bar,
    .fp-sidebar,
    .fp-bottom-nav,
    .mobile-bottom-nav,
    .mobile-quick-links {
        display: none !important;
    }

    body {
        background: #fff;
        color: #000;
    }

    .center-content,
    .market-section {
        box-shadow: none;
    }
}
