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

html {
    background: var(--surface-0);
    color: var(--text-primary);
    color-scheme: dark;
 overflow-x: clip;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-feature-settings: "cv11", "ss01";
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    min-height: 100dvh;
    letter-spacing: -0.011em;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}
[data-theme="light"] {
    color-scheme: light;
}

body {
    min-height: 100vh;
    min-height: 100dvh;
    height: auto;
    display: flex;
    flex-direction: column;
    background: var(--surface-0);
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
 overflow-x: clip;
 max-width: 100%;
}
body.scroll-lock {
    overflow: hidden;
    overscroll-behavior: none;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }
code {
    font-family: ui-monospace, "SF Mono", Consolas, monospace;
}

:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

.bg-glow {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(ellipse 80% 40% at 0% -10%, rgba(255, 144, 0, 0.18), transparent 62%),
        radial-gradient(ellipse 50% 30% at 100% 110%, rgba(255, 144, 0, 0.07), transparent 70%);
}
[data-theme="light"] .bg-glow {
    background:
        radial-gradient(ellipse 80% 40% at 0% -10%, rgba(255, 144, 0, 0.14), transparent 62%),
        radial-gradient(ellipse 50% 30% at 100% 110%, rgba(255, 144, 0, 0.06), transparent 70%);
}

.hidden { display: none !important; }
[hidden] { display: none !important; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--surface-0); }
::-webkit-scrollbar-thumb {
    background: var(--surface-3);
    border-radius: 8px;
    border: 2px solid var(--surface-0);
}
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

@media (max-width: 899px) {
    :root { --header-h: 52px; --tabbar-h: 56px; }
    input, select, textarea { font-size: 16px !important; }
    input[type="search"],
    input[type="text"],
    input[type="password"] {
        -webkit-appearance: none;
        appearance: none;
        border-radius: 12px;
    }
    input[type="search"]::-webkit-search-decoration,
    input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; }
    button, .icon-btn, .filter-btn, .tabbar-item, .nav-link, .mobile-nav-link {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
    a, .video-card, .gallery-card, .model-card {
        -webkit-tap-highlight-color: transparent;
        touch-action: pan-y;
    }
    .related-scroller,
    .related-list,
    .related-list .related-card,
    a.related-card {
        touch-action: pan-x pan-y !important;
    }
    html, body {
        height: auto !important;
        min-height: 100%;
        max-height: none !important;
        overflow: visible !important;
        overscroll-behavior-y: auto;
        position: static;
        -webkit-overflow-scrolling: touch;
    }
    body.has-user:not(.shorts-mode):not(.scroll-lock),
    body.watch-mode:not(.scroll-lock),
    body.dash-mode:not(.shorts-mode):not(.scroll-lock) {
        display: block;
        overflow: visible !important;
        height: auto !important;
        max-height: none !important;
        touch-action: pan-x pan-y pinch-zoom;
    }
    body.shorts-mode,
    body.scroll-lock {
        overflow: hidden !important;
    }
    ::-webkit-scrollbar { width: 0; height: 0; display: none; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
