/* ===== ShowBoat Web — Desktop-First Premium Stylesheet ===== */

/* --- CSS Variables --- */
:root {
  --slate-50: #f8fafc; --slate-100: #f1f5f9; --slate-200: #e2e8f0;
  --slate-300: #cbd5e1; --slate-400: #94a3b8; --slate-500: #64748b;
  --slate-600: #475569; --slate-700: #334155; --slate-800: #1e293b;
  --slate-900: #0f172a; --slate-950: #020617;
  --emerald-200: #a7f3d0; --emerald-300: #6ee7b7; --emerald-400: #34d399;
  --emerald-500: #10b981; --emerald-600: #059669; --emerald-700: #047857;
  --emerald-800: #065f46; --emerald-900: #064e3b;
  --indigo-200: #c7d2fe; --indigo-300: #a5b4fc; --indigo-400: #818cf8;
  --indigo-500: #6366f1; --indigo-600: #4f46e5; --indigo-700: #4338ca;
  --indigo-800: #3730a3; --indigo-900: #312e81;
  --purple-500: #a855f7; --purple-600: #9333ea;
  --blue-500: #3b82f6; --blue-600: #2563eb;
  --amber-200: #fde68a; --amber-300: #fcd34d; --amber-400: #fbbf24;
  --amber-500: #f59e0b; --amber-600: #d97706; --amber-700: #b45309;
  --amber-800: #92400e; --amber-900: #78350f;
  --orange-400: #fb923c; --orange-500: #f97316;
  --yellow-500: #eab308;
  --rose-200: #fecdd3; --rose-300: #fda4af; --rose-400: #fb7185;
  --rose-500: #f43f5e; --rose-600: #e11d48; --rose-700: #be123c;
  --rose-800: #9f1239; --rose-900: #881337;
  --pink-500: #ec4899; --fuchsia-500: #d946ef; --violet-500: #8b5cf6;
  --teal-500: #14b8a6; --cyan-500: #06b6d4; --lime-500: #84cc16;
  --green-600: #16a34a; --red-400: #f87171; --red-500: #ef4444;
  --bg-primary: #020617;
  --bg-secondary: #0f172a;
  --accent: #10b981;
  --sidebar-width: 240px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --glass-bg: rgba(15,23,42,.65);
  --glass-border: rgba(255,255,255,.06);
  --glass-blur: blur(20px);
  --transition: .25s cubic-bezier(.4,0,.2,1);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--slate-950);
  color: var(--slate-200);
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: var(--emerald-400); text-decoration: none; }
a:hover { color: var(--emerald-300); }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
input, select, textarea {
  font-family: inherit; font-size: .9375rem; color: white;
  background: var(--slate-900); border: 1px solid var(--slate-800); border-radius: var(--radius-md);
  padding: 12px 16px; outline: none; width: 100%; transition: border-color var(--transition);
}
input:focus, select:focus, textarea:focus { border-color: var(--emerald-500); box-shadow: 0 0 0 3px rgba(16,185,129,.1); }
input::placeholder, textarea::placeholder { color: var(--slate-500); }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--slate-700); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--slate-600); }

/* --- Loading Screen --- */
.loading-screen {
  position: fixed; inset: 0; background: var(--slate-950);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  z-index: 9999; gap: 16px; transition: opacity .3s;
}
.loading-screen.fade-out { opacity: 0; pointer-events: none; }
.loading-logo { width: 80px; height: 80px; display: flex; align-items: center; justify-content: center; }
.loading-logo img { width: 56px; height: 56px; object-fit: contain; }
.loading-title { font-size: 2rem; font-weight: 700; color: white; letter-spacing: -.5px; }

/* Brand logo images */
.brand-wordmark { height: 32px; width: auto; object-fit: contain; display: block; }
.brand-icon { width: 36px; height: 36px; object-fit: contain; display: block; }
.sidebar-wordmark { height: 34px; }
.auth-split-brand .brand-wordmark { height: 36px; }
.landing-nav-brand .brand-wordmark { height: 28px; }
.spinner { width: 32px; height: 32px; border: 3px solid var(--slate-800); border-top-color: var(--emerald-500); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* =============================================
   LAYOUT — Desktop sidebar + content
   ============================================= */
#app { min-height: 100vh; }

.app-layout {
  display: flex; min-height: 100vh;
}

/* --- Sidebar Navigation (Desktop) --- */
.sidebar-nav {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--sidebar-width); background: rgba(15,23,42,.92);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-right: 1px solid var(--glass-border);
  display: flex; flex-direction: column;
  z-index: 200; padding: 0;
  transition: transform var(--transition);
}
.sidebar-nav.hidden { display: none; }
.sidebar-brand {
  display: flex; align-items: center; gap: 12px;
  padding: 24px 20px 20px; border-bottom: 1px solid rgba(255,255,255,.04);
}
.sidebar-brand svg { flex-shrink: 0; }
.sidebar-brand-text {
  font-size: 1.25rem; font-weight: 800; color: white; letter-spacing: -.5px;
}
.sidebar-links {
  flex: 1; padding: 12px 8px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 2px;
}
.sidebar-divider { height: 1px; background: rgba(255,255,255,.04); margin: 8px 12px; }
.sidebar-btn {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: var(--radius-md);
  color: var(--slate-400); font-size: .875rem; font-weight: 500;
  transition: all var(--transition); white-space: nowrap;
}
.sidebar-btn:hover { background: rgba(255,255,255,.04); color: var(--slate-200); }
.sidebar-btn.active {
  background: rgba(16,185,129,.08); color: var(--emerald-400);
  font-weight: 600;
}
.sidebar-btn svg { flex-shrink: 0; width: 20px; height: 20px; }
.sidebar-footer {
  padding: 8px; border-top: 1px solid rgba(255,255,255,.04);
}

/* --- Page Content (with sidebar) --- */
.page-content {
  flex: 1; min-height: 100vh; margin-left: 0;
  overflow-y: auto; overflow-x: hidden;
}
.page-content.has-nav { margin-left: var(--sidebar-width); }

/* --- Bottom Nav (Mobile) --- */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; height: 64px;
  background: rgba(15,23,42,.96); backdrop-filter: blur(20px);
  border-top: 1px solid var(--glass-border);
  display: none; align-items: center; justify-content: space-around;
  z-index: 200; padding: 0 8px;
}
.nav-btn {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 6px 12px; border-radius: var(--radius-sm); color: var(--slate-500);
  font-size: 10px; font-weight: 500; transition: color var(--transition); min-width: 52px;
}
.nav-btn.active { color: var(--emerald-400); }

/* =============================================
   MOBILE: hide sidebar, show bottom nav
   ============================================= */
@media (max-width: 1023px) {
  .sidebar-nav { display: none !important; }
  .page-content { margin-left: 0 !important; padding-bottom: 72px; }
  .bottom-nav { display: flex; }
}

/* =============================================
   AUTH PAGES
   ============================================= */
.auth-page {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; padding: 24px;
  background: radial-gradient(ellipse 70% 50% at 50% 20%, rgba(16,185,129,.04) 0%, transparent 70%), var(--slate-950);
}
.auth-logo { width: 80px; height: 80px; background: rgba(16,185,129,.08); border-radius: 24px; display: flex; align-items: center; justify-content: center; border: 1px solid rgba(16,185,129,.15); margin-bottom: 16px; }
.auth-title { font-size: 2rem; font-weight: 700; color: white; margin-bottom: 8px; letter-spacing: -.5px; }
.auth-subtitle { color: var(--slate-400); font-size: 1rem; margin-bottom: 48px; }
.auth-form { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 20px; }
.input-group { display: flex; flex-direction: column; gap: 6px; }
.input-group label { color: var(--slate-300); font-size: .8125rem; font-weight: 600; margin-left: 2px; }
.input-wrapper {
  display: flex; align-items: center; gap: 12px;
  background: var(--slate-900); border: 1px solid var(--slate-800);
  border-radius: var(--radius-md); padding: 0 16px; height: 52px;
  transition: border-color var(--transition);
}
.input-wrapper:focus-within { border-color: var(--emerald-500); box-shadow: 0 0 0 3px rgba(16,185,129,.1); }
.input-wrapper input { border: none; padding: 0; background: transparent; flex: 1; height: 100%; }
.input-wrapper input:focus { border-color: transparent; box-shadow: none; }
.input-wrapper svg { flex-shrink: 0; color: var(--slate-400); }
.input-helper { font-size: .75rem; color: var(--slate-500); margin-left: 4px; }
.btn-primary {
  background: linear-gradient(135deg, var(--emerald-500), var(--emerald-600));
  color: white; font-weight: 700; font-size: .9375rem; padding: 14px 24px;
  border-radius: var(--radius-md); text-align: center; letter-spacing: .3px;
  box-shadow: 0 4px 12px rgba(16,185,129,.25); transition: all var(--transition);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(16,185,129,.35); }
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.auth-footer { text-align: center; margin-top: 16px; color: var(--slate-400); font-size: .875rem; }
.auth-footer a { color: var(--emerald-400); font-weight: 700; }
.toggle-password { cursor: pointer; color: var(--slate-400); background: none; border: none; display: flex; }

/* TMDB Attribution */
.tmdb-attribution {
  display: flex; align-items: center; gap: 12px; margin-top: 32px; padding-top: 20px;
  border-top: 1px solid var(--glass-border);
}
.tmdb-attr-logo { height: 16px; width: auto; flex-shrink: 0; opacity: .7; }
.tmdb-attribution p {
  color: var(--slate-500); font-size: .6875rem; line-height: 1.5; margin: 0;
}
.app-version {
  color: var(--slate-600); font-size: .6875rem; text-align: center; margin-top: 16px;
}

/* =============================================
   AUTH SPLIT LAYOUT (redesigned login/signup)
   ============================================= */
.auth-split-page {
  display: flex; min-height: 100vh;
}
.auth-split-left {
  width: 44%; background: linear-gradient(160deg, var(--slate-950) 0%, rgba(16,185,129,.03) 100%);
  border-right: 1px solid var(--glass-border); padding: 48px 40px;
  display: flex; flex-direction: column; gap: 28px; position: relative; overflow: hidden;
}
.auth-split-left::before {
  content: ''; position: absolute; top: -80px; left: -80px;
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(16,185,129,.06) 0%, transparent 70%);
  pointer-events: none;
}
.auth-split-right {
  flex: 1; display: flex; align-items: center; justify-content: center;
  padding: 32px 24px; background: var(--bg-primary);
}
.auth-form-card {
  width: 100%; max-width: 420px;
}
.auth-form-header {
  margin-bottom: 28px;
}
.auth-logo-sm {
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.auth-logo-sm .brand-icon { width: 48px; height: 48px; }
.auth-split-brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--emerald-400); font-weight: 800; font-size: 1.25rem; z-index: 1; position: relative;
}
.auth-split-headline {
  font-size: 1.875rem; font-weight: 800; color: white;
  line-height: 1.2; z-index: 1; position: relative;
}
.auth-split-sub {
  color: var(--slate-400); font-size: .9375rem; line-height: 1.6; z-index: 1; position: relative;
}
.auth-features-list {
  display: flex; flex-direction: column; gap: 16px; z-index: 1; position: relative;
}
.auth-feature {
  display: flex; align-items: flex-start; gap: 12px;
}
.auth-feature-icon {
  width: 36px; height: 36px; border-radius: 10px;
  background: rgba(16,185,129,.08); border: 1px solid rgba(16,185,129,.15);
  display: flex; align-items: center; justify-content: center;
  color: var(--emerald-400); flex-shrink: 0;
}
.auth-feature-title { color: white; font-weight: 600; font-size: .875rem; margin-bottom: 2px; }
.auth-feature-desc { color: var(--slate-400); font-size: .8rem; line-height: 1.45; }
.auth-split-back {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--slate-500); font-size: .8125rem; margin-top: auto;
  z-index: 1; position: relative; cursor: pointer;
}
.auth-split-back:hover { color: var(--slate-300); }
.auth-submit-btn {
  width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.auth-tmdb {
  display: flex; align-items: center; gap: 10px; margin-top: 28px; padding-top: 20px;
  border-top: 1px solid var(--glass-border);
}
.auth-tmdb img { height: 14px; opacity: .6; }
.auth-tmdb p { color: var(--slate-500); font-size: .6875rem; line-height: 1.5; margin: 0; }
@media (max-width: 767px) {
  .auth-split-left { display: none; }
  .auth-split-right { padding: 28px 20px; align-items: flex-start; padding-top: 48px; }
}

/* =============================================
   LANDING PAGE
   ============================================= */
.landing-page {
  min-height: 100vh; background: var(--bg-primary); color: var(--slate-300);
  overflow: hidden;
}
/* Nav */
.landing-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 32px; border-bottom: 1px solid var(--glass-border);
  position: sticky; top: 0; z-index: 100;
  background: rgba(2,6,23,.88); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.landing-nav-brand {
  display: flex; align-items: center;
}
.landing-nav-brand .brand-wordmark { height: 28px; }
.landing-nav-links { display: flex; gap: 10px; align-items: center; }
.landing-nav-login {
  background: none; border: 1px solid var(--glass-border); color: var(--slate-300);
  padding: 8px 20px; border-radius: var(--radius-md); font-weight: 600;
  cursor: pointer; font-size: .875rem; transition: all var(--transition);
}
.landing-nav-login:hover { border-color: var(--slate-600); color: white; }
.landing-nav-cta {
  background: linear-gradient(135deg, var(--emerald-500), var(--emerald-600));
  color: white; padding: 8px 20px; border-radius: var(--radius-md);
  font-weight: 700; font-size: .875rem; cursor: pointer;
  box-shadow: 0 2px 8px rgba(16,185,129,.3); transition: all var(--transition);
}
.landing-nav-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(16,185,129,.4); }

/* Hero */
.landing-hero {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 64px;
  padding: 100px 64px 80px; max-width: 1100px; margin: 0 auto;
  min-height: 70vh;
}
.landing-hero-orb {
  position: absolute; border-radius: 50%; pointer-events: none; filter: blur(100px); opacity: .35;
}
.landing-hero-orb--1 {
  width: 560px; height: 560px; top: -70px; left: -150px;
  background: radial-gradient(circle, var(--emerald-600), transparent 70%);
  animation: landing-orb-float 12s ease-in-out infinite alternate;
}
.landing-hero-orb--2 {
  width: 460px; height: 460px; bottom: -40px; right: -120px;
  background: radial-gradient(circle, var(--indigo-600), transparent 70%);
  animation: landing-orb-float 10s ease-in-out infinite alternate-reverse;
}
@keyframes landing-orb-float {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(30px, -20px) scale(1.08); }
}
.landing-hero-content { flex: 1; min-width: 0; position: relative; z-index: 1; }
.landing-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(16,185,129,.08); border: 1px solid rgba(16,185,129,.2);
  color: var(--emerald-400); padding: 6px 14px; border-radius: 999px;
  font-size: .8125rem; font-weight: 600; margin-bottom: 28px;
}
.landing-h1 {
  font-size: 3.5rem; font-weight: 800; color: white;
  line-height: 1.08; margin-bottom: 20px; letter-spacing: -.75px;
}
.landing-tagline {
  color: var(--slate-400); font-size: 1.125rem; line-height: 1.7;
  margin-bottom: 40px; max-width: 520px;
}
.landing-cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.landing-cta-main {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 32px; font-size: 1rem; border-radius: var(--radius-md);
  font-weight: 700; box-shadow: 0 4px 20px rgba(16,185,129,.25);
  transition: all var(--transition);
}
.landing-cta-main:hover { transform: translateY(-2px); box-shadow: 0 6px 28px rgba(16,185,129,.35); }
.landing-cta-secondary {
  color: var(--slate-400); font-size: .9375rem; cursor: pointer;
  background: none; border: none; transition: color var(--transition); font-weight: 500;
}
.landing-cta-secondary:hover { color: white; }

/* Phone mockup */
.landing-hero-visual { flex-shrink: 0; position: relative; z-index: 1; max-width: 300px; }
.landing-hero-phone {
  width: 280px; background: var(--slate-900);
  border: 2px solid rgba(255,255,255,.08); border-radius: 32px;
  padding: 12px; box-shadow: 0 40px 100px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.03);
}
.landing-phone-screen {
  background: var(--bg-primary); border-radius: 22px; overflow: hidden;
}
.landing-phone-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 10px; border-bottom: 1px solid var(--glass-border);
}
.landing-phone-bar-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--emerald-500);
}
.landing-phone-bar-title {
  font-size: .6875rem; font-weight: 700; color: var(--slate-300); letter-spacing: .5px; text-transform: uppercase;
}
.landing-mock-feed { padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.landing-feed-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 12px;
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.04);
}
.landing-feed-av {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 700; font-size: .6875rem;
}
.landing-feed-body {
  font-size: .6875rem; color: var(--slate-400); line-height: 1.4;
}
.landing-feed-name { color: white; font-weight: 600; }
.landing-feed-body strong { color: var(--slate-200); }
.landing-feed-score {
  display: inline-block; background: var(--emerald-600); color: white;
  font-size: .5625rem; font-weight: 700; padding: 1px 5px; border-radius: 4px; margin-left: 2px;
}

/* Stats ribbon */
.landing-stats {
  display: flex; justify-content: center; gap: 48px; flex-wrap: wrap;
  padding: 48px 32px; border-top: 1px solid var(--glass-border);
  border-bottom: 1px solid var(--glass-border);
  background: rgba(15,23,42,.5);
}
.landing-stat {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.landing-stat-num {
  font-size: 1.25rem; font-weight: 800; color: var(--emerald-400);
  display: flex; align-items: center;
}
.landing-stat-label {
  font-size: .8125rem; color: var(--slate-400); font-weight: 500;
}

/* Features grid */
.landing-features { padding: 80px 48px; max-width: 1100px; margin: 0 auto; }
.landing-section-header { text-align: center; margin-bottom: 56px; }
.landing-section-title {
  font-size: 2rem; font-weight: 800; color: white;
  margin-bottom: 12px; letter-spacing: -.4px;
}
.landing-section-sub {
  color: var(--slate-400); font-size: 1.0625rem; max-width: 480px; margin: 0 auto;
}
.landing-features-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.landing-feature-card {
  background: rgba(15,23,42,.6); border: 1px solid rgba(255,255,255,.06);
  border-radius: 16px; padding: 32px 28px;
  transition: border-color .2s, transform .2s, box-shadow .2s;
}
.landing-feature-card:hover {
  border-color: rgba(16,185,129,.2); transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0,0,0,.3);
}
.landing-feature-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: rgba(16,185,129,.08); border: 1px solid rgba(16,185,129,.15);
  display: flex; align-items: center; justify-content: center;
  color: var(--emerald-400); margin-bottom: 16px;
}
.landing-feature-card h3 { color: white; font-weight: 600; font-size: .9375rem; margin-bottom: 8px; }
.landing-feature-card p { color: var(--slate-400); font-size: .84375rem; line-height: 1.6; }

/* Proof / testimonial */
.landing-proof-section {
  padding: 72px 24px; text-align: center;
  background: linear-gradient(135deg, rgba(52,211,153,.03) 0%, rgba(99,102,241,.03) 100%);
  border-top: 1px solid var(--glass-border);
}
.landing-proof-inner { max-width: 600px; margin: 0 auto; }
.landing-proof-mark {
  font-size: 4rem; line-height: 1; color: var(--emerald-400); opacity: .4; font-family: Georgia, serif;
}
.landing-proof-quote {
  font-size: 1.375rem; font-style: italic; color: white;
  line-height: 1.6; margin-bottom: 16px; font-weight: 500;
}
.landing-proof-attr { color: var(--slate-500); font-size: .875rem; }

/* Waitlist CTA */
.landing-cta-section {
  text-align: center; padding: 80px 32px;
  background: radial-gradient(ellipse 60% 80% at 50% 50%, rgba(16,185,129,.04) 0%, transparent 70%);
  border-top: 1px solid var(--glass-border);
}
.landing-cta-inner {
  max-width: 680px; margin: 0 auto;
  padding: 44px 40px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(8,20,45,.82) 0%, rgba(4,12,31,.92) 100%);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 24px 80px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.03);
  position: relative;
  overflow: hidden;
}
.landing-cta-inner::before {
  content: '';
  position: absolute;
  inset: -120px auto auto -60px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(16,185,129,.18) 0%, transparent 68%);
  pointer-events: none;
}
.landing-cta-inner::after {
  content: '';
  position: absolute;
  inset: auto -80px -120px auto;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(99,102,241,.14) 0%, transparent 70%);
  pointer-events: none;
}
.landing-cta-section h2 {
  font-size: 2rem; font-weight: 800; color: white;
  margin-bottom: 12px; letter-spacing: -.3px;
  position: relative; z-index: 1;
}
.landing-cta-section p { color: var(--slate-400); margin-bottom: 28px; font-size: 1.0625rem; position: relative; z-index: 1; }
.landing-cta-signin { color: var(--slate-500); font-size: .875rem; margin-top: 20px; }
.landing-cta-signin a { color: var(--emerald-400); font-weight: 600; text-decoration: none; }
.landing-cta-signin a:hover { text-decoration: underline; }

.waitlist-form {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 12px;
  align-items: center;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 18px;
  padding: 14px;
}
.waitlist-input {
  min-width: 0;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  color: var(--text-primary);
  padding: 14px 16px;
  border-radius: 12px;
  font-size: 14px;
  transition: border-color .15s, background-color .15s, box-shadow .15s;
}
.waitlist-input::placeholder { color: var(--slate-500); }
.waitlist-input:focus {
  outline: none;
  border-color: rgba(52,211,153,.55);
  background: rgba(255,255,255,.055);
  box-shadow: 0 0 0 4px rgba(16,185,129,.12);
}
#waitlist-success {
  position: relative;
  z-index: 1;
}

/* Footer */
.landing-footer {
  padding: 28px 48px; border-top: 1px solid var(--glass-border);
}
.landing-footer-inner {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px; max-width: 1200px; margin: 0 auto;
}
.landing-footer .tmdb-attr-logo { height: 12px; opacity: .5; }

/* Responsive */
@media (max-width: 900px) {
  .landing-hero { flex-direction: column; padding: 60px 32px 48px; gap: 48px; min-height: auto; }
  .landing-h1 { font-size: 2.5rem; }
  .landing-hero-phone { width: 260px; align-self: center; }
  .landing-features { padding: 56px 24px; }
  .landing-features-grid { grid-template-columns: repeat(2, 1fr); }
  .landing-cta-section { padding: 56px 24px; }
  .landing-cta-inner { padding: 36px 28px; }
  .waitlist-form { grid-template-columns: 1fr; }
  .landing-footer { padding: 24px 24px; }
  .landing-footer-inner { justify-content: center; text-align: center; }
  .landing-stats { gap: 32px; padding: 36px 24px; }
}
@media (max-width: 600px) {
  .landing-nav { padding: 12px 20px; }
  .landing-hero { padding: 40px 20px 32px; }
  .landing-h1 { font-size: 2rem; }
  .landing-features-grid { grid-template-columns: 1fr; }
  .landing-cta-section h2 { font-size: 1.5rem; }
  .landing-stats { gap: 24px; }
  .landing-stat-num { font-size: 1rem; }
  .landing-cta-inner { padding: 28px 20px; border-radius: 22px; }
}

/* =============================================
   HOME PAGE
   ============================================= */
.home-page {
  padding-bottom: 60px;
  background: radial-gradient(ellipse 100% 50% at 50% 0%, rgba(15,23,42,.5) 0%, transparent 70%);
}

/* --- Hero Carousel --- */
/* Hero Carousel */
.hero-carousel {
  position: relative; width: 100%; height: 600px;
  cursor: pointer; overflow: hidden;
}
.hero-slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center top;
  opacity: 0; transition: opacity .8s cubic-bezier(.4,0,.2,1);
  pointer-events: none; z-index: 0;
}
.hero-slide.active {
  opacity: 1; pointer-events: auto; z-index: 1;
}
.hero-slide::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(2,6,23,.05) 0%,
    rgba(2,6,23,.12) 35%,
    rgba(2,6,23,.55) 70%,
    var(--slate-950) 100%
  );
  pointer-events: none;
}
.hero-slide-content {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 0 48px 56px; z-index: 5;
  display: flex; flex-direction: column; gap: 10px;
  max-width: 700px;
  opacity: 0; transform: translateY(16px);
  transition: opacity .6s .25s cubic-bezier(.4,0,.2,1), transform .6s .25s cubic-bezier(.4,0,.2,1);
}
.hero-slide.active .hero-slide-content {
  opacity: 1; transform: translateY(0);
}
.hero-profile-btn {
  position: absolute; top: 24px; right: 24px; z-index: 10;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(15,23,42,.5); backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center;
  color: white; transition: all var(--transition);
}
.hero-profile-btn:hover { background: rgba(15,23,42,.7); border-color: rgba(255,255,255,.2); transform: scale(1.05); }

/* Carousel arrows */
.carousel-controls {
  position: absolute; top: 50%; left: 0; right: 0; z-index: 8;
  display: flex; justify-content: space-between; padding: 0 16px;
  transform: translateY(-50%); pointer-events: none;
  opacity: 0; transition: opacity .3s ease;
}
.hero-carousel:hover .carousel-controls { opacity: 1; }
.carousel-arrow {
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(0,0,0,.45); backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.12);
  color: white; display: flex; align-items: center; justify-content: center;
  cursor: pointer; pointer-events: auto;
  transition: all .25s ease;
}
.carousel-arrow:hover { background: rgba(0,0,0,.7); border-color: rgba(255,255,255,.25); transform: scale(1.08); }

/* Carousel dots — now absolute bottom-center */
.carousel-dots {
  position: absolute; bottom: 20px; left: 48px; z-index: 8;
  display: flex; gap: 6px;
}
.carousel-dot {
  width: 8px; height: 8px; border-radius: 4px;
  background: rgba(255,255,255,.18); cursor: pointer;
  transition: all .4s cubic-bezier(.4,0,.2,1); border: none;
}
.carousel-dot.active { background: white; width: 32px; box-shadow: 0 0 10px rgba(255,255,255,.3); }

/* Hero content elements */
.hero-logo-container { margin-bottom: 4px; }
.hero-logo-img {
  max-height: 80px; max-width: 280px; object-fit: contain;
  filter: drop-shadow(0 4px 16px rgba(0,0,0,.6));
}
.hero-title {
  font-size: 2.75rem; font-weight: 800; color: white;
  text-shadow: 0 2px 20px rgba(0,0,0,.7);
  letter-spacing: -.5px; line-height: 1.1;
}
.hero-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hero-type, .hero-year {
  background: rgba(255,255,255,.08); backdrop-filter: blur(12px);
  padding: 5px 14px; border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,.1);
  color: rgba(255,255,255,.9); font-size: .75rem; font-weight: 600;
  letter-spacing: .3px;
}
.hero-rating {
  display: inline-flex; align-items: center; gap: 4px;
  color: var(--amber-400); font-size: .8125rem; font-weight: 700;
}
.hero-overview {
  color: rgba(255,255,255,.6); font-size: .9rem; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; text-shadow: 0 1px 6px rgba(0,0,0,.5);
  max-width: 550px;
}

