/* Reel Me — DramaBox-matched dark short-drama shell */
:root {
  --bg: #0f0f13;
  --bg-elevated: #16161d;
  --panel: #1a1a22;
  --ink: #f1f5f9;
  --muted: #94a3b8;
  --dim: #64748b;
  --line: #1e293b;
  --amber: #f59e0b;
  --amber-bright: #fbbf24;
  --amber-dim: rgba(245, 158, 11, 0.2);
  --amber-border: rgba(245, 158, 11, 0.4);
  --slate-950: #020617;
  --pink: #db2777;
  --warn: #f87171;
  --ok: #34d399;
  --radius: 16px;
  --radius-sm: 12px;
  --font: "Outfit", system-ui, sans-serif;
  color: var(--ink);
  font-family: var(--font);
  background: var(--bg);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: #07070a;
}

body {
  min-height: 100vh;
  display: grid;
  place-items: stretch center;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

.shell {
  position: relative;
  width: min(420px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 0 0 88px;
  background: var(--bg);
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

@media (min-width: 720px) {
  body {
    padding: 28px 16px;
    place-items: start center;
  }
  .shell {
    width: min(420px, 100%);
    min-height: min(844px, calc(100vh - 56px));
    border: 8px solid #1e293b;
    border-radius: 40px;
    box-shadow: 0 0 60px rgba(217, 119, 6, 0.1);
    overflow: hidden;
  }
}

.haze,
.grain {
  display: none;
}

@keyframes settle {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(24px);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}

@keyframes toast-bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

.view,
.app-nav,
.top-chrome {
  position: relative;
  z-index: 1;
}

.view {
  flex: 1;
  padding: 12px 20px 24px;
  overflow-y: auto;
  animation: settle 0.35s ease-out;
}

.view.hidden,
.hidden {
  display: none !important;
}

.wordmark {
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--ink);
  line-height: 1;
}

.wordmark.compact {
  font-size: 1.15rem;
}

.wordmark.quiet {
  opacity: 0.85;
}

.screen-title {
  margin: 12px 0 0;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--ink);
}

.meta-label,
.section-label {
  margin: 22px 0 0;
  color: var(--dim);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.muted {
  color: var(--muted);
  font-size: 0.85rem;
}

.support {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.error {
  margin-top: 10px;
  color: var(--warn);
  font-weight: 600;
  font-size: 0.88rem;
}

.ok-msg {
  margin-top: 10px;
  color: var(--ok);
  font-weight: 600;
  font-size: 0.88rem;
}

.api-hint {
  text-align: center;
  margin-top: 8px;
  font-size: 0.75rem;
  color: var(--dim);
}

/* ——— Top chrome: search + coins ——— */
.top-chrome {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 44px 20px 12px;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  border-bottom: 1px solid #111827;
  position: sticky;
  top: 0;
  z-index: 15;
  backdrop-filter: blur(12px);
}

.top-chrome.hidden-chrome {
  display: none;
}

.browse-search-wrap {
  position: relative;
  flex: 1;
}

.browse-search {
  width: 100%;
  min-height: 42px;
  padding: 10px 36px 10px 40px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #0f172a;
  font: inherit;
  font-size: 0.78rem;
  color: var(--ink);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.35);
}

.browse-search:focus {
  outline: none;
  border-color: var(--amber);
}

.browse-search::placeholder {
  color: #64748b;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  color: var(--amber);
  pointer-events: none;
}

.search-clear {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--dim);
  cursor: pointer;
  font: inherit;
  font-size: 0.85rem;
  display: grid;
  place-items: center;
}

.coin-badge {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 16px;
  border: 1px solid var(--amber-border);
  background: linear-gradient(
    90deg,
    rgba(245, 158, 11, 0.2),
    rgba(234, 179, 8, 0.2)
  );
  color: #fcd34d;
  font-weight: 800;
  font-size: 0.75rem;
  cursor: pointer;
  font: inherit;
  transition: transform 0.15s ease;
}

.coin-badge:hover {
  transform: scale(1.04);
}

.coin-badge .coin-glyph {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--amber);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
}

/* ——— Bottom nav ——— */
.app-nav {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 12px calc(8px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 95%, transparent);
  border-top: 1px solid #111827;
  backdrop-filter: blur(16px);
  z-index: 20;
}

.app-nav.hidden {
  display: none;
}

.shell.nav-hidden .view {
  padding-bottom: calc(24px + env(safe-area-inset-bottom));
}

.nav-btn {
  border: 0;
  background: transparent;
  font: inherit;
  font-weight: 600;
  font-size: 0.62rem;
  padding: 8px 6px;
  color: #64748b;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 56px;
  transition: color 0.15s ease, transform 0.15s ease;
}

.nav-btn .nav-icon {
  font-size: 1.05rem;
  line-height: 1;
}

