/* ═══════════════════════════════════════════════════════════
   StreamHub Premium — Netflix × Disney+ × Apple TV+
   Palette: #0A0A0A base · cyan accent · red CTA
   ═══════════════════════════════════════════════════════════ */

:root {
    --sh-bg: #0a0a0a;
    --sh-bg-elevated: #111114;
    --sh-surface: rgba(18, 20, 28, 0.72);
    --sh-glass: rgba(255, 255, 255, 0.04);
    --sh-border: rgba(255, 255, 255, 0.08);
    --sh-border-hover: rgba(0, 212, 255, 0.35);
    --sh-cyan: #00d4ff;
    --sh-cyan-dim: rgba(0, 212, 255, 0.15);
    --sh-red: #e50914;
    --sh-red-glow: rgba(229, 9, 20, 0.45);
    --sh-text: #a8acb8;
    --sh-text-hi: #f4f4f8;
    --sh-gold: #f5c518;
    --sh-radius: 12px;
    --sh-radius-lg: 16px;
    --sh-header-h: 72px;
    --sh-bottom-nav-h: 64px;
    --sh-ease: cubic-bezier(0.4, 0, 0.2, 1);
    --sh-shadow: 0 24px 80px rgba(0, 0, 0, 0.65);
    --font: 'Inter', system-ui, -apple-system, sans-serif;
}

/* Reset conflicts from legacy streamhub.css on home */
body.sh-home {
    background: var(--sh-bg);
    color: var(--sh-text);
    font-family: var(--font);
    padding-top: 0 !important;
    overflow-x: hidden;
}
body.sh-home > main { padding: 0; }
body.sh-home .navbar { display: none; }
body.sh-home .flash-messages { top: calc(var(--sh-header-h) + 12px); }

.hide-mobile { display: flex; }
.hide-desktop { display: none !important; }
@media (max-width: 900px) {
    .hide-mobile { display: none !important; }
    .hide-desktop { display: flex !important; }
    body.sh-home { padding-bottom: var(--sh-bottom-nav-h); }
}

/* ─── Header ───────────────────────────────────────────── */
.sh-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    height: var(--sh-header-h);
    transition: background 0.4s var(--sh-ease), box-shadow 0.4s;
}
.sh-header.scrolled {
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(20px) saturate(1.4);
    border-bottom: 1px solid var(--sh-border);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}
.sh-nav {
    max-width: 1600px;
    margin: 0 auto;
    height: 100%;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
}
.sh-logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    flex-shrink: 0;
}
.sh-logo-icon {
    width: 36px; height: 36px;
    background: linear-gradient(135deg, var(--sh-cyan), #0066ff);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
    font-size: 0.85rem;
    box-shadow: 0 4px 20px rgba(0, 212, 255, 0.35);
}
.sh-logo-text {
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: 0.12em;
    color: var(--sh-text-hi);
}
.sh-logo-text .accent { color: var(--sh-cyan); }

.sh-nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
    flex-shrink: 0;
}
.sh-nav-links > li {
    display: flex;
    align-items: center;
    height: 100%;
}
.sh-nav-links a,
.sh-nav-drop-btn {
    color: var(--sh-text);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    line-height: 1.25;
    transition: color 0.2s;
    white-space: nowrap;
}
.sh-nav-links a:hover,
.sh-nav-links a.active,
.sh-nav-drop-btn:hover,
.sh-nav-drop-btn.active { color: var(--sh-text-hi); }
.sh-nav-dropdown { position: relative; }
.sh-nav-drop-btn {
    background: none;
    border: none;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0;
    margin: 0;
    vertical-align: baseline;
}
.sh-nav-dropdown.open .sh-dropdown-genres {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.sh-dropdown-genres {
    min-width: 180px;
    max-height: 320px;
    overflow-y: auto;
}
.sh-dropdown-genres a.active { color: var(--sh-cyan); }
.sh-dropdown-empty { padding: 0.75rem; font-size: 0.82rem; color: var(--sh-text); }

.sh-search {
    flex: 1;
    max-width: 420px;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--sh-glass);
    border: 1px solid var(--sh-border);
    border-radius: 100px;
    padding: 0.5rem 1rem;
    transition: border-color 0.25s, box-shadow 0.25s;
}
.sh-search:focus-within {
    border-color: var(--sh-border-hover);
    box-shadow: 0 0 0 3px var(--sh-cyan-dim);
}
.sh-search input {
    flex: 1;
    background: none;
    border: none;
    color: var(--sh-text-hi);
    font-size: 0.88rem;
    outline: none;
}
.sh-search kbd {
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    background: rgba(255,255,255,0.08);
    color: var(--sh-text);
}