/* --- Quick Actions Menu Grid --- */
.menu-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
  padding: 24px 32px 16px;
}
.menu-item {
  position: relative;
  background: var(--glass-bg); backdrop-filter: var(--glass-blur);
  padding: 14px 16px; border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  display: flex; align-items: center; gap: 12px;
  cursor: pointer; color: white; font-weight: 600; font-size: .8125rem;
  transition: all var(--transition); overflow: hidden;
}
.menu-item::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,.03) 0%, transparent 50%);
  pointer-events: none;
}
.menu-item:hover {
  background: rgba(30,41,59,.65); border-color: rgba(255,255,255,.08);
  transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.3);
}
.menu-icon {
  width: 38px; height: 38px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  transition: transform var(--transition);
}
.menu-item:hover .menu-icon { transform: scale(1.1); }

/* --- Section Layout --- */
.section { margin-bottom: 32px; }
.section-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 32px; margin-bottom: 16px;
}
.section-header h3 {
  font-size: 1.25rem; font-weight: 700; color: white;
  display: flex; align-items: center; gap: 8px; letter-spacing: -.2px;
}
.see-all-btn {
  color: var(--emerald-400); font-size: .8125rem; font-weight: 600;
  cursor: pointer; background: none; border: none;
  transition: all var(--transition); padding: 4px 0;
}
.see-all-btn:hover { color: var(--emerald-300); text-decoration: underline; text-underline-offset: 3px; }

/* --- Horizontal Scroll --- */
.horizontal-scroll {
  display: flex; gap: 16px; overflow-x: auto; padding: 0 32px 8px;
  scrollbar-width: none; -ms-overflow-style: none;
  scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
  scroll-padding-inline: 32px;
}
.horizontal-scroll::-webkit-scrollbar { display: none; }
.horizontal-scroll > * { scroll-snap-align: start; }

/* --- Small Media Cards --- */
.media-card-sm {
  flex-shrink: 0; width: 185px; cursor: pointer;
  transition: transform .3s cubic-bezier(.4,0,.2,1);
}
.media-card-sm:hover { transform: scale(1.04) translateY(-4px); }
.media-card-sm img {
  width: 185px; height: 278px; border-radius: var(--radius-md);
  object-fit: cover; background: var(--slate-800); margin-bottom: 10px;
  box-shadow: 0 4px 16px rgba(0,0,0,.4);
  transition: box-shadow .3s cubic-bezier(.4,0,.2,1);
}
.media-card-sm:hover img { box-shadow: 0 12px 36px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.06); }
.card-title {
  color: rgba(255,255,255,.85); font-weight: 600; font-size: .8125rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-width: 185px; transition: color var(--transition);
}
.media-card-sm:hover .card-title { color: white; }
.card-subtitle { color: var(--slate-400); font-size: .75rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 185px; margin-top: 2px; }
.card-info { padding: 0 2px; }
.card-meta { color: var(--slate-400); font-size: .75rem; display: flex; align-items: center; gap: 4px; }

/* --- Poster Placeholder --- */
.poster-placeholder {
  width: 185px; height: 278px; border-radius: var(--radius-md);
  background: linear-gradient(160deg, var(--slate-800) 0%, var(--slate-900) 100%);
  display: flex; align-items: center; justify-content: center;
  color: var(--slate-600); margin-bottom: 10px;
  border: 1px solid rgba(255,255,255,.03); box-shadow: 0 4px 16px rgba(0,0,0,.3);
}

/* --- Shame Cards (Home) --- */
.shame-card { flex-shrink: 0; width: 185px; cursor: pointer; text-align: center; transition: transform var(--transition); position: relative; }
.shame-card:hover { transform: scale(1.04) translateY(-4px); }
.shame-poster {
  width: 185px; height: 278px; border-radius: var(--radius-md); object-fit: cover;
  background: var(--slate-800); border: 1px solid rgba(244,63,94,.15);
  box-shadow: 0 4px 16px rgba(0,0,0,.4);
}
.shame-poster.placeholder {
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, var(--slate-800), var(--slate-900));
}
.shame-badge {
  position: absolute; top: -4px; right: -4px;
  background: var(--rose-500); border-radius: 50%; width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--slate-950);
}
.shame-name { color: var(--rose-200); font-size: .8125rem; font-weight: 600; margin-top: 6px; }

/* --- Empty text --- */
.empty-text { color: var(--slate-500); font-size: .875rem; padding: 24px; text-align: center; }

/* =============================================
   PAGE HEADER (shared)
   ============================================= */
.page-header {
  display: flex; align-items: center; gap: 12px;
  padding: 24px 32px 16px;
}
.page-header .back-btn, .back-btn {
  width: 40px; height: 40px; border-radius: 50%; background: var(--glass-bg);
  border: 1px solid var(--glass-border); display: flex; align-items: center;
  justify-content: center; cursor: pointer; transition: all var(--transition);
  color: white; flex-shrink: 0;
}
.page-header .back-btn:hover, .back-btn:hover { background: var(--slate-800); border-color: var(--slate-700); }
.page-header h1 { font-size: 1.5rem; font-weight: 700; color: white; letter-spacing: -.3px; }

/* =============================================
   DISCOVER PAGE
   ============================================= */
.discover-page { padding-bottom: 40px; }
.search-container { padding: 0 32px; margin-bottom: 20px; }
.search-bar {
  display: flex; align-items: center; gap: 12px;
  background: var(--glass-bg); backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border); border-radius: var(--radius-md);
  padding: 0 18px; height: 52px; max-width: 600px;
  transition: border-color var(--transition);
}
.search-bar:focus-within { border-color: var(--emerald-500); box-shadow: 0 0 0 3px rgba(16,185,129,.08); }
.search-bar svg { flex-shrink: 0; color: var(--slate-400); }
.search-bar input { border: none; background: transparent; padding: 0; height: 100%; flex: 1; }
.search-bar input:focus { box-shadow: none; }
.clear-btn { color: var(--slate-400); cursor: pointer; padding: 4px; }
.filter-tabs { display: flex; gap: 8px; padding: 0 32px; margin-bottom: 16px; flex-wrap: wrap; }
.filter-tab {
  padding: 8px 20px; border-radius: 999px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); font-size: .8125rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition); white-space: nowrap;
}
.filter-tab.active { background: var(--emerald-500); border-color: var(--emerald-500); color: white; box-shadow: 0 2px 12px rgba(16,185,129,.25); }
.filter-chips { display: flex; gap: 8px; padding: 0 32px; margin-bottom: 20px; overflow-x: auto; scrollbar-width: none; }
.filter-chips::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0; padding: 6px 16px; border-radius: 999px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); font-size: .8125rem; cursor: pointer;
  transition: all var(--transition); white-space: nowrap;
}
.chip.active { background: var(--indigo-600); border-color: var(--indigo-500); color: white; }

/* Advanced Filters Panel */
.filter-toggle { display: inline-flex; align-items: center; gap: 4px; margin-left: auto; }
#advanced-filters.hidden { display: none; }
.adv-filters-panel { padding: 16px 32px; margin-bottom: 12px; }
.adv-filters-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px 16px; margin-bottom: 16px;
}
.filter-group label { display: block; font-size: 0.75rem; color: var(--slate-400); margin-bottom: 4px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
.filter-group select, .filter-group input {
  width: 100%; padding: 8px 10px; border-radius: var(--radius-md); border: 1px solid var(--slate-700);
  background: var(--slate-800); color: var(--slate-100); font-size: 0.85rem; outline: none;
  transition: border-color var(--transition);
}
.filter-group select:focus, .filter-group input:focus { border-color: var(--indigo-500); }
.filter-group-wide { grid-column: span 2; }
.filter-search-wrap { position: relative; }
.filter-dropdown {
  position: absolute; top: 100%; left: 0; right: 0; background: var(--slate-800);
  border: 1px solid var(--slate-700); border-radius: var(--radius-md); z-index: 50;
  max-height: 200px; overflow-y: auto; box-shadow: 0 8px 24px rgba(0,0,0,.4);
}
.filter-dropdown.hidden { display: none; }
.dropdown-item { padding: 8px 12px; cursor: pointer; display: flex; justify-content: space-between; align-items: center; font-size: 0.85rem; }
.dropdown-item:hover { background: var(--slate-700); }
.dropdown-sub { font-size: 0.75rem; color: var(--slate-400); }
.filter-chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; margin-top: 6px;
  background: var(--indigo-600); border-radius: 9999px; font-size: 0.8rem; color: white;
}
.filter-chip button { background: none; border: none; color: white; cursor: pointer; padding: 0; display: flex; }
.adv-filters-actions { display: flex; gap: 8px; }
.btn-primary.btn-sm { padding: 8px 16px; font-size: 0.85rem; background: var(--indigo-600); color: white; border: none; border-radius: var(--radius-md); cursor: pointer; font-weight: 500; }
.btn-primary.btn-sm:hover { background: var(--indigo-500); }
.btn-secondary.btn-sm { padding: 8px 16px; font-size: 0.85rem; background: var(--slate-700); color: var(--slate-200); border: none; border-radius: var(--radius-md); cursor: pointer; }
.btn-secondary.btn-sm:hover { background: var(--slate-600); }

.media-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 20px; padding: 0 32px;
}
.media-card {
  cursor: pointer; transition: transform var(--transition); position: relative;
}
.media-card:hover { transform: scale(1.03) translateY(-2px); }
.media-card img {
  width: 100%; aspect-ratio: 2/3; border-radius: var(--radius-md);
  object-fit: cover; background: var(--slate-800); margin-bottom: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.35);
}
.grid-card { cursor: pointer; transition: transform var(--transition); }
.grid-card:hover { transform: scale(1.03) translateY(-2px); }
.grid-card img {
  width: 100%; aspect-ratio: 2/3; border-radius: var(--radius-md);
  object-fit: cover; background: var(--slate-800); margin-bottom: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.35);
}
.grid-card .title, .media-card .title {
  color: white; font-weight: 600; font-size: .875rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.grid-card .year { color: var(--slate-500); font-size: .75rem; }
.person-card { text-align: center; }
.person-card img { border-radius: 50%; aspect-ratio: 1; }

/* =============================================
   DETAILS PAGE — Redesigned Desktop Layout
   ============================================= */
.details-page { padding-bottom: 60px; }
.details-hero {
  position: relative; width: 100%; height: 560px;
  background-size: cover; background-position: center top;
}
.details-hero .gradient,
.details-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(2,6,23,.15) 0%, var(--slate-950) 100%);
}
.back-btn-float {
  position: absolute; top: 20px; left: 20px; z-index: 5;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(0,0,0,.45); backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.15); display: flex;
  align-items: center; justify-content: center; color: white;
  cursor: pointer; transition: all var(--transition);
}
.back-btn-float:hover { background: rgba(0,0,0,.65); transform: scale(1.05); }
.details-body { padding: 0 40px; margin-top: -120px; position: relative; z-index: 2; }
.details-top { display: flex; gap: 36px; margin-bottom: 32px; }
.details-poster {
  width: 260px; height: 390px; border-radius: var(--radius-lg);
  object-fit: cover; background: var(--slate-800); flex-shrink: 0;
  box-shadow: 0 16px 48px rgba(0,0,0,.65);
}
.details-poster.placeholder {
  display: flex; align-items: center; justify-content: center; color: var(--slate-600);
}
.details-info { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; gap: 10px; }
.details-info h1 { font-size: 2.5rem; font-weight: 800; color: white; letter-spacing: -.5px; line-height: 1.1; }
.details-info h1.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.details-logo { max-width: 340px; max-height: 120px; object-fit: contain; object-position: left; display: block; }
.details-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.meta-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 12px; border-radius: 999px; font-size: .8125rem; font-weight: 600;
  background: rgba(255,255,255,.06); color: var(--slate-300); border: 1px solid rgba(255,255,255,.08);
}
.rating-chip { color: var(--amber-400); border-color: rgba(251,191,36,.2); background: rgba(251,191,36,.08); }
.rating-chip svg { color: var(--amber-400); }
.status-badge { background: var(--emerald-500); color: white; padding: 4px 12px; border-radius: 999px; font-size: .75rem; font-weight: 600; }
.details-genres { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0; }
.genre-tag {
  padding: 4px 14px; border-radius: 999px; font-size: .75rem; font-weight: 600;
  background: rgba(99,102,241,.1); color: var(--indigo-300, #a5b4fc); border: 1px solid rgba(99,102,241,.2);
}
.details-stats-row { display: flex; gap: 16px; color: var(--slate-400); font-size: .8125rem; }
.details-stats-row span { display: inline-flex; align-items: center; }
.overview-text { color: var(--slate-300); font-size: 1rem; line-height: 1.75; }
.overview-section { margin-bottom: 4px; }

/* Action Buttons Row — now inside info block */
.actions-row { display: flex; gap: 12px; margin-top: 8px; flex-wrap: wrap; }
.action-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 24px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); font-size: .875rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
}
.action-btn:hover { background: var(--slate-800); border-color: var(--slate-700); }
.action-btn.active { border-color: var(--emerald-500); color: var(--emerald-400); background: rgba(16,185,129,.1); }

/* Two-column content grid */
.details-content-grid { display: grid; grid-template-columns: 1fr 320px; gap: 32px; }
.details-main { min-width: 0; }
.details-sidebar { display: flex; flex-direction: column; gap: 24px; }

/* Season Tabs */
.season-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 0 0 8px; margin-bottom: 16px; scrollbar-width: none; }
.season-tabs::-webkit-scrollbar { display: none; }
.season-tab {
  flex-shrink: 0; padding: 8px 20px; border-radius: 999px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); font-size: .8125rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition); white-space: nowrap;
}
.season-tab.active { background: var(--emerald-500); border-color: var(--emerald-500); color: white; }

/* Episode List */
.episode-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }
.episode-item {
  display: flex; gap: 16px; padding: 14px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  cursor: pointer; transition: all var(--transition); align-items: center;
}
.episode-item:hover { background: var(--slate-800); border-color: var(--slate-700); }
.episode-still { width: 180px; height: 100px; border-radius: var(--radius-sm); object-fit: cover; background: var(--slate-800); flex-shrink: 0; }
.episode-still.placeholder { display: flex; align-items: center; justify-content: center; color: var(--slate-600); }
.episode-info { flex: 1; display: flex; flex-direction: column; gap: 4px; justify-content: center; }
.ep-number { color: var(--emerald-400); font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; }
.ep-name { color: white; font-weight: 600; font-size: 1rem; }
.ep-date { color: var(--slate-500); font-size: .8125rem; }
.ep-desc { color: var(--slate-400); font-size: .8125rem; line-height: 1.5; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ep-watched-btn {
  align-self: center; flex-shrink: 0;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  display: flex; align-items: center; justify-content: center;
  color: var(--slate-400); cursor: pointer; transition: all var(--transition);
}
.ep-watched-btn:hover { border-color: var(--emerald-500); color: var(--emerald-400); }
.ep-watched-btn.active { background: var(--emerald-500); border-color: var(--emerald-500); color: white; }

/* Cast sidebar grid */
.cast-section { background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); padding: 20px; }
.cast-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.cast-header h3 { margin: 0; }
.see-all-btn { background: none; border: none; color: var(--emerald-400); font-size: .8125rem; font-weight: 600; cursor: pointer; }
.see-all-btn:hover { text-decoration: underline; }
.cast-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.cast-card { text-align: center; cursor: pointer; transition: transform var(--transition); }
.cast-card:hover { transform: translateY(-3px); }
.cast-card img { width: 100%; aspect-ratio: 1; border-radius: 50%; object-fit: cover; background: var(--slate-800); margin-bottom: 6px; box-shadow: 0 4px 12px rgba(0,0,0,.3); }
.cast-placeholder { width: 100%; aspect-ratio: 1; border-radius: 50%; background: var(--slate-800); display: flex; align-items: center; justify-content: center; color: var(--slate-600); margin-bottom: 6px; }
.cast-name { color: white; font-size: .75rem; font-weight: 600; }
.cast-char { color: var(--slate-500); font-size: .6875rem; }

/* Friend Activity */
.friend-activity-list { display: flex; flex-direction: column; gap: 8px; }
.friend-activity-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
}
.friend-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: var(--slate-700);
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 700; font-size: .875rem; flex-shrink: 0;
}
.friend-name { flex: 1; color: white; font-weight: 600; font-size: .875rem; }
.friend-status { font-size: .75rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.friend-status.watched { background: rgba(16,185,129,.12); color: var(--emerald-400); }
.friend-status.watchlist { background: rgba(99,102,241,.12); color: var(--indigo-300, #a5b4fc); }

/* Rating Section */
.rating-section { margin-bottom: 28px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); padding: 24px; }
.rating-section label { color: var(--slate-300); font-weight: 600; font-size: .9375rem; display: block; margin-bottom: 14px; }

/* Rating Slider */
.rating-slider-row { display: flex; align-items: center; gap: 16px; padding: 8px 0; }
/* Unrate button */
.unrate-btn {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
  background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.25);
  color: #f87171; display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all .2s; font-size: 1rem; line-height: 1; padding: 0;
}
.unrate-btn:hover { background: #ef4444; color: white; border-color: #ef4444; }
.rating-slider {
  -webkit-appearance: none; appearance: none; width: 100%; max-width: 280px; height: 8px;
  border-radius: 4px; outline: none; cursor: pointer;
  background: linear-gradient(to right, var(--accent) 0%, rgba(255,255,255,0.08) 0%);
  transition: background 0.15s;
  position: relative;
}
.rating-slider:hover { height: 10px; }
.rating-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 24px; height: 24px;
  border-radius: 50%; background: var(--accent); border: 3px solid white;
  box-shadow: 0 2px 8px rgba(0,0,0,.45), 0 0 0 4px rgba(16,185,129,.15); cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.rating-slider::-webkit-slider-thumb:hover { transform: scale(1.15); box-shadow: 0 2px 12px rgba(0,0,0,.5), 0 0 0 6px rgba(16,185,129,.2); }
.rating-slider::-webkit-slider-thumb:active { transform: scale(1.25); }
.rating-slider::-moz-range-thumb {
  width: 24px; height: 24px; border-radius: 50%; background: var(--accent);
  border: 3px solid white; box-shadow: 0 2px 8px rgba(0,0,0,.45), 0 0 0 4px rgba(16,185,129,.15); cursor: pointer;
}
.rating-slider::-moz-range-track { height: 8px; border-radius: 4px; background: transparent; }
.rating-number {
  font-size: 1.6rem; font-weight: 800; color: var(--emerald-400); min-width: 56px;
  text-align: center; white-space: nowrap;
  background: rgba(16,185,129,.08); border-radius: var(--radius-sm); padding: 4px 8px;
}
.rating-badge {
  display: inline-block; padding: 2px 8px; border-radius: var(--radius-sm);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--amber-400); font-size: .8125rem; font-weight: 700; white-space: nowrap;
}

/* Detail Action Buttons in sidebar */
.detail-actions { display: flex; flex-direction: column; gap: 8px; }
.detail-action-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); font-size: .875rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition); width: 100%;
}
.detail-action-btn:hover { background: var(--slate-800); border-color: var(--slate-700); }

/* Friend/List Picker Modal */
.friend-picker, .list-picker { display: flex; flex-direction: column; gap: 16px; }
.friend-picker h3, .list-picker h3 { color: white; font-weight: 700; font-size: 1.125rem; }
.modal-subtitle { color: var(--slate-400); font-size: .875rem; }
.friend-list, .lists-options { display: flex; flex-direction: column; gap: 6px; }
.friend-pick-btn, .list-pick-btn {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: white; font-weight: 500; cursor: pointer; transition: all var(--transition);
}
.friend-pick-btn:hover, .list-pick-btn:hover { background: var(--slate-800); border-color: var(--slate-700); }

/* More actions modal */
.more-actions-modal { display: flex; flex-direction: column; gap: 4px; }
.more-actions-modal h3 { color: white; font-weight: 700; margin-bottom: 8px; }
.modal-action {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-radius: var(--radius-md);
  color: var(--slate-200); font-weight: 500; cursor: pointer;
  transition: background var(--transition);
}
.modal-action:hover { background: var(--slate-800); }

/* Episode modal */
.episode-modal { display: flex; flex-direction: column; gap: 12px; }
.episode-modal img.modal-still { width: 100%; border-radius: var(--radius-md); }
.episode-modal h3 { color: white; font-weight: 700; }
.modal-date { color: var(--slate-400); font-size: .875rem; }
.modal-tmdb-rating { display: flex; align-items: center; gap: 4px; color: var(--amber-400); font-weight: 600; }
.tmdb-label { color: var(--slate-500); font-size: .75rem; font-weight: 400; }
.modal-overview { color: var(--slate-300); line-height: 1.6; font-size: .9375rem; }

/* Episode rating section inside modal */
.ep-rating-section { border-top: 1px solid var(--glass-border); padding-top: 16px; margin-top: 4px; display: flex; flex-direction: column; gap: 10px; }
.ep-rating-section label { color: var(--slate-300); font-weight: 600; font-size: .875rem; }
.ep-comment-input {
  width: 100%; padding: 12px 14px; border-radius: var(--radius-md);
  background: var(--slate-800); border: 1px solid var(--glass-border);
  color: white; font-size: .875rem; font-family: inherit;
  resize: vertical; min-height: 60px; transition: border-color var(--transition);
}
.ep-comment-input:focus { outline: none; border-color: var(--accent); }
.ep-comment-input::placeholder { color: var(--slate-500); }
.ep-save-btn {
  padding: 12px 20px; border-radius: var(--radius-md);
  background: var(--accent); color: white; font-weight: 700;
  font-size: .875rem; cursor: pointer; border: none;
  transition: all var(--transition);
}
.ep-save-btn:hover { filter: brightness(1.15); transform: translateY(-1px); }

/* Friends' episode ratings */
.ep-friend-ratings { border-top: 1px solid var(--glass-border); padding-top: 16px; margin-top: 4px; }
.ep-friend-ratings h4 { color: var(--slate-300); font-weight: 600; font-size: .875rem; margin-bottom: 12px; }
.ep-friend-rating-item { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
.ep-friend-rating-item:last-child { border-bottom: none; }
.ep-friend-rating-info { flex: 1; }
.ep-friend-rating-info strong { color: white; font-size: .875rem; }
.ep-friend-score { color: var(--amber-400); font-weight: 700; margin-left: 8px; }
.ep-friend-comment { color: var(--slate-400); font-size: .8125rem; font-style: italic; margin-top: 4px; line-height: 1.4; }

/* Activity comment */
.activity-comment { color: var(--slate-400); font-size: .8125rem; font-style: italic; margin-top: 4px; line-height: 1.4; }

/* Floating modal close button (for headerless modals) */
.modal-close-float {
  position: absolute; top: 12px; right: 12px; z-index: 10;
  background: rgba(0,0,0,0.5); border: none; border-radius: 50%;
  width: 32px; height: 32px; display: flex; align-items: center; justify-content: center;
  color: white; cursor: pointer; transition: background var(--transition);
}
.modal-close-float:hover { background: rgba(0,0,0,0.8); }
.modal-box { position: relative; }

/* Overall Review Input */
.review-input {
  width: 100%; padding: 12px 14px; border-radius: var(--radius-md);
  background: var(--slate-800); border: 1px solid var(--glass-border);
  color: white; font-size: .875rem; font-family: inherit;
  resize: vertical; min-height: 72px; margin-top: 12px;
  transition: border-color var(--transition);
}
.review-input:focus { outline: none; border-color: var(--accent); }
.review-input::placeholder { color: var(--slate-500); }
.save-review-btn {
  margin-top: 10px; padding: 10px 20px; border-radius: var(--radius-md);
  background: var(--accent); color: white; font-weight: 700;
  font-size: .875rem; cursor: pointer; border: none;
  transition: all var(--transition); align-self: flex-start;
}
.save-review-btn:hover { filter: brightness(1.15); transform: translateY(-1px); }
.rating-section h3 { color: white; font-weight: 700; font-size: 1rem; margin-bottom: 12px; }

/* =============================================
   FULL-SCREEN EPISODE MODAL
   ============================================= */
.modal-box:has(.ep-modal-full) { max-width: 640px; padding: 0; overflow: hidden; }

.ep-modal-full { display: flex; flex-direction: column; }

.ep-modal-hero {
  position: relative; min-height: 220px; padding: 24px 28px;
  background-size: cover; background-position: center top;
  display: flex; align-items: flex-end;
  background-color: var(--bg-secondary);
}
.ep-modal-hero-info { position: relative; z-index: 2; }
.ep-modal-hero-info .ep-modal-show {
  color: var(--accent); font-size: .8125rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .05em; margin-bottom: 4px;
}
.ep-modal-logo {
  max-height: 32px; max-width: 160px; width: auto; object-fit: contain;
  margin-bottom: 6px; filter: drop-shadow(0 2px 6px rgba(0,0,0,.6));
}
.ep-modal-hero-info h2 { color: white; font-size: 1.35rem; font-weight: 800; line-height: 1.3; margin: 0; }
.ep-modal-meta {
  display: flex; align-items: center; gap: 12px; margin-top: 8px;
  color: var(--slate-300); font-size: .8125rem;
}
.ep-modal-meta span { display: flex; align-items: center; gap: 4px; }

/* Episode Modal Tabs */
.ep-modal-tabs {
  display: flex; border-bottom: 1px solid var(--glass-border);
  background: var(--bg-secondary); padding: 0 12px;
  position: sticky; top: 0; z-index: 3;
}
.ep-tab {
  padding: 14px 20px; font-size: .875rem; font-weight: 600;
  color: var(--slate-400); background: none; border: none;
  cursor: pointer; position: relative; transition: color var(--transition);
}
.ep-tab:hover { color: var(--slate-200); }
.ep-tab.active { color: var(--accent); }
.ep-tab.active::after {
  content: ''; position: absolute; bottom: 0; left: 12px; right: 12px;
  height: 2px; background: var(--accent); border-radius: 2px;
}

/* Tab Panels */
.ep-modal-content { padding: 24px 28px; }
.ep-tab-panel { display: none; }
.ep-tab-panel.active { display: block; }
.ep-overview { color: var(--slate-300); line-height: 1.7; font-size: .9375rem; }
.ep-overview.muted { color: var(--slate-500); font-style: italic; }

/* Episode Review Form (inside tab) */
.ep-review-form { display: flex; flex-direction: column; gap: 14px; }
.ep-review-form label { color: var(--slate-300); font-weight: 600; font-size: .875rem; }
.ep-review-form .rating-slider-row { margin-bottom: 4px; }
.ep-review-form .rating-number { font-size: 1.75rem; font-weight: 800; }

/* Friend Episode Cards */
.ep-friend-card {
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 16px; margin-bottom: 12px;
  transition: border-color var(--transition);
}
.ep-friend-card:hover { border-color: var(--slate-700); }
.ep-friend-card:last-child { margin-bottom: 0; }
.ep-friend-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.ep-friend-card-info { flex: 1; }
.ep-friend-card-info strong { color: white; font-size: .9375rem; display: block; }
.ep-friend-card-rating { margin-top: 2px; }
.ep-friend-card-rating .rating-badge { font-size: .75rem; padding: 1px 6px; }
.ep-friend-card-comment {
  color: var(--slate-400); font-size: .875rem; font-style: italic;
  line-height: 1.5; margin: 4px 0 10px; padding-left: 2px;
}
.ep-friend-card-time { color: var(--slate-500); font-size: .75rem; margin-top: 8px; }

/* Friend Avatar Large */
.friend-avatar.lg { width: 40px; height: 40px; font-size: 1rem; }
.friend-avatar.lg img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }

