:root {
  --bg: #050505;
  --bg-2: #0b0b0c;
  --surface: #111112;
  --surface-2: #171718;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #f4f4f5;
  --muted: #8d8d93;
  --muted-2: #6b6b70;
  --red: #ff2a33;
  --red-2: #c81018;
  --white: #ffffff;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  --radius: 14px;
  --radius-sm: 10px;
  --max: 1180px;
  --header: 72px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4, p { margin: 0; }

.page { min-height: 100vh; display: flex; flex-direction: column; }
.wrap { width: min(var(--max), calc(100% - 48px)); margin: 0 auto; }
.main { flex: 1; padding-top: calc(var(--header) + 28px); padding-bottom: 80px; }

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header);
  display: flex;
  align-items: center;
  background: rgba(5, 5, 5, 0.82);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid transparent;
}
.header.is-scrolled { border-bottom-color: var(--line); }
.header-inner {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 28px;
}
.logo {
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -0.04em;
  display: inline-flex;
  align-items: baseline;
  gap: 0;
}
.logo .dot { color: var(--red); font-size: 1.15em; line-height: 0; margin: 0 1px; }
.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: 8px;
}
.menu-btn { display: none; }
.nav a {
  color: #d7d7db;
  font-size: 14.5px;
  font-weight: 500;
  padding: 8px 0;
  position: relative;
}
.nav a:hover { color: #fff; }
.nav a.active { color: #fff; }
.nav a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
}
.header-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
}
.lang {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #cfcfd4;
  font-size: 13.5px;
  font-weight: 600;
}
.ghost-link { color: #e8e8ea; font-size: 14.5px; font-weight: 500; }
.icon-btn {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  color: #ddd;
  border-radius: 999px;
}
.icon-btn:hover { background: rgba(255,255,255,0.06); }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border-radius: 10px;
  font-weight: 650;
  font-size: 14.5px;
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-white { background: #fff; color: #111; }
.btn-red { background: var(--red); color: #fff; }
.btn-outline {
  background: transparent;
  border: 1px solid var(--line-strong);
  color: #fff;
}
.btn-lg { height: 48px; padding: 0 20px; border-radius: 12px; }

/* Hero */
.hero { padding: 18px 0 10px; }
.kicker {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
}
.hero h1 {
  margin-top: 14px;
  font-size: clamp(40px, 6vw, 68px);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 750;
  max-width: 14ch;
}
.hero .lead {
  margin-top: 18px;
  color: var(--muted);
  font-size: 17px;
  max-width: 46ch;
}
.room-grid {
  margin-top: 36px;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 18px;
}
.room-card {
  background: linear-gradient(180deg, #141416, #0e0e10);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.room-card h3 { font-size: 22px; letter-spacing: -0.03em; }
.room-card p { margin-top: 8px; color: var(--muted); font-size: 14.5px; }
.room-card .btn { margin-top: auto; }
.tiny-row {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--muted-2);
  font-size: 13px;
}
.tiny-row span { display: inline-flex; align-items: center; gap: 7px; }
.tiny-row span::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: #3f3f44;
}

/* How */
.how {
  margin-top: 64px;
  display: grid;
  grid-template-columns: 0.9fr 1.2fr;
  gap: 48px;
  align-items: start;
}
.how-copy h2 {
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
  line-height: 1.1;
}
.how-copy p { margin-top: 16px; color: var(--muted); max-width: 42ch; }
.step-list { display: grid; gap: 10px; }
.step {
  text-align: left;
  border: 1px solid var(--line);
  background: #0d0d0e;
  border-radius: 16px;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
}
.step.active { border-color: #3a3a3e; background: #151516; }
.step .num { color: var(--muted-2); font-weight: 700; }
.step h3 { font-size: 16px; }
.step p { color: var(--muted); font-size: 13.5px; margin-top: 4px; }

/* Sections */
.section { margin-top: 86px; }
.section-head { margin-bottom: 22px; }
.section-head .label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}
.section-head h2 {
  margin-top: 8px;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.04em;
}
.section-head p { margin-top: 10px; color: var(--muted); max-width: 52ch; }

.scene-grid, .clip-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.scene-card, .clip-card {
  display: block;
  text-align: left;
}
.poster, .thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 12px;
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 20%, color-mix(in srgb, var(--c1) 70%, transparent), transparent 42%),
    linear-gradient(145deg, var(--c1), var(--c2) 70%, #0a0a0c);
  border: 1px solid var(--line);
}
.poster::after, .thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0,0,0,.55));
}
.poster-title {
  position: absolute;
  left: 12px; right: 12px; bottom: 34px;
  z-index: 1;
  font-weight: 750;
  letter-spacing: -0.03em;
  font-size: 16px;
  text-shadow: 0 2px 12px rgba(0,0,0,.6);
}
.scene-card:hover .poster, .clip-card:hover .thumb { transform: translateY(-2px); }
.poster, .thumb { transition: transform .15s ease; }
.badge {
  position: absolute;
  z-index: 1;
  background: rgba(0,0,0,.72);
  border: 1px solid rgba(255,255,255,.08);
  color: #fff;
  font-size: 12px;
  padding: 3px 7px;
  border-radius: 7px;
}
.badge.dur { left: 8px; bottom: 8px; }
.badge.chars { right: 8px; top: 8px; }
.badge.mute { right: 8px; bottom: 8px; }
.scene-card h3, .clip-card h3 {
  margin-top: 10px;
  font-size: 15px;
  letter-spacing: -0.02em;
}
.clip-meta {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12.5px;
}
.avatar {
  width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 10px; font-weight: 700; color: #111;
  background: #d9d9de;
}
.stats { margin-left: auto; display: flex; gap: 10px; }