.sh-nav-actions { display: flex; align-items: center; gap: 0.5rem; margin-left: auto; }
.sh-icon-btn, .sh-btn {
    font-family: inherit;
    cursor: pointer;
    border: none;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.2s var(--sh-ease);
}
.sh-icon-btn {
    background: var(--sh-glass);
    border: 1px solid var(--sh-border);
    color: var(--sh-text-hi);
    padding: 0.45rem 0.75rem;
}
.sh-btn { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 1.1rem; text-decoration: none; }
.sh-btn-ghost { background: transparent; border: 1px solid var(--sh-border); color: var(--sh-text-hi); }
.sh-btn-ghost:hover { border-color: var(--sh-cyan); color: var(--sh-cyan); }
.sh-btn-primary {
    background: linear-gradient(135deg, var(--sh-red), #b20710);
    color: #fff;
    box-shadow: 0 4px 20px var(--sh-red-glow);
}
.sh-btn-primary:hover { transform: translateY(-1px); filter: brightness(1.08); }

.sh-avatar {
    width: 40px; height: 40px;
    border-radius: 50%;
    border: 2px solid var(--sh-border);
    background: linear-gradient(135deg, #333, #111);
    color: var(--sh-text-hi);
    font-weight: 700;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
}
.sh-avatar-guest { text-decoration: none; font-size: 1rem; }

.sh-lang, .sh-profile { position: relative; }
.sh-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 200px;
    background: rgba(16, 16, 20, 0.98);
    border: 1px solid var(--sh-border);
    border-radius: var(--sh-radius);
    padding: 0.5rem;
    box-shadow: var(--sh-shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.25s var(--sh-ease);
    z-index: 100;
}
.sh-lang.open .sh-dropdown, .sh-profile.open .sh-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.sh-dropdown button, .sh-dropdown a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: none;
    background: none;
    color: var(--sh-text);
    text-decoration: none;
    font-size: 0.88rem;
    border-radius: 8px;
    cursor: pointer;
    font-family: inherit;
}
.sh-dropdown button:hover, .sh-dropdown a:hover { background: var(--sh-glass); color: var(--sh-text-hi); }
.sh-dropdown button.active { color: var(--sh-cyan); }
.sh-dropdown-head { padding: 0.75rem; border-bottom: 1px solid var(--sh-border); margin-bottom: 0.25rem; }
.sh-dropdown-head strong { display: block; color: var(--sh-text-hi); }
.sh-dropdown-head small { color: var(--sh-text); font-size: 0.78rem; }
.sh-dropdown hr { border: none; border-top: 1px solid var(--sh-border); margin: 0.35rem 0; }
.sh-dropdown a.danger { color: #f87171; }

/* Bottom nav mobile */
.sh-bottom-nav {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: var(--sh-bottom-nav-h);
    background: rgba(10, 10, 10, 0.96);
    backdrop-filter: blur(16px);
    border-top: 1px solid var(--sh-border);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 999;
}
.sh-bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    color: var(--sh-text);
    text-decoration: none;
    font-size: 0.65rem;
    padding: 0.35rem;
}
.sh-bottom-nav a i { font-size: 1.15rem; }
.sh-bottom-nav a.active { color: var(--sh-cyan); }

/* ─── Hero Slider ──────────────────────────────────────── */
.sh-hero {
    position: relative;
    height: min(88vh, 820px);
    min-height: 520px;
    margin-top: 0;
    overflow: hidden;
}
.sh-hero-slides { position: absolute; inset: 0; }
.sh-hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s var(--sh-ease), visibility 1s;
    background-color: #0a0a0a;
    background-size: cover;
    background-position: center 20%;
    background-repeat: no-repeat;
    background-image: var(--hero-bg, linear-gradient(135deg, #0a0a12 0%, #1a0a14 50%, #0a0a0a 100%));
}
.sh-hero-slide.active { opacity: 1; visibility: visible; z-index: 1; }
.sh-hero-gradient {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(10,10,10,0.97) 0%, rgba(10,10,10,0.5) 45%, transparent 70%),
        linear-gradient(0deg, var(--sh-bg) 0%, transparent 40%),
        linear-gradient(180deg, rgba(10,10,10,0.6) 0%, transparent 30%);
}
.sh-hero-vignette {
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 120px rgba(0,0,0,0.5);
}
.sh-hero-fade-bottom {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 120px;
    background: linear-gradient(transparent, var(--sh-bg));
    z-index: 2;
    pointer-events: none;
}
.sh-hero-content {
    position: absolute;
    bottom: 18%;
    left: 0; right: 0;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 2rem;
    z-index: 3;
    max-width: 640px;
    margin-left: max(2rem, calc((100vw - 1600px) / 2 + 2rem));
}
.sh-hero-badges { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
.sh-hero-title {
    font-size: clamp(2.2rem, 5vw, 3.75rem);
    font-weight: 800;
    color: var(--sh-text-hi);
    line-height: 1.08;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
    text-shadow: 0 4px 40px rgba(0,0,0,0.8);
}
.sh-hero-desc {
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.75);
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.sh-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--sh-text);
    margin-bottom: 1.5rem;
}
.sh-hero-meta .fa-star { color: var(--sh-gold); }
.sh-hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.sh-btn-play {
    background: var(--sh-text-hi);
    color: #0a0a0a;
    padding: 0.75rem 1.75rem;
    font-size: 1rem;
    border-radius: 8px;
    font-weight: 700;
}
.sh-btn-play:hover { background: #fff; transform: scale(1.03); }
.sh-btn-glass {
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--sh-text-hi);
    padding: 0.75rem 1.5rem;
}
.sh-btn-glass:hover { background: rgba(255,255,255,0.2); }
.sh-btn-disabled { opacity: 0.6; cursor: not-allowed; }