/* Reaction Bar */
.reaction-bar { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.reaction-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.reaction-pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 999px; font-size: .8125rem;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-300); cursor: pointer; transition: all var(--transition);
}
.reaction-pill:hover { border-color: var(--slate-600); background: var(--slate-800); }
.reaction-pill.mine { border-color: var(--accent); background: rgba(var(--accent-rgb, 99,102,241), .12); }
.reaction-add { display: flex; flex-wrap: wrap; gap: 4px; }
.reaction-btn {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  font-size: 1rem; cursor: pointer; display: flex;
  align-items: center; justify-content: center;
  transition: all var(--transition);
}
.reaction-btn:hover { transform: scale(1.15); background: var(--slate-800); border-color: var(--slate-600); }
.reaction-btn.active { border-color: var(--accent); background: rgba(var(--accent-rgb, 99,102,241), .12); }

/* No friends message */
.ep-no-friends { color: var(--slate-500); font-size: .875rem; text-align: center; padding: 32px 16px; }

/* Friend Episode Reviews in sidebar */
.friend-ep-header { color: var(--slate-400); font-size: .8125rem; font-weight: 600; margin: 16px 0 8px; text-transform: uppercase; letter-spacing: .04em; }
.friend-ep-reviews { display: flex; flex-direction: column; gap: 6px; }
.friend-ep-review-item {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px;
  padding: 8px 10px; border-radius: var(--radius-sm);
  background: rgba(255,255,255,.02);
}
.friend-ep-review-item strong { color: white; font-size: .8125rem; }
.friend-ep-tag {
  font-size: .6875rem; font-weight: 700; color: var(--accent);
  background: rgba(var(--accent-rgb, 99,102,241), .12);
  padding: 2px 6px; border-radius: 4px;
}
.friend-ep-score { color: var(--amber-400); font-weight: 700; font-size: .8125rem; }
.friend-ep-comment { width: 100%; color: var(--slate-400); font-size: .75rem; font-style: italic; margin-top: 2px; line-height: 1.4; }

/* Details page responsive */
@media (max-width: 900px) {
  .details-content-grid { grid-template-columns: 1fr; }
  .details-sidebar { order: 2; }
  .details-hero { height: 400px; }
  .details-poster { width: 180px; height: 270px; }
  .details-info h1 { font-size: 1.75rem; }
  .details-body { padding: 0 20px; }
  .cast-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 600px) {
  .details-top { flex-direction: column; align-items: center; text-align: center; }
  .details-poster { width: 160px; height: 240px; }
  .details-info { align-items: center; }
  .actions-row { justify-content: center; }
  .details-genres { justify-content: center; }
  .details-stats-row { justify-content: center; }
  .details-hero { height: 300px; }
  .ep-modal-hero { min-height: 160px; padding: 16px 18px; }
  .ep-modal-hero-info h2 { font-size: 1.1rem; }
  .ep-modal-content { padding: 16px 18px; }
  .ep-tab { padding: 12px 14px; font-size: .8125rem; }
  .reaction-btn { width: 32px; height: 32px; font-size: .875rem; }
}

/* =============================================
   WATCHLIST PAGE
   ============================================= */
.watchlist-page { padding-bottom: 40px; }
.watchlist-items { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }
.watchlist-item {
  display: flex; gap: 16px; padding: 16px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  cursor: pointer; transition: all var(--transition);
  align-items: center;
}
.watchlist-item:hover { background: var(--slate-800); border-color: var(--slate-700); }
.watchlist-item img, .wl-poster {
  width: 64px; height: 96px; border-radius: var(--radius-sm);
  object-fit: cover; background: var(--slate-800); flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.wl-poster.placeholder {
  display: flex; align-items: center; justify-content: center; color: var(--slate-600);
}
.wl-info { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.wl-title { color: white; font-weight: 700; font-size: .9375rem; }
.wl-type { color: var(--slate-400); font-size: .8125rem; font-weight: 500; }
.wl-date { color: var(--slate-500); font-size: .75rem; }
.wl-remove {
  flex-shrink: 0; width: 36px; height: 36px; border-radius: 50%;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  display: flex; align-items: center; justify-content: center;
  color: var(--slate-400); cursor: pointer; transition: all var(--transition);
}
.wl-remove:hover { color: var(--rose-400); border-color: var(--rose-500); background: rgba(244,63,94,.08); }

/* =============================================
   PROFILE PAGE
   ============================================= */
.profile-page { padding: 0 32px 40px; max-width: 1000px; margin: 0 auto; }
.profile-header { text-align: center; padding: 32px 0 28px; }
.profile-avatar-lg {
  width: 96px; height: 96px; border-radius: 50%; margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--emerald-600), var(--emerald-800));
  border: 3px solid var(--emerald-500);
  display: flex; align-items: center; justify-content: center;
  font-size: 2.25rem; font-weight: 800; color: white; letter-spacing: .5px;
  box-shadow: 0 0 30px rgba(16,185,129,.15);
}
.profile-avatar-lg img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.profile-avatar-wrap {
  position: relative; display: inline-block; cursor: pointer; margin: 0 auto 16px;
}
.profile-avatar-wrap:hover .profile-avatar-edit { opacity: 1; }
.profile-avatar-edit {
  position: absolute; bottom: 2px; right: 2px;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--emerald-500); display: flex; align-items: center; justify-content: center;
  color: white; border: 2px solid var(--bg-primary);
  opacity: 0; transition: opacity .2s; pointer-events: none;
}
.profile-avatar-img {
  width: 96px; height: 96px; border-radius: 50%; object-fit: cover;
  border: 3px solid var(--emerald-500); box-shadow: 0 0 30px rgba(16,185,129,.15);
}
.friend-avatar-img {
  width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: var(--slate-700);
}
.profile-header h2 { font-size: 1.5rem; font-weight: 700; color: white; margin-bottom: 4px; }
.profile-email { color: var(--slate-400); font-size: .875rem; margin-bottom: 4px; }
.profile-joined { color: var(--slate-500); font-size: .8125rem; }

/* Stats Grid (shared between Profile, Analytics, FriendProfile) */
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 20px 16px; text-align: center;
}
.stat-card.accent { border-color: rgba(16,185,129,.15); background: rgba(16,185,129,.04); }
.stat-number { display: block; font-size: 1.75rem; font-weight: 800; color: var(--emerald-400); margin-bottom: 4px; }
.stat-label { color: var(--slate-400); font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }

/* Profile Menu */
.profile-menu { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.profile-menu-item {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  cursor: pointer; transition: all var(--transition);
  color: var(--slate-200); font-weight: 600; font-size: .9375rem;
}
.profile-menu-item:hover { background: var(--slate-800); border-color: var(--slate-700); }
.profile-menu-item svg:first-child { color: var(--slate-400); flex-shrink: 0; }
.profile-menu-item span { flex: 1; }
.profile-menu-item svg:last-child { color: var(--slate-600); flex-shrink: 0; }
.profile-admin-btn { border-top: 2px solid rgba(251,113,133,.25); color: #fb7185 !important; }
.profile-admin-btn svg:first-child { color: #fb7185; }
.profile-admin-btn:hover { background: rgba(251,113,133,.08); border-color: rgba(251,113,133,.3); }
.btn-logout {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 14px; border-radius: var(--radius-md);
  background: rgba(239,68,68,.08); border: 1px solid rgba(239,68,68,.15);
  color: var(--red-400); font-weight: 700; font-size: .9375rem;
  cursor: pointer; transition: all var(--transition);
}
.btn-logout:hover { background: rgba(239,68,68,.12); border-color: rgba(239,68,68,.25); }
.btn-danger {
  background: var(--red-500); color: white; padding: 14px; border-radius: var(--radius-md);
  font-weight: 700; font-size: .9375rem; width: 100%; text-align: center;
}

/* =============================================
   FRIENDS PAGE
   ============================================= */
.friends-page { padding-bottom: 40px; }
.friends-search-wrap { padding: 0 16px 16px; }
.friends-search-bar {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-card); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle); border-radius: 14px;
  padding: 12px 16px; transition: all 0.2s;
  box-shadow: 0 2px 12px rgba(0,0,0,.12);
}
.friends-search-bar:focus-within { border-color: var(--accent); box-shadow: 0 2px 16px rgba(52,211,153,.1); }
.friends-search-bar svg { color: var(--text-muted); flex-shrink: 0; }
.friends-search-bar input { background: none; border: none; color: var(--text-primary); font-size: 14px; flex: 1; outline: none; }
.friends-search-bar input::placeholder { color: var(--text-muted); }
.friend-items { display: flex; flex-direction: column; gap: 8px; padding: 0 16px; }
.friend-item {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px;
  border-radius: 16px; background: var(--bg-card);
  border: 1px solid var(--border-subtle); cursor: pointer;
  transition: all 0.2s; position: relative; overflow: hidden;
}
.friend-item::before {
  content: ''; position: absolute; inset: 0; border-radius: 16px;
  background: linear-gradient(135deg, rgba(99,102,241,0.04) 0%, transparent 50%);
  pointer-events: none; transition: opacity 0.2s; opacity: 0;
}
.friend-item:hover { background: var(--slate-800); border-color: var(--slate-700); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.2); }
.friend-item:hover::before { opacity: 1; }
.friend-avatar {
  width: 46px; height: 46px; border-radius: 50%;
  background: linear-gradient(135deg, var(--indigo-500), #8b5cf6);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.125rem; color: white; flex-shrink: 0;
  box-shadow: 0 2px 12px rgba(99,102,241,.25);
  border: 2px solid rgba(99,102,241,.3);
}
.friend-info { flex: 1; min-width: 0; }
.friend-name { color: white; font-weight: 700; font-size: .9375rem; letter-spacing: -.1px; }
.friend-remove-btn {
  flex-shrink: 0; color: var(--slate-500); padding: 8px;
  border-radius: 10px; transition: all 0.2s; background: transparent; border: none; cursor: pointer;
}
.friend-remove-btn:hover { color: var(--rose-400); background: rgba(244,63,94,.1); }
.search-result-items { display: flex; flex-direction: column; gap: 8px; padding: 0 16px; margin-bottom: 16px; }
.add-friend-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 10px;
  background: rgba(52,211,153,0.12); color: var(--accent);
  border: 1px solid rgba(52,211,153,0.25);
  font-weight: 600; font-size: .8125rem; cursor: pointer;
  transition: all 0.2s; flex-shrink: 0;
}
.add-friend-btn:hover { background: rgba(52,211,153,0.2); border-color: rgba(52,211,153,0.4); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(52,211,153,.12); }
.already-friend { color: var(--emerald-400); font-size: .8125rem; font-weight: 600; flex-shrink: 0; display: flex; align-items: center; gap: 4px; }

/* Friend Profile */
.friend-profile-page { padding-bottom: 40px; }
.friend-profile-page .stats-grid { padding: 0 32px; }
.friend-profile-page .section > h3 { padding: 0 32px; margin-bottom: 16px; font-size: 1.25rem; font-weight: 700; color: white; letter-spacing: -.2px; }

/* =============================================
   ACTIVITY FEED
   ============================================= */
.activity-page { padding-bottom: 40px; }
.activity-items { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }
.activity-item {
  display: flex; gap: 14px; padding: 16px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  cursor: pointer; transition: all var(--transition);
}
.activity-item:hover { background: var(--slate-800); }
.activity-poster {
  width: 48px; height: 72px; border-radius: var(--radius-sm);
  object-fit: cover; background: var(--slate-800); flex-shrink: 0;
}
.activity-poster.placeholder {
  display: flex; align-items: center; justify-content: center; color: var(--slate-600);
}
.activity-info { flex: 1; }
.activity-info p { margin-bottom: 2px; }
.activity-info strong { color: white; }
.activity-show { color: var(--emerald-400); font-weight: 600; cursor: pointer; font-size: .9375rem; }
.activity-time { color: var(--slate-500); font-size: .75rem; margin-top: 4px; }

/* iMessage-style activity thread */
.activity-thread { display: flex; flex-direction: column; gap: 14px; padding: 16px 24px 24px; }
.activity-msg-row { display: flex; align-items: flex-end; gap: 10px; }
.activity-msg-row.mine { flex-direction: row-reverse; }
.activity-msg-row.theirs { flex-direction: row; }

.activity-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  object-fit: cover; flex-shrink: 0;
  font-size: .8125rem; font-weight: 700; color: white;
  display: flex; align-items: center; justify-content: center;
  background: var(--slate-700);
}
.activity-avatar-initial { background: var(--indigo-600); }

.activity-bubble-wrap { display: flex; flex-direction: column; max-width: 70%; gap: 3px; }
.activity-msg-row.mine .activity-bubble-wrap { align-items: flex-end; }
.activity-msg-row.theirs .activity-bubble-wrap { align-items: flex-start; }

.activity-sender { color: var(--slate-400); font-size: .6875rem; font-weight: 600; padding: 0 8px; }

.activity-bubble {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 10px 14px; border-radius: 18px; cursor: pointer;
  transition: filter .15s; min-width: 110px;
}
.activity-bubble:hover { filter: brightness(1.1); }
.bubble-mine { background: var(--emerald-600); border-bottom-right-radius: 4px; }
.bubble-theirs { background: var(--slate-800); border: 1px solid var(--glass-border); border-bottom-left-radius: 4px; }

.activity-bubble-poster {
  width: 34px; height: 51px; border-radius: 5px;
  object-fit: cover; flex-shrink: 0; background: rgba(0,0,0,.2);
}
.activity-bubble-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.activity-action { color: rgba(255,255,255,.8); font-size: .75rem; font-weight: 500; }
.activity-show { font-size: .875rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bubble-mine .activity-show { color: rgba(255,255,255,.97); }
.bubble-theirs .activity-show { color: var(--emerald-400); }
.activity-ep-name { color: rgba(255,255,255,.65); font-size: .6875rem; font-style: italic; }
.activity-comment { color: rgba(255,255,255,.7); font-size: .6875rem; font-style: italic; margin-top: 2px; }
.activity-bubble-time { color: var(--slate-500); font-size: .625rem; padding: 0 8px; }

/* =============================================
   WALL OF SHAME
   ============================================= */
.shame-page { padding-bottom: 40px; }
.shame-items { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }

/* Shame Stats Row */
.shame-stats { display: flex; justify-content: center; gap: 24px; padding: 16px 32px 20px; }
.shame-stat { text-align: center; }
.shame-stat-num { display: block; font-size: 1.75rem; font-weight: 800; color: var(--rose-400); }
.shame-stat-label { font-size: .75rem; color: var(--slate-400); text-transform: uppercase; letter-spacing: .04em; }

/* Shame Tabs */
.shame-tabs { display: flex; gap: 0; padding: 0 32px; margin-bottom: 16px; border-bottom: 1px solid var(--glass-border); }
.shame-tab {
  padding: 12px 20px; font-size: .875rem; font-weight: 600;
  color: var(--slate-400); background: none; border: none; cursor: pointer;
  position: relative; transition: color var(--transition);
}
.shame-tab:hover { color: var(--slate-200); }
.shame-tab.active { color: var(--rose-400); }
.shame-tab.active::after {
  content: ''; position: absolute; bottom: -1px; left: 12px; right: 12px;
  height: 2px; background: var(--rose-400); border-radius: 2px;
}

/* Shame List Items */
.shame-list-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 14px 16px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  transition: all var(--transition);
}
.shame-list-item.active { border-left: 3px solid var(--rose-400); }
.shame-list-item.resolved { opacity: .6; }
.shame-list-item:hover { background: var(--slate-800); }
.shame-item-left { display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0; cursor: pointer; }
.shame-list-item img, .shame-item-poster {
  width: 48px; height: 72px; border-radius: var(--radius-sm);
  object-fit: cover; background: var(--slate-800); flex-shrink: 0;
}
.shame-item-poster.placeholder { display: flex; align-items: center; justify-content: center; color: var(--slate-600); }
.shame-item-info { flex: 1; min-width: 0; }
.shame-show { color: white; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shame-detail { color: var(--rose-300); font-size: .8125rem; margin-top: 2px; }
.shame-detail strong { color: var(--rose-200); }
.shame-item-meta { display: flex; align-items: center; gap: 10px; margin-top: 4px; flex-wrap: wrap; }
.shame-timer { color: var(--amber-400); font-size: .75rem; font-weight: 600; display: flex; align-items: center; gap: 3px; }
.shame-resolved-badge { color: var(--emerald-400); font-size: .75rem; font-weight: 600; display: flex; align-items: center; gap: 3px; }
.shame-time { color: var(--slate-500); font-size: .75rem; }
.shame-item-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.shame-resolve-btn {
  display: flex; align-items: center; gap: 6px; padding: 8px 14px;
  border-radius: var(--radius-md); background: var(--emerald-600);
  color: white; font-weight: 700; font-size: .75rem; border: none;
  cursor: pointer; transition: all var(--transition); white-space: nowrap;
}
.shame-resolve-btn:hover { filter: brightness(1.15); transform: translateY(-1px); }
.shame-icon { color: var(--rose-400); flex-shrink: 0; }
.shame-icon.resolved { color: var(--slate-600); }

/* Shame Someone Button */
.shame-someone-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: calc(100% - 64px); margin: 20px 32px 0; padding: 14px 24px;
  border-radius: var(--radius-md); background: var(--rose-600);
  color: white; font-weight: 700; font-size: .9375rem; border: none;
  cursor: pointer; transition: all var(--transition);
}
.shame-someone-btn:hover { filter: brightness(1.15); transform: translateY(-1px); }

/* Shame Search Modal */
.shame-search-modal { display: flex; flex-direction: column; gap: 8px; }
.shame-search-modal h3 { color: white; font-weight: 700; font-size: 1.125rem; }
.shame-search-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  border-radius: var(--radius-md); background: none; border: 1px solid transparent;
  cursor: pointer; transition: all var(--transition); width: 100;
  text-align: left; color: white;
}
.shame-search-item:hover { background: var(--slate-800); border-color: var(--glass-border); }
.shame-search-item img { width: 40px; height: 60px; border-radius: var(--radius-sm); object-fit: cover; flex-shrink: 0; }
.shame-search-poster { width: 40px; height: 60px; border-radius: var(--radius-sm); background: var(--slate-800); display: flex; align-items: center; justify-content: center; color: var(--slate-600); flex-shrink: 0; }
.shame-search-title { font-weight: 600; font-size: .875rem; }
.shame-search-type { color: var(--slate-400); font-size: .75rem; }

/* Shame Sections (new layout) */
.shame-section { margin: 0 32px 24px; }
.shame-section .shame-items { padding: 0; }
.shame-section-header {
  display: flex; align-items: center; gap: 8px;
  font-size: .8125rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; color: var(--slate-400);
  padding: 0 0 10px; border-bottom: 1px solid var(--glass-border); margin-bottom: 10px;
}
.shame-section-badge {
  margin-left: auto; background: var(--slate-700);
  color: var(--slate-300); font-size: .6875rem; font-weight: 700;
  padding: 2px 7px; border-radius: 99px;
}
.shame-section-badge.shame-badge-alert { background: var(--rose-600); color: white; }

/* Verdict / absolution buttons */
.shame-absolve-btn, .shame-deny-btn {
  display: flex; align-items: center; gap: 4px; padding: 6px 12px;
  border-radius: var(--radius-md); border: none; cursor: pointer;
  font-weight: 700; font-size: .75rem; transition: all var(--transition); white-space: nowrap;
}
.shame-absolve-btn { background: var(--emerald-600); color: white; }
.shame-absolve-btn:hover { filter: brightness(1.15); }
.shame-deny-btn { background: var(--rose-700); color: white; }
.shame-deny-btn:hover { filter: brightness(1.15); }
.shame-rescind-btn {
  display: flex; align-items: center; gap: 4px; padding: 6px 12px;
  border-radius: var(--radius-md); border: 1px solid rgba(148,163,184,.25); cursor: pointer;
  font-weight: 600; font-size: .75rem; transition: all var(--transition); white-space: nowrap;
  background: transparent; color: var(--slate-400);
}
.shame-rescind-btn:hover { background: rgba(239,68,68,.1); color: var(--rose-400); border-color: rgba(239,68,68,.3); }
.shame-verdict-prompt { color: var(--amber-400) !important; font-weight: 600; margin-top: 4px !important; }
.shame-pending-note { color: var(--amber-400) !important; font-size: .75rem !important; margin-top: 2px !important; }

/* Pending absolution card */
.shame-list-item.pending-absolution { border-color: var(--amber-500); border-left-width: 3px; animation: shame-pulse 2.5s ease-in-out infinite; }
@keyframes shame-pulse { 0%,100% { box-shadow: 0 0 0 rgba(245,158,11,0); } 50% { box-shadow: 0 0 12px rgba(245,158,11,.25); } }
.shame-empty-text { color: var(--slate-500); font-size: .875rem; padding: 12px 0; text-align: center; }

/* =============================================
   ACTIVITY DOTS ON CARDS
   ============================================= */
.media-card-sm, .media-card { position: relative; }
.activity-dot {
  position: absolute; top: 6px; right: 40px; z-index: 3;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--emerald-500); border: 2px solid var(--bg-primary);
  box-shadow: 0 0 6px rgba(16,185,129,.5);
  animation: dot-pulse 2s ease-in-out infinite;
}
@keyframes dot-pulse {
  0%, 100% { box-shadow: 0 0 6px rgba(16,185,129,.5); }
  50% { box-shadow: 0 0 12px rgba(16,185,129,.8); }
}
.plex-card-badge {
  position: absolute; bottom: 6px; right: 6px; z-index: 3;
  width: 24px; height: 24px;
  background: rgba(18, 14, 0, 0.72);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
  backdrop-filter: blur(3px);
  box-shadow: 0 1px 6px rgba(0,0,0,.5);
}

/* =============================================
   FRIEND AVATARS ON EPISODES
   ============================================= */
.ep-friend-avatars {
  display: flex; align-items: center; margin-top: 6px;
}
.ep-friend-av {
  width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid var(--bg-secondary);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: .625rem; font-weight: 700; color: white;
  background: linear-gradient(135deg, var(--indigo-500), var(--purple-600));
  margin-left: -6px; object-fit: cover; flex-shrink: 0;
}
.ep-friend-av:first-child { margin-left: 0; }
.ep-friend-av.more { background: var(--slate-700); font-size: .5625rem; color: var(--slate-300); }
img.ep-friend-av { background: var(--slate-800); }

/* =============================================
   MATCHER PAGES
   ============================================= */
.matcher-page { padding-bottom: 40px; max-width: 800px; margin: 0 auto; }
.matcher-setup-content { padding: 0 32px; }
.setup-desc { color: var(--slate-400); font-size: .9375rem; line-height: 1.6; margin-bottom: 28px; }
.setup-section { margin-bottom: 28px; }
.setup-section h3 { color: white; font-weight: 700; font-size: 1.0625rem; margin-bottom: 12px; }
.friend-select-list { display: flex; flex-wrap: wrap; gap: 10px; }
.friend-select-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 18px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: white; font-weight: 500; cursor: pointer;
  transition: all var(--transition);
}
.friend-select-btn:hover { background: var(--slate-800); border-color: var(--slate-700); }
.friend-select-btn.active { border-color: var(--emerald-500); background: rgba(16,185,129,.08); color: var(--emerald-400); }
.start-matcher-btn { width: 100%; margin-top: 8px; }

/* Swipe Page */
.swipe-page { padding: 0; display: flex; flex-direction: column; align-items: center; min-height: 100vh; }
.swipe-header {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  padding: 20px 32px;
}
.back-btn-sm {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  display: flex; align-items: center; justify-content: center;
  color: white; cursor: pointer; transition: all var(--transition);
}
.back-btn-sm:hover { background: var(--slate-800); }
.swipe-progress { color: var(--slate-400); font-size: .875rem; font-weight: 600; }
.swipe-card {
  width: 100%; max-width: 440px; height: 560px; border-radius: var(--radius-xl);
  overflow: hidden; background-size: cover; background-position: center;
  box-shadow: 0 16px 48px rgba(0,0,0,.4);
  transition: transform .3s, opacity .3s; margin-bottom: 28px;
}
.swipe-card-content {
  height: 100%; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 28px; background: linear-gradient(to top, rgba(0,0,0,.85) 0%, transparent 60%);
}
.swipe-poster { width: 80px; height: 120px; border-radius: var(--radius-sm); object-fit: cover; margin-bottom: 12px; box-shadow: 0 4px 16px rgba(0,0,0,.4); }
.swipe-title { color: white; font-size: 1.5rem; font-weight: 800; margin-bottom: 4px; }
.swipe-meta { display: flex; align-items: center; gap: 4px; color: var(--amber-400); font-weight: 600; margin-bottom: 6px; }
.swipe-overview { color: var(--slate-300); font-size: .8125rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.swipe-buttons { display: flex; justify-content: center; gap: 28px; }
.swipe-btn {
  width: 68px; height: 68px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid; transition: all var(--transition);
  background: var(--glass-bg); backdrop-filter: var(--glass-blur);
}
.swipe-btn:hover { transform: scale(1.1); }
.swipe-btn.dislike { border-color: var(--rose-500); color: var(--rose-500); }
.swipe-btn.dislike:hover { background: rgba(244,63,94,.1); }
.swipe-btn.like { border-color: var(--emerald-500); color: var(--emerald-500); }
.swipe-btn.like:hover { background: rgba(16,185,129,.1); }

/* Matcher Results */
.results-page { padding: 0 32px 40px; max-width: 1000px; margin: 0 auto; }
.results-summary { text-align: center; padding: 32px 0; }
.match-count { font-size: 4rem; font-weight: 800; color: var(--emerald-400); line-height: 1; }
.results-summary p { color: var(--slate-300); font-size: 1.125rem; margin-top: 8px; }

/* Matcher History */
.history-page { padding-bottom: 40px; }
.history-items { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }
.history-item {
  display: flex; align-items: center; gap: 14px; padding: 16px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border); cursor: pointer;
  transition: all var(--transition);
}
.history-item:hover { background: var(--slate-800); }
.history-info { flex: 1; }
.history-type { color: white; font-weight: 600; }
.history-matches { color: var(--emerald-400); font-size: .875rem; font-weight: 600; }
.history-date { color: var(--slate-500); font-size: .75rem; }

