/* QITO+ web app — Pacific linear TV streaming.
 * Visual language: black canvas, qito+ green primary, red live/play accents.
 * Home mirrors the marketing mock (full-bleed promo slideshow + card grid). */
:root {
  --brand: #74cc00;
  --brand-dark: #5aa300;
  --brand-light: #8fe61a;

  --bg: #000000;
  --surface: #101014;
  --panel: #16161d;
  --panel-2: #1c1c26;
  --panel-3: #24242f;
  --line: #2a2a35;
  --line-soft: #1f1f28;

  --text: #ffffff;
  --muted: #9ca3af;
  --muted-2: #6b7280;

  --live: #ef4444;
  --live-dark: #dc2626;
  --ok: var(--brand);
  --warn: #f5b942;
  --err: #ef4444;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.55);
  --shadow-sm: 0 10px 26px rgba(0, 0, 0, 0.45);

  /* Shared left/right gutter so the logo, promo copy and channel grid all
     line up on the same 1500px content column. */
  --content-edge: max(24px, calc((100vw - 1500px) / 2 + 24px));
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: "Inter", "Segoe UI", -apple-system, Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }

/* ── Top bar ──────────────────────────────────────────────────── */
header.appbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40;
  display: flex; align-items: center; gap: 18px;
  padding: 18px var(--content-edge);
  transition: background .25s ease, border-color .25s ease, transform .3s ease;
}
header.appbar.is-hidden { transform: translateY(-100%); }
body.route-home header.appbar {
  background: linear-gradient(to bottom, rgba(0, 0, 0, .85) 0%, rgba(0, 0, 0, 0) 100%);
  border-bottom: none;
}
body:not(.route-home) header.appbar {
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.brand { display: flex; align-items: center; cursor: pointer; }
.brand img { height: 65px; width: auto; transition: transform .15s ease, filter .15s ease; }
.brand:hover img { transform: scale(1.05); filter: drop-shadow(0 0 12px rgba(116, 204, 0, .5)); }
.appbar .spacer { flex: 1; }

.status-pills { display: flex; gap: 8px; align-items: center; }
.pill {
  font-size: 14px; color: var(--muted); border: 1px solid var(--line);
  padding: 5px 11px; border-radius: 999px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(0, 0, 0, .35); text-transform: uppercase; letter-spacing: .04em;
}
.pill .led { width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); }
.pill.on { color: var(--brand); border-color: rgba(116, 204, 0, .4); }
.pill.on .led { background: var(--brand); box-shadow: 0 0 8px var(--brand); }
.pill.off { color: var(--err); border-color: rgba(239, 68, 68, .4); }
.pill.off .led { background: var(--err); }

