/* ===== TOP NAV ROOT ===== */
:root {
    --nav-height: 104px;
}

.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    z-index: 1000;
    background: rgba(26, 22, 18, 0.97);
    border-bottom: 1px solid rgba(200, 135, 42, 0.3);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(6px);
}

/* Desktop only: on whole-page-scroll layouts (no internal-scroll containers
   like Search / Detail / Collection / Builder), let the top-nav scroll with
   the document instead of staying glued to the viewport. */
@media (min-width: 769px) {
    body:not(:has(.search-page-card)):not(:has(.detail-page)):not(:has(.coll-layout)):not(:has(.builder-app-card)) .top-nav {
        position: absolute;
    }
}

/* 3-column grid: nav links | centred logo | search + icons */
.top-nav__inner {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    height: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 1.5rem;
    gap: 0;
    position: relative;
}

/* ===== CENTER LOGO ===== */
.top-nav__center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.top-nav__logo {
    display: flex;
    align-items: center;
    text-decoration: none !important;
    flex-shrink: 0;
}

.top-nav__logo img {
    height: 88px;
    width: auto;
}

/* ===== LEFT LINKS (Browse + My Decks) ===== */
.top-nav__left {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    justify-content: flex-start;
}

.nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.75rem;
    background: transparent;
    border: none;
    color: var(--color-muted);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    text-decoration: none !important;
    white-space: nowrap;
    transition: color 0.15s ease, background 0.15s ease;
}

.nav-btn:hover,
.nav-btn:focus-visible {
    color: var(--color-text);
    background: rgba(200, 135, 42, 0.1);
}

.nav-btn.is-active {
    color: var(--color-accent);
}

.nav-btn .nav-chevron {
    font-size: 0.65rem;
    transition: transform 0.2s ease;
}

.nav-btn[aria-expanded="true"] .nav-chevron {
    transform: rotate(180deg);
}

/* ===== RIGHT: SEARCH + ICONS ===== */
.top-nav__right {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    justify-content: flex-end;
}

/* Search bar — squared, lives inside right column */
.top-nav__search,
.top-nav__search form,
.top-nav__search input,
.top-nav__search button,
.top-nav__search .nav-game-picker,
.top-nav__search .nav-game-picker__btn {
    border-radius: 0 !important;
}

.top-nav__search form {
    display: flex;
    align-items: stretch;
    background: rgba(14, 12, 10, 0.85);
    border: 1px solid rgba(200, 135, 42, 0.35);
    overflow: visible;
    width: 300px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, width 0.25s ease;
}

.top-nav__search form:focus-within {
    border-color: var(--color-accent);
    box-shadow: 0 0 12px rgba(200, 135, 42, 0.2);
    width: 380px;
}

.top-nav__search form:focus-within .nav-game-picker {
    border-right-color: var(--color-accent);
}

/* ── Custom game picker ── */
.nav-game-picker {
    position: relative;
    flex-shrink: 0;
    border-right: 1px solid rgba(200, 135, 42, 0.25);
}

.nav-game-picker__btn {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0 0.7rem 0 0.75rem;
    height: 100%;
    background: transparent;
    border: none;
    color: var(--color-muted);
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.15s ease, background 0.15s ease;
}

.nav-game-picker__btn:hover { color: var(--color-text); background: rgba(200,135,42,0.06); }

.nav-game-picker__btn .nav-chevron {
    font-size: 0.6rem;
    opacity: 0.6;
    transition: transform 0.2s ease;
}

.nav-game-picker__btn[aria-expanded="true"] .nav-chevron {
    transform: rotate(180deg);
    opacity: 1;
}

.nav-game-picker__menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    background: #1A1612;
    border: 1px solid rgba(200, 135, 42, 0.3);
    list-style: none;
    margin: 0;
    padding: 0.3rem 0;
    min-width: 140px;
    z-index: 11600;
    box-shadow: 0 8px 28px rgba(0,0,0,0.65);
    /* Transition — always rendered, animated in/out */
    opacity: 0;
    transform: translateY(-6px);
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.nav-game-picker__menu.is-open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}


.nav-game-option {
    padding: 0.45rem 1rem;
    font-family: var(--font-body);
    font-size: 0.82rem;
    color: var(--color-muted);
    cursor: pointer;
    transition: color 0.12s ease, background 0.12s ease;
}