.sh-hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 48px; height: 48px;
    border-radius: 50%;
    border: 1px solid var(--sh-border);
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    color: #fff;
    cursor: pointer;
    transition: all 0.25s;
}
.sh-hero-arrow:hover {
    background: rgba(0, 212, 255, 0.2);
    border-color: var(--sh-cyan);
    transform: translateY(-50%) scale(1.08);
}
.sh-hero-prev { left: 1.5rem; }
.sh-hero-next { right: 1.5rem; }
.sh-hero-dots {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 0.5rem;
}
.sh-hero-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.35);
    cursor: pointer;
    padding: 0;
    transition: all 0.3s;
}
.sh-hero-dot.active {
    width: 28px;
    border-radius: 4px;
    background: var(--sh-cyan);
    box-shadow: 0 0 12px var(--sh-cyan);
}

/* Badges */
.sh-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.sh-badge-tech {
    background: rgba(0, 212, 255, 0.15);
    border: 1px solid rgba(0, 212, 255, 0.35);
    color: var(--sh-cyan);
}
.sh-badge-dolby {
    background: rgba(139, 92, 246, 0.2);
    border: 1px solid rgba(139, 92, 246, 0.4);
    color: #c4b5fd;
}
.sh-badge-age {
    background: rgba(255,255,255,0.1);
    border: 1px solid var(--sh-border);
    color: var(--sh-text-hi);
}
.sh-badge-premium {
    background: linear-gradient(90deg, var(--sh-red), #ff6b35);
    color: #fff;
    border: none;
}
.sh-badge-lock {
    background: rgba(229, 9, 20, 0.25);
    border: 1px solid rgba(229, 9, 20, 0.5);
    color: #ff8a8a;
}

/* ─── Content rows ─────────────────────────────────────── */
.sh-main {
    position: relative;
    z-index: 5;
    margin-top: -4rem;
    padding-bottom: 4rem;
}
.sh-row {
    margin-bottom: 2.5rem;
    padding: 0 2rem;
    max-width: 1600px;
    margin-left: auto;
    margin-right: auto;
}
.sh-row-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}
.sh-row-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--sh-text-hi);
    letter-spacing: -0.01em;
}
.sh-see-all {
    margin-left: auto;
    color: var(--sh-cyan);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: gap 0.2s;
}
.sh-see-all:hover { gap: 0.55rem; }
.sh-count { font-size: 0.82rem; color: var(--sh-text); margin-left: auto; }
.sh-row-arrows { display: flex; gap: 0.35rem; }
.sh-row-arrow {
    width: 36px; height: 36px;
    border-radius: 50%;
    border: 1px solid var(--sh-border);
    background: var(--sh-glass);
    color: var(--sh-text-hi);
    cursor: pointer;
    transition: all 0.2s;
}
.sh-row-arrow:hover { border-color: var(--sh-cyan); color: var(--sh-cyan); }