.nav-btn.active {
  color: var(--amber);
  transform: scale(1.05);
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 48px;
  margin-top: 12px;
  padding: 12px 16px;
  border: 0;
  border-radius: 14px;
  font: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  color: var(--ink);
  background: transparent;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn.primary {
  background: linear-gradient(90deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  box-shadow: 0 10px 25px rgba(245, 158, 11, 0.28);
}

.btn.secondary {
  background: #0f172a;
  border: 1px solid var(--amber-border);
  color: #fcd34d;
}

.btn.ghost {
  background: transparent;
  color: var(--muted);
}

.linkback {
  border: 0;
  background: transparent;
  font: inherit;
  font-weight: 500;
  color: var(--muted);
  padding: 0;
  cursor: pointer;
  margin-bottom: 4px;
}

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

/* ——— Home hero + grid ——— */
.home-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 8px 0 14px;
}

.home-section-head h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.see-all {
  border: 0;
  background: transparent;
  color: var(--amber);
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

.browse-hero {
  margin-top: 4px;
  width: 100%;
  min-height: 200px;
  border: 1px solid var(--amber-border);
  border-radius: 24px;
  padding: 0;
  overflow: hidden;
  position: relative;
  display: block;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  background: linear-gradient(135deg, #1e1b4b, #0f172a 50%, #451a03);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

.browse-hero-art {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.55;
}

.browse-hero-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    transparent 20%,
    rgba(15, 15, 19, 0.85) 100%
  );
}

.browse-hero-body {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  align-content: end;
  min-height: 200px;
  padding: 22px 20px 20px;
}

.browse-hero-badge {
  justify-self: start;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--amber);
  color: #0f172a;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 0 8px 16px rgba(245, 158, 11, 0.25);
}

.browse-hero-title {
  font-weight: 900;
  font-size: 1.45rem;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.browse-hero-meta {
  font-size: 0.78rem;
  color: #cbd5e1;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.browse-hero-cta {
  justify-self: start;
  margin-top: 6px;
  padding: 10px 18px;
  border-radius: 12px;
  background: linear-gradient(90deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  font-size: 0.75rem;
  font-weight: 800;
}

.browse-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  margin: 4px 0 8px;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.browse-tabs::-webkit-scrollbar {
  display: none;
}

.browse-tab {
  flex: 0 0 auto;
  border: 1px solid #1e293b;
  background: #0f172a;
  color: #cbd5e1;
  font: inherit;
  font-weight: 600;
  font-size: 0.75rem;
  padding: 8px 14px;
  border-radius: 12px;
  cursor: pointer;
  white-space: nowrap;
}

.browse-tab.selected {
  background: var(--amber);
  border-color: var(--amber);
  color: #0f172a;
  box-shadow: 0 8px 16px rgba(245, 158, 11, 0.2);
}

.continue-strip {
  margin: 12px 0 4px;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--amber-border);
  background: #0f172a;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
}

.continue-copy {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 2px;
}

.continue-label {
  color: var(--amber);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.continue-title {
  color: var(--ink);
  font-weight: 700;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.continue-chevron {
  color: var(--amber);
  font-weight: 700;
}

.empty-search {
  margin-top: 36px;
  text-align: center;
}

.empty-search .empty-title {
  margin: 0 0 14px;
  font-size: 0.95rem;
  font-weight: 700;
  color: #cbd5e1;
}

/* 2-col DramaBox poster cards on Home */
.poster-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 4px;
}

.poster-card {
  border: 1px solid #1e293b;
  padding: 0;
  background: #0f172a;
  border-radius: 16px;
  overflow: hidden;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  width: 100%;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease;
}

.poster-card:hover {
  border-color: var(--amber-border);
}

.poster-art {
  aspect-ratio: 3 / 4.2;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  background-color: #1e293b;
}

.poster-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(2, 6, 23, 0.85));
}

.poster-rating {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  color: #fcd34d;
  font-size: 0.65rem;
  font-weight: 700;
}

.poster-views {
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 2;
  color: #cbd5e1;
  font-size: 0.7rem;
  font-weight: 600;
}

.poster-body {
  padding: 10px 12px 12px;
}

.poster-title {
  color: var(--ink);
  font-weight: 700;
  font-size: 0.78rem;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster-genre {
  margin-top: 4px;
  color: var(--dim);
  font-size: 0.65rem;
}

.tone-briar-mist {
  background: linear-gradient(160deg, #312e81, #1e1b4b 80%);
}
.tone-mist-teal {
  background: linear-gradient(160deg, #0f766e, #134e4a 85%);
}
.tone-slate-amber {
  background: linear-gradient(160deg, #78350f, #451a03 85%);
}
.tone-ember-ink {
  background: linear-gradient(160deg, #334155, #0f172a 85%);
}

/* Discover list rows */
.discover-list {
  display: grid;
  gap: 14px;
  margin-top: 8px;
}

.discover-row {
  display: flex;
  gap: 14px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: color-mix(in srgb, #0f172a 80%, transparent);
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  width: 100%;
  transition: border-color 0.15s ease;
}

.discover-row:hover {
  border-color: rgba(245, 158, 11, 0.4);
}

.discover-thumb {
  width: 80px;
  height: 112px;
  flex-shrink: 0;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  background-color: #1e293b;
}

.discover-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}

.discover-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ep-chip {
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--amber-dim);
  color: #fcd34d;
  font-size: 0.65rem;
  font-weight: 700;
}

.rating-chip {
  color: var(--amber);
  font-size: 0.7rem;
  font-weight: 700;
}

.discover-title {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink);
}

.discover-premise {
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Search result rows */
.search-results {
  display: grid;
  gap: 12px;
  margin-top: 8px;
}

.search-count {
  margin: 0 0 4px;
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
}

.search-row {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #0f172a;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
  width: 100%;
}

.search-thumb {
  width: 64px;
  height: 96px;
  border-radius: 12px;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
  background-color: #1e293b;
}

/* My List */
.watchlist-card {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--amber-border);
  background: #0f172a;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
  width: 100%;
}

.watchlist-thumb {
  width: 80px;
  height: 112px;
  border-radius: 12px;
  flex-shrink: 0;
  background: linear-gradient(160deg, #78350f, #1e293b);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 8px;
  color: #fcd34d;
  font-size: 0.75rem;
  font-weight: 700;
}

.progress-track-thin {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: #1e293b;
  overflow: hidden;
  margin-top: 10px;
}

.progress-track-thin > span {
  display: block;
  height: 100%;
  width: 66%;
  background: linear-gradient(90deg, var(--amber), var(--amber-bright));
}

/* Profile / Settings */
.profile-card {
  margin-top: 8px;
  padding: 20px;
  border-radius: 24px;
  border: 1px solid var(--amber-border);
  background: linear-gradient(135deg, rgba(120, 53, 15, 0.4), #0f172a);
  display: flex;
  align-items: center;
  gap: 14px;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  border: 0;
  background: linear-gradient(135deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  font-weight: 900;
  box-shadow: 0 10px 24px rgba(245, 158, 11, 0.25);
  cursor: pointer;
  flex-shrink: 0;
  font-family: inherit;
}

.profile-copy {
  flex: 1;
  min-width: 0;
}

.profile-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-name {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}

.profile-id {
  margin: 4px 0 0;
  font-size: 0.75rem;
  color: #fcd34d;
  font-weight: 600;
}

.member-pill {
  display: inline-block;
  margin-top: 8px;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid var(--amber-border);
  background: var(--amber-dim);
  color: #fcd34d;
  font-size: 0.65rem;
  font-weight: 700;
}

.vip-badge {
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--amber);
  color: #0f172a;
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.login-btn {
  flex-shrink: 0;
  padding: 10px 18px;
  border-radius: 16px;
  border: 0;
  background: linear-gradient(90deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(245, 158, 11, 0.25);
}

.vip-upgrade-banner {
  margin-top: 16px;
  width: 100%;
  padding: 18px;
  border-radius: 24px;
  border: 0;
  background: linear-gradient(90deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  cursor: pointer;
  font: inherit;
  box-shadow: 0 12px 28px rgba(245, 158, 11, 0.28);
}

.vip-upgrade-label {
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.vip-upgrade-banner h4 {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}

.vip-upgrade-banner p {
  margin: 4px 0 0;
  font-size: 0.72rem;
  opacity: 0.9;
}

.vip-upgrade-cta {
  flex-shrink: 0;
  padding: 10px 14px;
  border-radius: 16px;
  background: #0f172a;
  color: #fcd34d;
  font-size: 0.72rem;
  font-weight: 700;
}

.row-chevron {
  color: #64748b;
}

.settings-row.danger {
  color: #f87171;
  font-weight: 700;
}

.store-section-label {
  margin: 18px 0 8px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
}

.store-section-label.amber {
  color: #fbbf24;
}

.wallet-account {
  margin: 0 0 6px;
  font-size: 0.72rem;
  color: #94a3b8;
}

.vip-chip {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--amber);
  color: #0f172a;
  font-size: 0.58rem;
  font-weight: 900;
  vertical-align: middle;
}

.vip-pass-row {
  border-color: var(--amber-border);
  background: linear-gradient(
    90deg,
    rgba(245, 158, 11, 0.14),
    #020617 55%
  );
}

.wallet-banner {
  margin-top: 16px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid var(--amber-border);
  background: linear-gradient(
    90deg,
    rgba(245, 158, 11, 0.2),
    rgba(245, 158, 11, 0.08),
    #0f172a
  );
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  width: 100%;
  font: inherit;
  color: inherit;
  text-align: left;
}

.wallet-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: var(--amber-dim);
  display: grid;
  place-items: center;
  color: var(--amber);
  font-size: 1.25rem;
}

.topup-btn {
  padding: 8px 14px;
  border-radius: 12px;
  border: 0;
  background: var(--amber);
  color: #0f172a;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 800;
  cursor: pointer;
}

.settings-menu {
  margin-top: 18px;
  border-radius: 24px;
  border: 1px solid #1e293b;
  background: #0f172a;
  overflow: hidden;
}

.settings-row {
  width: 100%;
  min-height: 52px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border: 0;
  border-bottom: 1px solid color-mix(in srgb, #1e293b 80%, transparent);
  background: transparent;
  font: inherit;
  color: #cbd5e1;
  padding: 14px 16px;
  text-align: left;
  cursor: pointer;
}

.settings-row:last-child {
  border-bottom: 0;
}

.settings-row.static {
  cursor: default;
}

.row-value {
  color: var(--dim);
  font-weight: 500;
}

.toggle-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding: 14px 16px;
  border-bottom: 1px solid color-mix(in srgb, #1e293b 80%, transparent);
}

.toggle-label {
  font-weight: 600;
  color: #cbd5e1;
}

.toggle-hint {
  margin: 4px 0 0;
  color: var(--dim);
  font-size: 0.78rem;
  line-height: 1.35;
}

.switch {
  position: relative;
  width: 46px;
  height: 28px;
  flex: 0 0 auto;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-ui {
  position: absolute;
  inset: 0;
  background: #1e293b;
  border-radius: 999px;
  transition: background 0.2s ease;
}

.switch-ui::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  left: 3px;
  top: 3px;
  background: #e2e8f0;
  border-radius: 50%;
  transition: transform 0.2s ease;
}

.switch input:checked + .switch-ui {
  background: var(--amber);
}

.switch input:checked + .switch-ui::after {
  transform: translateX(18px);
}

/* Continue / generating / classic panels */
.story-title {
  margin: 6px 0 0;
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.player-frame,
.player-wrap {
  margin-top: 16px;
  aspect-ratio: 16 / 9;
  width: 100%;
  border-radius: var(--radius-sm);
  background: linear-gradient(160deg, #1e293b, #020617);
  border: 1px solid #1e293b;
  position: relative;
  overflow: hidden;
  color: var(--ink);
}

.player-frame {
  display: grid;
  place-items: center;
  cursor: pointer;
  font: inherit;
  padding: 0;
}

.player-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(15, 15, 19, 0.7);
  color: #fcd34d;
}

.player-play {
  font-size: 1.4rem;
  opacity: 0.9;
}

.player-wrap video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #020617;
}

.status-copy,
.unlock-meta {
  margin-top: 14px;
  color: #cbd5e1;
  font-size: 0.92rem;
  line-height: 1.4;
}

.soft-chip {
  display: inline-block;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.quota-banner {
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--amber-dim);
  color: #fcd34d;
  font-size: 0.85rem;
}

.progress-track {
  margin-top: 22px;
  height: 4px;
  background: #1e293b;
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: var(--amber);
  transition: width 0.35s ease;
}

.stages {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.stages li {
  display: flex;
  gap: 10px;
  color: var(--dim);
  font-size: 0.92rem;
}

.stages li.done {
  color: var(--ok);
}
.stages li.active {
  color: var(--ink);
  font-weight: 600;
}

.fail-panel {
  margin-top: 16px;
  padding: 12px;
  border-radius: var(--radius-sm);
  background: rgba(248, 113, 113, 0.1);
}

.choice-prompt {
  margin: 20px 0 0;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.choice-options {
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.choice-opt {
  border: 1px solid #1e293b;
  background: #0f172a;
  border-radius: var(--radius-sm);
  padding: 14px;
  text-align: left;
  font: inherit;
  cursor: pointer;
  color: inherit;
}

.choice-opt.selected {
  border-color: var(--amber);
  box-shadow: inset 0 0 0 1px var(--amber);
}

.choice-opt .hint {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.85rem;
}

.pack-list,
.plan-list {
  margin-top: 18px;
  display: grid;
  gap: 10px;
}

.pack-row,
.plan-row {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 16px;
  background: #0f172a;
  border: 1px solid #1e293b;
}

.pack-row.popular,
.plan-row.popular {
  border-color: var(--amber);
  background: rgba(120, 53, 15, 0.25);
  box-shadow: 0 8px 20px rgba(245, 158, 11, 0.1);
}

.pack-row-top,
.plan-row-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.badge {
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--amber-dim);
  padding: 2px 8px;
  border-radius: 999px;
}

.plan-perks {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.balance-line {
  margin-top: 12px;
  font-size: 1rem;
  color: #cbd5e1;
}

.download-row {
  margin-top: 12px;
  display: grid;
  gap: 6px;
}

.attribution {
  margin-top: 12px;
  color: var(--dim);
  font-size: 0.8rem;
}

/* ——— Vertical player chrome (episode) ——— */
.view[data-view="episode"] {
  padding: 0;
  position: relative;
  min-height: calc(100vh - 80px);
  background: #020617;
  overflow: hidden;
}

@media (min-width: 720px) {
  .view[data-view="episode"] {
    min-height: calc(844px - 80px - 16px);
  }
}

.ep-stage {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #1e1b4b, #0f0f13 55%, rgba(120, 53, 15, 0.35));
  display: flex;
  flex-direction: column;
}

.ep-stage-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse at top,
    rgba(245, 158, 11, 0.22),
    transparent 55%
  );
}

.ep-topbar {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 44px 16px 12px;
  background: linear-gradient(180deg, rgba(15, 15, 19, 0.9), transparent);
}

.ep-topbar-end {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.ep-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  color: white;
  cursor: pointer;
  font: inherit;
  display: grid;
  place-items: center;
}

#btn-ep-overflow {
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  line-height: 1;
}

.ep-selector-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--amber-border);
  background: rgba(15, 23, 42, 0.6);
  color: white;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.ep-selector-btn span.chev {
  color: var(--amber);
}

.ep-center {
  position: relative;
  z-index: 2;
  flex: 1;
  display: grid;
  place-items: center;
  padding: 20px;
  text-align: center;
  cursor: pointer;
}

.ep-play-orb {
  width: 80px;
  height: 80px;
  border-radius: 999px;
  border: 1px solid var(--amber-border);
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(12px);
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  font-size: 1.6rem;
  color: var(--amber);
}

.ep-center h3 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
}

.ep-center .ep-num {
  margin: 6px 0 0;
  color: var(--amber);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ep-center .ep-hint {
  margin: 8px 0 0;
  color: var(--dim);
  font-size: 0.75rem;
}

.ep-video-slot {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: none;
}

.ep-video-slot.active {
  display: block;
}

.ep-video-slot video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.ep-actions {
  position: absolute;
  right: 14px;
  bottom: 140px;
  z-index: 6;
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: center;
}

.ep-action {
  border: 0;
  background: transparent;
  color: white;
  font: inherit;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.ep-action-orb {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  display: grid;
  place-items: center;
  font-size: 1.15rem;
}

.ep-action.liked .ep-action-orb {
  background: var(--pink);
  border-color: transparent;
  box-shadow: 0 0 20px rgba(236, 72, 153, 0.55);
}

.ep-action span {
  font-size: 0.7rem;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.ep-bottom {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  padding: 64px 20px 24px;
  background: linear-gradient(
    0deg,
    #0f0f13,
    rgba(15, 15, 19, 0.8) 55%,
    transparent
  );
  pointer-events: none;
}

.ep-bottom > * {
  pointer-events: auto;
}

.hit-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--amber);
  color: #0f172a;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ep-genre {
  margin-left: 8px;
  color: #fcd34d;
  font-size: 0.75rem;
  font-weight: 600;
}

.ep-bottom h4 {
  margin: 8px 0 4px;
  font-size: 1rem;
  font-weight: 800;
  max-width: 280px;
}

.ep-bottom p.synopsis {
  margin: 0;
  max-width: 280px;
  color: #cbd5e1;
  font-size: 0.75rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ep-next-row {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--dim);
}

.ep-next-row button {
  border: 0;
  background: transparent;
  color: var(--amber);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.ep-cta-stack {
  position: relative;
  z-index: 7;
  padding: 0 20px 20px;
  display: grid;
  gap: 8px;
}

.ep-cta-stack .btn {
  margin-top: 0;
}

/* Paywall overlay */
.paywall {
  position: absolute;
  inset: 0;
  z-index: 30;
  background: rgba(15, 15, 19, 0.92);
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  animation: fadeIn 0.25s ease;
}

.paywall.hidden {
  display: none !important;
}

.paywall-lock {
  width: 80px;
  height: 80px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  display: grid;
  place-items: center;
  font-size: 2rem;
  margin-bottom: 20px;
  box-shadow: 0 0 30px rgba(245, 158, 11, 0.4);
}

.premium-pill {
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--amber-border);
  background: var(--amber-dim);
  color: #fcd34d;
  font-size: 0.7rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.paywall h2 {
  margin: 0 0 8px;
  font-size: 1.45rem;
  font-weight: 900;
}

.paywall p {
  margin: 0 0 24px;
  max-width: 280px;
  color: #cbd5e1;
  font-size: 0.85rem;
  line-height: 1.45;
}

.paywall .shop-link {
  margin-top: 18px;
  border: 0;
  background: transparent;
  color: var(--dim);
  font: inherit;
  font-size: 0.75rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  cursor: pointer;
}

/* Modals */
.modal-scrim {
  position: absolute;
  inset: 0;
  z-index: 50;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  animation: fadeIn 0.2s ease;
}

.modal-scrim.center {
  justify-content: center;
  padding: 20px;
}

.modal-sheet {
  background: #0f172a;
  border-top: 1px solid #1e293b;
  border-radius: 32px 32px 0 0;
  max-height: 60vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -20px 40px rgba(0, 0, 0, 0.4);
  animation: slideUp 0.25s ease;
}

.modal-card {
  background: #0f172a;
  border: 1px solid var(--amber-border);
  border-radius: 24px;
  padding: 24px;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  animation: slideUp 0.25s ease;
}

.modal-head {
  padding: 16px;
  border-bottom: 1px solid #1e293b;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-head h3 {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
}

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 0;
  background: #1e293b;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
}

.modal-back {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 0;
  background: #1e293b;
  color: #e2e8f0;
  cursor: pointer;
  font: inherit;
  display: grid;
  place-items: center;
  margin-right: 4px;
}

.modal-head:has(.modal-back:not(.hidden)) h3 {
  flex: 1;
}

.player-menu-list {
  display: grid;
  gap: 6px;
  padding: 4px 0;
}

.player-menu-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 13px 14px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #e2e8f0;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.player-menu-row:hover {
  border-color: rgba(245, 158, 11, 0.45);
}

.player-menu-row.active {
  border-color: var(--amber);
  background: rgba(120, 53, 15, 0.28);
  color: var(--amber);
}

.player-menu-row .menu-meta {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
}

.player-menu-row.active .menu-meta {
  color: var(--amber);
}

.player-menu-note {
  margin: 4px 2px 10px;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.4;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
}

.comment-row {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.comment-avatar {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  display: grid;
  place-items: center;
  font-size: 0.7rem;
  font-weight: 800;
  flex-shrink: 0;
}

.comment-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
}

.comment-meta strong {
  font-size: 0.75rem;
  color: #cbd5e1;
}

.comment-meta span {
  font-size: 0.65rem;
  color: var(--dim);
}

.comment-meta + p {
  margin: 0;
  font-size: 0.78rem;
  color: #e2e8f0;
  line-height: 1.4;
}

.comment-form {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid #1e293b;
  background: #020617;
}

.comment-form input {
  flex: 1;
  border: 1px solid #1e293b;
  background: #0f172a;
  border-radius: 12px;
  padding: 10px 14px;
  color: white;
  font: inherit;
  font-size: 0.8rem;
}

.comment-form button {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: var(--amber);
  color: #0f172a;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.ep-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.ep-cell {
  height: 56px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #1e293b;
  color: white;
  font: inherit;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
}

.ep-cell.current {
  background: linear-gradient(135deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  border-color: transparent;
  box-shadow: 0 8px 18px rgba(245, 158, 11, 0.3);
}

.ep-cell.locked {
  background: #020617;
  color: #64748b;
}

.ep-cell .lock-dot {
  position: absolute;
  top: 6px;
  right: 8px;
  font-size: 0.65rem;
  color: var(--amber);
}

.ep-cell .play-lbl {
  font-size: 0.58rem;
  font-weight: 500;
  color: #fcd34d;
}

.ep-cell.current .play-lbl {
  color: #0f172a;
  font-weight: 700;
}

.toast {
  position: absolute;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  padding: 12px 18px;
  border-radius: 16px;
  border: 1px solid rgba(251, 191, 36, 0.3);
  background: linear-gradient(90deg, #7c3aed, var(--amber));
  color: white;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  animation: toast-bounce 1.2s ease infinite;
  white-space: nowrap;
  max-width: calc(100% - 40px);
  overflow: hidden;
  text-overflow: ellipsis;
}

.wallet-hero {
  text-align: center;
  margin-bottom: 20px;
}

.wallet-hero .wallet-orb {
  width: 64px;
  height: 64px;
  margin: 0 auto 12px;
  border-radius: 16px;
  border: 1px solid var(--amber-border);
  background: var(--amber-dim);
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  color: var(--amber);
}

.wallet-hero h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 900;
}

.wallet-hero p {
  margin: 6px 0 0;
  font-size: 0.78rem;
  color: var(--muted);
}

/* Auth modal (Verify Account) */
.auth-sheet {
  max-height: 85vh;
  padding: 24px 20px 28px;
  position: relative;
  overflow-y: auto;
}

.auth-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
}

.auth-hero {
  text-align: center;
  padding: 8px 8px 16px;
}

.auth-orb {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--amber), var(--amber-bright));
  color: #0f172a;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  font-weight: 900;
  box-shadow: 0 12px 28px rgba(245, 158, 11, 0.28);
}

.auth-hero h3 {
  margin: 0 0 4px;
  font-size: 1.2rem;
  font-weight: 900;
}

.auth-hero p {
  margin: 0;
  font-size: 0.72rem;
  color: #94a3b8;
}

.auth-label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
}

.auth-phone-wrap {
  position: relative;
  margin-bottom: 12px;
}

.auth-phone-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--amber);
  font-size: 0.85rem;
}

.auth-phone-wrap input,
.auth-otp-input {
  width: 100%;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #fff;
  font: inherit;
  padding: 14px 16px 14px 42px;
  outline: none;
}

.auth-phone-wrap input:focus,
.auth-otp-input:focus {
  border-color: var(--amber);
}

.auth-otp-input {
  padding: 14px 16px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: 0.35em;
  color: #fbbf24;
}

.auth-otp-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.auth-change-phone {
  border: 0;
  background: transparent;
  color: var(--amber);
  font: inherit;
  font-size: 0.72rem;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-otp-hint {
  margin: 8px 0 12px;
  text-align: center;
  font-size: 0.68rem;
  color: #64748b;
}

.auth-otp-hint strong {
  color: #fbbf24;
}

.auth-submit {
  width: 100%;
  margin-top: 4px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  color: #64748b;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid #1e293b;
}

.auth-social {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.auth-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 10px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #fff;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
}

.auth-social-btn:hover {
  border-color: #334155;
}

.g-mark {
  color: #ea4335;
  font-weight: 900;
}

.f-mark {
  color: #1877f2;
  font-weight: 900;
  font-size: 1rem;
}

/* ——— DramaBox v3 additions ——— */
.get-vip-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--amber), #d97706);
  color: #0f172a;
  font: inherit;
  font-size: 0.7rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(245, 158, 11, 0.25);
}

.search-vip-chip {
  position: absolute;
  top: -6px;
  left: 10px;
  z-index: 2;
  padding: 1px 6px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--amber), #f43f5e);
  color: #0f172a;
  font-size: 0.55rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
}