.nav-game-option:hover { color: var(--color-text); background: rgba(200,135,42,0.08); }
.nav-game-option.is-selected { color: var(--color-accent); }

.top-nav__search input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 0.5rem 0.9rem;
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 0.85rem;
    min-width: 0;
    align-self: center;
}

.top-nav__search input::placeholder {
    color: var(--color-muted);
}

.top-nav__search button {
    background: var(--color-accent);
    border: none;
    color: #000;
    padding: 0 0.85rem;
    cursor: pointer;
    font-size: 0.85rem;
    font-family: var(--font-body);
    font-weight: 600;
    /* border-radius: 0 enforced by group rule above */
    transition: filter 0.18s ease;
    white-space: nowrap;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.top-nav__search button:hover {
    filter: brightness(1.15);
}

.nav-icon-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    color: var(--color-muted);
    font-size: 1.1rem;
    cursor: pointer;
    border-radius: 8px;
    transition: color 0.15s ease, background 0.15s ease;
}

.nav-icon-btn:hover {
    color: var(--color-accent);
    background: rgba(200, 135, 42, 0.1);
}

.nav-cart-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--color-pop);
    color: #fff;
    font-size: 0.62rem;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-body);
    pointer-events: none;
    line-height: 1;
}

/* ===== FLYOUT PANELS ===== */
/* Flyout panels are direct children of <body> with position:absolute.
   top-nav has position:fixed so flyouts position relative to viewport. */
.flyout-panel {
    position: fixed;
    top: var(--nav-height);
    background: rgba(26, 22, 18, 0.98);
    border: 1px solid rgba(200, 135, 42, 0.25);
    border-top: 2px solid var(--color-accent);
    border-radius: 0 0 12px 12px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
    padding: 1.25rem;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 1001;
}

.flyout-panel.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

/* Browse flyout — full viewport width, single row */
.flyout-browse {
    left: 0;
    right: 0;
    width: 100%;
    border-radius: 0 0 12px 12px;
    padding: 1rem 1.5rem;
}

/* Inner container matches the nav's centred content width */
.flyout-browse .flyout-game-grid {
    max-width: 1440px;
    margin: 0 auto;
}

/* Account flyout — right edge aligned with nav inner's right padding edge. */
.flyout-account {
    right: max(1.5rem, calc((100vw - 1440px) / 2 + 1.5rem));
    width: 360px;
}

/* Tools flyout — left-anchored under the Tools button in top-nav__left. */
.flyout-tools {
    left: max(1.5rem, calc((100vw - 1440px) / 2 + 1.5rem));
    width: 300px;
}

/* ===== FLYOUT GAME CARDS (Browse) ===== */
.flyout-game-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.6rem;
}

.flyout-game-card {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.65rem 0.75rem;
    background: rgba(14, 12, 10, 0.5);
    border: 1px solid rgba(200, 135, 42, 0.15);
    border-radius: 8px;
    text-decoration: none !important;
    color: var(--color-text);
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.flyout-game-card:hover {
    border-color: var(--color-accent);
    background: rgba(200, 135, 42, 0.07);
    transform: translateY(-2px);
    color: var(--color-text);
}

.flyout-game-icon {
    width: 40px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 1.1rem;
    flex-shrink: 0;
    overflow: hidden;
    padding: 5px;
}

.flyout-game-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* Keep subtle tinted bg for the logo containers, use icon color for accessories */
.flyout-game-icon.icon-fab     { background: rgba(200,135,42,0.12); }
.flyout-game-icon.icon-mtg     { background: rgba(76,175,80,0.10);  }
.flyout-game-icon.icon-poke    { background: rgba(33,150,243,0.10); }
.flyout-game-icon.icon-sorcery { background: rgba(139,92,246,0.12); }
.flyout-game-icon.icon-acc     { background: rgba(168,152,128,0.15); color: var(--color-muted); }

.flyout-game-info {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 0;
}

.flyout-game-name {
    font-family: var(--font-display);
    font-size: 16px;
    letter-spacing: 0.04em;
    color: var(--color-text);
    line-height: 1;
}

.flyout-game-sub {
    font-family: var(--font-body);
    font-size: 0.75rem;
    color: var(--color-muted);
}

/* ===== FLYOUT ACCOUNT CARDS ===== */
.flyout-auth-strip {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(200, 135, 42, 0.15);
}

.flyout-auth-btn {
    flex: 1;
    padding: 0.5rem;
    border-radius: 999px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none !important;
    cursor: pointer;
    border: none;
    transition: filter 0.18s ease;
}

.flyout-auth-btn--primary {
    background: var(--color-accent);
    color: #000;
}

.flyout-auth-btn--primary:hover {
    filter: brightness(1.12);
    color: #000;
}

.flyout-auth-btn--secondary {
    background: transparent;
    color: var(--color-muted);
    border: 1px solid rgba(168, 152, 128, 0.35);
}

.flyout-auth-btn--secondary:hover {
    color: var(--color-text);
    border-color: var(--color-muted);
}

.flyout-tool-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.flyout-tool-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    background: rgba(14, 12, 10, 0.4);
    border: 1px solid rgba(200, 135, 42, 0.12);
    border-radius: 8px;
    text-decoration: none !important;
    color: var(--color-text);
    transition: border-color 0.15s ease, background 0.15s ease;
}