.sh-row-track {
    display: flex;
    gap: 0.85rem;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 0.5rem 0 1rem;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.sh-row-track::-webkit-scrollbar { display: none; }
.sh-row-track-grid { flex-wrap: wrap; overflow-x: visible; scroll-snap-type: none; }

/* ─── Cards ──────────────────────────────────────────────── */
.sh-card {
    position: relative;
    flex: 0 0 240px;
    scroll-snap-align: start;
}
.sh-row-track-grid .sh-card { flex: 0 0 calc(20% - 0.7rem); min-width: 200px; }
@media (max-width: 1200px) { .sh-row-track-grid .sh-card { flex: 0 0 calc(25% - 0.7rem); } }
@media (max-width: 768px) { .sh-card { flex: 0 0 200px; } .sh-row-track-grid .sh-card { flex: 0 0 calc(50% - 0.5rem); min-width: 160px; } }

.sh-card-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    height: 100%;
    border-radius: var(--sh-radius);
    background: var(--sh-surface);
    border: 1px solid var(--sh-border);
    overflow: hidden;
    transition: transform 0.35s var(--sh-ease), border-color 0.3s, box-shadow 0.35s;
}
.sh-card:hover .sh-card-link {
    transform: translateY(-4px);
    border-color: var(--sh-border-hover);
    box-shadow: 0 16px 40px rgba(0, 212, 255, 0.1), var(--sh-shadow);
}
.sh-card-poster {
    position: relative;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: var(--sh-bg-elevated);
}
.sh-card-poster-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.sh-card-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--sh-text);
    background: linear-gradient(145deg, #1a1a22, #0d0d10);
}
.sh-card-badges-top {
    position: absolute;
    top: 0.5rem; left: 0.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    z-index: 2;
}
.sh-card-poster > .sh-badge-age {
    position: absolute;
    top: 0.5rem; right: 0.5rem;
    z-index: 2;
}
.sh-card-progress {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 4px;
    background: rgba(0,0,0,0.5);
    z-index: 3;
}
.sh-card-progress span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--sh-cyan), var(--sh-red));
    border-radius: 0 2px 2px 0;
}
.sh-card-play-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}
.sh-card:hover .sh-card-play-overlay { opacity: 1; }
.sh-card-play {
    width: 48px; height: 48px;
    background: rgba(255,255,255,0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0a0a0a;
    font-size: 1rem;
    padding-left: 3px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

/* Always-visible card info */
.sh-card-info {
    padding: 0.75rem 0.85rem 0.9rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}
.sh-card-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--sh-text-hi);
    margin: 0;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.sh-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.65rem;
    font-size: 0.74rem;
    color: var(--sh-text);
}
.sh-rating { color: var(--sh-gold); }
.sh-card-genres {
    font-size: 0.72rem;
    color: rgba(255,255,255,0.5);
    margin: 0;
    line-height: 1.3;
}
.sh-card-cast {
    font-size: 0.68rem;
    color: rgba(255,255,255,0.4);
    margin: 0;
    font-style: italic;
}
.sh-views { color: rgba(255,255,255,0.45); }
.sh-views i { font-size: 0.65rem; margin-right: 0.15rem; }
.sh-card-resume-badge {
    position: absolute;
    bottom: 0.75rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 212, 255, 0.9);
    color: #0a0a0a;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.75rem;
    border-radius: 100px;
    white-space: nowrap;
}
.sh-card-resume-text {
    font-size: 0.72rem;
    color: var(--sh-cyan);
    margin: 0.2rem 0 0;
}
.sh-row-empty {
    color: var(--sh-text);
    font-size: 0.9rem;
    padding: 0.5rem 0 1rem;
    line-height: 1.5;
}
.sh-row-empty i { color: var(--sh-cyan); }