.coin-badge {
  position: relative;
}

.coin-pulse {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #f43f5e;
  box-shadow: 0 0 0 2px #020617;
  animation: coinPulse 1.4s ease-in-out infinite;
}

@keyframes coinPulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.55;
    transform: scale(0.85);
  }
}

.browse-tabs.underline-tabs {
  gap: 16px;
  border-bottom: 1px solid #111827;
  margin-bottom: 10px;
}

.browse-tabs.underline-tabs .browse-tab {
  border: 0;
  background: transparent;
  border-radius: 0;
  padding: 8px 4px 10px;
  color: #94a3b8;
  position: relative;
  box-shadow: none;
}

.browse-tabs.underline-tabs .browse-tab.selected {
  background: transparent;
  color: #fbbf24;
  box-shadow: none;
}

.browse-tabs.underline-tabs .browse-tab.selected::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  border-radius: 999px;
  background: var(--amber);
}

.catalogue-block {
  margin-top: 14px;
}

.catalogue-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
}

.catalogue-head .ico {
  color: var(--amber);
}

.poster-art-overlay {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  z-index: 2;
}

.poster-art-overlay .poster-genre-on {
  display: block;
  color: #fbbf24;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.poster-art-overlay .poster-title-on {
  display: block;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster-new-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  padding: 2px 8px;
  border-radius: 999px;
  background: #10b981;
  color: #0f172a;
  font-size: 0.55rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.poster-synopsis {
  margin: 0;
  color: #94a3b8;
  font-size: 0.62rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster-footer {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(30, 41, 59, 0.7);
  color: #94a3b8;
  font-size: 0.62rem;
  font-weight: 600;
}

.poster-footer .eps {
  color: #fbbf24;
  font-weight: 800;
}

/* For You feed */
.for-you-view {
  padding: 0 !important;
  overflow: hidden !important;
}

.for-you-stage {
  position: relative;
  min-height: calc(100vh - 80px);
  background: #020617;
}

.for-you-art {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-color: #1e293b;
}

.for-you-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.45) 0%,
    transparent 35%,
    rgba(2, 6, 23, 0.85) 100%
  );
  pointer-events: none;
}

