/* =============================================
   STREAMFLIX — DESIGN SYSTEM v3
   Dark Cinema Theme
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
  --red:       #e50914;
  --red-dark:  #b20710;
  --red-glow:  rgba(229,9,20,.35);
  --bg:        #0a0a0a;
  --bg2:       #111111;
  --bg3:       #1a1a1a;
  --bg4:       #242424;
  --border:    rgba(255,255,255,.08);
  --text:      #e8e8e8;
  --text-muted:#888;
  --text-dim:  #555;
  --gold:      #f5c518;
  --radius:    10px;
  --radius-lg: 16px;
  --shadow:    0 8px 32px rgba(0,0,0,.6);
  --shadow-lg: 0 20px 60px rgba(0,0,0,.8);
  --transition: .2s cubic-bezier(.4,0,.2,1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'Helvetica Neue', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }

/* ---- SCROLLBAR ---- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #333; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #555; }

/* =============================================
   NAVBAR
   ============================================= */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 900;
  display: flex; align-items: center; gap: 32px;
  padding: 0 48px;
  height: 68px;
  background: linear-gradient(to bottom, rgba(0,0,0,.95) 0%, rgba(0,0,0,0) 100%);
  transition: background var(--transition), box-shadow var(--transition);
}
.navbar.scrolled {
  background: rgba(10,10,10,.97);
  backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}