/* Toast */
.sh-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3000;
    background: rgba(20, 22, 30, 0.96);
    border: 1px solid var(--sh-border);
    color: var(--sh-text-hi);
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
    font-size: 0.9rem;
    box-shadow: var(--sh-shadow);
    max-width: 90vw;
    text-align: center;
}
.sh-toast.hidden { display: none; }

/* My List page */
.sh-page-header {
    padding: calc(var(--sh-header-h) + 1.5rem) 2rem 1rem;
    max-width: 1600px;
    margin: 0 auto;
}
.sh-page-header h1 { color: var(--sh-text-hi); font-size: 1.75rem; margin: 0.5rem 0 0.25rem; }
.sh-page-sub { color: var(--sh-text); margin: 0; }
.sh-back {
    color: var(--sh-text);
    text-decoration: none;
    font-size: 0.88rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.sh-back:hover { color: var(--sh-cyan); }
.sh-grid-page {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    padding: 0 2rem 3rem;
    max-width: 1600px;
    margin: 0 auto;
}
.sh-empty-page {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--sh-text);
}
.sh-empty-page i { font-size: 3rem; color: var(--sh-cyan); margin-bottom: 1rem; }
.sh-empty-page h2 { color: var(--sh-text-hi); margin-bottom: 0.5rem; }

/* Browse / genre pages */
.sh-browse-header { padding-bottom: 0.5rem; }
.sh-browse-toolbar {
    margin-top: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.sh-sort-form {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.88rem;
}
.sh-sort-form label { color: var(--sh-text); }
.sh-sort-form select {
    background: var(--sh-bg-elevated);
    border: 1px solid var(--sh-border);
    color: var(--sh-text-hi);
    padding: 0.45rem 0.75rem;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.88rem;
}
.sh-browse-pills {
    padding: 0 2rem 1.25rem;
    max-width: 1600px;
    margin: 0 auto;
}
.sh-browse-pills .sh-genre-pill {
    text-decoration: none;
    display: inline-block;
}
.sh-browse-grid {
    padding-top: 0.5rem;
}

/* Pagination */
.sh-pagination {
    max-width: 1600px;
    margin: 0 auto 3rem;
    padding: 2rem 2rem 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}
.sh-pagination-info {
    font-size: 0.85rem;
    color: var(--sh-text);
}
.sh-pagination-total { color: rgba(255,255,255,0.4); margin-left: 0.35rem; }
.sh-pagination-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
}
.sh-page-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-width: 40px;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid var(--sh-border);
    background: var(--sh-glass);
    color: var(--sh-text-hi);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
}
.sh-page-btn:hover:not(.disabled):not(.active) {
    border-color: var(--sh-cyan);
    color: var(--sh-cyan);
}
.sh-page-btn.active {
    background: var(--sh-cyan);
    border-color: var(--sh-cyan);
    color: #0a0a0a;
    font-weight: 700;
}
.sh-page-btn.disabled {
    opacity: 0.35;
    cursor: not-allowed;
}
.sh-card-status { font-size: 0.68rem; color: var(--sh-cyan); margin-top: 0.15rem; }

.sh-watchlist-btn {
    position: absolute;
    top: 0.5rem; right: 0.5rem;
    z-index: 5;
    width: 34px; height: 34px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(8px);
    color: #fff;
    cursor: pointer;
    opacity: 0;
    transition: all 0.25s;
}
.sh-card:hover .sh-watchlist-btn { opacity: 1; }
.sh-watchlist-btn.active { opacity: 1; color: var(--sh-red); }
.sh-watchlist-btn:hover { transform: scale(1.1); background: rgba(229,9,20,0.3); }