/* TV Guide pill + hamburger (mock top-right) */
.tv-guide {
  height: 48px; padding: 0 22px; border: none; border-radius: 24px;
  background: var(--brand); color: #000; font-size: 15px; font-weight: 700; cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}
.tv-guide:hover { background: var(--brand-light); transform: scale(1.05); }
.tv-guide:active { transform: scale(1); }

.hamburger {
  width: 48px; height: 48px; border: none; border-radius: 50%; background: var(--brand); cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  transition: transform .15s ease, background .15s ease;
}
.hamburger:hover { background: var(--brand-light); transform: scale(1.06); }
.hamburger span { display: block; width: 20px; height: 2.5px; border-radius: 2px; background: #000; }

/* Hamburger dropdown menu */
.menu-wrap { position: relative; }
.menu {
  position: absolute; top: 58px; right: 0; min-width: 210px; z-index: 50;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow); padding: 8px; display: none; flex-direction: column; gap: 2px;
}
.menu.open { display: flex; }
.menu a, .menu button {
  text-align: left; background: transparent; border: none; color: var(--text);
  font-size: 14px; font-weight: 600; padding: 11px 14px; border-radius: 9px; cursor: pointer;
}
.menu a:hover, .menu button:hover { background: var(--panel-2); }
.menu a.active { color: var(--brand); background: rgba(116, 204, 0, .1); }
.menu .sep { height: 1px; background: var(--line-soft); margin: 6px 4px; }
.menu .who { padding: 8px 14px 4px; font-size: 12px; color: var(--muted); }

.avatar-btn {
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: var(--brand); color: #000;
  font-weight: 800; cursor: pointer; display: grid; place-items: center; font-size: 15px;
  transition: transform .15s ease, background .15s ease;
}
.avatar-btn:hover { background: var(--brand-light); transform: scale(1.06); }

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
  background: var(--panel-3); color: var(--text); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 10px 16px; font-size: 14px; cursor: pointer; font-weight: 600;
  transition: transform .05s ease, background .15s ease, filter .15s ease; white-space: nowrap;
}
.btn:hover { background: #2f2f3c; }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #000; }
.btn.primary:hover { background: var(--brand-light); }
.btn.ghost { background: transparent; }
.btn.ghost:hover { background: rgba(255, 255, 255, 0.06); }
.btn.sm { padding: 7px 12px; font-size: 13px; }
.btn.danger { color: #ffd6d6; border-color: rgba(239, 68, 68, .4); background: rgba(239, 68, 68, .12); }
.btn.danger:hover { background: rgba(239, 68, 68, .2); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.pill { border-radius: 999px; }
.btn svg { width: 16px; height: 16px; fill: currentColor; vertical-align: -3px; margin-right: 4px; }

/* ── Layout ───────────────────────────────────────────────────── */
main { width: 100%; }
body:not(.route-home) main { min-height: 100vh; }
.view { max-width: 1220px; margin: 0 auto; padding: 118px 22px 80px; animation: fade .25s ease; }
/* Home breaks out to full-bleed promo layers + grid. */
.view.home-view { max-width: none; padding: 0; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.section-head { display: flex; align-items: baseline; gap: 12px; margin: 30px 2px 14px; }
.section-head h2 { margin: 0; font-size: 20px; letter-spacing: .2px; }
.section-head .sub { color: var(--muted); font-size: 13px; }
.section-head .spacer { flex: 1; }
.eyebrow { color: var(--brand); font-weight: 700; font-size: 12px; letter-spacing: 1.4px; text-transform: uppercase; }

.card {
  background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.card.pad { padding: 20px; }
.muted { color: var(--muted); }
.empty { color: var(--muted); font-size: 14px; padding: 26px; text-align: center; border: 1px dashed var(--line); border-radius: var(--radius); }

/* ── Home: full-bleed promo slideshow ─────────────────────────── */
.promos, .promo-faces, .home-gradients, .promo-content {
  position: fixed; inset: 0; pointer-events: none;
}
.promos, .promo-faces, .promo-content { will-change: transform, opacity; }
.promos { z-index: 1; overflow: hidden; background: #000; }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.slide.is-active { opacity: 1; }
.slide__bg { position: absolute; inset: 0; background-size: cover; background-position: center; transform: scale(1.05); }
.slide__bg.is-fallback { background: radial-gradient(1200px 700px at 70% 20%, #14361a 0%, #000 70%); }

.promo-faces { z-index: 3; }
.fslide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.fslide.is-active { opacity: 1; }
.slide__faces { position: absolute; top: 0; right: 4%; width: 50%; height: auto; object-fit: contain; filter: drop-shadow(0 20px 40px rgba(0, 0, 0, .6)); }
.slide__faces.is-clickable { cursor: pointer; pointer-events: auto; }

.home-gradients { z-index: 2; }
.home-gradients > div { position: absolute; }
.home-gradients__top { top: 0; left: 0; right: 0; height: 220px; background: linear-gradient(to bottom, #000 0%, transparent 100%); }
.home-gradients__bottom { bottom: 0; left: 0; right: 0; height: 340px; background: linear-gradient(to top, #000 0%, transparent 100%); }
.home-gradients__left { top: 0; bottom: 0; left: 0; width: 42%; background: linear-gradient(to right, #000 0%, transparent 100%); }

.promo-content { z-index: 3; }
.pslide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.pslide.is-active { opacity: 1; }
.slide__content { position: absolute; left: var(--content-edge); top: 24%; max-width: 540px; }
.slide__eyebrow { margin-bottom: 12px; display: block; }
.slide__title { font-size: 52px; font-weight: 800; line-height: 1.05; letter-spacing: -1px; margin: 0 0 16px; text-shadow: 0 2px 16px rgba(0, 0, 0, .6); }
.slide__desc { font-size: 18px; line-height: 1.5; color: #e5e7eb; margin: 0 0 22px; text-shadow: 0 2px 10px rgba(0, 0, 0, .6); }
.slide__when { display: inline-flex; align-items: center; gap: 8px; color: var(--brand); font-weight: 700; font-size: 14px; margin-bottom: 18px; }
.slide__actions { display: flex; gap: 12px; pointer-events: auto; }
.slide__cta {
  display: inline-flex; align-items: center; gap: 8px; height: 52px; padding: 0 28px;
  border: none; border-radius: 26px; background: var(--brand); color: #000; font-size: 16px; font-weight: 700; cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}
.slide__cta svg { width: 18px; height: 18px; fill: currentColor; }
.slide__cta:hover { background: var(--brand-light); transform: scale(1.04); }
.slide__cta.ghost { background: rgba(0, 0, 0, .55); color: #fff; border: 1px solid rgba(255, 255, 255, .3); }
.slide__cta.ghost:hover { background: rgba(0, 0, 0, .75); }

/* ── Home: channel grid ───────────────────────────────────────── */
/* Wrapper is click-through so the promo CTA underneath stays usable; cards opt back in. */
.channels { position: relative; z-index: 4; pointer-events: none; }
.grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px;
  max-width: 1500px; margin: 0 auto; padding: 0 24px 40px;
}
.grid > * { pointer-events: auto; }
.home-subprompt {
  position: relative; z-index: 4; max-width: 1500px; margin: 0 auto 14px;
  padding: 0 24px;
}

/* ── Channel card (mock style) ────────────────────────────────── */
.chan-card {
  border-radius: 14px; padding: 10px; color: #fff; box-shadow: 0 12px 28px rgba(0, 0, 0, .5);
  display: flex; flex-direction: column; cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.chan-card:hover { transform: translateY(-6px) scale(1.02); box-shadow: 0 20px 40px rgba(0, 0, 0, .65); filter: brightness(1.08); }
.chan-card:active { transform: translateY(-2px) scale(1); }
.chan-card:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; }

.grad-1 { background: linear-gradient(135deg, #6d28d9 0%, #4c1d95 100%); }
.grad-2 { background: linear-gradient(135deg, #0891b2 0%, #0e7490 100%); }
.grad-3 { background: linear-gradient(135deg, #db2777 0%, #9d174d 100%); }
.grad-4 { background: linear-gradient(135deg, #ea580c 0%, #9a3412 100%); }
.grad-5 { background: linear-gradient(135deg, #16a34a 0%, #166534 100%); }
.grad-6 { background: linear-gradient(135deg, #2563eb 0%, #1e3a8a 100%); }
.grad-7 { background: linear-gradient(135deg, #dc2626 0%, #7f1d1d 100%); }
.grad-8 { background: linear-gradient(135deg, #0d9488 0%, #115e59 100%); }

.chan-card__badges { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.badges__left { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.badge--chan { background: rgba(0, 0, 0, .55); color: #fff; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge { font-size: 11px; font-weight: 700; letter-spacing: .5px; border-radius: 6px; padding: 3px 7px; display: inline-flex; align-items: center; gap: 6px; }
.badge--live { background: rgba(0, 0, 0, .55); color: #fff; }
.badge--live .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 3px rgba(239, 68, 68, .3); animation: pulse 1.4s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }
.badge--hd { background: rgba(255, 255, 255, .15); color: #fff; font-style: italic; }

.chan-card__media { position: relative; display: grid; grid-template-columns: 16fr 9fr; gap: 0; border-radius: 8px; overflow: hidden; }
.media__logo { background: #000; aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.media__logo img { width: 100%; height: 100%; object-fit: contain; }
.media__logo .logo-fallback { font-size: 14px; font-weight: 800; color: #fff; text-align: center; line-height: 1.15; }
.media__epg { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: rgba(0, 0, 0, .25); }
.media__epg img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.chan-card:hover .media__epg img { transform: scale(1.08); }

.chan-card__progress { height: 5px; border-radius: 4px; background: rgba(255, 255, 255, .25); margin: 8px 0 0; overflow: hidden; }
.chan-card__progress > span { display: block; height: 100%; background: var(--brand); border-radius: 4px; }

.chan-card__footer { display: flex; align-items: center; gap: 8px; padding: 8px 2px 2px; }
.footer__icon { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; background: rgba(255, 255, 255, .15); display: flex; align-items: center; justify-content: center; }
.footer__icon svg { width: 14px; height: 14px; fill: var(--brand-light); }
.footer__title { flex: 1 1 0; min-width: 0; font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.footer__title.is-scrolling { text-overflow: clip; }
.footer__title .ticker__track { display: inline-flex; gap: 2.5rem; white-space: nowrap; will-change: transform; }
.footer__title.is-scrolling .ticker__track { animation: ticker linear infinite; }
.chan-card:hover .footer__title.is-scrolling .ticker__track { animation-play-state: paused; }
@keyframes ticker { to { transform: translateX(calc(-1 * var(--ticker-shift, 0px))); } }

.play {
  flex: 0 0 auto; margin-left: auto; width: 34px; height: 34px; border: none; border-radius: 50%;
  background: var(--live); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .4); transition: transform .15s ease, background .15s ease;
}
.chan-card:hover .play { background: var(--live-dark); transform: scale(1.12); }
.play:hover { transform: scale(1.08); background: var(--live-dark); }
.play svg { width: 17px; height: 17px; fill: #fff; margin-left: 2px; }

/* ── Standard channel grid (used off-home if needed) ──────────── */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 22px; }

/* ── Subscription banner ──────────────────────────────────────── */
.sub-banner { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); margin-bottom: 8px; }
.sub-banner .ring { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; }
.sub-banner .ring.ok { background: rgba(116, 204, 0, .16); color: var(--brand); }
.sub-banner .ring.no { background: rgba(245, 185, 66, .16); color: var(--warn); }
.sub-banner .grow { flex: 1; }
.sub-banner b { font-size: 15px; }
.sub-banner small { color: var(--muted); display: block; font-size: 12.5px; margin-top: 2px; }
.home-subprompt .sub-banner { background: rgba(16, 16, 20, .82); backdrop-filter: blur(8px); }

/* ── Guide (EPG) ──────────────────────────────────────────────── */
.guide-row { display: grid; grid-template-columns: 200px 1fr; gap: 0; border-bottom: 1px solid var(--line-soft); }
.guide-row:last-child { border-bottom: none; }
.guide-chan { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 8px; padding: 14px; border-right: 1px solid var(--line-soft); background: var(--panel); }
.guide-chan img { height: 56px; width: auto; max-width: 100%; object-fit: contain; }
.guide-chan b { font-size: 14px; }
.guide-progs { display: flex; gap: 8px; overflow-x: auto; padding: 12px 14px; scrollbar-width: thin; }
.prog { flex: 0 0 auto; min-width: 150px; max-width: 220px; border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px; background: var(--panel); cursor: pointer; transition: border-color .12s ease; }
.prog:hover { border-color: var(--brand-dark); }
.prog.live { border-color: var(--brand); background: rgba(116, 204, 0, .1); }
.prog .time { font-size: 11px; color: var(--brand); font-weight: 700; }
.prog .title { font-size: 13px; font-weight: 600; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prog .feat { font-size: 10px; color: var(--muted); }

/* ── Plans / packages ─────────────────────────────────────────── */
.plan-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; }
.plan { flex: 1 1 300px; max-width: 460px; min-width: 280px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); display: flex; flex-direction: column; }
.plan .plan-head { padding: 20px; border-bottom: 1px solid var(--line-soft); position: relative; }
.plan .plan-head .badge { position: absolute; top: 16px; right: 16px; font-size: 11px; font-weight: 800; letter-spacing: .5px; color: #000; background: var(--brand); padding: 3px 9px; border-radius: 6px; }
.plan h3 { margin: 0 0 6px; font-size: 20px; }
.plan .price { font-size: 30px; font-weight: 800; margin: 8px 0 2px; }
.plan .price s { color: var(--muted-2); font-size: 17px; font-weight: 600; margin-left: 8px; }
.plan .price small { font-size: 17px; color: var(--muted); font-weight: 600; }
.plan .plan-body { padding: 18px 20px; flex: 1; display: flex; flex-direction: column; gap: 12px; }
.plan ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; }
.plan ul li { font-size: 13.5px; color: #d1d5db; display: flex; gap: 9px; align-items: flex-start; }
.plan ul li::before { content: "✓"; color: var(--brand); font-weight: 800; }
.plan .plan-foot { padding: 0 20px 20px; }
.plan .plan-foot .btn { width: 100%; text-align: center; justify-content: center; }
.plan.owned { border-color: rgba(116, 204, 0, .45); }
.plan.promo-applied { border-color: rgba(116, 204, 0, .55); box-shadow: 0 0 0 1px rgba(116, 204, 0, .25); }
.promo-modal { padding: 24px; }
.promo-modal h3 { margin: 0 0 4px; font-size: 20px; }
.promo-modal .field input { text-transform: uppercase; }
.promo-msg { font-size: 12.5px; margin-top: 8px; min-height: 16px; color: var(--muted); }
.promo-msg.ok { color: var(--brand); }
.promo-msg.err { color: var(--err); }

/* ── Player ───────────────────────────────────────────────────── */
.player-wrap { display: grid; grid-template-columns: 1fr 340px; gap: 20px; align-items: start; }
.stage { position: relative; background: #000; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); aspect-ratio: 16 / 9; }
.stage video { width: 100%; height: 100%; display: block; background: #000; object-fit: contain; }
.stage .fallback { position: absolute; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; color: var(--muted); padding: 24px; background: radial-gradient(600px 300px at 50% 30%, #14361a, #000); }
.stage.demo .fallback { display: flex; }
.stage .fallback .big { font-size: 17px; color: var(--text); font-weight: 700; }
.privacy-overlay { position: absolute; z-index: 5; pointer-events: none; font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .82); text-shadow: 0 1px 3px rgba(0, 0, 0, .9); background: rgba(0, 0, 0, .28); padding: 3px 9px; border-radius: 6px; transition: opacity .5s ease; opacity: 0; left: 50%; top: 12%; }
.privacy-overlay.show { opacity: 1; }
.player-side .card { margin-bottom: 16px; }
.now-playing h2 { margin: 0 0 4px; font-size: 22px; }
.kv { display: grid; grid-template-columns: 120px 1fr; gap: 6px 12px; font-size: 13px; margin-top: 6px; }
.kv div:nth-child(odd) { color: var(--muted); }
.kv code { color: var(--brand-light); word-break: break-all; font-size: 12px; }
.stream-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.tag { font-size: 11px; padding: 3px 9px; border-radius: 6px; border: 1px solid var(--line); color: var(--muted); }
.tag.ok { color: var(--brand); border-color: rgba(116, 204, 0, .4); }
.tag.brand { color: var(--brand-light); border-color: rgba(116, 204, 0, .4); }

/* ── Account ──────────────────────────────────────────────────── */
.acct-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.acct-tabs { display: flex; flex-wrap: wrap; gap: 6px; border-bottom: 1px solid var(--line); margin: 4px 0 20px; }
.acct-tab { background: transparent; border: none; color: var(--muted); font-size: 15px; font-weight: 600; padding: 12px 16px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; border-radius: 8px 8px 0 0; }
.acct-tab:hover { color: var(--text); background: rgba(255, 255, 255, .03); }
.acct-tab.active { color: var(--brand-light); border-bottom-color: var(--brand); }
.acct-panel { max-width: 620px; }
.field label { font-size: 13px; color: var(--muted); display: block; margin: 10px 0 5px; }
.field input, .field select { background: #0c0c11; border: 1px solid var(--line); color: var(--text); border-radius: 9px; padding: 13px 14px; font-size: 15px; width: 100%; }
.field input:focus, .field select:focus { outline: none; border-color: var(--brand); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.list { display: flex; flex-direction: column; gap: 10px; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line-soft); border-radius: var(--radius-sm); background: var(--panel); }
.list-item .grow { flex: 1; }
.list-item b { font-size: 14px; }
.list-item small { color: var(--muted); font-size: 12px; }
.badge-soft { font-size: 11px; padding: 3px 9px; border-radius: 6px; background: var(--panel-3); color: var(--muted); border: 1px solid var(--line); }
.badge-soft.ok { color: var(--brand); border-color: rgba(116, 204, 0, .35); }
.badge-soft.warn { color: var(--warn); border-color: rgba(245, 185, 66, .35); }

/* ── Auth / modals ────────────────────────────────────────────── */
.backdrop { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .78); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px; }
.modal { width: 100%; max-width: 460px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); overflow: hidden; animation: pop .2s ease; }
@keyframes pop { from { transform: scale(.96); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.modal .modal-head { padding: 22px 24px 6px; }
.modal .modal-head .eyebrow { margin-bottom: 8px; display: block; }
.modal .modal-head h2 { margin: 0; font-size: 26px; }
.modal .modal-head p { color: var(--muted); font-size: 15px; margin: 8px 0 0; }
.modal .modal-body { padding: 16px 24px 24px; }
.modal .close { position: absolute; top: 14px; right: 16px; background: transparent; border: none; color: var(--muted); font-size: 22px; cursor: pointer; }
.otp-inputs { display: flex; gap: 8px; margin: 8px 0; }
.otp-inputs input { flex: 1 1 0; min-width: 0; text-align: center; font-size: 24px; font-weight: 700; letter-spacing: 1px; padding: 16px 0; background: #0c0c11; border: 1px solid var(--line); color: var(--text); border-radius: 10px; }
.otp-inputs input:focus { outline: none; border-color: var(--brand); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted-2); font-size: 12px; margin: 18px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.dev-hint { font-size: 12px; color: var(--brand-light); background: rgba(116, 204, 0, .1); border: 1px solid rgba(116, 204, 0, .3); border-radius: 8px; padding: 8px 10px; margin-top: 10px; }
.pay-summary { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.pay-summary .row { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; font-size: 14px; }
.pay-summary .row.muted { color: var(--muted); }
.auth-resend { text-align: center; font-size: 13px; color: var(--muted); margin-top: 14px; }
.linklike { background: none; border: none; padding: 0; font: inherit; color: var(--brand); font-weight: 600; cursor: pointer; }
.linklike:hover:not(:disabled) { text-decoration: underline; }
.linklike:disabled { color: var(--muted-2); cursor: default; }

/* ── Landing (signed-out) ─────────────────────────────────────── */
.landing { position: relative; z-index: 4; text-align: center; padding: 150px 20px 60px; max-width: 900px; margin: 0 auto; }
.landing .eyebrow { justify-content: center; }
.landing h1 { font-size: 56px; margin: 14px 0 12px; letter-spacing: -1.5px; line-height: 1.02; }
.landing h1 .grad { color: var(--brand); }
.landing p.lede { color: var(--muted); font-size: 18px; max-width: 640px; margin: 0 auto 28px; line-height: 1.55; }
.landing .cta-row { display: flex; gap: 12px; justify-content: center; }
.feature-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin-top: 60px; text-align: left; }
.feature { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.feature .ico { font-size: 26px; margin-bottom: 10px; }
.feature b { display: block; margin-bottom: 4px; }
.feature small { color: var(--muted); font-size: 13px; line-height: 1.5; }

/* ── Site footer ──────────────────────────────────────────────── */
.site-footer { position: relative; z-index: 5; background: #0a0a0d; border-top: 1px solid var(--line-soft); }
.footer-inner { max-width: 1500px; margin: 0 auto; padding: 22px 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer-copy { color: var(--muted); font-size: 13px; margin: 0; }
.footer-links { display: flex; gap: 22px; }
.footer-links a { color: var(--muted); font-size: 13px; font-weight: 600; }
.footer-links a:hover { color: var(--brand); }
@media (max-width: 620px) { .footer-inner { flex-direction: column; text-align: center; } }

/* ── Console drawer (dev) ─────────────────────────────────────── */
.console-toggle { position: fixed; z-index: 70; right: 18px; bottom: 18px; }
#console { position: fixed; z-index: 75; right: 0; bottom: 0; top: 0; width: 460px; max-width: 92vw; background: #050507; border-left: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .25s ease; }
#console.open { transform: none; }
#console .con-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
#console .con-head b { font-size: 14px; }
#console .con-head .spacer { flex: 1; }
#conlog { flex: 1; overflow: auto; padding: 12px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; line-height: 1.5; white-space: pre-wrap; }
.log-row { padding: 1px 0; }
.t-ok { color: var(--brand); } .t-err { color: var(--err); } .t-req { color: #60a5fa; } .t-info { color: var(--muted); } .t-ws { color: var(--brand-light); } .t-sum { color: var(--text); font-weight: 700; }

/* ── Spinner ──────────────────────────────────────────────────── */
.spinner { width: 22px; height: 22px; border: 2.5px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.center-load { display: grid; place-items: center; padding: 60px; }

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .player-wrap { grid-template-columns: 1fr; }
  .acct-grid { grid-template-columns: 1fr; }
  .slide__title { font-size: 34px; }
  .slide__content { top: 18%; }
  .landing h1 { font-size: 38px; }
}
@media (max-width: 620px) {
  .status-pills .pill { display: none; }
  .tv-guide { display: none; }
  .view { padding: 104px 14px 80px; }
  .guide-row { grid-template-columns: 120px 1fr; }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .slide__faces { display: none; }
}