.for-you-watch {
  border: 0;
  border-radius: 999px;
  margin-top: 12px;
  padding: 8px 14px;
  background: var(--amber);
  color: #0f172a;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
}

.for-you-actions {
  position: absolute;
  right: 14px;
  bottom: 160px;
  z-index: 3;
  display: grid;
  gap: 16px;
}

.for-you-actions .ep-action.saved .ep-action-orb {
  background: rgba(245, 158, 11, 0.22);
  border-color: rgba(245, 158, 11, 0.45);
  color: #fbbf24;
}

.for-you-bottom {
  position: absolute;
  left: 16px;
  right: 72px;
  bottom: 24px;
  z-index: 3;
}

.for-you-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.for-you-bottom h3 {
  margin: 0;
  color: #fff;
  font-size: 1rem;
  font-weight: 900;
}

.empty-orb {
  width: 64px;
  height: 64px;
  margin: 0 auto 12px;
  border-radius: 999px;
  border: 1px solid #1e293b;
  background: #0f172a;
  color: #475569;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
}

.watchlist-remove {
  border: 0;
  background: transparent;
  color: #fb7185;
  font: inherit;
  font-size: 0.62rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.profile-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.lang-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid #1e293b;
  background: #0f172a;
  color: #cbd5e1;
  font: inherit;
  font-size: 0.72rem;
  cursor: pointer;
}