/* Genre pills */
.sh-genre-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.sh-genre-pill {
    padding: 0.4rem 1rem;
    border-radius: 100px;
    font-size: 0.8rem;
    font-family: inherit;
    text-decoration: none;
    color: var(--sh-text);
    border: 1px solid var(--sh-border);
    background: var(--sh-glass);
    transition: all 0.2s;
    cursor: pointer;
}
.sh-genre-pill:hover, .sh-genre-pill.active {
    border-color: var(--sh-cyan);
    color: var(--sh-cyan);
    background: var(--sh-cyan-dim);
}
.sh-genre-clear {
    margin-left: 0.5rem;
    background: rgba(229, 9, 20, 0.15);
    border: 1px solid rgba(229, 9, 20, 0.4);
    color: #ff8a8a;
    padding: 0.3rem 0.65rem;
    border-radius: 100px;
    font-size: 0.75rem;
    cursor: pointer;
    font-family: inherit;
}
.sh-genre-clear.hidden { display: none; }
.sh-card-hidden { display: none !important; }
.hidden { display: none !important; }

/* Studio strip */
.sh-studio-strip {
    margin: 3rem 2rem;
    max-width: 1600px;
    margin-left: auto;
    margin-right: auto;
}
.sh-studio-inner {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 2rem;
    padding: 2.5rem;
    border-radius: var(--sh-radius-lg);
    background: linear-gradient(135deg, rgba(0,212,255,0.06) 0%, rgba(229,9,20,0.04) 100%);
    border: 1px solid var(--sh-border);
    backdrop-filter: blur(20px);
}
@media (max-width: 900px) { .sh-studio-inner { grid-template-columns: 1fr; } }
.sh-studio-label {
    color: var(--sh-cyan);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.sh-studio-copy h3 {
    font-size: 1.75rem;
    color: var(--sh-text-hi);
    margin: 0.5rem 0 0.75rem;
}
.sh-studio-copy p { line-height: 1.65; margin-bottom: 1.25rem; max-width: 520px; }
.sh-studio-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
}
.sh-studio-stats strong { display: block; font-size: 1.5rem; color: var(--sh-cyan); }
.sh-studio-stats span { font-size: 0.78rem; color: var(--sh-text); }
.sh-glass-panel {
    padding: 2rem;
    border-radius: var(--sh-radius);
    background: var(--sh-glass);
    border: 1px solid var(--sh-border);
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}
.sh-glass-panel i { font-size: 3rem; color: var(--sh-cyan); opacity: 0.8; }

/* More Info modal */
.sh-modal-card-lg {
    max-width: 720px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 0;
}
.sh-modal-hero { display: flex; flex-direction: column; }
@media (min-width: 640px) {
    .sh-modal-hero { flex-direction: row; }
    .sh-modal-poster {
        width: 200px;
        min-height: 280px;
        flex-shrink: 0;
        background: center/cover;
        border-radius: var(--sh-radius) 0 0 var(--sh-radius);
    }
    .sh-modal-body { flex: 1; padding: 1.5rem 1.75rem; }
}
.sh-modal-poster {
    height: 180px;
    background: center/cover;
}
.sh-modal-body { padding: 1.25rem 1.5rem; }
.sh-modal-body h2 {
    color: var(--sh-text-hi);
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}
.sh-info-tagline { color: var(--sh-cyan); font-size: 0.95rem; margin-bottom: 0.75rem; }
.sh-info-desc { line-height: 1.65; margin-bottom: 1rem; color: var(--sh-text); font-size: 0.9rem; }
.sh-info-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem 1rem;
    margin-bottom: 1.25rem;
    font-size: 0.85rem;
}
.sh-info-meta-grid label {
    display: block;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--sh-text);
    margin-bottom: 0.15rem;
}
.sh-info-meta-grid span { color: var(--sh-text-hi); }
.sh-info-meta-grid .full { grid-column: 1 / -1; }
.sh-info-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* Modal shell */
.sh-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}
.sh-modal.hidden { display: none; }
.sh-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
}
.sh-modal-card {
    position: relative;
    max-width: 520px;
    width: 100%;
    padding: 2rem;
    background: var(--sh-bg-elevated);
    border: 1px solid var(--sh-border);
    border-radius: var(--sh-radius-lg);
    box-shadow: var(--sh-shadow);
}
.sh-modal-close {
    position: absolute;
    top: 1rem; right: 1rem;
    background: none;
    border: none;
    color: var(--sh-text);
    font-size: 1.25rem;
    cursor: pointer;
}
.sh-modal-card h3 { color: var(--sh-text-hi); margin-bottom: 0.75rem; }
.sh-search-results { padding: 6rem 2rem 2rem; max-width: 1600px; margin: 0 auto; }
.sh-search-results h2 { color: var(--sh-text-hi); margin-bottom: 1.5rem; }
.sh-empty { color: var(--sh-text); padding: 2rem; }