/* =============================================
   ANALYTICS PAGE
   ============================================= */
.analytics-page { padding-bottom: 40px; }
.analytics-content { padding: 0 32px; }
.analytics-stats { grid-template-columns: repeat(4, 1fr); }

/* Top media horizontal scroll */
.analytics-top-scroll {
  display: flex; gap: 12px; overflow-x: auto; padding-bottom: 8px;
  scrollbar-width: thin; scrollbar-color: var(--slate-700) transparent;
}
.analytics-top-scroll::-webkit-scrollbar { height: 4px; }
.analytics-top-scroll::-webkit-scrollbar-track { background: transparent; }
.analytics-top-scroll::-webkit-scrollbar-thumb { background: var(--slate-700); border-radius: 2px; }
.analytics-top-card {
  flex-shrink: 0; width: 96px; cursor: pointer;
  transition: transform .15s; text-align: left;
}
.analytics-top-card:hover { transform: translateY(-3px); }
.analytics-top-card img {
  width: 96px; height: 144px; border-radius: var(--radius-md);
  object-fit: cover; display: block; margin-bottom: 6px; background: var(--slate-800);
}
.analytics-top-poster-ph {
  width: 96px; height: 144px; border-radius: var(--radius-md);
  background: var(--slate-800); display: flex; align-items: center; justify-content: center;
  color: var(--slate-600); margin-bottom: 6px;
}
.analytics-top-title {
  font-size: .6875rem; color: white; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 96px;
}
.analytics-top-rating { font-size: .6875rem; color: var(--emerald-400); font-weight: 700; margin-top: 2px; display: flex; align-items: center; gap: 3px; }

/* Top episodes list */
.analytics-ep-list { display: flex; flex-direction: column; gap: 4px; }
.analytics-ep-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px;
  border-radius: var(--radius-md); background: rgba(255,255,255,.03);
  transition: background .15s; cursor: default;
}
.analytics-ep-item:hover { background: rgba(255,255,255,.06); }
.analytics-ep-info { flex: 1; min-width: 0; }
.analytics-ep-show { color: var(--emerald-400); font-weight: 600; font-size: .875rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.analytics-ep-name { color: white; font-size: .8125rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.analytics-ep-num { color: var(--slate-400); font-size: .75rem; }
.analytics-ep-rating { color: white; font-weight: 700; font-size: .9375rem; flex-shrink: 0; }

.chart-section {
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 24px; margin-bottom: 20px;
}
.chart-section h3 { color: white; font-weight: 700; font-size: 1.0625rem; margin-bottom: 16px; }

.bar-chart { display: flex; flex-direction: column; gap: 10px; }
.bar-row { display: flex; align-items: center; gap: 12px; }
.bar-label { width: 80px; color: var(--slate-400); font-size: .8125rem; text-align: right; flex-shrink: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { flex: 1; height: 28px; background: var(--slate-800); border-radius: var(--radius-sm); overflow: hidden; }
.bar-fill {
  height: 100%; border-radius: var(--radius-sm);
  background: linear-gradient(90deg, var(--emerald-500), var(--emerald-400));
  transition: width .6s cubic-bezier(.4,0,.2,1);
  display: flex; align-items: center; padding-left: 10px;
  font-size: .75rem; font-weight: 600; color: white; min-width: 0;
}
.bar-value { color: var(--slate-400); font-size: .8125rem; font-weight: 600; min-width: 32px; }

/* Rating Distribution */
.bar-chart.horizontal {
  flex-direction: row; align-items: flex-end; gap: 6px;
  height: 140px; justify-content: center;
}
.rating-bar {
  flex: 1; max-width: 48px; display: flex; flex-direction: column;
  align-items: center; justify-content: flex-end; height: 100%; position: relative;
}
.rbar-fill {
  width: 100%; border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  background: linear-gradient(to top, var(--indigo-600), var(--indigo-400));
  transition: height .6s cubic-bezier(.4,0,.2,1); min-height: 2px;
}
.rbar-label { color: var(--slate-400); font-size: .75rem; margin-top: 6px; font-weight: 600; }

/* =============================================
   ACTIVITY CALENDAR
   ============================================= */
.activity-calendar-section { overflow-x: auto; }
.activity-calendar {
  display: flex; flex-wrap: wrap; gap: 20px;
  padding-bottom: 8px;
}
.cal-month-block { flex: 0 0 auto; min-width: 200px; }
.cal-month-label {
  font-size: .75rem; font-weight: 700; color: var(--slate-300);
  text-transform: uppercase; letter-spacing: .06em; margin-bottom: 6px;
}
.cal-day-headers { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin-bottom: 2px; }
.cal-dh { font-size: .625rem; color: var(--slate-500); text-align: center; font-weight: 600; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-cell {
  aspect-ratio: 1; border-radius: 3px; background: var(--slate-800);
  display: flex; align-items: center; justify-content: center;
  font-size: .6rem; font-weight: 700; cursor: default; position: relative;
  transition: transform .1s;
}
.cal-cell:hover { transform: scale(1.3); z-index: 2; }
.cal-cell.cal-empty { background: transparent; cursor: default; }
.cal-cell.cal-today { outline: 2px solid var(--indigo-400); outline-offset: 1px; }
.cal-cell.heat-low  { background: var(--emerald-900); color: var(--emerald-300); }
.cal-cell.heat-mid  { background: var(--emerald-700); color: var(--emerald-100); }
.cal-cell.heat-high { background: var(--emerald-500); color: white; box-shadow: 0 0 8px rgba(16,185,129,.4); }
.cal-count { font-size: .6rem; line-height: 1; }
.calendar-legend {
  display: flex; align-items: center; gap: 8px;
  font-size: .75rem; color: var(--slate-500); margin-top: 12px;
}
.cal-dot-low, .cal-dot-mid, .cal-dot-high {
  width: 12px; height: 12px; border-radius: 3px; display: inline-block;
}
.cal-dot-low  { background: var(--emerald-900); }
.cal-dot-mid  { background: var(--emerald-700); }
.cal-dot-high { background: var(--emerald-500); }

/* Calendar Day Detail Modal */
.cal-day-modal { padding: 4px 0; }
.cal-day-modal-title { font-size: 1.125rem; font-weight: 800; color: var(--text-primary); margin: 0 0 4px; }
.cal-day-modal-sub { font-size: .8125rem; color: var(--text-secondary); margin: 0 0 16px; }
.cal-day-modal-list { display: flex; flex-direction: column; gap: 8px; }
.cal-day-group { background: var(--bg-secondary, var(--surface-1)); border: 1px solid var(--border-subtle); border-radius: 10px; padding: 10px 12px; transition: border-color .15s, background .15s; }
.cal-day-group:hover { border-color: rgba(99,102,241,.3); background: rgba(99,102,241,.04); }
.cal-day-group-header { display: flex; align-items: center; gap: 8px; }
.cal-day-icon { color: var(--text-secondary); flex-shrink: 0; display: flex; }
.cal-day-show-name { font-size: .875rem; font-weight: 700; color: var(--text-primary); flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-day-count { font-size: .6875rem; font-weight: 600; color: var(--indigo-400); background: rgba(99,102,241,.12); padding: 2px 7px; border-radius: 999px; flex-shrink: 0; }
.cal-day-type-badge { font-size: .6875rem; font-weight: 600; color: var(--text-secondary); background: var(--surface-2, rgba(255,255,255,.06)); padding: 2px 7px; border-radius: 999px; flex-shrink: 0; }
.cal-day-eps { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.cal-day-ep-tag { font-size: .75rem; color: var(--text-secondary); background: rgba(255,255,255,.05); border: 1px solid var(--border-subtle); padding: 3px 8px; border-radius: 6px; }

/* =============================================
   BADGES PAGE
   ============================================= */
.badges-page { padding-bottom: 40px; }
.badges-summary { text-align: center; padding: 16px 32px 24px; }
.badge-count { font-size: 2rem; font-weight: 800; color: var(--amber-400); }
.badges-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px; padding: 0 32px;
}
.badge-card {
  background: var(--glass-bg); border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border); padding: 20px 16px;
  text-align: center; transition: all var(--transition);
}
.badge-card.earned { border-color: rgba(245,158,11,.2); background: rgba(245,158,11,.04); }
.badge-card.locked { opacity: .6; }
.badge-emoji { font-size: 2.25rem; margin-bottom: 8px; display: block; }
.badge-name { color: white; font-weight: 700; font-size: .875rem; margin-bottom: 4px; }
.badge-desc { color: var(--slate-500); font-size: .75rem; margin-bottom: 10px; line-height: 1.4; }
.badge-progress { height: 4px; background: var(--slate-800); border-radius: 2px; overflow: hidden; }
.badge-progress-fill { height: 100%; background: var(--amber-500); border-radius: 2px; transition: width .5s; }

/* =============================================
   PLEX PAGES
   ============================================= */
.plex-page { padding-bottom: 40px; max-width: 800px; margin: 0 auto; }
.plex-content { padding: 0 32px; }
.plex-status {
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg); padding: 40px; text-align: center;
}
.plex-status h3 { color: white; font-weight: 700; font-size: 1.25rem; margin-bottom: 8px; }
.plex-status p { color: var(--slate-400); line-height: 1.6; margin-bottom: 20px; }
.plex-icon {
  width: 72px; height: 72px; border-radius: var(--radius-lg);
  background: rgba(245,158,11,.08); border: 1px solid rgba(245,158,11,.15);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 20px; color: var(--amber-500);
}
.plex-icon.connected { background: rgba(16,185,129,.08); border-color: rgba(16,185,129,.15); color: var(--emerald-500); }
.plex-server { color: var(--slate-300); font-size: .9375rem; margin-bottom: 20px; }
.plex-actions { display: flex; flex-direction: column; gap: 10px; }
.btn-secondary {
  padding: 14px 24px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--slate-200); font-weight: 700; font-size: .9375rem;
  text-align: center; cursor: pointer; transition: all var(--transition);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-secondary:hover { background: var(--slate-800); border-color: var(--slate-700); }

.plex-watched-page { padding-bottom: 40px; }
.plex-watched-page .filter-tabs { padding: 0 32px; margin-bottom: 16px; }
.plex-tag { background: var(--amber-500); color: black; padding: 2px 8px; border-radius: 999px; font-size: .6875rem; font-weight: 700; }
.plex-history-list { padding: 0 32px; }
.plex-date-separator {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0 8px; margin-top: 8px; border-bottom: 1px solid var(--glass-border);
  color: var(--slate-300); font-weight: 600; font-size: .875rem;
}
.plex-date-separator:first-child { margin-top: 0; }
.plex-date-count { color: var(--slate-500); font-weight: 400; font-size: .75rem; }
.plex-history-group { display: flex; flex-direction: column; gap: 4px; padding: 8px 0; }
.plex-history-item {
  display: flex; align-items: center; gap: 14px; padding: 12px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border); transition: all var(--transition);
}
.plex-history-item:hover { background: var(--slate-800); border-color: var(--slate-700); }
.plex-poster {
  width: 48px; height: 72px; border-radius: var(--radius-sm); object-fit: cover;
  background: var(--slate-800); flex-shrink: 0;
}
.plex-poster.placeholder {
  display: flex; align-items: center; justify-content: center; color: var(--slate-600);
}
.plex-item-info { flex: 1; min-width: 0; }
.plex-item-title { color: white; font-weight: 600; font-size: .9375rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plex-item-sub { color: var(--slate-400); font-size: .8125rem; margin-top: 2px; }

/* =============================================
   SHARED LISTS
   ============================================= */
.lists-page { padding-bottom: 40px; }
.create-list-btn { margin: 0 32px 20px; }
.list-items { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }
.list-item {
  display: flex; align-items: center; gap: 14px; padding: 16px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border); cursor: pointer;
  transition: all var(--transition);
}
.list-item:hover { background: var(--slate-800); border-color: var(--slate-700); }
.list-icon {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.list-info { flex: 1; }
.list-name { color: white; font-weight: 600; }
.list-count { color: var(--slate-400); font-size: .8125rem; }
.list-date { color: var(--slate-500); font-size: .75rem; }
.list-members { color: var(--slate-400); font-size: .875rem; padding: 0 32px; margin-bottom: 20px; }
.card-remove-btn {
  position: absolute; top: 8px; right: 8px;
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(0,0,0,.6); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  color: white; cursor: pointer; transition: all var(--transition);
  opacity: 0;
}
.media-card:hover .card-remove-btn { opacity: 1; }
.card-remove-btn:hover { background: var(--rose-500); }

.list-detail-page { padding-bottom: 40px; }

/* Create list modal */
.create-list-modal { display: flex; flex-direction: column; gap: 16px; }
.create-list-modal h3 { color: white; font-weight: 700; }
.modal-buttons { display: flex; gap: 10px; justify-content: flex-end; }

/* =============================================
   ACTOR / CAST / SHARED ACTORS / YOUTUBE
   ============================================= */
.actor-page { padding-bottom: 40px; }
.actor-header { display: flex; gap: 24px; padding: 0 32px; margin-bottom: 28px; align-items: flex-start; }
.actor-photo {
  width: 160px; height: 200px; border-radius: var(--radius-lg);
  object-fit: cover; background: var(--slate-800); flex-shrink: 0;
  box-shadow: 0 8px 28px rgba(0,0,0,.4);
}
.actor-photo.placeholder { display: flex; align-items: center; justify-content: center; color: var(--slate-600); }
.actor-info { flex: 1; padding-top: 8px; }
.actor-info h2 { color: white; font-weight: 700; font-size: 1.5rem; margin-bottom: 8px; }
.actor-dept { color: var(--emerald-400); font-weight: 600; font-size: .875rem; margin-bottom: 4px; }
.actor-birth { color: var(--slate-400); font-size: .875rem; }
.actor-place { color: var(--slate-500); font-size: .8125rem; }
.bio-text { color: var(--slate-300); font-size: .9375rem; line-height: 1.7; padding: 0 32px; }

.filmography-section { margin-bottom: 24px; }
.filmography-heading {
  color: var(--slate-200); font-weight: 700; font-size: 1rem;
  padding: 12px 0 8px; border-bottom: 1px solid var(--glass-border); margin-bottom: 8px;
}

.cast-page { padding-bottom: 40px; }
.cast-list { display: flex; flex-direction: column; gap: 2px; padding: 0 32px; }
.cast-list-item {
  display: flex; align-items: center; gap: 14px; padding: 12px 16px;
  border-radius: var(--radius-md); background: var(--glass-bg);
  border: 1px solid var(--glass-border); cursor: pointer;
  transition: all var(--transition);
}
.cast-list-item:hover { background: var(--slate-800); }
.cast-photo { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; background: var(--slate-800); flex-shrink: 0; }
.cast-photo.placeholder { display: flex; align-items: center; justify-content: center; color: var(--slate-600); }
.cast-info { flex: 1; }
.cast-info .cast-name { color: white; font-weight: 600; }
.cast-info .cast-char { color: var(--slate-400); font-size: .8125rem; }

.shared-actors-page { padding-bottom: 40px; }

.youtube-page { padding: 0 32px 40px; }
.youtube-embed { border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 16px; }
.youtube-embed iframe { width: 100%; height: 480px; border: none; }
.youtube-note { color: var(--slate-400); font-size: .875rem; }

/* =============================================
   MODAL
   ============================================= */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.65);
  backdrop-filter: blur(6px); z-index: 500;
  display: flex; align-items: center; justify-content: center;
  transition: opacity .2s;
}
.modal-overlay.hidden { display: none; }
.modal-box {
  background: var(--slate-900); border: 1px solid var(--slate-800);
  border-radius: var(--radius-xl); width: 100%; max-width: 500px;
  max-height: 85vh; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 28px;
  animation: fadeScale .25s ease-out;
  box-shadow: 0 24px 64px rgba(0,0,0,.5);
  overscroll-behavior: contain;
}
@keyframes fadeScale { from { transform: scale(.96); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.modal-header h2 { color: white; font-size: 1.25rem; font-weight: 700; }
.modal-close {
  width: 36px; height: 36px; border-radius: 50%; background: var(--glass-bg);
  border: 1px solid var(--glass-border); display: flex; align-items: center;
  justify-content: center; cursor: pointer; color: var(--slate-400);
  transition: all var(--transition);
}
.modal-close:hover { background: var(--slate-800); color: white; }

/* =============================================
   TOAST
   ============================================= */
#toast-container {
  position: fixed; top: 20px; right: 20px; z-index: 9999;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  background: var(--slate-800); border: 1px solid var(--slate-700);
  border-radius: var(--radius-md); padding: 14px 18px; min-width: 280px;
  display: flex; align-items: center; gap: 10px; color: white;
  font-size: .875rem; font-weight: 500;
  box-shadow: 0 8px 28px rgba(0,0,0,.35);
  animation: toastIn .3s ease-out;
  transition: opacity .3s, transform .3s;
}
.toast.success { border-color: rgba(16,185,129,.3); }
.toast.error { border-color: rgba(239,68,68,.3); }
.toast.info { border-color: rgba(59,130,246,.3); }
@keyframes toastIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* Badge unlock toast */
.badge-toast { padding: 12px 14px; min-width: 300px; gap: 12px; }
.badge-toast-icon { font-size: 1.6rem; flex-shrink: 0; line-height: 1; }
.badge-toast-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.badge-toast-title { font-size: .65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; opacity: .7; }
.badge-toast-name { font-size: .9rem; font-weight: 600; }
.badge-toast-view { background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.2); color: #fff; padding: 5px 12px; border-radius: 6px; cursor: pointer; font-size: .8rem; font-weight: 600; flex-shrink: 0; transition: background .15s; }
.badge-toast-view:hover { background: rgba(255,255,255,.25); }

/* =============================================
   EMPTY STATE
   ============================================= */
.empty-state {
  text-align: center; padding: 64px 32px; color: var(--slate-500);
}
.empty-state svg { margin-bottom: 16px; opacity: .4; }
.empty-state h3 { color: var(--slate-400); font-size: 1.125rem; margin-bottom: 8px; font-weight: 600; }
.empty-state p { font-size: .875rem; line-height: 1.5; }

/* =============================================
   UTILITIES
   ============================================= */
.hidden { display: none !important; }
.loading-inline { display: flex; justify-content: center; padding: 48px; }
.text-center { text-align: center; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.px-16 { padding-left: 16px; padding-right: 16px; }

/* Plex watched items */
.plex-watched-item {
  display: flex; gap: 14px; padding: 14px; border-radius: var(--radius-md);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  margin-bottom: 4px;
}
.plex-watched-item img { width: 64px; height: 96px; border-radius: var(--radius-sm); object-fit: cover; background: var(--slate-800); }
.plex-watched-item .info { flex: 1; }
.plex-watched-item .title { color: white; font-weight: 600; }
.plex-watched-item .meta { color: var(--slate-400); font-size: .8125rem; }
.progress-bar { height: 4px; background: var(--slate-800); border-radius: 2px; overflow: hidden; margin-top: 4px; }
.progress-fill { height: 100%; background: var(--emerald-500); border-radius: 2px; }

/* Matcher Setup buttons */
.btn-sm {
  padding: 8px 16px; border-radius: 999px; font-size: .8125rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
}
.btn-sm.primary { background: var(--emerald-500); color: white; }
.btn-sm.primary:hover { background: var(--emerald-600); }
.btn-sm.outline { border: 1px solid var(--slate-700); color: var(--slate-300); }
.btn-sm.outline:hover { background: var(--slate-800); }
.btn-sm.danger { background: var(--rose-500); color: white; }

/* =============================================
   RESPONSIVE — Tablet (max-width: 1023px)
   ============================================= */
@media (max-width: 1023px) {
  .hero-carousel { height: 500px; }
  .hero-slide-content { padding: 0 24px 48px; max-width: none; }
  .hero-title { font-size: 2.25rem; }
  .carousel-dots { left: 24px; }
  .carousel-arrow { width: 40px; height: 40px; }
  .menu-grid { grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 20px 16px 12px; }
  .section-header { padding: 0 16px; }
  .horizontal-scroll { padding: 0 16px 8px; gap: 12px; }
  .media-card-sm { width: 160px; }
  .media-card-sm img { width: 160px; height: 240px; }
  .poster-placeholder { width: 160px; height: 240px; }
  .card-title { max-width: 160px; }
  .card-subtitle { max-width: 140px; }
  .page-header { padding: 20px 16px 12px; }
  .details-body { padding: 0 16px; }
  .details-top { gap: 16px; }
  .details-poster { width: 160px; height: 240px; }
  .details-info h1 { font-size: 1.5rem; }
  .details-content-grid { grid-template-columns: 1fr; }
  .cast-grid { grid-template-columns: repeat(3, 1fr); }
  .watchlist-items, .friend-items, .activity-items, .shame-items,
  .history-items, .list-items, .search-result-items, .cast-list { padding: 0 16px; }
  .profile-page { padding: 0 16px 40px; max-width: none; }
  .friend-profile-page .stats-grid { padding: 0 16px; }
  .friend-profile-page .section > h3 { padding: 0 16px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .media-grid { padding: 0 16px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .filter-tabs, .filter-chips { padding: 0 16px; }
  .search-container { padding: 0 16px; }
  .analytics-content { padding: 0 16px; }
  .badges-grid { padding: 0 16px; }
  .matcher-setup-content { padding: 0 16px; }
  .results-page { padding: 0 16px 40px; }
  .plex-content { padding: 0 16px; }
  .create-list-btn { margin: 0 16px 16px; }
  .actor-header { padding: 0 16px; }
  .bio-text { padding: 0 16px; }
  .youtube-page { padding: 0 16px 40px; }
}

/* =============================================
   RESPONSIVE — Small Mobile (max-width: 480px)
   ============================================= */
@media (max-width: 480px) {
  .hero-carousel { height: 420px; }
  .hero-title { font-size: 1.75rem; }
  .hero-slide-content { padding: 0 16px 44px; }
  .carousel-dots { left: 16px; }
  .carousel-controls { display: none; }
  .menu-grid { grid-template-columns: repeat(2, 1fr); }
  .details-top { flex-direction: column; align-items: center; text-align: center; }
  .details-poster { width: 120px; height: 180px; }
  .details-info h1 { font-size: 1.25rem; }
  .details-info { align-items: center; }
  .actions-row { justify-content: center; }
  .details-genres { justify-content: center; }
  .details-stats-row { justify-content: center; }
  .actor-header { flex-direction: column; align-items: center; text-align: center; }
  .actor-photo { width: 120px; height: 150px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat-number { font-size: 1.25rem; }
  .stat-card { padding: 14px 10px; }
  .swipe-card { max-width: 100%; height: 480px; border-radius: var(--radius-lg); }
  .modal-box { margin: 16px; max-width: calc(100% - 32px); }
  .youtube-embed iframe { height: 260px; }
}

/* =============================================
   RESPONSIVE — Large Desktop (min-width: 1440px)
   ============================================= */
@media (min-width: 1440px) {
  .hero-carousel { height: 650px; }
  .hero-title { font-size: 3rem; }
  .hero-slide-content { padding: 0 64px 60px; }
  .carousel-dots { left: 64px; }
  .menu-grid { padding: 28px 48px 16px; gap: 14px; }
  .section-header { padding: 0 48px; }
  .horizontal-scroll { padding: 0 48px 8px; }
  .media-card-sm { width: 200px; }
  .media-card-sm img { width: 200px; height: 300px; }
  .poster-placeholder { width: 200px; height: 300px; }
  .card-title { max-width: 200px; }
  .card-subtitle { max-width: 180px; }
  .page-header { padding: 28px 48px 16px; }
  .details-body { padding: 0 48px; }
  .details-poster { width: 280px; height: 420px; }
  .details-info h1 { font-size: 2.75rem; }
  .details-content-grid { grid-template-columns: 1fr 360px; }
  .watchlist-items, .friend-items, .activity-items, .shame-items,
  .history-items, .list-items, .search-result-items, .cast-list { padding: 0 48px; }
  .media-grid { padding: 0 48px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .filter-tabs, .filter-chips { padding: 0 48px; }
  .search-container { padding: 0 48px; }
  .analytics-content { padding: 0 48px; }
  .badges-grid { padding: 0 48px; }
  .matcher-setup-content { padding: 0 48px; }
  .profile-page { padding: 0 48px 40px; max-width: none; }
  .friend-profile-page .stats-grid { padding: 0 48px; }
  .friend-profile-page .section > h3 { padding: 0 48px; }
  .results-page { padding: 0 48px 40px; }
  .plex-content { padding: 0 48px; }
  .create-list-btn { margin: 0 48px 20px; }
  .actor-header { padding: 0 48px; }
  .bio-text { padding: 0 48px; }
}

/* =============================================
   ANIMATIONS — pages, cards, lists, modals
   ============================================= */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInScale {
  from { opacity: 0; transform: scale(.96) translateY(6px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: translateX(0); }
}

/* Page-level and element animations are handled by js/animations.js (Web Animations API).
   Keeping only keyframes needed by non-page elements (spinner, toast, modal, chart bars). */

/* Chart bars animate in */
.bar-fill { animation: barGrow .6s .2s cubic-bezier(.4,0,.2,1) both; }
@keyframes barGrow { from { width: 0; } }
.rbar-fill { animation: rbarGrow .6s .2s cubic-bezier(.4,0,.2,1) both; }
@keyframes rbarGrow { from { height: 0; } }

/* Modal backdrop */
.modal-overlay:not(.hidden) { animation: modalBgIn .2s ease-out; }
@keyframes modalBgIn { from { opacity: 0; } to { opacity: 1; } }

/* Swipe card enter */
.swipe-card {
  animation: fadeInScale .35s cubic-bezier(.4,0,.2,1);
}

/* Respect reduced motion preference */
/* prefers-reduced-motion: we rely on Web Animations API for entrance
   animations (unaffected by this rule) so no blanket kill needed. */

/* =============================================
   MOBILE RESPONSIVE — Full content layout
   ============================================= */
@media (max-width: 768px) {
  /* Hero */
  .hero-carousel { height: 460px; }
  .hero-slide-content { padding: 0 20px 44px; max-width: none; }
  .hero-title { font-size: 2rem; }
  .hero-overview { font-size: .8125rem; -webkit-line-clamp: 2; line-clamp: 2; }
  .hero-logo-img { max-height: 56px; max-width: 200px; }

  /* Menu 2-col */
  .menu-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; padding: 16px 16px 12px; }
  .menu-item { padding: 12px 14px; font-size: .75rem; }
  .menu-icon { width: 32px; height: 32px; }

  /* Sections tighter */
  .section-header { padding: 0 16px; margin-bottom: 12px; }
  .section-header h3 { font-size: 1.1rem; }
  .horizontal-scroll { padding: 0 16px 8px; gap: 12px; }

  /* Cards smaller */
  .media-card-sm { width: 145px; }
  .media-card-sm img { width: 145px; height: 218px; }
  .poster-placeholder { width: 145px; height: 218px; }
  .card-title { max-width: 145px; font-size: .75rem; }
  .card-subtitle { max-width: 130px; }

  /* Details — left-aligned, NOT centered */
  .details-hero { height: 360px; }
  .details-body { padding: 0 16px; margin-top: -100px; }
  .details-top { gap: 16px; flex-direction: row; text-align: left; }
  .details-poster { width: 130px; height: 195px; }
  .details-info h1 { font-size: 1.5rem; }
  .details-info { align-items: flex-start; }
  .details-logo { max-width: 200px; max-height: 60px; }
  .actions-row { justify-content: flex-start; flex-wrap: wrap; }
  .action-btn { padding: 10px 16px; font-size: .8125rem; }
  .details-genres { justify-content: flex-start; }
  .details-stats-row { justify-content: flex-start; }
  .details-content-grid { grid-template-columns: 1fr; gap: 20px; }
  .details-sidebar { order: 2; }
  .cast-grid { grid-template-columns: repeat(3, 1fr); }

  /* Episodes compact */
  .episode-item { padding: 10px; gap: 12px; }
  .episode-still { width: 120px; height: 68px; }
  .ep-name { font-size: .875rem; }
  .ep-desc { -webkit-line-clamp: 1; line-clamp: 1; font-size: .75rem; }

  /* Watchlist */
  .watchlist-items { padding: 0 16px; }
  .watchlist-item { padding: 12px; gap: 12px; }
  .watchlist-item img, .wl-poster { width: 52px; height: 78px; }
  .wl-title { font-size: .875rem; }

  /* Profile */
  .profile-page { padding: 0 16px 80px; }
  .profile-avatar-lg { width: 80px; height: 80px; font-size: 1.75rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat-card { padding: 14px 10px; }
  .stat-number { font-size: 1.5rem; }
  .stat-label { font-size: .6875rem; }

  /* Friend watched-all episode cards (mobile) */
  .fw-ep-card { flex-direction: column; gap: 0; }
  .fw-ep-backdrop-wrap { width: 100%; min-width: unset; }
  .fw-ep-details { padding: 12px 14px 14px; }
  .fw-ep-logo { max-height: 22px; max-width: 120px; }
  .fw-section-tabs { gap: 4px; }
  .fw-section-tab { padding: 6px 10px; font-size: 12px; }

  /* Friends / Activity */
  .friend-items { padding: 0 16px; }
  .search-result-items { padding: 0 16px; }
  .activity-items { padding: 0 16px; }
  .shame-items { padding: 0 16px; }

  /* Analytics */
  .analytics-content { padding: 0 16px; }
  .chart-section { padding: 16px; }
  .bar-chart.horizontal { height: 120px; }
  .rating-bar { max-width: 36px; }

  /* Badges */
  .badges-grid { padding: 0 16px; grid-template-columns: repeat(2, 1fr); }

  /* Matcher */
  .matcher-setup-content { padding: 0 16px; }
  .swipe-card { max-width: 100%; height: 480px; }
  .swipe-buttons { gap: 20px; }
  .swipe-btn { width: 60px; height: 60px; }

  /* Actor */
  .actor-header { padding: 0 16px; gap: 16px; }
  .actor-photo { width: 120px; height: 150px; }
  .actor-info h2 { font-size: 1.25rem; }
  .bio-text { padding: 0 16px; font-size: .875rem; }

  /* Plex */
  .plex-content { padding: 0 16px; }
  .plex-status { padding: 28px 20px; }

  /* Lists */
  .list-items { padding: 0 16px; }
  .create-list-btn { margin: 0 16px 16px; }

  /* Media grid */
  .media-grid { padding: 0 16px; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }

  /* Discover */
  .search-container { padding: 0 16px; }
  .filter-tabs { padding: 0 16px; }
  .filter-chips { padding: 0 16px; }
  .disc-grid-slider-row { padding: 0 16px; }
  .search-bar { height: 48px; }

  /* Modal */
  .modal-box { max-width: calc(100vw - 32px); padding: 20px; margin: 16px; }

  /* Toast at bottom for mobile */
  #toast-container { top: auto; bottom: 80px; right: 16px; left: 16px; }
  .toast { min-width: auto; width: 100%; }

  /* YouTube */
  .youtube-embed iframe { height: 240px; }
  .youtube-page { padding: 0 16px 80px; }

  /* Page header */
  .page-header { padding: 16px 16px 12px; }
  .page-header h1 { font-size: 1.25rem; }

  /* History / Results */
  .history-items { padding: 0 16px; }
  .results-page { padding: 0 16px 40px; }
}

/* Small phones */
@media (max-width: 400px) {
  .hero-carousel { height: 380px; }
  .hero-title { font-size: 1.5rem; }
  .hero-meta { gap: 4px; }
  .hero-type, .hero-year { padding: 3px 10px; font-size: .6875rem; }
  .menu-grid { padding: 12px; }
  .menu-item { padding: 10px 12px; font-size: .6875rem; gap: 8px; }
  .menu-icon { width: 28px; height: 28px; }
  .details-poster { width: 100px; height: 150px; }
  .details-info h1 { font-size: 1.25rem; }
  .episode-still { width: 90px; height: 50px; }
  .swipe-card { height: 420px; }
  .badges-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .badge-card { padding: 14px 10px; }
  .badge-emoji { font-size: 1.75rem; }
}

/* =============================================
   NEW FEATURE STYLES
   ============================================= */

/* --- Task 11: iOS input zoom fix --- */
@media (hover: none) and (pointer: coarse) {
  input, select, textarea { font-size: 16px !important; }
}

/* --- Task 12: Carousel scroll-padding mobile override --- */
@media (max-width: 1023px) {
  .horizontal-scroll { scroll-padding-inline: 16px; }
}

/* --- Task 5: Rating chip overlay on discover cards --- */
.disc-rating-chip {
  position: absolute; bottom: 44px; right: 6px;
  background: rgba(0,0,0,.75); backdrop-filter: blur(4px);
  color: var(--amber-400); font-size: .6875rem; font-weight: 700;
  padding: 3px 7px; border-radius: 6px; border: 1px solid rgba(255,255,255,.1);
  display: inline-flex; align-items: center; gap: 3px; z-index: 2;
}

/* Quick-add button on discover cards */
.disc-quick-add {
  position: absolute; top: 6px; right: 6px; z-index: 3;
  width: 30px; height: 30px; border-radius: 50%;
  background: rgba(0,0,0,.65); backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,.15);
  color: white; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: .65; transition: opacity .2s, background .2s, transform .15s;
}
.media-card:hover .disc-quick-add { opacity: 1; }
.disc-quick-add:hover { background: var(--indigo-500); transform: scale(1.1); }
.disc-qa-popup {
  position: absolute; top: 40px; right: 6px; z-index: 10;
  background: var(--slate-800); border: 1px solid var(--slate-700);
  border-radius: 10px; padding: 4px;
  min-width: 160px; box-shadow: 0 8px 24px rgba(0,0,0,.5);
  display: flex; flex-direction: column;
}
.disc-qa-opt {
  background: none; border: none; color: var(--slate-200); cursor: pointer;
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 8px; font-size: .8125rem; font-weight: 500;
  white-space: nowrap; text-align: left;
}
.disc-qa-opt:hover { background: var(--slate-700); color: white; }
.disc-qa-divider { height: 1px; background: var(--slate-700); margin: 2px 8px; }

/* --- Global range slider base --- */
input[type="range"] {
  -webkit-appearance: none; appearance: none;
  height: 6px; border-radius: 3px; outline: none; cursor: pointer;
  background: var(--slate-700); transition: background .15s;
  margin: 0; padding: 0;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 6px; border-radius: 3px; background: var(--slate-700);
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 20px; height: 20px;
  border-radius: 50%; background: var(--indigo-500); cursor: pointer;
  border: 2px solid rgba(255,255,255,.25);
  box-shadow: 0 1px 6px rgba(0,0,0,.4);
  transition: transform .15s, box-shadow .15s;
  margin-top: -7px;
}
input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15); box-shadow: 0 2px 10px rgba(0,0,0,.5), 0 0 0 4px rgba(99,102,241,.15);
}
input[type="range"]::-webkit-slider-thumb:active { transform: scale(1.2); }
input[type="range"]::-moz-range-thumb {
  width: 20px; height: 20px; border-radius: 50%; background: var(--indigo-500);
  border: 2px solid rgba(255,255,255,.25); cursor: pointer;
  box-shadow: 0 1px 6px rgba(0,0,0,.4);
}
input[type="range"]::-moz-range-track {
  height: 6px; border-radius: 3px; background: var(--slate-700); border: none;
}
input[type="range"]::-ms-track {
  height: 6px; border-radius: 3px; background: var(--slate-700); border: none; color: transparent;
}
input[type="range"]::-ms-thumb {
  width: 20px; height: 20px; border-radius: 50%; background: var(--indigo-500);
  border: 2px solid rgba(255,255,255,.25); cursor: pointer;
  box-shadow: 0 1px 6px rgba(0,0,0,.4); margin-top: 0;
}
input[type="range"]::-ms-fill-lower { background: var(--indigo-500); border-radius: 3px; }
input[type="range"]::-ms-fill-upper { background: var(--slate-700); border-radius: 3px; }

/* Grid size slider row */
.disc-grid-slider-row {
  display: flex; align-items: center; gap: 10px;
  padding: 0 32px; margin: 6px 0 2px;
}
.disc-grid-slider-row label {
  color: var(--slate-500); display: flex; align-items: center;
}
#disc-grid-slider {
  flex: 1; max-width: 140px;
}

/* --- Task 6: Watched badge + filter --- */
.watched-overlay {
  position: absolute; top: 8px; left: 8px; z-index: 2;
  background: rgba(16,185,129,.85); backdrop-filter: blur(4px);
  color: white; font-size: .625rem; font-weight: 700; letter-spacing: .5px;
  padding: 3px 8px; border-radius: 4px; text-transform: uppercase;
}
.media-card.is-watched img { opacity: .65; }
.filter-check-label { display: flex; align-items: center; gap: 6px; font-size: .875rem; color: var(--text-secondary); cursor: pointer; }

/* --- Task 7: Plex badge in details --- */
.plex-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(229,160,13,.12); border: 1px solid rgba(229,160,13,.3);
  color: var(--amber-400); font-size: .75rem; font-weight: 600;
  padding: 5px 12px; border-radius: 20px; cursor: pointer;
  transition: all var(--transition);
}
.plex-badge:hover { background: rgba(229,160,13,.2); }

/* --- Task 8: Lists overhaul --- */
.lists-toolbar { display: flex; justify-content: flex-end; padding: 8px 16px 16px; }
.lists-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; padding: 0 16px 40px; }
.list-card { border-radius: 12px; overflow: hidden; background: var(--bg-card); border: 1px solid var(--border-subtle); cursor: pointer; transition: transform var(--transition), box-shadow var(--transition); }
.list-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.3); }
.list-card-cover { position: relative; aspect-ratio: 1; background: var(--bg-tertiary); }
.list-cover-grid { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; height: 100%; }
.list-cover-cell { background-size: cover; background-position: center; }
.list-cover-cell.empty { background: var(--bg-tertiary); }
.list-cover-placeholder { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--text-muted); }
.list-role-badge { position: absolute; top: 6px; right: 6px; font-size: .625rem; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; padding: 3px 8px; border-radius: 4px; }
.list-role-badge.owner { background: rgba(99,102,241,.85); color: white; }
.list-role-badge.shared { background: rgba(16,185,129,.85); color: white; }
.list-card-info { padding: 10px 12px 12px; }
.list-card-name { font-size: .9375rem; font-weight: 600; margin: 0 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-card-meta { display: flex; gap: 10px; font-size: .75rem; color: var(--text-secondary); }
.list-card-date { font-size: .6875rem; color: var(--text-muted); margin: 4px 0 0; }
.lists-empty-state { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 60px 24px; gap: 12px; }
.lists-empty-icon { color: var(--text-muted); margin-bottom: 8px; }
/* Shared With You section */
.lists-shared-section { margin-bottom: 24px; }
.lists-shared-banner { display: flex; align-items: center; gap: 12px; margin: 0 20px 14px; padding: 14px 18px; border-radius: var(--radius-md); background: rgba(99,102,241,.08); border: 1px solid rgba(99,102,241,.18); }
.lists-shared-icon { width: 38px; height: 38px; border-radius: 10px; background: rgba(99,102,241,.15); color: var(--indigo-400); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lists-shared-text { display: flex; flex-direction: column; gap: 2px; }
.lists-shared-text strong { font-size: .9375rem; font-weight: 700; color: var(--text-primary); }
.lists-shared-text span { font-size: .8125rem; color: var(--text-secondary); }
.lists-section-label { display: flex; align-items: center; gap: 8px; padding: 0 20px; margin-bottom: 12px; font-size: .875rem; font-weight: 600; color: var(--text-secondary); }
/* --- Shared List Detail (redesign) --- */
.sld-page { min-height: 100vh; }
.sld-hero { position: relative; overflow: hidden; border-radius: 0 0 var(--radius-lg) var(--radius-lg); min-height: 200px; }
.sld-hero-bg { position: absolute; inset: 0; display: flex; }
.sld-hero-poster { flex: 1; background-size: cover; background-position: center top; filter: blur(20px) brightness(.35) saturate(1.2); transform: scale(1.15); }
.sld-hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15,23,42,.4) 0%, var(--bg-primary) 100%); }
.sld-hero-content { position: relative; z-index: 1; padding: 24px 24px 28px; display: flex; flex-direction: column; gap: 16px; }
.sld-hero-content .back-btn-float { position: relative; top: auto; left: auto; width: 36px; height: 36px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--text-primary); cursor: pointer; backdrop-filter: blur(8px); transition: background var(--transition); }
.sld-hero-content .back-btn-float:hover { background: rgba(255,255,255,.15); }
.sld-hero-info { display: flex; flex-direction: column; gap: 10px; }
.sld-title { font-size: 1.75rem; font-weight: 800; margin: 0; letter-spacing: -.02em; line-height: 1.2; }
.sld-stats { display: flex; gap: 14px; flex-wrap: wrap; }
.sld-stat { display: inline-flex; align-items: center; gap: 5px; font-size: .8125rem; color: var(--text-secondary); }
.sld-stat strong { color: var(--text-primary); font-weight: 600; }
.sld-members-row { display: flex; align-items: center; gap: 10px; margin-top: 2px; }
.sld-members-avatars { display: flex; }
.sld-member { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--bg-primary); margin-left: -8px; overflow: hidden; background: rgba(99,102,241,.25); display: flex; align-items: center; justify-content: center; }
.sld-member:first-child { margin-left: 0; }
.sld-member img { width: 100%; height: 100%; object-fit: cover; }
.sld-member span { font-size: .7rem; font-weight: 700; color: var(--indigo-300); }
.sld-members-label { font-size: .8125rem; color: var(--text-muted); }
/* Toolbar */
.sld-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 24px; flex-wrap: wrap; }
.sld-sort { background: var(--bg-card); border: 1px solid var(--border-subtle); color: var(--text-primary); border-radius: 10px; padding: 7px 12px; font-size: .8125rem; backdrop-filter: blur(8px); }
.sld-toolbar-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.sld-action-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 10px; font-size: .8125rem; font-weight: 500; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.04); color: var(--text-secondary); cursor: pointer; transition: all var(--transition); }
.sld-action-btn:hover { background: rgba(255,255,255,.08); color: var(--text-primary); border-color: var(--indigo-500); }
.sld-action-btn.sld-danger { color: var(--rose-400); }
.sld-action-btn.sld-danger:hover { border-color: var(--rose-400); background: rgba(244,63,94,.08); }
/* Card Grid */
.sld-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)); gap: 18px; padding: 4px 24px 40px; }
.sld-card { cursor: pointer; transition: transform var(--transition); position: relative; }
.sld-card:hover { transform: translateY(-4px); }
.sld-card-poster { position: relative; border-radius: var(--radius-md); overflow: hidden; aspect-ratio: 2/3; background: var(--bg-tertiary); }
.sld-card-poster img { width: 100%; height: 100%; object-fit: cover; }
.sld-card-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.sld-card-remove { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border-radius: 50%; background: rgba(0,0,0,.65); border: none; color: rgba(255,255,255,.8); display: flex; align-items: center; justify-content: center; cursor: pointer; opacity: 0; transition: opacity var(--transition), background var(--transition); backdrop-filter: blur(4px); }
.sld-card:hover .sld-card-remove { opacity: 1; }
.sld-card-remove:hover { background: var(--rose-500); color: white; }
.sld-card-type { position: absolute; bottom: 6px; left: 6px; padding: 2px 8px; border-radius: 6px; font-size: .625rem; font-weight: 600; background: rgba(0,0,0,.6); color: rgba(255,255,255,.85); backdrop-filter: blur(4px); text-transform: uppercase; letter-spacing: .04em; }
.sld-card-title { font-size: .8125rem; font-weight: 600; margin: 8px 0 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Empty State */
.sld-empty { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 60px 24px 40px; gap: 10px; }
.sld-empty-icon { color: var(--text-muted); margin-bottom: 4px; }
.sld-empty h3 { font-size: 1.125rem; font-weight: 700; margin: 0; }
.sld-empty p { font-size: .875rem; color: var(--text-secondary); margin: 0 0 12px; }
/* Invite Friend Modal */
.sld-invite-modal {}
.sld-invite-desc { font-size: .875rem; color: var(--text-secondary); margin: 0 0 14px; }
.sld-invite-list { display: flex; flex-direction: column; gap: 6px; max-height: 300px; overflow-y: auto; }
.sld-invite-friend { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.03); cursor: pointer; transition: all var(--transition); width: 100%; text-align: left; color: var(--text-primary); }
.sld-invite-friend:hover { background: rgba(99,102,241,.08); border-color: var(--indigo-500); }
.sld-invite-friend.invited { border-color: var(--emerald-500); background: rgba(16,185,129,.08); pointer-events: none; }
.sld-invite-avatar { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; flex-shrink: 0; background: rgba(99,102,241,.2); display: flex; align-items: center; justify-content: center; }
.sld-invite-avatar img { width: 100%; height: 100%; object-fit: cover; }
.sld-invite-avatar span { font-size: .8125rem; font-weight: 700; color: var(--indigo-300); }
.sld-invite-name { flex: 1; font-size: .9375rem; font-weight: 500; }
.sld-invite-add { color: var(--indigo-400); flex-shrink: 0; transition: color var(--transition); }
.sld-invite-friend.invited .sld-invite-add { color: var(--emerald-400); }
.sld-invite-none { font-size: .875rem; color: var(--text-muted); text-align: center; padding: 20px 0; margin: 0; }
/* Added-by attribution */
.sld-card-added-by { font-size: .6875rem; color: var(--text-muted); margin: 3px 0 0; display: flex; align-items: center; gap: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Manage Members modal */
.sld-manage-row { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.03); transition: all .25s ease; }
.sld-member-role { font-size: .6875rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: rgba(255,255,255,.06); color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; margin-left: auto; }
.sld-member-role.owner { background: rgba(99,102,241,.12); color: var(--indigo-400); }
.sld-member-kick { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--border-subtle); background: transparent; color: var(--text-muted); display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; transition: all var(--transition); }
.sld-member-kick:hover { background: rgba(244,63,94,.12); border-color: var(--rose-400); color: var(--rose-400); }
/* Fun pick button */
.sld-action-btn.sld-fun { color: var(--emerald-400); }
.sld-action-btn.sld-fun:hover { border-color: var(--emerald-400); background: rgba(16,185,129,.08); }
/* Random Pick modal */
.sld-random-modal { text-align: center; }
.sld-random-label { font-size: .9375rem; color: var(--text-secondary); margin: 0 0 16px; }
.sld-random-card { display: flex; align-items: center; gap: 16px; padding: 14px; border-radius: var(--radius-md); background: rgba(255,255,255,.04); border: 1px solid var(--border-subtle); cursor: pointer; text-align: left; transition: background var(--transition); }
.sld-random-card:hover { background: rgba(99,102,241,.08); }
.sld-random-poster { width: 80px; height: 120px; border-radius: 8px; object-fit: cover; flex-shrink: 0; background: var(--bg-tertiary); }
.sld-random-info { display: flex; flex-direction: column; gap: 8px; }
.sld-random-info h3 { font-size: 1.125rem; font-weight: 700; margin: 0; }
/* Responsive */
@media (max-width: 480px) {
  .sld-hero-content { padding: 16px 16px 22px; }
  .sld-title { font-size: 1.35rem; }
  .sld-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 14px; padding: 4px 16px 32px; }
  .sld-toolbar { padding: 12px 16px; }
}
@media (min-width: 1440px) {
  .sld-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
}