/* Featured */
.featured {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #0c0c0d;
}
.player {
  position: relative;
  min-height: 320px;
  background: #101012;
  display: grid;
  place-items: center;
}
.player video, .poster video {
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
  display: block;
  background: #000;
}
.poster video { min-height: 0; position: absolute; inset: 0; }
.mix-player { position: relative; }
.mix-play {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 2;
}
.player .stage {
  width: 100%; height: 100%;
  min-height: 320px;
  background:
    radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--c1) 55%, transparent), transparent 40%),
    linear-gradient(160deg, var(--c1), #0a0a0c);
}
.player-ui {
  position: absolute;
  left: 12px; right: 12px; bottom: 12px;
  display: flex; align-items: center; gap: 10px;
  color: #fff;
}
.play-circle {
  width: 36px; height: 36px; border-radius: 50%;
  background: #fff; color: #111;
  display: grid; place-items: center;
}
.bar { flex: 1; height: 4px; background: rgba(255,255,255,.22); border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; width: 18%; background: #fff; }
.featured-meta { padding: 28px 26px; display: flex; flex-direction: column; }
.day-label {
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
}
.day-label::after {
  content: "";
  display: block;
  width: 42px; height: 2px;
  background: var(--red);
  margin-top: 8px;
}
.featured-meta h2 {
  margin-top: 18px;
  font-size: 34px;
  letter-spacing: -0.04em;
}
.featured-meta .people { margin-top: 10px; color: var(--muted); }
.featured-meta .foot { margin-top: auto; color: var(--muted); font-size: 13px; letter-spacing: 0.04em; }

/* Pricing */
.price-box {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  background: #0d0d0e;
}
.price-top { display: flex; justify-content: space-between; gap: 20px; }
.price-col h3 { color: var(--muted); font-size: 14px; font-weight: 600; }
.price-col .amount { margin-top: 8px; font-size: 36px; letter-spacing: -0.04em; }
.price-col .amount small { font-size: 16px; color: var(--muted); font-weight: 500; }
.compare { margin-top: 22px; display: grid; gap: 10px; }
.compare div {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  color: #c9c9ce;
  font-size: 14.5px;
}

/* Page titles */
.page-title h1 {
  font-size: clamp(40px, 6vw, 64px);
  letter-spacing: -0.045em;
}
.page-title p { margin-top: 10px; color: var(--muted); }
.tabs { display: flex; gap: 18px; margin: 22px 0 18px; }
.tabs button, .tabs a {
  color: var(--muted);
  font-weight: 600;
  padding-bottom: 8px;
  border-bottom: 2px solid transparent;
}
.tabs .on { color: #fff; border-bottom-color: #fff; }
.pills { display: flex; gap: 10px; margin: 8px 0 22px; flex-wrap: wrap; }
.pill {
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: #fff;
  font-weight: 600;
  font-size: 13.5px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.pill.on { background: #fff; color: #111; border-color: #fff; }

.search-row {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 22px 0;
}
.search {
  flex: 1;
  height: 46px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #101011;
  padding: 0 14px;
  outline: none;
}
.search:focus { border-color: #3d3d42; }
.filter-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* Auth */
.auth-card {
  width: min(420px, 100%);
  margin: 20px auto 0;
  background: #101011;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px;
}
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 13px; color: var(--muted); }
.field input {
  height: 44px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #0b0b0c;
  padding: 0 12px;
  outline: none;
}
.field input:focus { border-color: #444; }
.auth-switch { margin-top: 14px; color: var(--muted); font-size: 14px; text-align: center; }
.auth-switch button { color: #fff; font-weight: 600; }

/* How page */
.steps-6 { display: grid; gap: 12px; margin-top: 28px; }
.step-row {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #0d0d0e;
}
.step-row .n { font-size: 22px; font-weight: 750; color: var(--muted-2); }
.tips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 20px; }
.tip {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #0d0d0e;
}
.tip h3 { font-size: 18px; letter-spacing: -0.03em; }
.tip p { margin-top: 8px; color: var(--muted); }
.faq details {
  border-top: 1px solid var(--line);
  padding: 14px 0;
}
.faq summary { cursor: pointer; font-weight: 650; }
.faq p { margin-top: 8px; color: var(--muted); }

/* Room */
.lobby {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 20px;
}
.panel {
  background: #101011;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
}
.code-box {
  font-size: 40px;
  letter-spacing: 0.18em;
  font-weight: 750;
}
.players { display: grid; gap: 10px; margin-top: 16px; }
.player-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  background: #0c0c0d;
  border-radius: 12px;
  border: 1px solid var(--line);
}
.rec-stage {
  border-radius: 18px;
  min-height: 360px;
  border: 1px solid var(--line);
  background: #0c0c0d;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 24px;
}
.studio { display: grid; gap: 14px; }
.studio-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.studio-top .room {
  font-weight: 750;
  letter-spacing: 0.08em;
}
.studio-stage {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #000;
}
.studio-stage video {
  width: 100%;
  min-height: 180px;
  max-height: 36vh;
  object-fit: contain;
  display: block;
  background: #000;
}
.rec-flag {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 4;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 6px 10px;
  border-radius: 8px;
}
.freq-track {
  position: relative;
  height: 110px;
  border-radius: 12px;
  border: 0;
  background: #101012;
  overflow: hidden;
}
.freq-track canvas {
  display: block;
  width: 100%;
  height: 100%;
}
.freq-head {
  position: absolute;
  top: 0; bottom: 0;
  width: 2px;
  background: #fff;
  box-shadow: 0 0 8px #fff;
  pointer-events: none;
  transform: translateX(-1px);
}
.studio-hint {
  color: #cfcfd3;
  font-size: 14px;
  text-align: center;
}
.script-box {
  background: #1a1a1d;
  border-radius: 16px;
  padding: 22px 26px;
  font-size: clamp(17px, 2.3vw, 24px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.6;
  color: #ececec;
}
.script-word { color: #8d8d93; font-weight: 600; }
.script-word.mine { color: #f4f4f5; }
.script-word.now { color: #fff; font-weight: 800; }
.mode-badge {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.mode-badge.online { background: rgba(255,42,51,.18); color: #ff8a90; }
.mode-badge.local { background: #222; color: #b8b8be; }
.lobby-link {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #0c0c0e;
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
  word-break: break-all;
}
.cue-pills {
  display: flex;
  gap: 6px;
  align-items: center;
}
.cue-pill {
  flex: 1;
  height: 10px;
  border-radius: 99px;
  background: #2c2c30;
}
.cue-pill.on {
  background: linear-gradient(90deg, #ff3140, #c81018);
  box-shadow: 0 0 0 1px rgba(255,255,255,.35);
}
.cue-pill.done { background: #5a5a62; }
.cue-count {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #d0d0d4;
}
.studio .btn-block {
  width: 100%;
  height: 52px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 16px;
}
.studio-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}
#preview-audio, #tape-audio, #mix-tape { display: none; }
.rec-scrub {
  width: 100%;
  appearance: none;
  height: 4px;
  border-radius: 99px;
  background: #2a2a2e;
  outline: none;
  accent-color: var(--red);
}
.rec-scrub::-webkit-slider-thumb {
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ff6b73;
  border: 0;
}
.line-card {
  max-width: 520px;
  background: rgba(0,0,0,.45);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
}
.rec-dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 6px rgba(255,42,51,.15);
  display: inline-block;
}

/* Mini game */
.game-board {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  background: #101011;
  min-height: 320px;
}
.game-line {
  font-size: clamp(22px, 4vw, 36px);
  letter-spacing: -0.03em;
  font-weight: 700;
  line-height: 1.25;
}
.game-input {
  width: 100%;
  margin-top: 22px;
  height: 52px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #0b0b0c;
  padding: 0 14px;
  outline: none;
}

/* Footer */
.footer {
  border-top: 1px solid var(--line);
  padding: 48px 0 28px;
  background: #070708;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
}
.footer h4 { font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { color: #d8d8dc; font-size: 14px; }
.footer a:hover { color: #fff; }
.socials { display: flex; gap: 10px; margin-top: 16px; }
.socials a {
  width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid var(--line);
}
.legal {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

/* Toast / modal / widget */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  background: #fff;
  color: #111;
  padding: 10px 14px;
  border-radius: 10px;
  font-weight: 600;
  z-index: 80;
  display: none;
}
.widget {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 280px;
  background: #1a0b0c;
  border: 1px solid rgba(255,42,51,.35);
  border-radius: 16px;
  padding: 14px;
  z-index: 50;
  box-shadow: var(--shadow);
}
.widget p { color: #f1c9cc; font-size: 13px; margin: 8px 0 12px; }
.modal-back {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.62);
  display: none;
  place-items: center;
  z-index: 70;
  padding: 20px;
}
.modal-back.on { display: grid; }
.modal {
  width: min(460px, 100%);
  background: #121213;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
}
.hidden { display: none !important; }

@media (max-width: 1100px) {
  .nav { display: none; }
  .nav.open {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: absolute;
    top: var(--header);
    left: 0; right: 0;
    background: #0b0b0c;
    border-bottom: 1px solid var(--line);
    padding: 12px 24px 18px;
    gap: 4px;
    z-index: 45;
  }
  .nav.open a { padding: 10px 0; width: 100%; }
  .menu-btn { display: grid; place-items: center; width: 36px; height: 36px; color: #fff; }
  .room-grid, .how, .featured, .lobby, .footer-grid, .tips, .scene-grid, .clip-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 700px) {
  .scene-grid, .clip-grid, .room-grid, .featured, .lobby, .tips, .footer-grid, .how {
    grid-template-columns: 1fr;
  }
  .header-right .ghost-link { display: none; }
  .legal { flex-direction: column; }
}