.flyout-tool-card:hover {
    border-color: var(--color-accent);
    background: rgba(200, 135, 42, 0.06);
    color: var(--color-text);
}

/* Admin-only tool cards — subtle red-gold tint to distinguish them */
.flyout-tool-card--admin {
    border-color: rgba(200, 135, 42, 0.22);
    background: rgba(200, 135, 42, 0.04);
}

.flyout-tool-card--admin .flyout-tool-icon {
    background: rgba(200, 135, 42, 0.15);
}

.flyout-tool-card--admin:hover {
    border-color: var(--color-accent);
    background: rgba(200, 135, 42, 0.10);
}

.flyout-tool-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 1rem;
    flex-shrink: 0;
    background: rgba(200, 135, 42, 0.1);
    color: var(--color-accent);
}

.flyout-tool-info {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.flyout-tool-name {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text);
}

.flyout-tool-desc {
    font-family: var(--font-body);
    font-size: 0.75rem;
    color: var(--color-muted);
}

/* ===== CART SLIDE PANEL ===== */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1099;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.cart-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* Desktop: right-slide panel */
.cart-panel {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 360px;
    max-width: 95vw;
    background: rgba(26, 22, 18, 0.99);
    border-left: 1px solid rgba(200, 135, 42, 0.25);
    box-shadow: -8px 0 40px rgba(0, 0, 0, 0.6);
    z-index: 1100;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.cart-panel.is-open {
    transform: translateX(0);
}

/* Mobile: bottom-sheet */
@media (max-width: 768px) {
    .cart-overlay { z-index: 11100; }
    .cart-panel {
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        width: 100%;
        max-width: 100%;
        height: auto;
        max-height: 85dvh;
        border-left: none;
        border-top: 1px solid rgba(200, 135, 42, 0.25);
        border-radius: 16px 16px 0 0;
        box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.6);
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
        z-index: 11200;
    }
    .cart-panel.is-open {
        transform: translateY(0);
    }
}

.cart-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(200, 135, 42, 0.2);
    flex-shrink: 0;
}

.cart-panel__title {
    font-family: var(--font-display);
    font-size: 20px;
    letter-spacing: 0.06em;
    color: var(--color-accent);
    margin: 0;
}

.cart-panel__close {
    background: none;
    border: none;
    color: var(--color-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: color 0.15s ease;
}

.cart-panel__close:hover {
    color: var(--color-text);
}

.cart-panel__body {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.cart-panel__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 0.75rem;
    color: var(--color-muted);
    font-family: var(--font-body);
    font-size: 0.9rem;
    text-align: center;
}

.cart-panel__empty i {
    font-size: 2.5rem;
    color: rgba(200, 135, 42, 0.3);
}

.cart-item {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    padding: 0.6rem;
    background: rgba(14, 12, 10, 0.5);
    border: 1px solid rgba(200, 135, 42, 0.1);
    border-radius: 8px;
}

.cart-item__img {
    width: 48px;
    height: 67px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
    background: rgba(0,0,0,0.3);
}

.cart-item__details {
    flex: 1;
    min-width: 0;
}

.cart-item__name {
    font-family: var(--font-display);
    font-size: 14px;
    letter-spacing: 0.03em;
    color: var(--color-text);
    line-height: 1.2;
    margin-bottom: 0.2rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item__set {
    font-family: var(--font-body);
    font-size: 0.72rem;
    color: var(--color-muted);
    margin-bottom: 0.25rem;
}

.cart-item__qty-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: var(--font-body);
    font-size: 0.85rem;
}

.cart-item__qty {
    color: var(--color-muted);
}

.cart-item__price {
    color: var(--color-accent);
    font-weight: 700;
}

.cart-item__remove {
    background: none;
    border: none;
    color: rgba(168, 152, 128, 0.5);
    cursor: pointer;
    font-size: 0.8rem;
    padding: 0.2rem;
    flex-shrink: 0;
    transition: color 0.15s ease;
    margin-top: 2px;
}

.cart-item__remove:hover {
    color: var(--color-danger);
}

.cart-panel__footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid rgba(200, 135, 42, 0.2);
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    flex-shrink: 0;
}