/* --- Task 10: Matcher restyle --- */
.matcher-setup-hero { text-align: center; padding: 24px 20px 16px; }
.matcher-setup-hero h3 { color: var(--indigo-400); margin: 0 0 6px; font-size: 1.25rem; }
.matcher-setup-hero .setup-desc { color: var(--text-secondary); font-size: .9375rem; margin: 0; }
.matcher-friend-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px; padding: 0 16px; }
.matcher-friend-card { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px; border-radius: 12px; border: 2px solid var(--border-subtle); background: var(--bg-card); cursor: pointer; transition: all var(--transition); position: relative; }
.matcher-friend-card.active { border-color: var(--indigo-500); background: rgba(99,102,241,.1); }
.matcher-friend-card:hover { border-color: var(--indigo-400); }
.matcher-friend-avatar { width: 44px; height: 44px; border-radius: 50%; background: rgba(99,102,241,.2); color: var(--indigo-400); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.125rem; }
.matcher-friend-name { font-size: .75rem; font-weight: 500; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 80px; }
.matcher-friend-check { position: absolute; top: 4px; right: 4px; color: var(--indigo-400); }
.matcher-type-row { display: flex; gap: 10px; padding: 0 16px; }
.matcher-type-btn { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px; border-radius: 12px; border: 2px solid var(--border-subtle); background: var(--bg-card); color: var(--text-secondary); cursor: pointer; transition: all var(--transition); font-size: .875rem; }
.matcher-type-btn.active { border-color: var(--indigo-500); color: var(--indigo-400); background: rgba(99,102,241,.1); }
.swipe-page { display: flex; flex-direction: column; height: 100%; }
.swipe-header { display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
.swipe-progress-bar { flex: 1; height: 4px; background: var(--bg-tertiary); border-radius: 2px; }
.swipe-progress-fill { height: 100%; border-radius: 2px; background: var(--indigo-500); transition: width 0.3s ease; }
.swipe-progress-label { font-size: .75rem; color: var(--text-secondary); white-space: nowrap; }
.swipe-card { flex: 1; margin: 0 16px; border-radius: 16px; overflow: hidden; position: relative; background: var(--bg-card); min-height: 320px; }
.swipe-backdrop { position: absolute; inset: 0; background-size: cover; background-position: center; }
.swipe-backdrop::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,.2) 0%, rgba(0,0,0,.85) 70%); }
.swipe-card-body { position: relative; z-index: 1; display: flex; gap: 16px; align-items: flex-end; padding: 20px; height: 100%; box-sizing: border-box; }
.swipe-poster { width: 90px; height: 135px; border-radius: 8px; object-fit: cover; flex-shrink: 0; box-shadow: 0 4px 16px rgba(0,0,0,.5); }
.swipe-card-info { flex: 1; }
.swipe-title { font-size: 1.25rem; font-weight: 700; color: white; margin: 0 0 8px; text-shadow: 0 2px 8px rgba(0,0,0,.5); }
.swipe-meta-row { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.swipe-meta-chip { background: rgba(255,255,255,.15); backdrop-filter: blur(4px); color: white; font-size: .75rem; padding: 3px 8px; border-radius: 4px; }
.swipe-meta-chip.rating { color: var(--amber-400); }
.swipe-overview { font-size: .8125rem; color: rgba(255,255,255,.8); line-height: 1.4; -webkit-line-clamp: 3; line-clamp: 3; display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.swipe-buttons { display: flex; gap: 16px; padding: 16px; justify-content: center; }
.swipe-btn { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 80px; height: 80px; border-radius: 50%; border: 2px solid; cursor: pointer; justify-content: center; font-size: .75rem; font-weight: 600; transition: all var(--transition); background: none; }
.swipe-btn.dislike { border-color: var(--rose-500); color: var(--rose-400); background: rgba(244,63,94,.1); }
.swipe-btn.like { border-color: var(--emerald-500); color: var(--emerald-400); background: rgba(16,185,129,.1); }
.swipe-btn:hover { transform: scale(1.05); }
.results-summary { text-align: center; padding: 24px 20px; }
.results-count-circle { width: 100px; height: 100px; border-radius: 50%; background: rgba(99,102,241,.15); border: 3px solid var(--indigo-500); display: flex; flex-direction: column; align-items: center; justify-content: center; margin: 0 auto 16px; }
.match-count { font-size: 2rem; font-weight: 800; color: var(--indigo-400); line-height: 1; }
.match-count-label { font-size: .6875rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: .5px; }
.results-tagline { color: var(--text-secondary); font-size: 1rem; margin: 0 0 8px; }
.history-cards { display: flex; flex-direction: column; gap: 10px; padding: 0 16px 40px; }
.history-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--bg-card); border: 1px solid var(--border-subtle); border-radius: 12px; cursor: pointer; transition: all var(--transition); color: var(--text-primary); }
.history-card:hover { border-color: rgba(99,102,241,.4); background: var(--bg-secondary); }
.history-card-icon { width: 40px; height: 40px; border-radius: 10px; background: rgba(99,102,241,.15); color: var(--indigo-400); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.history-card-info { flex: 1; }
.history-type { font-weight: 600; font-size: .9375rem; margin: 0 0 2px; }
.history-matches { font-size: .8125rem; color: var(--text-secondary); margin: 0 0 2px; }
.history-date { font-size: .75rem; color: var(--text-muted); margin: 0; }

/* --- Task 13: Fix Match button + result styles --- */
.fix-match-btn { display: inline-flex; align-items: center; gap: 4px; background: rgba(99,102,241,.12); border: 1px solid rgba(99,102,241,.3); color: var(--indigo-400); font-size: .625rem; font-weight: 600; padding: 3px 8px; border-radius: 4px; cursor: pointer; transition: all var(--transition); }
.fix-match-btn:hover { background: rgba(99,102,241,.25); }
.fix-match-result { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border-subtle); background: var(--bg-secondary); cursor: pointer; transition: all var(--transition); }
.fix-match-result:hover { border-color: var(--indigo-500); background: rgba(99,102,241,.08); }