.account-gear {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid #1e293b;
  background: #0f172a;
  color: #fbbf24;
  font: inherit;
  font-size: 1.05rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transition: transform 0.15s ease;
}

.account-gear:hover {
  transform: scale(1.05);
}

.login-btn.ghost {
  background: #1e293b;
  color: #e2e8f0;
}

.streak-card {
  margin-top: 16px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid #1e293b;
  background: #0f172a;
}

.streak-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 0.78rem;
}

.streak-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 12px;
}

.streak-day {
  display: grid;
  gap: 2px;
  place-items: center;
  padding: 8px 2px;
  border-radius: 12px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #64748b;
  font-size: 0.58rem;
  font-weight: 700;
}

.streak-day.claimed {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
}

.vip-inline .plan-row {
  margin-top: 10px;
}

.modal-card {
  position: relative;
  margin: auto;
  width: min(100%, 360px);
  max-height: 85vh;
  overflow: auto;
  padding: 22px 18px 18px;
  border-radius: 24px;
  border: 1px solid rgba(245, 158, 11, 0.3);
  background: #0f172a;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.modal-card h3 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 1rem;
  font-weight: 900;
}

.share-platforms {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.share-platform {
  display: grid;
  gap: 6px;
  place-items: center;
  padding: 12px 6px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #e2e8f0;
  font: inherit;
  font-size: 0.62rem;
  font-weight: 700;
  cursor: pointer;
}

.lang-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.lang-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #cbd5e1;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
}