.nav-brand { flex-shrink: 0; }
.logo {
  font-size: 1.7rem; font-weight: 900;
  color: var(--red);
  letter-spacing: -1px;
  text-shadow: 0 0 30px var(--red-glow);
  transition: opacity var(--transition);
}
.logo:hover { opacity: .85; }
.nav-links { display: flex; gap: 4px; }
.nav-links a {
  padding: 8px 14px; border-radius: 8px;
  font-size: .88rem; font-weight: 500; color: #ccc;
  transition: all var(--transition);
}
.nav-links a:hover, .nav-links a.active { color: #fff; background: rgba(255,255,255,.08); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.search-form { display: flex; align-items: center; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); border-radius: 8px; overflow: hidden; transition: all var(--transition); }
.search-form:focus-within { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.2); }
.search-input { background: transparent; border: none; color: #fff; padding: 8px 14px; font-size: .88rem; width: 180px; outline: none; }
.search-input::placeholder { color: #666; }
.search-btn { background: transparent; border: none; color: #888; padding: 8px 12px; cursor: pointer; font-size: 1rem; transition: color var(--transition); }
.search-btn:hover { color: #fff; }
.profile-menu { position: relative; }
.profile-name {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 8px;
  font-size: .85rem; font-weight: 600; cursor: pointer;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08);
  transition: all var(--transition);
}
.profile-name:hover { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.15); }
.profile-avatar { width: 28px; height: 28px; background: var(--red); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: .8rem; }
.profile-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  background: rgba(15,15,15,.97); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 8px; min-width: 180px;
  backdrop-filter: blur(20px); box-shadow: var(--shadow-lg);
}
.profile-menu:hover .profile-dropdown { display: block; }
.profile-dropdown a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 8px;
  font-size: .85rem; color: #ccc; transition: all var(--transition);
}
.profile-dropdown a:hover { background: rgba(255,255,255,.08); color: #fff; }
.profile-dropdown a.admin-link { color: var(--red); }
.profile-dropdown hr { border: none; border-top: 1px solid var(--border); margin: 6px 0; }

.main-content { min-height: 100vh; }

/* =============================================
   HERO BANNER
   ============================================= */
.hero-banner {
  position: relative; height: 90vh; min-height: 560px;
  display: flex; align-items: flex-end;
  background-size: cover; background-position: center 20%;
  overflow: hidden;
}
.hero-banner::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    var(--bg) 0%,
    rgba(0,0,0,.7) 40%,
    rgba(0,0,0,.2) 70%,
    transparent 100%
  );
}
.hero-content {
  position: relative; z-index: 2;
  padding: 0 64px 72px; max-width: 680px;
  animation: heroIn .8s ease both;
}
@keyframes heroIn {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--red); color: #fff;
  padding: 4px 12px; border-radius: 4px;
  font-size: .75rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .5px; margin-bottom: 16px;
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.8rem);
  font-weight: 900; line-height: 1.05;
  letter-spacing: -1px;
  text-shadow: 0 2px 20px rgba(0,0,0,.8);
  margin-bottom: 16px;
}
.hero-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.hero-meta span { font-size: .88rem; color: #bbb; }
.hero-meta .dot { color: #555; }
.hero-rating { color: var(--gold); font-weight: 700; }
.hero-desc {
  font-size: .98rem; line-height: 1.65; color: #ccc;
  margin-bottom: 28px; max-width: 520px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-play {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; color: #000;
  padding: 14px 28px; border-radius: 8px;
  font-size: 1rem; font-weight: 700;
  transition: all var(--transition); border: none; cursor: pointer;
}
.btn-play:hover { background: rgba(255,255,255,.85); transform: scale(1.02); }
.btn-info {
  display: inline-flex; align-items: center; gap: 10px;
  background: rgba(109,109,110,.7); color: #fff;
  padding: 14px 28px; border-radius: 8px;
  font-size: 1rem; font-weight: 600; backdrop-filter: blur(10px);
  transition: all var(--transition); border: 1px solid rgba(255,255,255,.15); cursor: pointer;
}
.btn-info:hover { background: rgba(109,109,110,.9); transform: scale(1.02); }

/* =============================================
   CONTENT ROWS / CAROUSELS
   ============================================= */
.content-sections { padding: 0 0 80px; }
.content-row { margin-bottom: 48px; }
.row-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 48px; margin-bottom: 16px;
}
.row-title {
  font-size: 1.25rem; font-weight: 700; color: #fff;
  display: flex; align-items: center; gap: 10px;
}
.row-more {
  font-size: .82rem; font-weight: 600; color: var(--red);
  display: flex; align-items: center; gap: 4px;
  padding: 6px 12px; border-radius: 6px;
  border: 1px solid rgba(229,9,20,.3);
  transition: all var(--transition);
}
.row-more:hover { background: rgba(229,9,20,.1); border-color: var(--red); }

.carousel {
  display: flex; gap: 10px;
  padding: 8px 48px 16px;
  overflow-x: auto; overflow-y: visible;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.carousel::-webkit-scrollbar { display: none; }

/* =============================================
   CARDS
   ============================================= */
.card {
  flex: 0 0 180px; position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  scroll-snap-align: start;
  transition: transform .3s cubic-bezier(.4,0,.2,1), box-shadow .3s ease, z-index 0s;
  background: var(--bg3);
}
.card:hover {
  transform: scale(1.08) translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,.8), 0 0 0 2px rgba(255,255,255,.12);
  z-index: 10;
}
.card-img-wrap {
  position: relative; aspect-ratio: 2/3; overflow: hidden;
  background: var(--bg3);
}
.card-img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.card:hover .card-img-wrap img { transform: scale(1.05); }

/* Gradient overlay no bottom da imagem */
.card-img-wrap::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(to top, rgba(0,0,0,.85), transparent);
  opacity: 0; transition: opacity .3s ease;
}
.card:hover .card-img-wrap::after { opacity: 1; }

.card-rating {
  position: absolute; top: 8px; right: 8px;
  background: rgba(0,0,0,.75); color: var(--gold);
  padding: 3px 7px; border-radius: 5px;
  font-size: .72rem; font-weight: 700; backdrop-filter: blur(8px);
}
.card-info {
  padding: 10px 12px 12px;
  background: linear-gradient(to bottom, var(--bg3), var(--bg4));
}
.card-title {
  font-size: .82rem; font-weight: 600; color: #e0e0e0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  margin-bottom: 3px;
}
.card-year { font-size: .72rem; color: var(--text-dim); }
.card-type { font-size: .72rem; color: var(--text-muted); }
.card-reason { font-size: .7rem; color: var(--red); margin-top: 2px; }

/* Quick-play overlay on hover */
.card-play-btn {
  position: absolute; bottom: 52px; left: 50%; transform: translateX(-50%) scale(0);
  width: 44px; height: 44px;
  background: rgba(255,255,255,.95); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; color: #000;
  transition: transform .2s cubic-bezier(.4,0,.2,1);
  z-index: 5;
}
.card:hover .card-play-btn { transform: translateX(-50%) scale(1); }

/* Progress bar */
.progress-bar {
  position: absolute; bottom: 0; left: 0; height: 3px;
  background: var(--red); border-radius: 0 2px 0 0;
  transition: width .3s ease;
}

/* =============================================
   CATEGORY CHIPS
   ============================================= */
.cats-wrap {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding: 4px 48px;
}
.cat-chip {
  display: inline-flex; align-items: center;
  padding: 8px 18px; border-radius: 24px;
  font-size: .82rem; font-weight: 600;
  background: var(--bg3); color: var(--text-muted);
  border: 1px solid var(--border);
  transition: all var(--transition); white-space: nowrap;
}
.cat-chip:hover {
  background: var(--red); color: #fff;
  border-color: var(--red);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px var(--red-glow);
}

/* =============================================
   GRID (movies/series index)
   ============================================= */
.page-header { padding: 88px 48px 24px; }
.page-title { font-size: 2rem; font-weight: 800; }
.page-subtitle { color: var(--text-muted); font-size: .9rem; margin-top: 6px; }

.filter-bar {
  display: flex; gap: 10px; flex-wrap: wrap;
  padding: 0 48px 24px;
}
.filter-btn {
  padding: 8px 18px; border-radius: 24px; border: 1px solid var(--border);
  background: var(--bg3); color: var(--text-muted);
  font-size: .82rem; font-weight: 600; cursor: pointer;
  transition: all var(--transition);
}
.filter-btn:hover, .filter-btn.active {
  background: var(--red); color: #fff; border-color: var(--red);
  box-shadow: 0 4px 16px var(--red-glow);
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 16px; padding: 0 48px;
}
.grid-card {
  position: relative; border-radius: var(--radius);
  overflow: hidden; cursor: pointer;
  background: var(--bg3);
  transition: transform .3s ease, box-shadow .3s ease;
}
.grid-card:hover {
  transform: scale(1.05) translateY(-4px);
  box-shadow: 0 16px 48px rgba(0,0,0,.7), 0 0 0 2px rgba(255,255,255,.1);
  z-index: 5;
}
.grid-card .card-img-wrap { aspect-ratio: 2/3; }
.grid-card .card-info { padding: 10px 12px 12px; }

/* =============================================
   DETAIL PAGE
   ============================================= */
.detail-hero {
  position: relative; min-height: 70vh;
  display: flex; align-items: flex-end;
  background-size: cover; background-position: center top;
  padding-top: 68px;
}
.detail-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(
    to right, rgba(0,0,0,.97) 0%, rgba(0,0,0,.7) 50%, rgba(0,0,0,.2) 100%
  ), linear-gradient(to top, var(--bg) 0%, transparent 60%);
}
.detail-content {
  position: relative; z-index: 2;
  display: flex; gap: 40px; align-items: flex-end;
  padding: 0 64px 56px; width: 100%;
}
.detail-poster {
  flex: 0 0 200px; border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-lg);
  border: 2px solid rgba(255,255,255,.1);
}
.detail-poster img { width: 100%; display: block; }
.detail-info { flex: 1; max-width: 620px; }
.detail-title { font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 900; margin-bottom: 12px; line-height: 1.1; letter-spacing: -0.5px; }
.detail-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.detail-meta span {
  padding: 4px 12px; border-radius: 5px;
  font-size: .78rem; font-weight: 600;
  background: var(--bg4); color: #ccc; border: 1px solid var(--border);
}
.detail-plot { color: #bbb; line-height: 1.7; margin-bottom: 24px; font-size: .95rem; }
.detail-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.btn-play.btn-lg { padding: 15px 32px; font-size: 1.05rem; }
.btn-fav {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 24px; border-radius: 8px;
  background: var(--bg4); border: 1px solid var(--border);
  color: #ccc; font-size: .95rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
}
.btn-fav:hover, .btn-fav.is-fav { background: rgba(229,9,20,.15); border-color: var(--red); color: var(--red); }
.detail-crew { font-size: .85rem; color: var(--text-muted); margin-top: 8px; }
.detail-crew strong { color: #ccc; }
.watch-progress { height: 4px; background: var(--bg4); border-radius: 4px; overflow: hidden; margin-top: 16px; }
.watch-progress-bar { height: 100%; background: var(--red); border-radius: 4px; }

/* =============================================
   PLAYER PAGE
   ============================================= */
.player-page { background: #000; min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.player-wrap { position: relative; width: 100%; max-width: 1280px; margin: 0 auto; }
.player-back {
  position: fixed; top: 24px; left: 24px; z-index: 100;
  display: flex; align-items: center; gap: 8px;
  background: rgba(0,0,0,.7); color: #fff; border: none;
  padding: 10px 18px; border-radius: 8px; cursor: pointer;
  font-size: .88rem; font-weight: 600; backdrop-filter: blur(10px);
  transition: all var(--transition);
}
.player-back:hover { background: rgba(255,255,255,.15); }

/* =============================================
   PAGINATION
   ============================================= */
.pagination {
  display: flex; align-items: center; justify-content: center;
  gap: 8px; padding: 40px 48px;
}
.page-btn {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 8px;
  font-size: .88rem; font-weight: 600;
  background: var(--bg3); border: 1px solid var(--border);
  color: #aaa; cursor: pointer; transition: all var(--transition);
  text-decoration: none;
}
.page-btn:hover { background: var(--bg4); color: #fff; border-color: rgba(255,255,255,.2); }
.page-btn.active { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 0 4px 16px var(--red-glow); }

/* =============================================
   AUTH PAGES
   ============================================= */
.auth-page {
  min-height: 100vh; display: flex;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a0a0a 50%, #0a0a0a 100%);
  position: relative; overflow: hidden;
}
.auth-page::before {
  content: ''; position: absolute; inset: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(229,9,20,.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(229,9,20,.05) 0%, transparent 40%);
}
.auth-left {
  flex: 1; display: flex; align-items: center; justify-content: center;
  padding: 60px; position: relative; z-index: 2;
}
.auth-box {
  width: 100%; max-width: 420px;
  background: rgba(15,15,15,.9);
  border: 1px solid var(--border);
  border-radius: 24px; padding: 48px 44px;
  backdrop-filter: blur(20px);
  box-shadow: 0 40px 80px rgba(0,0,0,.6);
}
.auth-logo-wrap { margin-bottom: 36px; }
.auth-logo { font-size: 2rem; font-weight: 900; color: var(--red); letter-spacing: -1px; }
.auth-title { font-size: 1.75rem; font-weight: 800; margin-bottom: 6px; }
.auth-sub { color: var(--text-muted); font-size: .9rem; margin-bottom: 28px; }
.auth-form-group { margin-bottom: 14px; position: relative; }
.auth-form-group label { display: block; font-size: .8rem; font-weight: 600; color: var(--text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .5px; }
.auth-form-group input {
  width: 100%; padding: 14px 16px;
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: 10px; color: #fff; font-size: .95rem;
  transition: all var(--transition); outline: none;
}
.auth-form-group input:focus { border-color: var(--red); background: var(--bg4); box-shadow: 0 0 0 3px var(--red-glow); }
.auth-form-group input::placeholder { color: #444; }
.auth-btn {
  width: 100%; padding: 15px;
  background: var(--red); color: #fff; border: none;
  border-radius: 10px; font-size: 1rem; font-weight: 700;
  cursor: pointer; margin-top: 8px;
  transition: all var(--transition);
  position: relative; overflow: hidden;
}
.auth-btn:hover { background: var(--red-dark); transform: translateY(-1px); box-shadow: 0 8px 24px var(--red-glow); }
.auth-btn:active { transform: translateY(0); }
.auth-btn::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(255,255,255,.1), transparent);
}
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-divider span { font-size: .78rem; color: #444; white-space: nowrap; }
.auth-link-text { text-align: center; font-size: .88rem; color: var(--text-muted); margin-top: 20px; }
.auth-link-text a { color: #fff; font-weight: 600; border-bottom: 1px solid rgba(255,255,255,.2); transition: border-color var(--transition); }
.auth-link-text a:hover { border-color: #fff; }
.auth-alert { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: .85rem; }
.auth-alert.error { background: rgba(229,9,20,.15); border: 1px solid rgba(229,9,20,.3); color: #ff8080; }
.auth-alert.success { background: rgba(34,197,94,.1); border: 1px solid rgba(34,197,94,.2); color: #86efac; }

/* Auth right side — cinematic showcase */
.auth-right {
  flex: 1; position: relative; overflow: hidden;
  display: none;
}
@media (min-width: 900px) { .auth-right { display: block; } }
.auth-showcase {
  position: absolute; inset: 0;
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 12px; padding: 24px; transform: rotate(-5deg) scale(1.15);
  opacity: .4; filter: blur(1px);
}
.showcase-col { display: flex; flex-direction: column; gap: 12px; }
.showcase-col:nth-child(2) { margin-top: -60px; }
.showcase-col:nth-child(3) { margin-top: -30px; }
.showcase-poster { border-radius: 10px; overflow: hidden; aspect-ratio: 2/3; background: var(--bg3); }
.showcase-poster img { width: 100%; height: 100%; object-fit: cover; }
.auth-right-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to right, var(--bg) 0%, transparent 30%, transparent 70%, var(--bg) 100%),
              linear-gradient(to bottom, var(--bg) 0%, transparent 20%, transparent 80%, var(--bg) 100%);
}

/* =============================================
   PROFILE SELECT
   ============================================= */
.profiles-page {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  background: radial-gradient(ellipse at center top, rgba(229,9,20,.06) 0%, var(--bg) 60%);
  padding: 40px 20px;
}
.profiles-logo { font-size: 1.8rem; font-weight: 900; color: var(--red); margin-bottom: 48px; letter-spacing: -1px; }
.profiles-title { font-size: 2.2rem; font-weight: 700; margin-bottom: 48px; color: #e0e0e0; }
.profiles-grid { display: flex; gap: 24px; flex-wrap: wrap; justify-content: center; margin-bottom: 40px; }
.profile-item {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  cursor: pointer; transition: transform var(--transition);
}
.profile-item:hover { transform: scale(1.05); }
.profile-avatar-lg {
  width: 112px; height: 112px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem; border: 3px solid transparent;
  transition: all var(--transition);
  background: linear-gradient(135deg, var(--bg3), var(--bg4));
  box-shadow: 0 8px 24px rgba(0,0,0,.4);
}
.profile-item:hover .profile-avatar-lg { border-color: #fff; box-shadow: 0 12px 32px rgba(0,0,0,.6); }
.profile-item-name { font-size: .9rem; color: #aaa; font-weight: 500; transition: color var(--transition); }
.profile-item:hover .profile-item-name { color: #fff; }
.profile-add .profile-avatar-lg { border: 3px dashed var(--bg4); color: #555; font-size: 2.5rem; }
.profile-add:hover .profile-avatar-lg { border-color: #888; color: #aaa; }
.profile-manage-btn {
  padding: 10px 28px; border: 1px solid #555; border-radius: 6px;
  color: #aaa; font-size: .9rem; font-weight: 600; cursor: pointer;
  background: transparent; transition: all var(--transition);
}
.profile-manage-btn:hover { border-color: #aaa; color: #fff; }

/* =============================================
   DEVICE CHOOSER
   ============================================= */
.device-page {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 40px 20px;
  background: radial-gradient(ellipse at 50% 0%, rgba(229,9,20,.08) 0%, var(--bg) 60%);
}
.device-title { font-size: 2.2rem; font-weight: 800; margin-bottom: 8px; text-align: center; }
.device-sub { color: var(--text-muted); margin-bottom: 48px; text-align: center; }
.device-grid { display: flex; gap: 20px; flex-wrap: wrap; justify-content: center; max-width: 800px; }
.device-card {
  flex: 0 0 220px; padding: 36px 28px; text-align: center;
  background: var(--bg3); border: 2px solid var(--border);
  border-radius: var(--radius-lg); cursor: pointer;
  transition: all .25s ease;
}
.device-card:hover, .device-card.selected {
  border-color: var(--red); background: rgba(229,9,20,.08);
  transform: translateY(-6px); box-shadow: 0 20px 60px rgba(229,9,20,.2);
}
.device-icon { font-size: 3.5rem; margin-bottom: 16px; }
.device-name { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.device-desc { font-size: .82rem; color: var(--text-muted); line-height: 1.5; }

/* =============================================
   LANDING PAGE
   ============================================= */
.landing-hero {
  min-height: 100vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, #0a0a0a 0%, #180808 50%, #0a0a0a 100%);
}
.landing-bg {
  position: absolute; inset: 0; overflow: hidden;
}
.landing-bg::before {
  content: ''; position: absolute;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(229,9,20,.12) 0%, transparent 70%);
  top: -200px; right: -200px; border-radius: 50%;
}
.landing-bg::after {
  content: ''; position: absolute;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(229,9,20,.06) 0%, transparent 70%);
  bottom: -100px; left: -100px; border-radius: 50%;
}
.floating-cards {
  position: absolute; right: 0; top: 0; bottom: 0; width: 55%;
  display: grid; grid-template-columns: repeat(4,1fr);
  gap: 10px; padding: 40px; transform: perspective(800px) rotateY(-12deg);
  opacity: .35; pointer-events: none;
}
.floating-col { display: flex; flex-direction: column; gap: 10px; }
.floating-col:nth-child(odd) { margin-top: 40px; }
.floating-poster { border-radius: 8px; overflow: hidden; aspect-ratio: 2/3; background: var(--bg3); }
.floating-poster img { width: 100%; height: 100%; object-fit: cover; }
.landing-overlay {
  position: absolute; right: 0; top: 0; bottom: 0; width: 55%;
  background: linear-gradient(to right, var(--bg) 0%, transparent 40%, var(--bg) 100%),
              linear-gradient(to bottom, var(--bg) 0%, transparent 15%, transparent 85%, var(--bg) 100%);
}
.landing-content {
  position: relative; z-index: 2; padding: 80px 80px;
  max-width: 620px;
}
.landing-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(229,9,20,.15); border: 1px solid rgba(229,9,20,.3);
  color: var(--red); padding: 6px 16px; border-radius: 24px;
  font-size: .78rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 1px; margin-bottom: 24px;
}
.landing-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 900; line-height: 1.05;
  letter-spacing: -2px; margin-bottom: 20px;
}
.landing-title .highlight { color: var(--red); }
.landing-desc { font-size: 1.05rem; color: #aaa; line-height: 1.7; margin-bottom: 36px; }
.landing-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 48px; }
.btn-cta-primary {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--red); color: #fff;
  padding: 16px 32px; border-radius: 10px;
  font-size: 1rem; font-weight: 700; border: none; cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 8px 32px var(--red-glow);
}
.btn-cta-primary:hover { background: var(--red-dark); transform: translateY(-2px); box-shadow: 0 16px 48px var(--red-glow); }
.btn-cta-secondary {
  display: inline-flex; align-items: center; gap: 10px;
  background: transparent; color: #fff;
  padding: 16px 32px; border-radius: 10px;
  font-size: 1rem; font-weight: 600;
  border: 1px solid rgba(255,255,255,.2); cursor: pointer;
  transition: all var(--transition);
}
.btn-cta-secondary:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.35); }
.landing-stats { display: flex; gap: 32px; }
.stat-item .val { font-size: 1.6rem; font-weight: 900; color: #fff; }
.stat-item .lbl { font-size: .78rem; color: #555; font-weight: 500; margin-top: 2px; }

/* Landing Features Section */
.landing-features {
  padding: 100px 80px;
  background: linear-gradient(to bottom, var(--bg), var(--bg2));
}
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fill,minmax(260px,1fr));
  gap: 24px; max-width: 1100px; margin: 0 auto;
}
.feature-card {
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 32px;
  transition: all .25s ease;
}
.feature-card:hover { border-color: rgba(229,9,20,.3); transform: translateY(-4px); box-shadow: 0 16px 48px rgba(0,0,0,.4); }
.feature-icon { font-size: 2.2rem; margin-bottom: 16px; }
.feature-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.feature-desc { font-size: .85rem; color: var(--text-muted); line-height: 1.6; }

/* =============================================
   SEASONS / EPISODES
   ============================================= */
.seasons-section { padding: 48px; }
.seasons-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 20px; }
.season-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.season-tab {
  padding: 8px 20px; border-radius: 24px;
  background: var(--bg3); border: 1px solid var(--border);
  font-size: .85rem; font-weight: 600; color: var(--text-muted);
  cursor: pointer; transition: all var(--transition);
}
.season-tab:hover, .season-tab.active { background: var(--red); border-color: var(--red); color: #fff; }
.episodes-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(300px,1fr)); gap: 16px; }
.episode-card {
  display: flex; gap: 14px; padding: 14px;
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: var(--radius); cursor: pointer;
  transition: all var(--transition);
}
.episode-card:hover { background: var(--bg4); border-color: rgba(255,255,255,.15); transform: translateX(4px); }
.ep-thumb { flex: 0 0 120px; border-radius: 6px; overflow: hidden; aspect-ratio: 16/9; background: var(--bg4); }
.ep-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ep-info { flex: 1; min-width: 0; }
.ep-num { font-size: .72rem; font-weight: 700; color: var(--red); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 4px; }
.ep-title { font-size: .88rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 6px; }
.ep-desc { font-size: .78rem; color: var(--text-muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* =============================================
   SEARCH
   ============================================= */
.search-page { padding: 96px 48px 60px; }
.search-header { margin-bottom: 32px; }
.search-query { font-size: 1.5rem; font-weight: 700; }
.search-query span { color: var(--red); }
.search-count { color: var(--text-muted); font-size: .88rem; margin-top: 4px; }
.search-section-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 16px; margin-top: 32px; padding-bottom: 10px; border-bottom: 1px solid var(--border); }

/* =============================================
   TOAST NOTIFICATIONS
   ============================================= */
.toast-wrap { position: fixed; bottom: 24px; right: 24px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast {
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: 10px; padding: 14px 20px;
  font-size: .88rem; font-weight: 500;
  box-shadow: var(--shadow); min-width: 240px;
  display: flex; align-items: center; gap: 10px;
  animation: toastIn .3s ease both;
}
.toast.success { border-color: rgba(34,197,94,.3); }
.toast.error   { border-color: rgba(229,9,20,.3); }
@keyframes toastIn { from { opacity:0; transform: translateX(20px); } to { opacity:1; transform: translateX(0); } }

/* =============================================
   SKELETON LOADING
   ============================================= */
@keyframes shimmer {
  0%   { background-position: -600px 0; }
  100% { background-position: 600px 0; }
}
.skeleton {
  background: linear-gradient(90deg, var(--bg3) 25%, var(--bg4) 50%, var(--bg3) 75%);
  background-size: 600px 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 6px;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
  .navbar { padding: 0 20px; height: 56px; }
  .nav-links { display: none; }
  .hero-content { padding: 0 24px 56px; }
  .hero-title { font-size: 1.8rem; }
  .hero-actions .btn-info { display: none; }
  .row-header, .cats-wrap { padding: 0 20px; }
  .carousel { padding: 8px 20px 16px; }
  .card { flex: 0 0 130px; }
  .grid-container { grid-template-columns: repeat(auto-fill,minmax(130px,1fr)); padding: 0 20px; gap: 10px; }
  .page-header { padding: 76px 20px 16px; }
  .filter-bar { padding: 0 20px 16px; }
  .detail-content { flex-direction: column; padding: 0 24px 40px; }
  .detail-poster { flex: 0 0 auto; width: 140px; }
  .landing-content { padding: 80px 24px; }
  .landing-features { padding: 60px 24px; }
  .auth-box { padding: 36px 28px; }
}