.cart-panel__total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-body);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.cart-panel__total-label {
    color: var(--color-muted);
}

.cart-panel__total-value {
    font-family: var(--font-accent);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-accent);
}

.btn-cart-clear {
    padding: 0.6rem;
    background: transparent;
    border: 1px solid rgba(140, 58, 46, 0.4);
    border-radius: 999px;
    color: var(--color-muted);
    font-family: var(--font-body);
    font-size: 0.85rem;
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.btn-cart-clear:hover {
    color: var(--color-danger);
    border-color: var(--color-danger);
}

.btn-cart-checkout {
    display: block;
    padding: 0.75rem;
    background: linear-gradient(135deg, var(--color-accent) 0%, #e8a040 100%);
    border: none;
    border-radius: 999px;
    color: #000;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 0.95rem;
    text-align: center;
    text-decoration: none !important;
    cursor: pointer;
    transition: filter 0.18s ease, box-shadow 0.18s ease;
}

.btn-cart-checkout:hover {
    filter: brightness(1.12);
    box-shadow: 0 0 14px rgba(200, 135, 42, 0.4);
    color: #000;
}

/* ===== ACCOUNT FLYOUT — POLICIES SECTION ===== */
.flyout-policies {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(200, 135, 42, 0.12);
}

.flyout-policies__label {
    font-family: var(--font-body);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(168, 152, 128, 0.45);
    padding: 0 1rem 0.4rem;
}

.flyout-policies__links {
    display: flex;
    flex-direction: column;
}

.flyout-policies__link {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.38rem 1rem;
    font-family: var(--font-body);
    font-size: 0.78rem;
    color: var(--color-muted);
    text-decoration: none !important;
    transition: color 0.12s ease, background 0.12s ease;
}

.flyout-policies__link:hover {
    color: var(--color-text);
    background: rgba(200, 135, 42, 0.07);
}

.flyout-policies__link i {
    width: 14px;
    text-align: center;
    font-size: 0.72rem;
    color: rgba(200, 135, 42, 0.5);
    flex-shrink: 0;
}

.flyout-policies__copy {
    font-family: var(--font-body);
    font-size: 0.68rem;
    color: rgba(168, 152, 128, 0.35);
    padding: 0.5rem 1rem 0.25rem;
    text-align: center;
}

.flyout-policies__disclosure {
    font-family: var(--font-body);
    font-size: 0.7rem;
    line-height: 1.45;
    color: rgba(168, 152, 128, 0.55);
    padding: 0.6rem 1rem 0.4rem;
    margin-top: 0.4rem;
    border-top: 1px solid rgba(200, 135, 42, 0.15);
    text-align: left;
    font-style: italic;
}

/* ===== HERO SEARCH — wider + taller than nav ===== */
.home-hero-search-wrap .top-nav__search form {
    width: 620px;
    max-width: 100%;
}

.home-hero-search-wrap .top-nav__search form:focus-within {
    width: 680px;
    max-width: 100%;
}

.home-hero-search-wrap .top-nav__search input {
    padding: 0.9rem 1rem;
    font-size: 0.95rem;
}

.home-hero-search-wrap .top-nav__search button[type="submit"] {
    padding: 0 1.2rem;
    font-size: 1rem;
}

.home-hero-search-wrap .nav-game-picker__btn {
    padding: 0 0.9rem 0 1rem;
    font-size: 0.85rem;
}

/* ===== MOBILE BOTTOM NAV ===== */

/* Hidden on desktop */
.mob-nav           { display: none; }
.mob-flyout-overlay { display: none; }

@media (max-width: 768px) {
    :root {
        --nav-height: 64px; /* reused as bottom nav height for layout calcs */
    }

    /* ── Hide desktop top nav ── */
    .top-nav { display: none; }

    /* ── Bottom nav bar — flex sibling in #mob-shell, no longer position:fixed ── */
    .mob-nav {
        display: flex;
        flex-shrink: 0;
        width: 100%;
        height: var(--nav-height);
        background: rgba(26, 22, 18, 0.98);
        border-top: 1px solid rgba(200, 135, 42, 0.3);
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.45);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        position: relative;
        z-index: 12000;
        align-items: center;
        padding: 0 0.5rem 0 0.75rem;
    }

    .mob-nav__logo {
        flex-shrink: 0;
        display: flex;
        align-items: center;
        padding-right: 0.75rem;
        border-right: 1px solid rgba(200, 135, 42, 0.2);
        margin-right: 0.25rem;
        text-decoration: none;
    }

    .mob-nav__logo img {
        height: 36px;
        width: auto;
    }

    .mob-nav__items {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: space-around;
    }

    .mob-nav__btn {
        position: relative;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 3px;
        background: none;
        border: none;
        color: var(--color-muted);
        font-family: var(--font-body);
        font-size: 0.6rem;
        font-weight: 500;
        letter-spacing: 0.02em;
        cursor: pointer;
        padding: 0.3rem 0.65rem;
        border-radius: 8px;
        transition: color 0.15s ease;
        text-decoration: none;
        line-height: 1;
        -webkit-tap-highlight-color: transparent;
    }

    .mob-nav__btn i {
        font-size: 1.15rem;
        line-height: 1;
    }

    .mob-nav__btn.is-active,
    .mob-nav__btn:active {
        color: var(--color-accent);
    }

    .mob-nav__badge {
        position: absolute;
        top: 1px; right: 4px;
        background: var(--color-pop);
        color: #fff;
        font-size: 0.55rem;
        font-weight: 700;
        min-width: 14px;
        height: 14px;
        border-radius: 999px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: var(--font-body);
        pointer-events: none;
    }

    /* ── Flyout overlay ── */
    .mob-flyout-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.55);
        z-index: 12000;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease;
    }

    .mob-flyout-overlay.is-open {
        opacity: 1;
        pointer-events: auto;
    }

    /* ── Flyout panels → bottom sheets ── */
    .flyout-panel {
        position: fixed !important;
        top: auto !important;
        bottom: var(--nav-height) !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-height: 72vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        z-index: 12100;
        border-radius: 16px 16px 0 0 !important;
        border-top: 2px solid var(--color-accent) !important;
        border-left: none !important;
        border-right: none !important;
        padding: 0 !important;
        transform: translateY(110%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.15s ease;
    }

    .flyout-panel.is-open {
        transform: translateY(0) !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }

    /* Drag handle pill */
    .flyout-panel::before {
        content: '';
        display: block;
        width: 36px;
        height: 4px;
        background: rgba(200, 135, 42, 0.35);
        border-radius: 2px;
        margin: 10px auto 0;
    }

    /* Sheet header (used by tools panel) */
    .mob-sheet-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.9rem 1.25rem 0.65rem;
        border-bottom: 1px solid rgba(200, 135, 42, 0.15);
    }

    .mob-sheet-title {
        font-family: var(--font-display);
        font-size: 17px;
        letter-spacing: 0.06em;
        color: var(--color-accent);
    }

    .mob-sheet-close {
        background: none;
        border: none;
        color: var(--color-muted);
        font-size: 1rem;
        cursor: pointer;
        padding: 0.2rem 0.4rem;
        border-radius: 4px;
        transition: color 0.15s ease;
    }

    .mob-sheet-close:hover { color: var(--color-text); }

    /* Browse flyout content */
    .flyout-browse {
        padding-bottom: 0.75rem !important;
    }

    .flyout-browse .flyout-game-grid {
        grid-template-columns: 1fr;
        padding: 0.75rem 1rem;
        gap: 0.6rem;
    }

    /* Account flyout content */
    .flyout-account {
        padding: 1rem 1.25rem 1.25rem !important;
    }

    .flyout-account .flyout-auth-strip {
        margin-top: 0.25rem;
    }

    /* Tools panel */
    .mob-tools-panel .flyout-tool-grid {
        padding: 0.5rem 1rem 1rem;
        gap: 0.5rem;
    }

    /* Cart stays as a right slide-in, but full width */
    .cart-panel {
        width: 100vw;
    }
}
