:root {
  color-scheme: dark;
  --bg: #050421;
  --bg-soft: #0b0933;
  --surface: rgba(25, 21, 70, 0.82);
  --surface-strong: #191546;
  --surface-soft: rgba(255, 255, 255, 0.055);
  --border: rgba(255, 255, 255, 0.1);
  --border-accent: rgba(147, 112, 255, 0.42);
  --text: #f7f4ff;
  --text-soft: #c7c0df;
  --text-muted: #978eba;
  --accent: #7a5cff;
  --accent-light: #b29cff;
  --accent-warm: #c83cff;
  --success: #66e6aa;
  --shadow: 0 24px 70px rgba(1, 0, 20, 0.42);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 8% -10%, rgba(112, 75, 255, 0.27), transparent 32rem),
    radial-gradient(circle at 100% 20%, rgba(190, 47, 255, 0.15), transparent 30rem),
    linear-gradient(160deg, #070526 0%, var(--bg) 50%, #08062b 100%);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

a:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(178, 156, 255, 0.72);
  outline-offset: 3px;
}

.ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 70%);
}

.site-header {
  position: relative;
  z-index: 5;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  text-decoration: none;
  font-weight: 750;
  letter-spacing: -0.025em;
}

.brand img { width: 42px; height: 42px; }
.brand span { font-size: 1.08rem; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 7px;
}

.site-nav a {
  padding: 9px 12px;
  border-radius: 12px;
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.91rem;
  font-weight: 600;
  transition: color .18s ease, background .18s ease;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--text);
  background: rgba(255, 255, 255, 0.07);
}

.home-main,
.legal-main {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.hero {
  min-height: 560px;
  padding: 72px 0 92px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, .85fr);
  align-items: center;
  gap: clamp(36px, 8vw, 96px);
}

.eyebrow,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--accent-light);
  font-size: .78rem;
  font-weight: 750;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.eyebrow::before,
.page-kicker::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent), var(--accent-warm));
}

h1, h2, h3 { line-height: 1.16; letter-spacing: -0.035em; }

.hero h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(3rem, 7vw, 5.7rem);
  font-weight: 820;
}