@media (max-width: 768px) {
    .sh-hero { min-height: 480px; height: 75vh; }
    .sh-hero-content { margin-left: 0; padding: 0 1.25rem; bottom: 14%; }
    .sh-hero-arrow { width: 40px; height: 40px; }
    .sh-hero-prev { left: 0.75rem; }
    .sh-hero-next { right: 0.75rem; }
    .sh-row { padding: 0 1.25rem; }
    .sh-nav { padding: 0 1rem; }
    .sh-search { max-width: none; flex: 1; }
    .sh-search kbd { display: none; }
}

/* ═══ App shell (all pages) ═══════════════════════════════ */
body.sh-app {
    background: var(--sh-bg);
    color: var(--sh-text);
    font-family: var(--font);
    padding-top: var(--sh-header-h) !important;
    min-height: 100vh;
}
body.sh-app > main { padding: 0; }
body.sh-app .navbar { display: none; }
body.sh-app.auth-page main {
    min-height: calc(100vh - var(--sh-header-h));
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}
body.sh-app.auth-page .auth-card-wrap { width: 100%; max-width: 420px; padding: 0; }

.sh-filter-input {
    width: 72px;
    padding: 0.4rem 0.5rem;
    border-radius: 8px;
    border: 1px solid var(--sh-border);
    background: var(--sh-bg-elevated);
    color: var(--sh-text-hi);
    font-size: 0.85rem;
}

/* ═══ Movie title page (hero look, normal document flow) ═══ */
body.sh-title-page {
    padding-top: 0 !important;
}
body.sh-title-page .sh-header {
    position: absolute;
    background: transparent;
    border: none;
}
body.sh-title-page .sh-header.scrolled {
    background: rgba(10,10,10,0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--sh-border);
}

/* Title page: no fixed viewport hero — buttons stay under description */
body.sh-title-page .movie-hero {
    min-height: auto;
    overflow: visible;
    margin-bottom: 0;
}
body.sh-title-page .movie-hero-inner {
    min-height: auto;
    justify-content: flex-start;
    padding-bottom: 2.5rem;
}
body.sh-title-page .movie-hero-layout {
    align-items: flex-start;
}
body.sh-title-page .sh-hero-desc {
    display: block;
    overflow: visible;
    -webkit-line-clamp: unset;
    margin-bottom: 1.25rem;
}
body.sh-title-page .sh-hero-actions {
    margin-top: 0;
    margin-bottom: 0;
    position: static;
}

.movie-hero {
    position: relative;
    min-height: 72vh;
    overflow: hidden;
}
.movie-hero-bg {
    position: absolute;
    inset: 0;
    background: #0a0a0a center/cover no-repeat;
    background-image: var(--movie-hero-bg, none);
    transform: scale(1.05);
    filter: blur(2px);
}
.movie-hero-gradient {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(10,10,10,0.98) 0%, rgba(10,10,10,0.75) 40%, rgba(10,10,10,0.35) 100%),
        linear-gradient(0deg, var(--sh-bg) 0%, transparent 35%);
}
.movie-hero-vignette {
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 100px rgba(0,0,0,0.4);
}
.movie-hero-fade {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100px;
    background: linear-gradient(transparent, var(--sh-bg));
    z-index: 2;
    pointer-events: none;
}
.movie-hero-inner {
    position: relative;
    z-index: 3;
    max-width: 1200px;
    margin: 0 auto;
    padding: calc(var(--sh-header-h) + 1rem) 2rem 3rem;
    min-height: 72vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}