/* ============================================================
   ACTIVITY FEED V2
   ============================================================ */
.activity-feed-v2 { display: flex; flex-direction: column; gap: 10px; padding: 0 0 40px; }
.activity-card-v2 { display: flex; align-items: stretch; gap: 0; background: var(--bg-card); border: 1px solid var(--border-subtle); border-radius: 14px; cursor: pointer; transition: box-shadow .2s, border-color .2s, transform .15s; overflow: hidden; }
.activity-card-v2:hover { border-color: rgba(99,102,241,.3); box-shadow: 0 4px 20px rgba(0,0,0,.25); transform: translateY(-1px); }
.act-poster { width: 64px; min-height: 80px; background-size: cover; background-position: center; background-color: var(--bg-secondary); flex-shrink: 0; }
.act-poster-ph { display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.act-body { flex: 1; min-width: 0; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.act-top-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.act-avatar-sm { width: 20px; height: 20px; border-radius: 50%; overflow: hidden; flex-shrink: 0; }
.act-avatar-sm .act-avatar-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.act-avatar-sm .act-avatar-initial { width: 20px; height: 20px; font-size: .625rem; }
.act-username { font-weight: 700; font-size: .8125rem; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 120px; }
.act-badge { display: inline-flex; align-items: center; gap: 3px; font-size: .625rem; font-weight: 700; padding: 2px 7px; border-radius: 999px; text-transform: uppercase; letter-spacing: .3px; flex-shrink: 0; }
.act-badge-watched { background: rgba(99,102,241,.12); color: var(--indigo-400, #818cf8); }
.act-badge-rated { background: rgba(245,158,11,.12); color: #f59e0b; }
.act-badge-watchlist { background: rgba(16,185,129,.12); color: #10b981; }
.act-badge-shame { background: rgba(239,68,68,.12); color: #ef4444; }
.act-badge-plex { background: rgba(229,160,13,.15); color: #E5A00D; }
.act-time { font-size: .6875rem; color: var(--text-muted); margin-left: auto; flex-shrink: 0; }
.act-title { font-weight: 700; font-size: .9375rem; color: var(--text-primary); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-ep-label { font-weight: 500; font-size: .8125rem; color: var(--text-secondary); }
.act-ep-name { font-size: .75rem; color: var(--text-muted); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-rating-inline { display: flex; align-items: baseline; gap: 1px; }
.act-rating-score { font-size: 1rem; font-weight: 800; color: #f59e0b; }
.act-rating-max { font-size: .75rem; font-weight: 500; color: var(--text-muted); }
.act-comment { font-size: .8125rem; font-style: italic; color: var(--text-secondary); margin: 0; border-left: 2px solid var(--indigo-500); padding-left: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plex-activity-card { border-color: rgba(229,160,13,.12); }
.plex-activity-card:hover { border-color: rgba(229,160,13,.3); }

/* ============================================================
   BADGE CARDS V2
   ============================================================ */
.badges-header-strip { padding: 16px 16px 0; }
.badges-summary-v2 { display: flex; align-items: center; gap: 24px; padding: 20px 16px; }
.badges-progress-ring { flex-shrink: 0; }
.badges-ring-label { font-size: .75rem; fill: var(--text-secondary); }
.ring-num { font-size: 1.5rem; font-weight: 800; fill: var(--text-primary); }
.ring-total { font-size: .8rem; fill: var(--text-secondary); }
.badges-earned-text { font-size: 1.375rem; font-weight: 800; color: var(--text-primary); margin: 0 0 2px; }
.badges-sub-text { font-size: .875rem; color: var(--text-secondary); margin: 0; }
.badges-displayed-preview { padding: 0 16px 12px; }
.badges-displayed-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.displayed-badge-chip { display: flex; align-items: center; gap: 8px; background: var(--bg-secondary); border: 1px solid var(--border-subtle); border-radius: 10px; padding: 6px 12px; }
.chip-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.chip-emoji { font-size: 1.125rem; }
.chip-name { font-size: .8125rem; font-weight: 600; color: var(--text-primary); }
.badges-tip { font-size: .8125rem; color: var(--text-muted); margin: 4px 0 0; padding: 0 16px; }
.badge-category-section { padding: 20px 16px 8px; }
.badge-cat-title { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); margin: 0 0 14px; }
.badges-grid-v2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 600px) { .badges-grid-v2 { grid-template-columns: repeat(3, 1fr); } }
.badge-card-v2 { background: var(--bg-secondary); border: 1px solid var(--border-subtle); border-radius: 14px; padding: 16px 14px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; position: relative; overflow: hidden; transition: box-shadow var(--transition), transform var(--transition); }
.badge-card-v2.earned { border-color: rgba(99,102,241,.35); background: linear-gradient(135deg, rgba(99,102,241,.08) 0%, var(--bg-secondary) 100%); }
.badge-card-v2.earned:hover { box-shadow: 0 4px 20px rgba(99,102,241,.25); transform: translateY(-2px); }
.badge-card-v2.locked { opacity: 0.6; }
.badge-card-shine { position: absolute; top: -30%; left: -20%; width: 60%; height: 160%; background: rgba(255,255,255,.05); transform: rotate(20deg); pointer-events: none; }
.badge-tier-dot { position: absolute; top: 10px; right: 10px; width: 9px; height: 9px; border-radius: 50%; }
.badge-icon-wrap { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; }
.badge-emoji-v2 { font-size: 1.75rem; line-height: 1; }
.badge-name-v2 { font-weight: 700; font-size: .9375rem; color: var(--text-primary); margin: 0; line-height: 1.2; }
.badge-desc-v2 { font-size: .8125rem; color: var(--text-secondary); margin: 0; line-height: 1.35; }
.badge-tier-label { font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; margin: 2px 0 0; }
.badge-progress-wrap { width: 100%; display: flex; flex-direction: column; gap: 4px; margin-top: 2px; }
.badge-progress-bar-v2 { width: 100%; height: 5px; background: rgba(255,255,255,.08); border-radius: 3px; overflow: hidden; }
.badge-progress-fill-v2 { height: 100%; border-radius: 3px; background: var(--indigo-500); transition: width .4s ease; }
.badge-progress-pct { font-size: .75rem; color: var(--text-muted); text-align: right; }
.badge-display-btn { align-self: flex-end; margin-top: 4px; padding: 4px 10px; font-size: .75rem; font-weight: 600; border-radius: 7px; border: 1px solid var(--border-subtle); background: transparent; color: var(--text-secondary); cursor: pointer; transition: all var(--transition); }
.badge-display-btn:hover { background: rgba(99,102,241,.15); border-color: var(--indigo-500); color: var(--text-primary); }
.badge-display-btn.active { background: rgba(99,102,241,.2); border-color: var(--indigo-500); color: var(--indigo-400); }
.locked-group { padding: 0 16px 24px; }
.locked-group .badge-cat-title { margin-bottom: 10px; }

/* ============================================================
   FRIEND PROFILE PAGE
   ============================================================ */
.fp-hero { padding: 20px 16px 16px; background: linear-gradient(180deg, rgba(99,102,241,.10) 0%, transparent 100%); border-bottom: 1px solid var(--border-subtle); }
.fp-hero-top { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
.fp-hero-avatar { flex-shrink: 0; }
.fp-avatar-img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; border: 2.5px solid var(--indigo-500); box-shadow: 0 4px 20px rgba(99,102,241,.22); }
.fp-avatar-initial { width: 72px; height: 72px; border-radius: 50%; background: linear-gradient(135deg, var(--indigo-500), #a855f7); display: flex; align-items: center; justify-content: center; font-size: 1.75rem; font-weight: 800; color: #fff; border: 2.5px solid var(--indigo-500); box-shadow: 0 4px 20px rgba(99,102,241,.22); }
.fp-hero-info { flex: 1; min-width: 0; }
.fp-name { font-size: 1.25rem; font-weight: 800; color: var(--text-primary); margin: 0 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fp-stats-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.fp-stat { font-size: .8125rem; color: var(--text-secondary); display: inline-flex; align-items: center; gap: 3px; }
.fp-stat strong { color: var(--text-primary); font-weight: 700; }
.fp-stat-sep { color: var(--text-muted); font-size: .75rem; }
.fp-stats-sub { margin-top: 3px; }
.fp-stats-sub .fp-stat { font-size: .75rem; color: var(--text-muted); }
.fp-hero-actions { display: flex; gap: 8px; }
.fp-action-btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 5px; padding: 8px 10px; border-radius: 10px; font-size: 12px; font-weight: 600; border: 1px solid var(--border-subtle); background: var(--surface-1, var(--bg-secondary)); color: var(--text-secondary); cursor: pointer; transition: all 0.15s; white-space: nowrap; }
.fp-action-btn:hover { border-color: var(--accent); color: var(--accent); }
.fp-action-primary { background: rgba(99,102,241,.1); border-color: rgba(99,102,241,.25); color: var(--indigo-400, #818cf8); }
.fp-action-primary:hover { background: rgba(99,102,241,.18); border-color: rgba(99,102,241,.45); color: var(--indigo-300, #a5b4fc); }
.fp-report-btn { flex: 0 0 auto; padding: 8px 10px; color: var(--text-muted); }
.fp-report-btn:hover { color: #ef4444; border-color: rgba(239,68,68,.3); }

/* Friend Profile Badges */
.fp-badges-section { padding: 12px 16px 4px; }
.fp-badges-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 8px; }
.fp-badge-card { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 8px 10px; background: var(--bg-secondary, var(--surface-1)); border: 1px solid var(--border-subtle); border-radius: 14px; text-align: center; transition: all 0.2s; cursor: default; position: relative; overflow: hidden; }
.fp-badge-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--badge-color); opacity: 0.7; }
.fp-badge-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,.25); border-color: var(--badge-color); }
.fp-badge-icon { font-size: 1.5rem; line-height: 1; }
.fp-badge-name { font-size: .6875rem; font-weight: 700; color: var(--text-primary); line-height: 1.2; }
.fp-badge-tier { font-size: .625rem; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }

/* Friend Profile — stat pills (legacy compat) */
.fp-stat-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 16px; }
.fp-stat-pill { display: flex; flex-direction: column; align-items: center; background: var(--bg-secondary); border: 1px solid var(--border-subtle); border-radius: 12px; padding: 8px 14px; min-width: 52px; }
.fp-stat-val { font-size: 1.125rem; font-weight: 800; color: var(--text-primary); line-height: 1.2; }
.fp-stat-lbl { font-size: .6875rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; font-weight: 600; }
.fp-body { padding: 0 0 80px; }
.fp-section { padding: 20px 16px 8px; }
.fp-section-label { display: flex; align-items: center; gap: 6px; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); padding: 0 16px; margin: 0 0 10px; }
.fp-activity-list { display: flex; flex-direction: column; gap: 10px; padding: 0 16px; }
.fp-act-row { display: flex; align-items: center; gap: 12px; background: var(--bg-secondary); border: 1px solid var(--border-subtle); border-radius: 12px; padding: 10px 12px; cursor: pointer; transition: all var(--transition); }
.fp-act-row:hover { border-color: rgba(99,102,241,.35); background: rgba(99,102,241,.06); }
.fp-act-thumb { width: 48px; height: 72px; border-radius: 8px; background-size: cover; background-position: center; background-color: var(--bg-card); border: 1px solid var(--border-subtle); flex-shrink: 0; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.fp-act-thumb-ph { display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 1.25rem; }
.fp-act-info { flex: 1; min-width: 0; }
.fp-act-title { font-size: .9375rem; font-weight: 700; color: var(--text-primary); margin: 0 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fp-act-verb { font-size: .8125rem; color: var(--text-secondary); margin: 0; }
.fp-actions { padding: 12px 16px 8px; }

/* ============================================================
   PLEX NOW PLAYING
   ============================================================ */
.plex-now-playing-page { min-height: 100vh; }
.np-header { display: flex; align-items: center; justify-content: space-between; padding: 0 16px 12px; }
.np-subtitle { font-size: .9375rem; color: var(--text-secondary); margin: 0; }
.np-sessions { display: flex; flex-direction: column; gap: 14px; padding: 0 16px 80px; }
.np-card { background: var(--bg-card); border: 1px solid var(--border-subtle); border-radius: 16px; padding: 14px; overflow: hidden; cursor: pointer; transition: all var(--transition); }
.np-card:hover { border-color: rgba(229, 160, 13, 0.4); box-shadow: 0 4px 24px rgba(229,160,13,.12); transform: translateY(-2px); }
.np-card-top { display: flex; gap: 14px; align-items: flex-start; }
.np-thumb { width: 130px; height: 195px; border-radius: 10px; background-size: cover; background-position: center; background-color: var(--bg-secondary); flex-shrink: 0; border: 1px solid var(--border-subtle); }
.np-thumb-ph { display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.np-card-info { flex: 1; min-width: 0; }
.np-state-badge { display: inline-flex; align-items: center; gap: 5px; font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; padding: 3px 8px; border-radius: 6px; margin-bottom: 6px; }
.np-state-badge.playing { background: rgba(16,185,129,.15); color: #10b981; border: 1px solid rgba(16,185,129,.3); }
.np-state-badge.paused  { background: rgba(245,158,11,.15); color: #f59e0b; border: 1px solid rgba(245,158,11,.3); }
.np-title { font-size: 1.0625rem; font-weight: 800; color: var(--text-primary); margin: 0 0 3px; }
.np-subtitle-text { font-size: .875rem; color: var(--text-secondary); margin: 0 0 8px; }
.np-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.np-meta-chip { display: flex; align-items: center; gap: 4px; font-size: .75rem; color: var(--text-muted); background: var(--bg-secondary); border-radius: 6px; padding: 3px 8px; }
.np-progress-wrap { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.np-progress-bar { flex: 1; height: 5px; background: rgba(255,255,255,.08); border-radius: 3px; overflow: hidden; }
.np-progress-fill { height: 100%; background: linear-gradient(90deg, #e5a00d, #f59e0b); border-radius: 3px; transition: width .4s ease; }
.np-progress-pct { font-size: .75rem; color: var(--text-muted); flex-shrink: 0; width: 36px; text-align: right; }
.np-tmdb-details { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border-subtle); display: flex; flex-direction: column; gap: 10px; }
.np-tmdb-details:empty { display: none; }
.np-progress-section { margin-top: 14px; }
.np-time-row { display: flex; justify-content: space-between; margin-top: 5px; }
.np-time-elapsed { font-size: .75rem; color: var(--text-muted); }
.np-time-remaining { font-size: .75rem; color: var(--text-muted); }
.np-separator { display: flex; align-items: center; gap: 8px; font-size: .75rem; font-weight: 700; color: #e5a00d; letter-spacing: .5px; text-transform: uppercase; padding: 4px 0 8px; opacity: .8; }
.np-separator::after { content: ''; flex: 1; height: 1px; background: rgba(229,160,13,.25); }
.np-still { width: 100%; max-height: 180px; object-fit: cover; border-radius: 10px; border: 1px solid var(--border-subtle); }
.np-fact-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.np-fact-chip { display: inline-flex; align-items: center; gap: 5px; font-size: .75rem; color: var(--text-secondary); background: rgba(255,255,255,.04); border-radius: 8px; padding: 5px 10px; border: 1px solid var(--border-subtle); transition: background var(--transition); }
.np-fact-chip:hover { background: rgba(255,255,255,.07); }
.np-vote-count { color: var(--text-muted); font-size: .6875rem; }
.np-overview { font-size: .875rem; color: var(--text-secondary); margin: 0; line-height: 1.55; }
.np-fact { font-size: .8125rem; color: var(--text-muted); margin: 0 0 8px; display: flex; align-items: center; gap: 5px; }
.np-cast-section { margin-top: 4px; }
.np-cast-label { font-size: .6875rem; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; margin: 0 0 8px; display: flex; align-items: center; gap: 5px; }
.np-cast-row { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
.np-cast-row::-webkit-scrollbar { display: none; }
.np-cast-chip { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 8px; border-radius: 12px; background: rgba(255,255,255,.03); border: 1px solid var(--border-subtle); cursor: pointer; transition: all var(--transition); flex-shrink: 0; min-width: 0; }
.np-cast-chip:hover { background: rgba(99,102,241,.08); border-color: var(--indigo-500); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(99,102,241,.08); }
.np-cast-photo { width: 42px; height: 42px; border-radius: 10px; overflow: hidden; flex-shrink: 0; background: var(--bg-secondary); }
.np-cast-photo img { width: 100%; height: 100%; object-fit: cover; }
.np-cast-ph { width: 42px; height: 42px; border-radius: 10px; background: rgba(99,102,241,.12); display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--indigo-400); font-size: .9375rem; }
.np-cast-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.np-cast-name { font-size: .8125rem; font-weight: 600; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-cast-char { font-size: .6875rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 120px; }
.np-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 60px 32px; gap: 12px; color: var(--text-muted); }
.np-empty h3 { font-size: 1.125rem; font-weight: 700; color: var(--text-secondary); margin: 0; }
.np-empty p { font-size: .9375rem; margin: 0; }

/* ============================================================
   DISCOVER — INFINITE SCROLL SENTINEL + SPINNER
   ============================================================ */
#discover-sentinel { display: flex; align-items: center; justify-content: center; padding: 24px 0 40px; grid-column: 1 / -1; }
.load-more-spinner { display: flex; align-items: center; justify-content: center; gap: 10px; color: var(--text-muted); font-size: .875rem; }
.load-more-spinner svg { animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   PAGE TRANSITIONS
   ============================================================ */
#page-content.page-exit { opacity: 0; pointer-events: none; }
#page-content.page-enter { opacity: 1; }
.nav-btn { transition: transform 120ms ease, box-shadow 120ms ease, background 200ms ease; }
.nav-btn.nav-tapped { transform: scale(0.93); }
@media (max-width: 768px) {
  .menu-item.nav-tapped { animation: menuTap 200ms cubic-bezier(0.34,1.56,0.64,1) forwards; }
  @keyframes menuTap {
    0%   { transform: scale(1); }
    50%  { transform: scale(0.88) translateY(-3px); }
    100% { transform: scale(1); }
  }
}

/* ============================================================
   MOBILE HERO FIX — subject centering
   ============================================================ */

/* ============================================================
   RECOMMENDED FRIENDS
   ============================================================ */
.recommended-section { margin-bottom: 8px; padding: 0 16px; }
.recommended-header {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; color: var(--accent);
  padding: 0 2px 12px; letter-spacing: .01em;
}
.recommended-header svg { flex-shrink: 0; }
.recommended-subtitle { color: var(--text-muted); font-weight: 400; font-size: 12px; margin-left: 4px; }
.recommended-list { display: flex; flex-direction: column; gap: 8px; }
.recommended-item {
  background: var(--bg-card); border: 1px solid rgba(52,211,153,0.12) !important;
  position: relative; overflow: hidden;
}
.recommended-item::after {
  content: ''; position: absolute; top: 0; left: 0; width: 3px; height: 100%;
  background: linear-gradient(180deg, var(--emerald-400), var(--emerald-600));
  border-radius: 3px 0 0 3px; opacity: 0; transition: opacity 0.2s;
}
.recommended-item:hover { border-color: rgba(52,211,153,0.3) !important; }
.recommended-item:hover::after { opacity: 1; }
.friend-reason { font-size: 11px; color: var(--text-muted); margin-top: 3px; font-weight: 500; }
.add-friend-btn { display: flex; align-items: center; gap: 5px; padding: 7px 14px; background: rgba(52,211,153,0.12); color: var(--accent); border: 1px solid rgba(52,211,153,0.25); border-radius: 10px; font-size: 12px; font-weight: 600; cursor: pointer; transition: all 0.2s; flex-shrink: 0; }
.add-friend-btn:hover { background: rgba(52,211,153,0.2); border-color: rgba(52,211,153,0.4); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(52,211,153,.12); }
.friends-section-header {
  font-size: 12px; font-weight: 700; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .08em;
  padding: 12px 18px 10px; margin-top: 6px;
  border-top: 1px solid var(--border-subtle);
}
.friend-avatar-img { object-fit: cover; border-radius: 50%; border: 2px solid rgba(99,102,241,.3); }
.recommended-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 28px 16px; text-align: center; }
.recommended-empty-icon { color: var(--text-muted); opacity: .4; }
.recommended-empty p { color: var(--text-secondary); font-size: 13px; margin: 0; }

/* ============================================================
   FRIEND RECOMMENDATION CARDS (Home Page)
   ============================================================ */
.friend-rec-card {
  position: relative; flex-shrink: 0; width: 130px; cursor: pointer;
  transition: transform 0.3s, opacity 0.3s;
}
.friend-rec-card img {
  width: 130px; height: 195px; object-fit: cover; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.06);
}
.friend-rec-card .poster-placeholder {
  width: 130px; height: 195px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-card); border: 1px solid rgba(255,255,255,0.06);
  color: var(--slate-400);
}
.friend-rec-card .card-title {
  font-size: 12px; color: var(--slate-200); margin: 6px 0 0; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.friend-rec-dismiss {
  position: absolute; top: 6px; right: 6px; width: 24px; height: 24px;
  border-radius: 50%; border: none; cursor: pointer;
  background: rgba(0,0,0,0.6); color: var(--slate-300);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.2s;
}
.friend-rec-card:hover .friend-rec-dismiss { opacity: 1; }
.friend-rec-dismiss:hover { background: rgba(220,38,38,0.7); color: #fff; }
.friend-rec-from {
  position: absolute; bottom: 30px; left: 4px; right: 4px;
  display: flex; align-items: center; gap: 5px;
  padding: 3px 6px; border-radius: 8px;
  background: rgba(0,0,0,0.65); backdrop-filter: blur(6px);
  font-size: 10px; color: var(--slate-200); font-weight: 600;
  white-space: nowrap; overflow: hidden;
}
.friend-rec-avatar {
  width: 18px; height: 18px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  border: 1px solid rgba(52,211,153,0.4);
}
.friend-rec-avatar-ph {
  width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(52,211,153,0.2); color: var(--emerald-400);
  font-size: 10px; font-weight: 700;
}

/* ============================================================
   PROFILE — INVITE CODES & TICKETS
   ============================================================ */

/* Settings Page */
.settings-page { padding-bottom: 40px; }
.settings-section { margin-bottom: 24px; }
.settings-section-title { display: flex; align-items: center; gap: 8px; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); padding: 0 16px; margin-bottom: 10px; }
.settings-card { background: var(--surface-1); border: 1px solid var(--border); border-radius: 14px; padding: 16px; margin: 0 16px 8px; }
.settings-label { font-size: .875rem; font-weight: 600; color: var(--text-primary); display: block; margin-bottom: 4px; }
.settings-value { font-size: .875rem; color: var(--text-secondary); margin: 0; }
.settings-desc { font-size: .8125rem; color: var(--text-secondary); margin: 0 0 10px; }
.settings-input-row { display: flex; gap: 8px; align-items: center; }
.settings-input { flex: 1; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-primary); padding: 9px 12px; border-radius: 8px; font-size: 14px; outline: none; transition: border-color 0.15s; }
.settings-input:focus { border-color: var(--accent); }
.settings-save-btn { padding: 9px 18px; border-radius: 8px; background: var(--accent); color: #000; font-weight: 600; font-size: 13px; border: none; cursor: pointer; transition: opacity 0.15s; flex-shrink: 0; }
.settings-save-btn:hover { opacity: .85; }
.settings-save-btn:disabled { opacity: .5; cursor: default; }
.settings-action-btn { display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-secondary); font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.15s; }
.settings-action-btn:hover { border-color: var(--accent); color: var(--accent); }
.settings-toggle-group { display: flex; gap: 6px; }
.settings-toggle { display: inline-flex; align-items: center; gap: 5px; padding: 8px 14px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-secondary); font-size: 13px; font-weight: 500; cursor: pointer; transition: all 0.15s; }
.settings-toggle.active { background: rgba(52,211,153,.12); border-color: rgba(52,211,153,.35); color: var(--accent); }
.settings-toggle:hover:not(.active) { border-color: var(--text-muted); }
.settings-notif-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.settings-notif-row .settings-label { margin-bottom: 0; }
.settings-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.settings-switch input { opacity: 0; width: 0; height: 0; }
.settings-switch-slider { position: absolute; cursor: pointer; inset: 0; background: var(--surface-2); border: 1px solid var(--border); border-radius: 24px; transition: 0.2s; }
.settings-switch-slider::before { content: ''; position: absolute; width: 18px; height: 18px; left: 2px; top: 2px; background: var(--text-secondary); border-radius: 50%; transition: 0.2s; }
.settings-switch input:checked + .settings-switch-slider { background: rgba(52,211,153,.2); border-color: rgba(52,211,153,.5); }
.settings-switch input:checked + .settings-switch-slider::before { transform: translateX(20px); background: var(--accent); }
.settings-section-desc { font-size: 12px; color: var(--text-secondary); margin: -4px 16px 8px; }
.settings-link-info { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.settings-linked-badge { font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: rgba(52,211,153,.12); color: var(--accent); border: 1px solid rgba(52,211,153,.25); }
.settings-unlinked-badge { font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: rgba(148,163,184,.08); color: var(--text-muted); border: 1px solid var(--border); }
.settings-link-btn { background: rgba(52,211,153,.1) !important; border-color: rgba(52,211,153,.3) !important; color: var(--accent) !important; }
.settings-unlink-btn { background: rgba(239,68,68,.08) !important; border-color: rgba(239,68,68,.2) !important; color: #ef4444 !important; }

/* Edge swipe back indicator */
.swipe-back-indicator {
  position: fixed; top: 0; bottom: 0; left: 0; width: 32px; z-index: 9999;
  display: flex; align-items: center; pointer-events: none;
}
.swipe-back-arrow {
  width: 32px; height: 64px; display: flex; align-items: center; justify-content: center;
  background: rgba(52,211,153,.15); backdrop-filter: blur(12px);
  border-radius: 0 16px 16px 0; color: var(--accent);
  opacity: 0; transform: translateX(-32px);
  transition: opacity .15s, transform .15s;
}
.swipe-back-indicator.active .swipe-back-arrow {
  opacity: 1; transform: translateX(0);
}

.invite-section { background: var(--surface-1); border: 1px solid var(--border); border-radius: 16px; padding: 18px; margin: 16px 0; }
.invite-section-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; font-size: 14px; font-weight: 600; color: var(--text-primary); }
.invite-section-header > span { display: flex; align-items: center; gap: 8px; }
.ticket-badge { background: rgba(251,191,36,0.15); color: #fbbf24; border: 1px solid rgba(251,191,36,0.25); border-radius: 999px; font-size: 11px; font-weight: 600; padding: 2px 9px; }
.invite-request-btn { display: flex; align-items: center; gap: 5px; background: transparent; border: 1px solid var(--border); color: var(--text-secondary); padding: 5px 12px; border-radius: 8px; font-size: 12px; cursor: pointer; transition: all 0.15s; }
.invite-request-btn:hover { border-color: var(--accent); color: var(--accent); }
.invite-desc { font-size: 12px; color: var(--text-secondary); margin-bottom: 12px; }
.invite-codes-list { display: flex; flex-wrap: wrap; gap: 8px; }
.invite-code-chip { display: flex; align-items: center; gap: 7px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 8px 13px; font-family: monospace; font-size: 14px; letter-spacing: 2px; color: var(--accent); cursor: pointer; transition: all 0.15s; user-select: none; }
.invite-code-chip:hover { border-color: var(--accent); background: rgba(52,211,153,0.08); }
.invite-empty { color: var(--text-secondary); font-size: 13px; }

/* ============================================================
   LANDING PAGE — WAITLIST & UPDATES
   ============================================================ */
.landing-proof-section { padding: 72px 24px; text-align: center; background: linear-gradient(135deg, rgba(52,211,153,.03) 0%, rgba(99,102,241,.03) 100%); border-top: 1px solid var(--glass-border); }
.landing-proof-inner { max-width: 600px; margin: 0 auto; }
.landing-proof-mark { font-size: 4rem; line-height: 1; color: var(--emerald-400); opacity: .4; font-family: Georgia, serif; }
.landing-proof-quote { font-size: 1.375rem; font-style: italic; color: white; line-height: 1.6; margin-bottom: 16px; font-weight: 500; }
.landing-proof-attr { color: var(--slate-500); font-size: .875rem; }

/* ============================================================
   ACTIVITY PAGE — PLEX HISTORY TAB
   ============================================================ */
.activity-tabs { display: flex; gap: 4px; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
.act-tab { background: none; border: none; color: var(--text-secondary); padding: 10px 16px; cursor: pointer; font-size: 13px; font-weight: 500; border-bottom: 2px solid transparent; transition: all 0.15s; }
.act-tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.plex-history-search-bar { display: flex; align-items: center; gap: 8px; background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; margin-bottom: 14px; }
.plex-search-input { background: none; border: none; color: var(--text-primary); font-size: 14px; flex: 1; outline: none; }
.plex-show-group { background: var(--surface-1); border: 1px solid var(--border); border-radius: 12px; padding: 14px; margin-bottom: 10px; }
.plex-show-group-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.act-plex-poster { width: 40px; height: 56px; border-radius: 6px; object-fit: cover; background: var(--surface-2); flex-shrink: 0; }
.dot-plex { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex-shrink: 0; }
.plex-watched-actions { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }

/* ============================================================
   FRIEND PROFILE — TABS, SECTIONS
   ============================================================ */
.fp-hero-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.fp-action-btn { display: flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 10px; font-size: 13px; font-weight: 600; border: 1px solid var(--border); background: var(--surface-1); color: var(--text-secondary); cursor: pointer; transition: all 0.15s; }
.fp-action-btn:hover { border-color: var(--accent); color: var(--accent); background: rgba(52,211,153,0.06); }
.fp-action-primary { background: rgba(99,102,241,.12); border-color: rgba(99,102,241,.3); color: var(--indigo-400, #818cf8); }
.fp-action-primary:hover { background: rgba(99,102,241,.2); border-color: rgba(99,102,241,.5); color: var(--indigo-300, #a5b4fc); }
.fp-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin: 16px 0 0; padding: 0 16px; }
.fp-tab { flex: 1; display: flex; align-items: center; justify-content: center; gap: 5px; background: none; border: none; color: var(--text-secondary); padding: 11px 8px; cursor: pointer; font-size: 13px; font-weight: 500; border-bottom: 2px solid transparent; transition: all 0.15s; }
.fp-tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.fp-section-header-row { display: flex; align-items: center; justify-content: space-between; padding: 16px 16px 12px; }
.fp-section-count { font-size: 12px; color: var(--text-secondary); }
.fp-see-all-btn { font-size: 12px; color: var(--accent); background: none; border: none; cursor: pointer; font-weight: 600; }
/* Poster card grid layout */
.fp-card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 14px; padding: 0 16px; }
.fp-grid-card { position: relative; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s; border-radius: 12px; }
.fp-grid-card:hover { transform: translateY(-4px); }
.fp-grid-card:hover .fp-grid-poster-wrap { box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.fp-grid-poster-wrap { position: relative; aspect-ratio: 2/3; border-radius: 12px; overflow: hidden; background: var(--surface-2); box-shadow: 0 2px 10px rgba(0,0,0,.25); transition: box-shadow 0.2s; }
.fp-grid-poster { width: 100%; height: 100%; object-fit: cover; display: block; }
.fp-grid-poster-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); background: var(--surface-2); }
.fp-grid-both { position: absolute; top: 6px; right: 6px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent, #34d399); color: #000; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.fp-grid-plex { position: absolute; top: 6px; left: 6px; width: 20px; height: 20px; border-radius: 50%; background: #E5A00D; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.fp-grid-type { position: absolute; bottom: 6px; left: 6px; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; background: rgba(0,0,0,.65); color: #fff; padding: 2px 6px; border-radius: 4px; backdrop-filter: blur(4px); }
.fp-grid-title { font-size: 12px; font-weight: 600; margin: 6px 0 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-primary, var(--slate-200)); line-height: 1.3; }
.fp-grid-rating { position: absolute; bottom: 6px; right: 6px; font-size: 10px; font-weight: 700; background: rgba(0,0,0,.7); color: #facc15; padding: 2px 6px; border-radius: 4px; display: flex; align-items: center; gap: 3px; backdrop-filter: blur(4px); }
.fp-grid-add-btn { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 50%; background: rgba(52,211,153,.85); color: #000; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,.3); opacity: 0; transition: opacity 0.2s; z-index: 2; }
.fp-grid-card:hover .fp-grid-add-btn { opacity: 1; }
/* Episode landscape cards */
.fp-ep-card { grid-column: span 2; position: relative; cursor: pointer; border-radius: 12px; transition: transform 0.2s, box-shadow 0.2s; }
.fp-ep-card:hover { transform: translateY(-5px); }
.fp-ep-card:hover .fp-ep-backdrop-wrap { box-shadow: 0 12px 32px rgba(0,0,0,.45); }
.fp-ep-backdrop-wrap { position: relative; aspect-ratio: 16/9; border-radius: 14px; overflow: hidden; background: var(--surface-2); box-shadow: 0 3px 12px rgba(0,0,0,.3); transition: box-shadow .25s cubic-bezier(.4,0,.2,1); }
.fp-ep-backdrop { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s cubic-bezier(.4,0,.2,1); }
.fp-ep-card:hover .fp-ep-backdrop { transform: scale(1.05); }
.fp-ep-backdrop-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); background: var(--surface-2); }
.fp-ep-gradient { position: absolute; bottom: 0; left: 0; right: 0; height: 65%; background: linear-gradient(to top, rgba(0,0,0,.8) 0%, rgba(0,0,0,.15) 60%, transparent 100%); pointer-events: none; }
.fp-ep-badge { position: absolute; top: 8px; left: 8px; font-size: 10.5px; font-weight: 800; letter-spacing: .5px; background: rgba(0,0,0,.65); color: var(--accent, #34d399); padding: 3px 8px; border-radius: 6px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); z-index: 1; border: 1px solid rgba(52,211,153,.15); box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.fp-ep-info { padding: 6px 2px 0; }
.fp-ep-show { font-size: 12px; font-weight: 600; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text-primary, var(--slate-200)); line-height: 1.3; }

/* Episode carousel cards (friend profile watched tab) */
.fp-ep-carousel-card { flex-shrink: 0; width: 280px; cursor: pointer; border-radius: 16px; overflow: hidden; background: var(--surface-1, rgba(255,255,255,.04)); border: 1px solid rgba(255,255,255,.07); transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s cubic-bezier(.4,0,.2,1), border-color .25s; position: relative; }
.fp-ep-carousel-card:hover { transform: translateY(-6px) scale(1.01); box-shadow: 0 12px 32px rgba(0,0,0,.45), 0 0 0 1px rgba(52,211,153,.12); border-color: rgba(255,255,255,.12); }
.fp-ep-carousel-img { position: relative; aspect-ratio: 16/9; overflow: hidden; background: var(--surface-2); }
.fp-ep-carousel-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s cubic-bezier(.4,0,.2,1), filter .4s; }
.fp-ep-carousel-card:hover .fp-ep-carousel-img img { transform: scale(1.06); filter: brightness(1.05); }
.fp-ep-carousel-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); }
.fp-ep-carousel-gradient { position: absolute; bottom: 0; left: 0; right: 0; height: 60%; background: linear-gradient(to top, rgba(0,0,0,.85) 0%, rgba(0,0,0,.2) 50%, transparent 100%); pointer-events: none; }
.fp-ep-carousel-info { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 3px; background: linear-gradient(to bottom, rgba(255,255,255,.02), transparent); }
.fp-ep-carousel-logo { max-height: 24px; max-width: 140px; object-fit: contain; filter: brightness(0) invert(1); opacity: .92; }
.fp-ep-carousel-show { font-size: 12.5px; font-weight: 700; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.1px; }
.fp-ep-carousel-name { font-size: 11.5px; font-weight: 500; color: var(--text-secondary); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.35; }
.fp-ep-carousel-code { font-size: 10px; color: var(--text-muted, var(--slate-500)); margin: 0; display: none; }
.fp-carousel-both { position: absolute; top: 8px; right: 8px; width: 22px; height: 22px; display: flex; align-items: center; justify-content: center; background: var(--accent, #34d399); border-radius: 50%; z-index: 2; box-shadow: 0 2px 8px rgba(52,211,153,.4); }
.fp-carousel-both svg { color: #000; }
@media (max-width: 600px) {
  .fp-ep-carousel-card { width: 240px; }
}

/* Friend watched-all page — section tabs */
.fw-section-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.fw-section-tab { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 20px; border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.04); color: var(--text-secondary); font-size: 13px; font-weight: 600; cursor: pointer; transition: all .2s; }
.fw-section-tab:hover { background: rgba(255,255,255,.08); color: var(--text-primary); }
.fw-section-tab.active { background: var(--accent, #34d399); color: #000; border-color: transparent; }
.fw-tab-count { font-size: 11px; opacity: .7; font-weight: 700; }
.fw-section-tab.active .fw-tab-count { opacity: .85; }

/* Watched-all episode list */
.fw-ep-list { display: flex; flex-direction: column; gap: 10px; padding: 0 16px; }
.fw-ep-card { display: flex; gap: 0; background: var(--surface-1, rgba(255,255,255,.03)); border: 1px solid rgba(255,255,255,.06); border-radius: 16px; overflow: hidden; cursor: pointer; transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s cubic-bezier(.4,0,.2,1), border-color .3s; position: relative; }
.fw-ep-card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--accent, #34d399); opacity: 0; transition: opacity .25s; z-index: 2; border-radius: 3px 0 0 3px; }
.fw-ep-card:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(0,0,0,.35), inset 0 0 0 1px rgba(255,255,255,.04); border-color: rgba(255,255,255,.1); }
.fw-ep-card:hover::before { opacity: 1; }
.fw-ep-backdrop-wrap { position: relative; width: 190px; min-width: 190px; aspect-ratio: 16/9; overflow: hidden; flex-shrink: 0; }
.fw-ep-backdrop { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s cubic-bezier(.4,0,.2,1); }
.fw-ep-card:hover .fw-ep-backdrop { transform: scale(1.05); }
.fw-ep-backdrop-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); background: var(--surface-2); }
.fw-ep-gradient { position: absolute; bottom: 0; left: 0; right: 0; height: 50%; background: linear-gradient(to top, rgba(0,0,0,.6) 0%, transparent 100%); pointer-events: none; }
.fw-ep-badge { position: absolute; top: 8px; left: 8px; font-size: 10px; font-weight: 800; letter-spacing: .5px; background: rgba(0,0,0,.65); color: var(--accent, #34d399); padding: 3px 8px; border-radius: 6px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); z-index: 1; border: 1px solid rgba(52,211,153,.15); }
.fw-ep-details { display: flex; flex-direction: column; justify-content: center; padding: 14px 16px 14px 16px; min-width: 0; flex: 1; gap: 5px; }
.fw-ep-show-row { display: flex; align-items: center; min-height: 28px; }
.fw-ep-logo { max-height: 28px; max-width: 160px; object-fit: contain; filter: brightness(0) invert(1); opacity: .92; }
.fw-ep-show-name { font-size: 14px; font-weight: 700; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.1px; }
.fw-ep-name { font-size: 13px; font-weight: 500; color: var(--text-secondary); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.35; }
.fw-ep-sub { font-size: 11px; color: var(--text-muted, var(--slate-500)); margin: 0; letter-spacing: .2px; }

.fp-empty { color: var(--text-secondary); font-size: 13px; text-align: center; padding: 32px 20px; display: flex; flex-direction: column; align-items: center; gap: 8px; }

/* Plex tab on friend profile */
.fp-plex-now-playing { margin-bottom: 16px; }
.fp-plex-sessions { display: flex; flex-direction: column; gap: 8px; }
.fp-plex-session { background: rgba(229,160,13,.06); border: 1px solid rgba(229,160,13,.15); border-radius: var(--radius-md); padding: 10px 12px; }
.fp-plex-session-info { display: flex; align-items: flex-start; gap: 8px; }
.fp-plex-session-state { flex-shrink: 0; width: 22px; height: 22px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: rgba(229,160,13,.15); color: #E5A00D; }
.fp-plex-session-state.paused { background: rgba(148,163,184,.15); color: var(--slate-400); }
.fp-plex-session-title { font-size: 13px; font-weight: 600; color: var(--slate-200); margin: 0; }
.fp-plex-session-sub { font-size: 11px; color: var(--slate-400); margin: 2px 0 0; }
.fp-plex-session-user { font-size: 10px; color: var(--slate-500); margin: 2px 0 0; }
.fp-plex-session-bar { height: 3px; border-radius: 2px; background: rgba(255,255,255,.08); margin-top: 8px; overflow: hidden; }
.fp-plex-session-fill { height: 100%; border-radius: 2px; background: #E5A00D; transition: width .3s; }
/* Plex now-playing inside activity tab */
.fp-act-plex-live { background: rgba(229,160,13,.06); border: 1px solid rgba(229,160,13,.18); border-radius: var(--radius-md); padding: 10px 12px; margin-bottom: 12px; }
.fp-act-plex-header { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: #E5A00D; margin-bottom: 8px; text-transform: uppercase; letter-spacing: .4px; }
.fp-act-plex-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; }
.fp-act-plex-row + .fp-act-plex-row { border-top: 1px solid rgba(255,255,255,.04); }
.fp-act-plex-info { flex: 1; min-width: 0; }
.fp-act-plex-title { font-size: 13px; font-weight: 600; color: var(--slate-200); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fp-act-plex-ep { font-weight: 400; color: var(--slate-400); font-size: 11px; }
.fp-act-plex-sub { font-size: 11px; color: var(--slate-400); margin: 1px 0 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fp-act-plex-tag { display: inline-block; font-size: 9px; font-weight: 700; color: #1F1F1F; background: #E5A00D; padding: 1px 5px; border-radius: 3px; vertical-align: middle; margin-left: 4px; letter-spacing: .3px; }
.fp-report-btn { color: var(--text-muted); border-color: rgba(239,68,68,.15); }
.fp-report-btn:hover { color: #ef4444; border-color: rgba(239,68,68,.35); background: rgba(239,68,68,.06); }

/* Full friend list / watchlist pages */
.fp-all-page { padding: 0; }
.fw-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.fw-count { font-size: 12px; color: var(--text-secondary); margin-left: auto; }

/* Analytics page */
.fp-analytics-page {}
.fa-stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
.fa-stat { background: var(--surface-1); border: 1px solid var(--border); border-radius: 10px; padding: 14px; text-align: center; }

/* ============================================================
   Activity Feed — Filter Pills
   ============================================================ */
.act-filter-row { display: flex; gap: 8px; padding: 0 16px 12px; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.act-filter-row::-webkit-scrollbar { display: none; }
.act-filter-pill { flex-shrink: 0; background: var(--surface-1); border: 1px solid var(--border); color: var(--text-secondary); padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 500; cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; }
.act-filter-pill.active { background: var(--indigo-600, #4f46e5); color: #fff; border-color: transparent; }

/* Plex activity cards (legacy) */
.act-plex-card { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.05)); cursor: pointer; }
.act-plex-card:active { background: var(--surface-1); }
.dot-plex { background: #E5A00D !important; }

/* ============================================================
   Back to Top Button
   ============================================================ */
.back-to-top-btn { position: fixed; bottom: 80px; right: 20px; z-index: 200; width: 44px; height: 44px; border-radius: 50%; background: var(--indigo-600, #4f46e5); color: #fff; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 16px rgba(0,0,0,0.4); opacity: 0; pointer-events: none; transition: opacity 0.2s, transform 0.2s; transform: translateY(8px); }
.back-to-top-btn.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }

/* ============================================================
   Plex Calendar
   ============================================================ */
.plex-calendar { background: var(--surface-1); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; margin: 0 16px 16px; }
.cal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.cal-title { font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cal-nav-btn { background: none; border: none; color: var(--text-secondary); cursor: pointer; padding: 4px 8px; border-radius: 6px; font-size: 18px; line-height: 1; }
.cal-nav-btn:hover { background: var(--surface-2); }
.cal-weekdays { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin-bottom: 4px; }
.cal-weekday { font-size: 10px; font-weight: 600; color: var(--text-muted, #64748b); text-align: center; padding: 4px 0; text-transform: uppercase; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-day { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 32px; border-radius: 6px; font-size: 12px; color: var(--text-secondary); position: relative; padding: 2px 0; }
.cal-day.has-items { cursor: pointer; color: var(--text-primary); font-weight: 600; }
.cal-day.has-items:hover { background: var(--surface-2); }
.cal-day.today { color: var(--accent, #6366f1); font-weight: 700; }
.cal-day.selected { background: var(--indigo-600, #4f46e5); color: #fff !important; border-radius: 6px; }
.cal-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--emerald-400, #34d399); margin-top: 2px; }
.cal-selected-bar { display: flex; align-items: center; justify-content: space-between; padding: 8px 16px; background: var(--surface-1); border-top: 1px solid var(--border); font-size: 13px; color: var(--text-secondary); margin: 0 16px 8px; border-radius: 0 0 10px 10px; }
.cal-clear-btn { background: none; border: none; color: var(--accent); font-size: 12px; cursor: pointer; padding: 2px 8px; }

/* Plex history search bar */
.plex-search-bar-wrap { padding: 8px 16px; }
.plex-search-bar { width: 100%; box-sizing: border-box; background: var(--surface-1); border: 1px solid var(--border); color: var(--text-primary); padding: 8px 14px; border-radius: 10px; font-size: 14px; font-family: inherit; }
.plex-search-bar:focus { outline: none; border-color: var(--accent); }

/* ============================================================
   Actor Filmography Tabs
   ============================================================ */
.act-type-tabs { display: flex; gap: 8px; padding: 8px 16px 12px; border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.05)); }
.act-tab-btn { background: var(--surface-1); border: 1px solid var(--border); color: var(--text-secondary); padding: 6px 16px; border-radius: 999px; font-size: 13px; font-weight: 500; cursor: pointer; transition: background 0.15s, color 0.15s; }
.act-tab-btn.active { background: var(--indigo-600, #4f46e5); color: #fff; border-color: transparent; }

/* ============================================================
   Watched History Page
   ============================================================ */
.watched-history-page { padding-bottom: 80px; }
.wh-summary { display: flex; gap: 0; margin: 0 16px 8px; border-radius: 16px; background: linear-gradient(135deg, rgba(255,255,255,.03), rgba(255,255,255,.01)); border: 1px solid rgba(255,255,255,.06); overflow: hidden; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.wh-stat { flex: 1; text-align: center; padding: 18px 8px; position: relative; }
.wh-stat + .wh-stat::before { content: ''; position: absolute; left: 0; top: 20%; height: 60%; width: 1px; background: rgba(255,255,255,.06); }
.wh-stat-num { display: block; font-size: 1.625rem; font-weight: 800; color: var(--accent, #6366f1); text-shadow: 0 0 20px rgba(99,102,241,.2); }
.wh-stat-label { display: block; font-size: 10px; color: var(--text-muted); margin-top: 4px; text-transform: uppercase; letter-spacing: 0.8px; font-weight: 600; }
.wh-tabs { border-bottom: 1px solid var(--border); }
.wh-list { padding: 0 16px 16px; display: flex; flex-direction: column; gap: 8px; }
.wh-card { display: flex; align-items: center; gap: 16px; padding: 12px 14px; background: var(--bg-card, var(--glass-bg)); border: 1px solid var(--border-subtle, rgba(255,255,255,0.05)); border-radius: 16px; cursor: pointer; transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s, border-color .3s, background .2s; position: relative; overflow: hidden; }
.wh-card::after { content: ''; position: absolute; inset: 0; border-radius: 16px; background: linear-gradient(135deg, rgba(255,255,255,.02) 0%, transparent 50%); pointer-events: none; }
.wh-card:hover { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.1); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.wh-poster { width: 60px; height: 90px; border-radius: 10px; object-fit: cover; flex-shrink: 0; box-shadow: 0 3px 12px rgba(0,0,0,.35); transition: transform .3s cubic-bezier(.4,0,.2,1), box-shadow .3s; }
.wh-card:hover .wh-poster { transform: scale(1.04); box-shadow: 0 6px 18px rgba(0,0,0,.4); }
.wh-poster-placeholder { width: 60px; height: 90px; border-radius: 10px; background: linear-gradient(145deg, var(--surface-2), rgba(255,255,255,.02)); display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--text-muted, #64748b); }
.wh-card-info { flex: 1; min-width: 0; }
.wh-card-title { font-size: 14.5px; font-weight: 700; color: var(--slate-200); margin: 0 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.2px; transition: color .2s; }
.wh-card:hover .wh-card-title { color: #fff; }
.wh-card-year { font-weight: 400; color: var(--slate-400); font-size: 12.5px; }
.wh-card-sub { font-size: 12px; color: var(--slate-400); margin: 0 0 3px; }
.wh-card-date { font-size: 11px; color: var(--text-muted, #64748b); margin: 0; }
.wh-ring-wrap { display: flex; flex-direction: column; align-items: center; gap: 3px; flex-shrink: 0; }
.wh-ring { width: 48px; height: 48px; filter: drop-shadow(0 1px 3px rgba(0,0,0,.2)); }
.wh-ring-bg { stroke: var(--surface-2, #1e293b); }
.wh-ring-fill { stroke: var(--emerald-400, #34d399); stroke-linecap: round; transition: stroke-dasharray 0.4s; filter: drop-shadow(0 0 3px rgba(52,211,153,.25)); }
.wh-ring-complete { stroke: var(--indigo-500, #6366f1); filter: drop-shadow(0 0 3px rgba(99,102,241,.3)); }
.wh-ring-text { font-size: 11px; font-weight: 700; fill: var(--slate-200); }
.wh-ring-text-sm { font-size: 10px; font-weight: 700; fill: var(--slate-200); }
.wh-ring-text-tiny { font-size: 8px; fill: var(--slate-400); }
.wh-ring-label { font-size: 10px; color: var(--slate-400); text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }

/* ============================================================
   Modal form fields
   ============================================================ */
.modal-label { display: block; font-size: 12px; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
.modal-input { display: block; width: 100%; box-sizing: border-box; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-primary); padding: 9px 12px; border-radius: 8px; font-size: 14px; font-family: inherit; }
.modal-input:focus { outline: none; border-color: var(--accent); }
.bug-report-form { display: flex; flex-direction: column; }

/* ============================================================
   GUIDED TOUR
   ============================================================ */
.tour-overlay { position: fixed; inset: 0; z-index: 99999; }
.tour-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.65); }
.tour-spotlight { position: fixed; border-radius: 12px; box-shadow: 0 0 0 9999px rgba(0,0,0,.65), 0 0 0 3px rgba(99,102,241,.6); z-index: 1; pointer-events: none; transition: all .3s ease; }
.tour-tooltip { position: fixed; z-index: 2; background: var(--surface-1, #1e293b); border: 1px solid var(--border, rgba(255,255,255,.08)); border-radius: 14px; padding: 18px; box-shadow: 0 12px 40px rgba(0,0,0,.4); max-width: 320px; }
.tour-tooltip-title { font-size: 1rem; font-weight: 700; color: var(--text-primary, #f1f5f9); margin-bottom: 6px; }
.tour-tooltip-text { font-size: .875rem; color: var(--text-secondary, #94a3b8); line-height: 1.5; margin-bottom: 14px; }
.tour-tooltip-footer { display: flex; align-items: center; justify-content: space-between; }
.tour-step-counter { font-size: .75rem; color: var(--text-muted, #64748b); }
.tour-tooltip-btns { display: flex; gap: 6px; }
.tour-skip-btn { background: none; border: none; color: var(--text-muted, #64748b); font-size: .8125rem; cursor: pointer; padding: 6px 10px; }
.tour-skip-btn:hover { color: var(--text-secondary); }
.tour-prev-btn { background: var(--surface-2, #334155); border: 1px solid var(--border); color: var(--text-secondary); padding: 7px 14px; border-radius: 8px; font-size: .8125rem; font-weight: 600; cursor: pointer; }
.tour-next-btn { background: var(--indigo-500, #6366f1); border: none; color: #fff; padding: 7px 16px; border-radius: 8px; font-size: .8125rem; font-weight: 600; cursor: pointer; transition: background .15s; }
.tour-next-btn:hover { background: var(--indigo-600, #4f46e5); }

/* ============================================================
   Friend Profile — Report button
   ============================================================ */
.fp-report-btn { color: var(--rose-400, #f87171) !important; border-color: rgba(248,113,113,0.3) !important; }
.fp-report-btn:hover { background: rgba(248,113,113,0.1) !important; }

/* ============================================================
   Keep Watching — home section
   ============================================================ */
#keep-watching-section .media-card-sm { min-width: 120px; max-width: 120px; }
#keep-watching-section .media-card-sm img { width: 120px; height: 180px; }
#keep-watching-section .card-title { max-width: 120px; }
#keep-watching-section .card-subtitle { font-size: 11px; color: var(--accent); font-weight: 600; max-width: 120px; }
.fa-stat.accent { border-color: rgba(52,211,153,0.3); background: rgba(52,211,153,0.06); }
.fa-stat-num { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); }
.fa-stat.accent .fa-stat-num { color: var(--accent); }
.fa-stat-label { font-size: 11px; color: var(--text-secondary); margin-top: 2px; }
.fa-section { margin-bottom: 20px; }
.fa-section-title { font-size: 13px; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 10px; }
.fa-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }

/* ============================================================
   V66 — LISTS PAGE HERO + ENHANCEMENTS
   ============================================================ */
.lists-page-v2 { min-height: 100vh; }
.lp-hero { position: relative; padding: 20px 20px 0; overflow: hidden; }
.lp-hero-glow { position: absolute; top: -80px; right: -60px; width: 220px; height: 220px; background: radial-gradient(circle, rgba(99,102,241,.12) 0%, transparent 70%); pointer-events: none; animation: heroGlowFloat 8s ease-in-out infinite alternate; }
@keyframes heroGlowFloat { 0% { transform: translate(0, 0); } 100% { transform: translate(-20px, 20px); } }
.lp-hero-row { display: flex; align-items: center; gap: 14px; position: relative; z-index: 1; }
.lp-hero-text { flex: 1; }
.lp-hero-text h1 { font-size: 1.75rem; font-weight: 800; letter-spacing: -.03em; margin: 0; background: linear-gradient(135deg, #fff 30%, var(--indigo-400)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.lp-hero-text p { font-size: .8125rem; color: var(--text-secondary); margin: 3px 0 0; }
.lp-create-btn { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: 12px; background: linear-gradient(135deg, var(--indigo-600), var(--indigo-500)); color: white; font-size: .8125rem; font-weight: 600; border: none; cursor: pointer; transition: all var(--transition); box-shadow: 0 4px 16px rgba(99,102,241,.25); flex-shrink: 0; }
.lp-create-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 24px rgba(99,102,241,.4); }
.lp-stats-strip { display: flex; gap: 8px; padding: 16px 20px 8px; flex-wrap: wrap; }
.lp-stat-pill { display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px; border-radius: 20px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); font-size: .75rem; color: var(--text-secondary); }
.lp-stat-pill strong { color: var(--text-primary); font-weight: 700; }
/* Enhanced list card hover */
.lists-page-v2 .list-card { border-radius: 14px; }
.lists-page-v2 .list-card:hover { transform: translateY(-5px) scale(1.01); box-shadow: 0 12px 32px rgba(0,0,0,.35), 0 0 0 1px rgba(99,102,241,.15); border-color: rgba(99,102,241,.2); }
.list-card-cover::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 50%; background: linear-gradient(to top, rgba(0,0,0,.4) 0%, transparent 100%); pointer-events: none; z-index: 0; }
.list-preview-chips { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
.list-preview-chip { font-size: .625rem; padding: 2px 8px; border-radius: 6px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.06); color: var(--text-muted); white-space: nowrap; max-width: 80px; overflow: hidden; text-overflow: ellipsis; }
.list-preview-chip.more { background: rgba(99,102,241,.1); border-color: rgba(99,102,241,.2); color: var(--indigo-400); }
/* Lists empty state V2 */
.lists-page-v2 .lists-empty-state { padding: 48px 24px; }
.lists-page-v2 .lists-empty-hero h3 { background: linear-gradient(135deg, #fff, var(--indigo-400)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* ============================================================
   V66 — MATCHER SETUP ENHANCEMENTS
   ============================================================ */
.matcher-page-v2 { min-height: 100vh; }
.matcher-setup-hero { position: relative; overflow: hidden; }
.mt-hero-glow { position: absolute; top: -60px; left: 50%; transform: translateX(-50%); width: 300px; height: 200px; background: radial-gradient(ellipse, rgba(99,102,241,.12) 0%, transparent 70%); pointer-events: none; }
.mt-hero-icon { width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 14px; background: linear-gradient(135deg, rgba(99,102,241,.15), rgba(168,85,247,.15)); border: 1px solid rgba(99,102,241,.2); display: flex; align-items: center; justify-content: center; color: var(--indigo-400); }
.mt-section-label { display: flex; align-items: center; gap: 6px; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .8px; color: var(--text-muted); padding: 20px 20px 10px; }
.matcher-friend-card { overflow: hidden; }
.matcher-friend-card.active { box-shadow: 0 0 20px rgba(99,102,241,.12); }
.matcher-friend-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.mt-start-btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: calc(100% - 32px); margin: 24px auto 0; padding: 14px 24px; border-radius: 14px; background: linear-gradient(135deg, var(--indigo-600), var(--indigo-500)); color: white; font-size: .9375rem; font-weight: 700; border: none; cursor: pointer; transition: all .25s ease; box-shadow: 0 4px 20px rgba(99,102,241,.3); }
.mt-start-btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(99,102,241,.4); }
.mt-start-btn:disabled { opacity: .4; cursor: default; }
/* Results celebration */
.results-count-circle { position: relative; animation: pulseGlow 2s ease-in-out infinite; }
@keyframes pulseGlow { 0%, 100% { box-shadow: 0 0 0 0 rgba(99,102,241,.15); } 50% { box-shadow: 0 0 0 16px transparent; } }
/* Results V2 grid */
.mr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 14px; padding: 0 20px 20px; }
.mr-card { border-radius: 12px; overflow: hidden; cursor: pointer; transition: transform .2s; background: var(--bg-card); border: 1px solid var(--border-subtle); }
.mr-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,.3); }
.mr-card img { width: 100%; aspect-ratio: 2/3; object-fit: cover; display: block; }
.mr-card-title { font-size: .8125rem; font-weight: 600; padding: 8px 8px 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mr-actions { display: flex; flex-direction: column; gap: 8px; padding: 0 20px 32px; }
.mr-celebration { text-align: center; padding: 32px 20px 16px; }
.mr-tagline { font-size: 1.125rem; color: var(--text-primary); font-weight: 600; margin: 0 0 4px; }
.mr-subtitle { font-size: .875rem; color: var(--text-secondary); margin: 0; }

/* ============================================================
   V66 — DISCOVER LAZY LOAD ANIMATION
   ============================================================ */
.media-card img, .person-card img { opacity: 0; transition: opacity .35s ease, transform .35s ease; transform: translateY(6px); }
.media-card img.loaded, .person-card img.loaded { opacity: 1; transform: translateY(0); }

/* ============================================================
   V66 — NAV PROFILE AVATAR
   ============================================================ */
.nav-avatar, .sidebar-avatar { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; border: 1.5px solid rgba(99,102,241,.4); flex-shrink: 0; }
.sidebar-btn .sidebar-avatar { width: 22px; height: 22px; }

/* ============================================================
   V68 — SHARE CARD BUILDER (expanded with unlockable themes, creative QR)
   ============================================================ */
.scb-wrapper { display: flex; flex-direction: column; gap: 16px; }
.scb-preview { display: flex; justify-content: center; }
.scb-preview canvas { border-radius: 16px; max-width: 100%; height: auto; box-shadow: 0 8px 32px rgba(0,0,0,.4); }
.scb-section { display: flex; flex-direction: column; gap: 8px; }
.scb-section-label { font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .8px; color: var(--text-muted); }
.scb-cat-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.scb-cat-btn { padding: 4px 10px; border-radius: 6px; background: rgba(255,255,255,.04); border: 1px solid var(--border-subtle); color: var(--text-secondary); font-size: .75rem; font-weight: 500; cursor: pointer; transition: all .2s; display: flex; align-items: center; gap: 4px; }
.scb-cat-btn.active { background: rgba(99,102,241,.12); border-color: var(--indigo-500); color: var(--indigo-400); }
.scb-cat-btn:hover:not(.active) { background: rgba(255,255,255,.08); }
.scb-lock-count { display: inline-flex; align-items: center; gap: 2px; font-size: .625rem; opacity: .6; }
.scb-themes { display: flex; gap: 6px; flex-wrap: wrap; max-height: 170px; overflow-y: auto; padding: 2px; }
.scb-themes::-webkit-scrollbar { width: 3px; }
.scb-themes::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 3px; }
.scb-theme-card { width: 72px; height: 52px; border-radius: 10px; border: 2px solid transparent; cursor: pointer; transition: all .2s; position: relative; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; overflow: hidden; }
.scb-theme-card.active { border-color: #fff; transform: scale(1.06); box-shadow: 0 0 14px rgba(255,255,255,.25); }
.scb-theme-card:hover:not(.active) { transform: scale(1.04); border-color: rgba(255,255,255,.2); }
.scb-theme-card.locked { opacity: .35; filter: grayscale(.6); }
.scb-theme-card.locked:hover { opacity: .55; }
.scb-theme-emoji { font-size: 16px; line-height: 1; pointer-events: none; }
.scb-theme-name { font-size: .5rem; font-weight: 600; color: rgba(255,255,255,.85); pointer-events: none; text-shadow: 0 1px 3px rgba(0,0,0,.7); max-width: 66px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; }
.scb-theme-lock { position: absolute; top: 3px; right: 3px; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,.5); border-radius: 50%; width: 16px; height: 16px; }
.scb-theme-lock svg { width: 9px; height: 9px; color: rgba(255,255,255,.7); }
.scb-styles { display: flex; gap: 5px; flex-wrap: wrap; }
.scb-style-btn { padding: 5px 12px; border-radius: 8px; background: rgba(255,255,255,.04); border: 1px solid var(--border-subtle); color: var(--text-secondary); font-size: .8rem; font-weight: 500; cursor: pointer; transition: all .2s; }
.scb-style-btn.active { background: rgba(99,102,241,.12); border-color: var(--indigo-500); color: var(--indigo-400); }
.scb-style-btn:hover:not(.active) { background: rgba(255,255,255,.06); }
.scb-toggles { display: flex; gap: 14px; flex-wrap: wrap; }
.scb-toggle { display: flex; align-items: center; gap: 6px; font-size: .8rem; color: var(--text-secondary); cursor: pointer; }
.scb-toggle input[type="checkbox"] { accent-color: var(--indigo-500); width: 15px; height: 15px; }
.scb-actions { display: flex; gap: 10px; }
.scb-btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 12px; border-radius: 12px; font-size: .875rem; font-weight: 600; cursor: pointer; transition: all .2s; }
.scb-btn-primary { background: linear-gradient(135deg, var(--indigo-600), var(--indigo-500)); color: white; border: none; box-shadow: 0 4px 16px rgba(99,102,241,.25); }
.scb-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(99,102,241,.35); }
.scb-btn-secondary { background: rgba(255,255,255,.04); border: 1px solid var(--border-subtle); color: var(--text-secondary); }
.scb-btn-secondary:hover { background: rgba(255,255,255,.08); color: var(--text-primary); }
.invite-code-row { display: flex; align-items: center; gap: 4px; }
.invite-share-btn { width: 32px; height: 32px; border-radius: 8px; background: rgba(52,211,153,.08); border: 1px solid rgba(52,211,153,.2); color: var(--accent); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s; flex-shrink: 0; }
.invite-share-btn:hover { background: rgba(52,211,153,.15); border-color: rgba(52,211,153,.35); }
@media (max-width: 768px) {
  .hero-slide { background-position: center top !important; }
  .hero-slide[style*="background-image"] { background-position: 50% 15% !important; }
}

/* ============================================================
   HOME — PLEX NOW PLAYING SECTION
   ============================================================ */
.plex-carousel-wrap { position: relative; }
.plex-carousel-btn {
  display: none; position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 36px; height: 36px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(0,0,0,.65); color: #e5a00d; backdrop-filter: blur(8px);
  box-shadow: 0 2px 10px rgba(0,0,0,.4);
  transition: all var(--transition);
}
.plex-carousel-btn:hover { background: rgba(229,160,13,.2); transform: translateY(-50%) scale(1.1); }
.plex-carousel-prev { left: 4px; }
.plex-carousel-next { right: 4px; }
@media (min-width: 640px) { .plex-carousel-btn { display: flex; align-items: center; justify-content: center; } }
.plex-home-sessions {
  display: flex; gap: 14px; overflow-x: auto; padding: 4px 16px 12px;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory; scroll-behavior: smooth;
}
.plex-home-sessions::-webkit-scrollbar { display: none; }
.plex-home-card {
  display: flex; gap: 14px; align-items: stretch;
  background: linear-gradient(135deg, rgba(229,160,13,.06), rgba(229,160,13,.02));
  border: 1px solid rgba(229,160,13,.2); border-radius: 16px;
  padding: 12px; cursor: pointer; transition: all var(--transition);
  flex-shrink: 0; min-width: 320px; max-width: 380px;
  scroll-snap-align: start;
}
.plex-home-card:hover { border-color: rgba(229,160,13,.5); background: rgba(229,160,13,.08); transform: translateY(-2px); box-shadow: 0 6px 24px rgba(229,160,13,.12); }
.plex-home-poster-wrap { position: relative; flex-shrink: 0; width: 80px; height: 120px; border-radius: 10px; overflow: hidden; }
.plex-home-thumb { width: 100%; height: 100%; background-size: cover; background-position: center; background-color: var(--bg-card); }
.plex-home-thumb-ph { display: flex; align-items: center; justify-content: center; color: var(--text-muted); width: 100%; height: 100%; background: var(--bg-card); }
.plex-home-paused-overlay { position: absolute; inset: 0; background: rgba(0,0,0,.45); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,.8); }
.plex-home-info { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.plex-home-state {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: .625rem; font-weight: 700; text-transform: uppercase; letter-spacing: .4px;
  border-radius: 4px; padding: 2px 7px; width: fit-content; position: absolute; bottom: 4px; left: 4px;
}
.plex-home-state.playing { background: rgba(16,185,129,.85); color: #fff; }
.plex-home-state.paused  { background: rgba(245,158,11,.85); color: #fff; }
.plex-home-title { font-size: .875rem; font-weight: 700; color: var(--text-primary); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plex-home-sub { font-size: .75rem; color: var(--text-secondary); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plex-home-user { font-size: .6875rem; color: var(--slate-400); margin: 2px 0 0; display: flex; align-items: center; gap: 4px; }
.plex-home-progress { margin-top: auto; }
.plex-home-bar { width: 100%; height: 4px; background: rgba(255,255,255,.08); border-radius: 2px; overflow: hidden; }
.plex-home-fill { height: 100%; background: linear-gradient(90deg, #e5a00d, #f59e0b); border-radius: 2px; transition: width .4s ease; }
.plex-home-times { display: flex; justify-content: space-between; font-size: .625rem; color: var(--text-muted); margin-top: 3px; }

/* ============================================================
   NOW PLAYING — thumb wrap, paused overlay, Play on Plex btn
   ============================================================ */
.np-thumb-wrap { position: relative; flex-shrink: 0; width: 130px; height: 195px; }
.np-thumb-wrap .np-thumb { width: 100%; height: 100%; }
.np-thumb-paused-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.48);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.85);
  border-radius: 10px;
  pointer-events: none;
}
.np-card-paused { opacity: 0.88; border-color: rgba(245,158,11,.35) !important; }
.np-plex-btn {
  display: inline-flex; align-items: center; gap: 5px;
  margin-top: 10px;
  font-size: .75rem; font-weight: 600;
  color: #e5a00d;
  background: rgba(229,160,13,.1);
  border: 1px solid rgba(229,160,13,.3);
  border-radius: 7px;
  padding: 5px 11px;
  text-decoration: none;
  transition: background var(--transition), border-color var(--transition);
  cursor: pointer;
}
.np-plex-btn:hover { background: rgba(229,160,13,.2); border-color: rgba(229,160,13,.55); }

/* ============================================================
   LISTS PAGE — empty state redesign, type badge, preview chips
   ============================================================ */
.lists-empty-state { display: flex; flex-direction: column; align-items: stretch; padding: 24px 20px 40px; gap: 0; }
.lists-empty-icon { color: var(--text-muted); margin-bottom: 8px; }
.lists-empty-hero {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 32px 20px 28px;
  gap: 10px;
}
.lists-empty-hero h3 { font-size: 1.3125rem; font-weight: 800; margin: 0; color: var(--text-primary); }
.lists-empty-hero p { font-size: .9375rem; color: var(--text-secondary); max-width: 340px; margin: 0; line-height: 1.5; }
.lists-create-cta { margin-top: 6px; }
.lists-inspiration-label {
  font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  color: var(--text-muted); padding: 0 4px 10px;
}
.lists-inspiration-grid { display: flex; flex-direction: column; gap: 10px; }
.lists-inspiration-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  border-radius: 14px; padding: 14px 16px; cursor: pointer; text-align: left;
  transition: border-color var(--transition), background var(--transition);
  width: 100%; color: var(--text-primary);
}
.lists-inspiration-card:hover { border-color: rgba(139,92,246,.4); background: rgba(139,92,246,.05); }
.lic-icon {
  width: 42px; height: 42px; border-radius: 11px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.lic-text { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.lic-text strong { font-size: .9375rem; font-weight: 700; line-height: 1.2; }
.lic-text span { font-size: .8125rem; color: var(--text-secondary); line-height: 1.4; }
.lic-tag { font-size: .6875rem; font-weight: 700; padding: 3px 8px; border-radius: 20px; border: 1px solid; white-space: nowrap; flex-shrink: 0; }
.list-type-badge {
  position: absolute; bottom: 6px; left: 6px;
  font-size: .625rem; font-weight: 700; letter-spacing: .03em;
  padding: 2px 7px; border-radius: 5px; border: 1px solid;
  backdrop-filter: blur(4px); pointer-events: none;
}
.list-role-badge { position: absolute; top: 6px; right: 6px; }
.list-preview-chips { display: flex; flex-wrap: wrap; gap: 4px; margin: 5px 0 2px; }
.list-preview-chip {
  font-size: .6875rem; color: var(--text-muted);
  background: var(--bg-secondary); border: 1px solid var(--border-subtle);
  border-radius: 5px; padding: 1px 6px;
  max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.list-preview-chip.more { color: var(--text-muted); }
/* Create modal suggestions */
.create-list-suggestions { margin-bottom: 4px; }
.create-suggestions-label { font-size: .6875rem; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; margin: 0 0 7px; }
.create-suggestions-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.suggestion-chip {
  font-size: .8125rem; color: var(--text-secondary);
  background: var(--bg-secondary); border: 1px solid var(--border-subtle);
  border-radius: 20px; padding: 4px 12px; cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.suggestion-chip:hover { background: rgba(139,92,246,.12); color: var(--indigo-300); border-color: rgba(139,92,246,.35); }

/* ============================================================
   CAST LIST — search bar + episode chips
   ============================================================ */
.cast-search-bar { padding: 0 20px 14px; position: sticky; top: 0; z-index: 10; background: var(--bg-primary); }
.cast-search-input {
  width: 100%; box-sizing: border-box;
  background: var(--bg-tertiary); border: 1px solid var(--border-subtle);
  border-radius: 10px; padding: 10px 14px;
  color: var(--text-primary); font-size: .9375rem;
  outline: none; transition: border-color var(--transition);
}
.cast-search-input:focus { border-color: var(--indigo-500); }
.cast-ep-chip {
  font-size: .6875rem; font-weight: 600; white-space: nowrap; flex-shrink: 0;
  background: rgba(99,102,241,.12); color: var(--indigo-300);
  border: 1px solid rgba(99,102,241,.25); border-radius: 6px; padding: 2px 7px;
}
.cast-empty { text-align: center; color: var(--text-muted); font-size: .9375rem; padding: 40px 20px; }

/* ============================================================
   ACTOR DETAILS — filmography episode expand
   ============================================================ */
.fi-year { color: var(--text-muted); font-size: .8125rem; margin-left: 4px; }
.fi-type-tag {
  display: inline-block; font-size: .625rem; font-weight: 700; letter-spacing: .3px;
  padding: 1px 5px; border-radius: 4px; vertical-align: middle; margin-left: 6px;
  background: rgba(99,102,241,.15); color: var(--indigo-400);
}
.fi-ep-row { display: flex; align-items: center; gap: 7px; margin-top: 5px; flex-wrap: wrap; }
.fi-expand-btn {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: .75rem; color: var(--text-muted);
  background: var(--bg-secondary); border: 1px solid var(--border-subtle);
  border-radius: 6px; padding: 2px 8px; cursor: pointer;
  transition: color var(--transition), border-color var(--transition);
}
.fi-expand-btn:hover { color: var(--text-secondary); border-color: var(--indigo-500); }
.fi-expand-btn svg { transition: transform 200ms ease; }
.fi-expand-btn svg.rotate-180 { transform: rotate(180deg); }
.fi-ep-detail { margin-top: 8px; padding: 8px 0 4px; border-top: 1px solid var(--border-subtle); }
.fi-role-block { display: flex; align-items: center; justify-content: space-between; padding: 5px 0; gap: 8px; }
.fi-role-char { font-size: .8125rem; color: var(--text-secondary); display: flex; align-items: center; gap: 5px; margin: 0; }
.fi-role-eps { font-size: .75rem; color: var(--text-muted); margin: 0; white-space: nowrap; }
.fi-loading { font-size: .8125rem; color: var(--text-muted); display: flex; align-items: center; gap: 6px; padding: 4px 0; margin: 0; }
.fi-empty { font-size: .8125rem; color: var(--text-muted); padding: 4px 0; margin: 0; }

/* ============================================================
   EPISODE HIGHLIGHT — scroll-to effect
   ============================================================ */
@keyframes epHighlight {
  0%   { background: rgba(99,102,241,.25); }
  100% { background: transparent; }
}
.ep-highlight { animation: epHighlight 2s ease-out forwards; border-radius: 12px; }

/* ============================================================
   V67 — NOW PLAYING DESKTOP LAYOUT FIX
   ============================================================ */
@media (min-width: 768px) {
  .plex-now-playing-page { max-width: 720px; margin: 0 auto; }
  .np-card { padding: 20px; }
  .np-card-top { gap: 20px; }
  .np-still { max-height: 240px; border-radius: 12px; }
  .np-cast-chip { padding: 10px 14px 10px 10px; }
  .np-overview { font-size: .9375rem; }
  .np-title { font-size: 1.25rem; }
  .np-subtitle-text { font-size: .9375rem; }
}

/* ============================================================
   NATIVE APP — Capacitor Adjustments
   ============================================================ */

/* Keyboard open — push content up away from keyboard */
body.keyboard-open .bottom-nav { display: none; }
body.keyboard-open #main-content { padding-bottom: var(--keyboard-height, 0px); }

/* Safe area insets for notch devices */
@supports (padding-top: env(safe-area-inset-top)) {
  .top-bar, .sidebar-nav { padding-top: env(safe-area-inset-top); }
  .bottom-nav { padding-bottom: env(safe-area-inset-bottom); }
  /* Home page: hero bleeds behind status bar; other pages get safe-area padding */
  html.native-app #page-content { padding-top: env(safe-area-inset-top); }
  html.native-app #page-content.home-active { padding-top: 0; }
  html.native-app .hero-profile-btn { top: calc(env(safe-area-inset-top) + 8px); }
}

/* Capacitor native — disable overscroll bounce & double-tap zoom */
html.native-app { overscroll-behavior: none; }
html.native-app * { touch-action: manipulation; }

@keyframes spin { to { transform: rotate(360deg); } }

/* =============================================
   MOBILE HEADER (Native apps only)
   ============================================= */
.mobile-header {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 210;
  background: rgba(15,23,42,.96);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--glass-border);
}
.mobile-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px;
  height: 52px;
}
.mobile-header-logo {
  height: 29px; width: auto; object-fit: contain;
}
.mobile-header-menu-btn {
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); color: var(--slate-300);
  transition: all var(--transition); background: transparent; border: none; cursor: pointer;
}
.mobile-header-menu-btn:hover { background: rgba(255,255,255,.06); }
.mobile-header-menu-btn.open { color: var(--emerald-400); }
.mobile-header-menu-btn svg {
  transition: transform .3s ease;
}
.mobile-header-menu-btn.open svg {
  transform: rotate(90deg);
}

/* Dropdown menu */
.mobile-dropdown {
  display: none; flex-direction: column;
  padding: 8px 12px 12px;
  background: rgba(15,23,42,.98);
  border-bottom: 1px solid var(--glass-border);
  max-height: 70vh; overflow-y: auto;
}
.mobile-dropdown.open { display: flex; }
.mobile-dropdown-btn {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 14px; border-radius: var(--radius-md);
  color: var(--slate-400); font-size: .9rem; font-weight: 500;
  transition: all var(--transition); white-space: nowrap;
  background: transparent; border: none; cursor: pointer;
  text-align: left; width: 100%;
}
.mobile-dropdown-btn:hover { background: rgba(255,255,255,.04); color: var(--slate-200); }
.mobile-dropdown-btn.active {
  background: rgba(16,185,129,.08); color: var(--emerald-400);
  font-weight: 600;
}
.mobile-dropdown-btn svg { flex-shrink: 0; width: 20px; height: 20px; }
.mobile-dropdown-avatar {
  width: 20px; height: 20px; border-radius: 50%; object-fit: cover;
}
.mobile-dropdown-divider {
  height: 1px; background: rgba(255,255,255,.04); margin: 6px 12px;
}

/* Native app: use mobile header instead of bottom nav */
html.native-app .bottom-nav { display: none !important; }
html.native-app .mobile-header { display: block; }
html.native-app .page-content { padding-bottom: 0; }

/* When mobile header is visible, offset page content */
html.native-app #page-content.has-nav {
  padding-top: 0;
}

/* Safe area for mobile header on notch devices */
@supports (padding-top: env(safe-area-inset-top)) {
  html.native-app .mobile-header-inner {
    padding-top: calc(env(safe-area-inset-top) + 6px);
    height: calc(52px + env(safe-area-inset-top));
  }
  html.native-app #page-content.has-nav {
    padding-top: calc(52px + env(safe-area-inset-top)) !important;
  }
  html.native-app #page-content.has-nav.home-active {
    padding-top: 0 !important;
  }
}