.gradient-text {
  background: linear-gradient(105deg, #fff 8%, #c8b9ff 50%, #d963ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy > p:not(.eyebrow) {
  max-width: 620px;
  margin: 24px 0 0;
  color: var(--text-soft);
  font-size: clamp(1rem, 2vw, 1.18rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  min-height: 48px;
  padding: 12px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid transparent;
  border-radius: 15px;
  color: white;
  text-decoration: none;
  font-weight: 720;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.button:hover { transform: translateY(-2px); }
.button.primary { background: linear-gradient(135deg, #7957ff, #9e4dff); box-shadow: 0 14px 32px rgba(103, 69, 255, .28); }
.button.secondary { border-color: var(--border); background: rgba(255,255,255,.055); color: var(--text-soft); }

.hero-visual { position: relative; display: grid; place-items: center; }

.app-preview {
  position: relative;
  width: min(100%, 360px);
  padding: 22px;
  border: 1px solid var(--border-accent);
  border-radius: 30px;
  background: linear-gradient(150deg, rgba(35, 28, 92, .92), rgba(11, 9, 48, .96));
  box-shadow: var(--shadow), inset 0 1px rgba(255,255,255,.08);
  transform: rotate(2deg);
}

.preview-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.preview-brand { display: flex; align-items: center; gap: 10px; font-weight: 750; }
.preview-brand img { width: 38px; height: 38px; }

.points-chip,
.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  white-space: nowrap;
}

.points-chip { padding: 7px 11px; border: 1px solid rgba(255, 197, 82, .35); background: rgba(255, 190, 59, .09); color: #ffd25f; font-size: .82rem; font-weight: 750; }
.preview-title { margin: 32px 0 8px; font-size: .78rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .08em; }
.room-code { margin: 0; font-size: 2.25rem; letter-spacing: .09em; font-weight: 820; }
.preview-row { margin-top: 20px; padding: 14px; border-radius: 17px; background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.06); }
.preview-row strong { display: block; font-size: .94rem; }
.preview-row span { color: var(--text-muted); font-size: .78rem; }
.status-chip { margin-top: 18px; padding: 7px 11px; background: rgba(102,230,170,.1); border: 1px solid rgba(102,230,170,.25); color: var(--success); font-size: .76rem; font-weight: 700; }

.section { padding: 34px 0 82px; }
.section-heading { max-width: 650px; margin-bottom: 28px; }
.section-heading h2 { margin: 0; font-size: clamp(2rem, 4vw, 3.1rem); }
.section-heading p { margin: 13px 0 0; color: var(--text-soft); }

.feature-grid,
.link-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.feature-card,
.link-card {
  border: 1px solid var(--border);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: inset 0 1px rgba(255,255,255,.04);
}

.feature-card { padding: 24px; }
.feature-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 14px; background: linear-gradient(145deg, rgba(122,92,255,.25), rgba(200,60,255,.12)); color: #d9ceff; font-size: 1.25rem; }
.feature-card h3 { margin: 20px 0 8px; font-size: 1.1rem; }
.feature-card p { margin: 0; color: var(--text-soft); font-size: .92rem; }

.policy-section {
  margin-bottom: 70px;
  padding: clamp(24px, 5vw, 44px);
  border: 1px solid var(--border-accent);
  border-radius: 30px;
  background: linear-gradient(145deg, rgba(29,24,78,.92), rgba(15,12,54,.9));
  box-shadow: var(--shadow);
}

.link-grid { margin-top: 26px; }
.link-card { min-height: 170px; padding: 22px; display: flex; flex-direction: column; color: var(--text); text-decoration: none; transition: transform .18s ease, border-color .18s ease, background .18s ease; }
.link-card:hover { transform: translateY(-3px); border-color: rgba(178,156,255,.46); background: rgba(39,32,96,.92); }
.link-card small { color: var(--accent-light); font-weight: 700; }
.link-card h3 { margin: 10px 0 6px; }
.link-card p { margin: 0; color: var(--text-soft); font-size: .88rem; }
.link-arrow { margin-top: auto; padding-top: 18px; color: var(--accent-light); font-weight: 800; }

.legal-main { max-width: 940px; padding: 56px 0 84px; }
.legal-hero { margin-bottom: 28px; }
.legal-hero h1 { max-width: 760px; margin: 0; font-size: clamp(2.35rem, 6vw, 4.25rem); }
.legal-hero .meta { margin: 14px 0 0; color: var(--text-muted); }

.legal-card {
  padding: clamp(22px, 5vw, 48px);
  border: 1px solid var(--border);
  border-radius: 28px;
  background: rgba(18, 15, 59, .88);
  box-shadow: var(--shadow);
}

.legal-card > p:first-child { margin-top: 0; color: var(--text-soft); font-size: 1.04rem; }
.legal-card h2 { margin: 38px 0 12px; padding-top: 4px; color: #ded6ff; font-size: 1.35rem; }
.legal-card p { color: var(--text-soft); }
.legal-card ul, .legal-card ol { padding-left: 1.35rem; color: var(--text-soft); }
.legal-card li + li { margin-top: 8px; }
.legal-card a { color: var(--accent-light); text-underline-offset: 3px; }

.notice {
  margin: 24px 0;
  padding: 18px 20px;
  border: 1px solid rgba(122,92,255,.32);
  border-radius: 18px;
  background: rgba(122,92,255,.08);
}
.notice h2 { margin-top: 0; }
.notice p:last-child, .notice ol:last-child { margin-bottom: 0; }

.page-links { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 9px; }
.page-links a { padding: 9px 12px; border: 1px solid var(--border); border-radius: 12px; background: rgba(255,255,255,.04); color: var(--text-soft); text-decoration: none; font-size: .88rem; }
.page-links a:hover { color: var(--text); border-color: rgba(178,156,255,.38); }

.site-footer {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 34px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: .84rem;
}
.site-footer a { color: var(--text-soft); text-decoration: none; }

@media (max-width: 780px) {
  .site-header { align-items: flex-start; }
  .site-nav { max-width: 58%; flex-wrap: wrap; justify-content: flex-end; gap: 2px; }
  .site-nav a { padding: 7px 8px; font-size: .79rem; }
  .hero { min-height: auto; padding: 42px 0 72px; grid-template-columns: 1fr; }
  .hero h1 { font-size: clamp(2.75rem, 14vw, 4.6rem); }
  .hero-visual { padding-top: 8px; }
  .app-preview { transform: none; }
  .feature-grid, .link-grid { grid-template-columns: 1fr; }
  .link-card { min-height: 145px; }
  .legal-main { padding-top: 34px; }
}

@media (max-width: 480px) {
  .site-header, .home-main, .legal-main, .site-footer { width: min(100% - 24px, 1120px); }
  .site-header { padding: 14px 0; }
  .brand img { width: 38px; height: 38px; }
  .brand span { display: none; }
  .site-nav { max-width: calc(100% - 48px); }
  .site-nav a { font-size: .76rem; }
  .hero { padding-top: 34px; }
  .hero-actions { flex-direction: column; }
  .button { width: 100%; }
  .app-preview { width: 100%; padding: 18px; border-radius: 24px; }
  .policy-section { padding: 20px; border-radius: 24px; }
  .legal-card { border-radius: 22px; }
  .site-footer { flex-direction: column; gap: 5px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