.movie-hero-back {
    position: absolute;
    top: calc(var(--sh-header-h) + 0.5rem);
    left: 2rem;
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-size: 0.88rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}
.movie-hero-back:hover { color: #fff; }
.movie-hero-layout {
    display: flex;
    gap: 2rem;
    align-items: flex-end;
}
.movie-hero-poster {
    flex-shrink: 0;
    width: 220px;
}
.movie-hero-poster img {
    width: 100%;
    aspect-ratio: 2/3;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.55);
    border: 1px solid rgba(255,255,255,0.1);
    display: block;
}
.movie-hero-copy { flex: 1; min-width: 0; max-width: 640px; }
.movie-hero-tagline {
    color: var(--sh-cyan);
    font-size: 1.05rem;
    margin: -0.25rem 0 0.75rem;
}
.movie-hero-details {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem 1rem;
}
.movie-meta-block p {
    color: var(--sh-text);
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0.35rem 0;
}
.movie-meta-block strong { color: var(--sh-text-hi); }
body.sh-title-page .sh-main,
.movie-hero-main {
    margin-top: 0 !important;
    padding-top: 1.5rem;
    position: relative;
    z-index: 5;
    clear: both;
}

@media (max-width: 768px) {
    body.sh-title-page .movie-hero-inner {
        padding-bottom: 2rem;
    }
    body.sh-title-page .movie-hero-layout {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    body.sh-title-page .movie-hero-poster { width: 160px; }
    body.sh-title-page .movie-hero-copy { max-width: none; }
    body.sh-title-page .sh-hero-actions { justify-content: center; }

    .movie-hero { min-height: auto; }
    .movie-hero-inner { min-height: auto; padding-bottom: 2rem; }
    .movie-hero-layout { flex-direction: column; align-items: center; text-align: center; }
    .movie-hero-poster { width: 160px; }
    .movie-hero-copy { max-width: none; }
    .sh-hero-actions { justify-content: center; }
}

/* ABR stats modal */
.abr-modal {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}
.abr-modal.hidden { display: none; }
.abr-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.7);
}
.abr-modal-sheet {
    position: relative;
    width: 100%;
    max-width: 640px;
    max-height: 85vh;
    background: var(--sh-bg-elevated);
    border-radius: 16px 16px 0 0;
    border: 1px solid var(--sh-border);
    overflow: auto;
}
.abr-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--sh-border);
}
.abr-modal-head h3 { margin: 0; color: var(--sh-text-hi); font-size: 1rem; }
.abr-modal-close {
    background: none;
    border: none;
    color: var(--sh-text);
    font-size: 1.2rem;
    cursor: pointer;
}
.abr-modal-body { padding: 1rem 1.25rem 1.5rem; }
.abr-modal-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1rem;
}
.abr-modal-cols h4 {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--sh-text);
    margin: 0 0 0.5rem;
}
.abr-table-compact { font-size: 0.78rem; }

/* Profile page */
.profile-page {
    max-width: 480px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
}
.profile-page h1 { color: var(--sh-text-hi); margin: 1rem 0 0.25rem; }
.profile-sub { color: var(--sh-text); margin-bottom: 1.5rem; }
.profile-form label {
    display: block;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--sh-text);
    margin: 1rem 0 0.35rem;
}
.profile-form input[type=text],
.profile-form select {
    width: 100%;
    padding: 0.65rem 0.85rem;
    border-radius: 8px;
    border: 1px solid var(--sh-border);
    background: var(--sh-bg-elevated);
    color: var(--sh-text-hi);
}
.field-hint { font-size: 0.8rem; color: var(--sh-text); margin-top: 0.35rem; }
.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 0.5rem;
    text-transform: none !important;
    margin-top: 1.25rem !important;
}

@media (max-width: 900px) {
    .abr-modal-cols { grid-template-columns: 1fr; }
}