.lang-option.selected {
  border-color: var(--amber);
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
}

.top-chrome.hidden-chrome,
.view.for-you-view ~ .top-chrome {
  /* handled via JS class */
}

.modal-card-scroll {
  max-height: 85vh;
}

.modal-icon-hero {
  width: 48px;
  height: 48px;
  margin: 0 auto 10px;
  border-radius: 16px;
  border: 1px solid rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  font-weight: 800;
}

.modal-kicker {
  margin: 0 0 14px;
  text-align: center;
  color: #fbbf24;
  font-size: 0.72rem;
  font-weight: 800;
}

.modal-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.legal-block {
  margin-bottom: 12px;
}

.legal-block h4 {
  margin: 0 0 4px;
  color: #fff;
  font-size: 0.78rem;
}

.legal-block p {
  margin: 0;
  color: #cbd5e1;
  font-size: 0.72rem;
  line-height: 1.45;
}

.legal-callout {
  margin: 12px 0;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(245, 158, 11, 0.3);
  background: #020617;
  color: #fcd34d;
  font-size: 0.68rem;
  line-height: 1.45;
}

.legal-callout.rose {
  border-color: rgba(244, 63, 94, 0.35);
  color: #fda4af;
}

.legal-callout strong {
  display: block;
  margin-bottom: 4px;
  color: inherit;
}

