/* =====================================================
   BOOKIEZZ - phone and tablet fixes (loaded after every other stylesheet)
   ===================================================== */

/* ---------- Sportsbooks page search box (was unstyled) ---------- */
.sb-search .form-control {
    width: 100%;
    height: 46px;
    padding: 0 104px 0 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 10px;
    color: #fff;
    font-size: 16px; /* 16px stops iOS from zooming in on focus */
    outline: none;
}

.sb-search .form-control::placeholder {
    color: var(--gray-400, #94a3b8);
}

.sb-search .form-control:focus {
    border-color: rgba(255, 107, 53, 0.6);
}

.sb-search .btn {
    top: 5px !important;
    right: 5px !important;
    height: 36px;
    padding: 0 16px;
}

/* ---------- Header: logo left, menu button right, compact ---------- */
@media (max-width: 768px) {
    .header-container {
        padding: 10px 16px;
        gap: 12px;
    }

    .site-logo {
        gap: 10px;
        min-width: 0;
    }

    .site-logo .logo-icon,
    .site-logo .logo-icon svg {
        width: 36px;
        height: 36px;
    }

    .site-logo .logo-text {
        font-size: 1.3rem !important;
    }

    .mobile-menu-toggle {
        display: flex !important;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        padding: 0;
        flex-shrink: 0;
        font-size: 1.5rem;
        line-height: 1;
        border-radius: 10px;
        border: 1px solid rgba(255, 255, 255, 0.14);
        background: rgba(255, 255, 255, 0.05);
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-menu-toggle[aria-expanded="true"] {
        border-color: rgba(255, 107, 53, 0.5);
        background: rgba(255, 107, 53, 0.12);
    }

    /* Dropdown menu */
    .main-nav {
        z-index: 1000;
        background: #0a1128 !important; /* solid: no page text showing through */
        gap: 0;
        padding: 6px 16px 14px;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
        border-bottom: 1px solid rgba(255, 107, 53, 0.25);
    }

    .main-nav a {
        display: block;
        width: 100%;
        padding: 14px 8px;
        font-size: 1.05rem;
        border-radius: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }

    .main-nav a:last-child {
        border-bottom: 0;
    }

    .main-nav a.active {
        background: rgba(255, 107, 53, 0.08);
        border-radius: 8px;
    }

    .main-nav a.active::after {
        display: none;
    }

    /* ---------- Hero bands: less dead space ---------- */
    .hero {
        padding: 40px 0;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.15;
    }

    /* ---------- Sportsbook cards: no empty gap above the buttons ---------- */
    div.site-header,
    .site-bonus,
    .site-features {
        min-height: 0 !important;
    }

    /* ---------- Articles: contents first, then the article, then the sidebar widgets ---------- */
    .article-layout {
        display: flex;
        flex-direction: column;
        gap: 24px;
    }

    .article-sidebar {
        display: contents;
    }

    .article-sidebar .toc-widget {
        order: 0;
        width: 100%;
        max-width: none;
    }

    .article-main {
        order: 1;
        width: 100%;
    }

    .article-sidebar > *:not(.toc-widget) {
        order: 2;
        width: 100%;
        max-width: none;
    }

    /* ---------- Articles index: featured article stacks ---------- */
    .featured-article-grid {
        grid-template-columns: 1fr !important;
    }

    .featured-article-grid > div:first-child {
        height: 210px !important;
    }

    .featured-article-grid > div:last-child {
        padding: 22px !important;
    }

    .featured-article-grid h2 {
        font-size: 1.5rem !important;
    }
}

@media (max-width: 480px) {
    /* Sportsbooks page: the global ".btn { width: 100% }" made the Search button cover the input
       and stretched every filter chip to a full row. */
    .sb-search .btn {
        width: auto;
    }

    .sb-filter-chips {
        gap: 8px !important;
    }

    .sb-filter-chips .btn {
        width: auto;
        flex: 0 0 auto;
        padding: 8px 12px;
    }

    /* Review page quick stats: two per row instead of one */
    .stats-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 10px;
    }

    .stats-grid .stat-item {
        padding: 12px 8px;
    }
}