.social-links {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
  color: #e2e8f0;
  font-size: 0.72rem;
  font-weight: 800;
  text-decoration: none;
}

.modal-settings {
  margin-top: 12px;
  border: 1px solid #1e293b;
  border-radius: 16px;
  overflow: hidden;
  background: #020617;
}

.account-panel {
  margin-top: 14px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid #1e293b;
  background: #020617;
}

.account-panel h4 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 0.85rem;
}

.account-panel.danger {
  border-color: rgba(244, 63, 94, 0.35);
}

.account-panel.danger h4 {
  color: #fb7185;
}

.btn.danger {
  background: #e11d48;
  color: #fff;
  border: none;
}

.btn.danger-outline {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.4);
}

.theme-toggle-row {
  display: flex;
  gap: 10px;
}

.theme-btn {
  flex: 1;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #1e293b;
  background: #0f172a;
  color: #cbd5e1;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 800;
  cursor: pointer;
}

.theme-btn.active {
  background: var(--amber);
  border-color: var(--amber);
  color: #020617;
}

/* Local light theme (Account Settings) — default remains dark */
html[data-theme="light"] body {
  background: #f1f5f9;
  color: #0f172a;
}

html[data-theme="light"] .shell {
  background: #fff;
  border-color: #cbd5e1;
  color: #0f172a;
}

html[data-theme="light"] .haze,
html[data-theme="light"] .grain {
  opacity: 0.25;
}

html[data-theme="light"] .screen-title,
html[data-theme="light"] .profile-name,
html[data-theme="light"] .settings-row,
html[data-theme="light"] .toggle-label {
  color: #0f172a;
}

html[data-theme="light"] .settings-menu,
html[data-theme="light"] .streak-card,
html[data-theme="light"] .account-gear,
html[data-theme="light"] .modal-card {
  background: #f8fafc;
  border-color: #e2e8f0;
  color: #0f172a;
}

html[data-theme="light"] .account-gear {
  color: #b45309;
}

html[data-theme="light"] .support,
html[data-theme="light"] .muted,
html[data-theme="light"] .row-value {
  color: #64748b;
}
