:root {
  --bg: #F5F3FA;
  --surface: #FFFFFF;
  --surface-2: #ECE7F5;
  --border: #DCD4EA;
  --text: #211A2E;
  --text-secondary: #574B6B;
  --text-muted: #746A87;
  --accent: #7A2BE0;
  --accent-strong: #B01E6B;
  --on-accent: #FFFFFF;
  --badge-bg: #EFE6FB;
  --badge-text: #6B2FA0;
  --shadow: 0 20px 50px -25px rgba(122, 43, 224, 0.35);
  --radius: 16px;
  --radius-sm: 10px;
  color-scheme: light;
}

/* Light mode is the brand default. Dark only applies when the user
   explicitly toggles it (data-theme="dark"), never from system preference. */
[data-theme="dark"] {
  --bg: #14101C;
  --surface: #1D1828;
  --surface-2: #272033;
  --border: #3A3248;
  --text: #ECE8F5;
  --text-secondary: #B7AECB;
  --text-muted: #877F9B;
  --accent: #B14BFF;
  --accent-strong: #FF4D8D;
  --on-accent: #150A22;
  --badge-bg: #3A2350;
  --badge-text: #D9A6FF;
  --shadow: 0 20px 50px -25px rgba(0, 0, 0, 0.6);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Prompt", "Noto Sans Thai", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: background 0.25s ease, color 0.25s ease;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 { margin: 0 0 0.6em; font-weight: 600; line-height: 1.3; }
p { margin: 0 0 1em; color: var(--text-secondary); }
a { color: inherit; text-decoration: none; }

img, svg { display: block; max-width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 16px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
}
.logo:not(:has(> .logo-mark))::before {
  content: "";
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 9px;
  background: url("/assets/logo-mark.png?v=20260813-violet") center / cover no-repeat;
  box-shadow: 0 8px 20px -12px rgba(122, 43, 224, .75);
}
.logo-mark { border-radius: 9px; box-shadow: 0 8px 20px -12px rgba(122, 43, 224, .75); }
.logo-dot { color: var(--accent); }

.nav {
  display: flex;
  gap: 22px;
  font-size: 15px;
  color: var(--text-secondary);
}
.nav a { white-space: nowrap; }
.nav a:hover { color: var(--accent); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-toggle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

.nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.nav-toggle span { width: 16px; height: 2px; background: var(--text); border-radius: 2px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: var(--shadow);
}
.btn-primary:hover { opacity: 0.92; }
.btn-light {
  background: #ffffff;
  color: var(--accent-strong);
}
.btn-sm { padding: 10px 20px; font-size: 14px; }
.btn-lg { padding: 16px 30px; font-size: 16px; }
.btn-outline {
  background: transparent;
  color: var(--accent-strong);
  box-shadow: inset 0 0 0 1px var(--border);
}
.btn-outline:hover { box-shadow: inset 0 0 0 1px var(--accent); }
.btn-play {
  color: var(--accent-strong);
  background: linear-gradient(135deg, #fff 0%, var(--surface-2) 100%);
  box-shadow: inset 0 0 0 1px var(--border), 0 10px 24px rgba(122, 43, 224, .10);
}
.btn-play:hover { box-shadow: inset 0 0 0 1px var(--accent), 0 14px 28px rgba(122, 43, 224, .15); }

/* Replaces the old waitlist form as the primary conversion point. */
.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 12px;
}
.cta-group-center { justify-content: center; }

/* ---------- Hero ---------- */
.hero { padding: 64px 0 40px; overflow: hidden; }
.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  background: var(--badge-bg);
  color: var(--badge-text);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 999px;
  margin-bottom: 20px;
}
.eyebrow-light { background: rgba(255,255,255,0.16); color: #fff; }

.hero-copy h1 {
  font-size: clamp(32px, 5vw, 48px);
  letter-spacing: -0.02em;
}
.hero-sub {
  font-size: 17px;
  max-width: 46ch;
}

.form-note {
  font-size: 14px;
  color: var(--text-muted);
}
.form-note-light {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
}
.seats-badge {
  display: block;
  color: var(--accent-strong);
  font-weight: 600;
  margin-bottom: 4px;
}
.seats-badge strong { font-variant-numeric: tabular-nums; }

/* ---------- Hero visual (phone mock) ---------- */
.hero-visual { position: relative; display: flex; justify-content: center; }
.phone-mock {
  position: relative;
  z-index: 2;
  width: min(320px, 90%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 28px 18px 22px;
  box-shadow: var(--shadow);
}
.phone-notch {
  width: 60px;
  height: 6px;
  border-radius: 99px;
  background: var(--border);
  margin: 0 auto 20px;
}
.chat-row { display: flex; align-items: flex-end; gap: 10px; margin-bottom: 16px; }
.chat-row.me { justify-content: flex-end; }
.avatar-blur {
  width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), var(--badge-bg));
  filter: blur(3px);
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.avatar-blur.small { width: 32px; height: 32px; }
.avatar-blur .lock {
  filter: none;
  font-size: 12px;
}
.chat-meta { font-size: 11px; color: var(--text-muted); margin-bottom: 4px; }
.chat-bubble {
  font-size: 13px;
  padding: 9px 14px;
  border-radius: 14px 14px 14px 4px;
  max-width: 200px;
}
.chat-bubble.in { background: var(--surface-2); color: var(--text); }
.chat-bubble.in.dim { color: var(--text-muted); }
.chat-bubble.out {
  background: var(--accent);
  color: var(--on-accent);
  border-radius: 14px 14px 4px 14px;
}

.glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
  z-index: 1;
}
.glow-1 { width: 260px; height: 260px; background: var(--accent); top: -40px; right: 20px; }
.glow-2 { width: 200px; height: 200px; background: var(--badge-bg); bottom: -30px; left: 10px; }

/* ---------- Section shared ---------- */
section { padding: 84px 0; }
.section-title { font-size: clamp(24px, 3.4vw, 32px); text-align: center; }
.section-sub { text-align: center; max-width: 46ch; margin: 0 auto 48px; }

/* ---------- Live activity ---------- */
.live-proof { padding: 0 0 72px; }
.live-proof-card {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 1fr) auto;
  align-items: center;
  gap: 28px;
  padding: 26px 28px;
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.live-pill { display: inline-flex; align-items: center; gap: 7px; color: var(--accent-strong); font-size: 12px; font-weight: 700; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #27ae60; box-shadow: 0 0 0 5px color-mix(in srgb, #27ae60 15%, transparent); }
.live-proof h2 { margin: 8px 0 4px; font-size: clamp(20px, 3vw, 27px); }
.live-proof p { margin: 0; font-size: 13.5px; }
.live-proof-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.live-proof-stats div { min-width: 0; padding: 12px 8px; border-radius: 14px; background: var(--surface-2); text-align: center; }
.live-proof-stats strong { display: block; color: var(--accent-strong); font-size: 22px; }
.live-proof-stats span { display: block; color: var(--text-muted); font-size: 10px; }

@media (max-width: 900px) {
  .live-proof-card { grid-template-columns: 1fr; gap: 18px; }
  .live-proof-card > .btn { width: 100%; }
}

@media (max-width: 460px) {
  .live-proof { padding-bottom: 52px; }
  .live-proof-card { padding: 20px 16px; }
  .live-proof-stats strong { font-size: 19px; }
}

/* ---------- How it works ---------- */
.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.how-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}
.how-num {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--badge-bg);
  color: var(--badge-text);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  margin-bottom: 16px;
}
.how-card h3 { font-size: 17px; }
.how-card p { font-size: 14.5px; margin: 0; }

/* ---------- Features ---------- */
.features { background: var(--surface-2); }
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.feature-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--badge-bg);
  color: var(--accent-strong);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-card h3 { font-size: 16px; }
.feature-card p { font-size: 14px; margin: 0; }
.feature-card em { color: var(--accent-strong); font-style: normal; }
.feature-card-link {
  display: block;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.feature-card-link:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.feature-link-label {
  display: inline-block;
  margin-top: 14px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
}

/* ---------- Founder ---------- */
.founder {
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: #fff;
}
[data-theme="dark"] .founder { background: linear-gradient(135deg, #2C2152, #4A3699); }
.founder-inner { display: flex; justify-content: center; }
.founder-copy { max-width: 560px; text-align: center; }
.founder-copy h2 { font-size: clamp(26px, 3.6vw, 36px); }
.founder-list {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: inline-flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}
.founder-list li {
  font-size: 15px;
  padding-left: 26px;
  position: relative;
  color: rgba(255,255,255,0.9);
}
.founder-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #fff;
  font-weight: 700;
}

/* ---------- Safety ---------- */
.safety-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.safety-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
}
.safety-card h3 { font-size: 15px; }
.safety-card p { font-size: 13.5px; margin: 0; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  background: var(--surface);
}
.faq-item summary {
  cursor: pointer;
  font-weight: 500;
  font-size: 15.5px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 20px;
  color: var(--accent);
  margin-left: 12px;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item p { margin: 12px 0 0; font-size: 14.5px; }

/* ---------- Final CTA ---------- */
.final-cta { text-align: center; }
.final-cta h2 { font-size: clamp(26px, 3.6vw, 34px); }
.final-cta-inner .cta-group { margin: 24px auto 0; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 40px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 16px; }
.footer-tagline { font-size: 14px; margin: 8px 0 0; }
.footer-copy { font-size: 13px; color: var(--text-muted); }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { order: -1; margin-bottom: 12px; }
  .how-grid { grid-template-columns: 1fr; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .safety-grid { grid-template-columns: repeat(2, 1fr); }
}

/* The header's own login button is the first thing to drop when space runs
   out — it's reachable from the mobile nav dropdown instead (.nav-login-mobile
   below), and losing it stops the header row from overflowing horizontally
   on narrow phones. */
.nav-login-mobile { display: none; }

@media (max-width: 640px) {
  .nav { display: none; }
  .nav-toggle { display: flex; }
  .header-actions .btn-outline { display: none; }
  .nav-login-mobile { display: block; }
  .feature-grid { grid-template-columns: 1fr; }
  .safety-grid { grid-template-columns: 1fr; }
  .cta-group { flex-direction: column; }
  .cta-group .btn { width: 100%; }
  section { padding: 56px 0; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* Mobile nav dropdown */
body.nav-open .nav {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 68px;
  left: 0;
  right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 16px 24px 24px;
  gap: 16px;
}

/* ---------- Natkan public brand alignment ----------
   Keep every public/SEO page in the same night-violet family as the app. */
body {
  background:
    radial-gradient(circle at 12% 8%, rgba(122, 43, 224, .13), transparent 28rem),
    radial-gradient(circle at 88% 26%, rgba(176, 30, 107, .10), transparent 26rem),
    var(--bg);
  background-attachment: fixed;
}

.site-header {
  background: rgba(20, 16, 28, .92);
  border-bottom-color: rgba(217, 166, 255, .16);
  box-shadow: 0 12px 32px -24px rgba(14, 5, 28, .85);
}
.site-header .logo,
.site-header .nav,
.site-header .nav a { color: #ECE8F5; }
.site-header .nav a:hover { color: #D9A6FF; }
.site-header .theme-toggle,
.site-header .nav-toggle {
  border-color: #3A3248;
  background: #272033;
  color: #D9D0E8;
}
.site-header .nav-toggle span { background: #ECE8F5; }
.site-header .btn-primary {
  background: linear-gradient(135deg, #7A2BE0, #B01E6B);
  color: #fff;
}

.hero { padding-top: 34px; }
.hero-inner {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(34px, 5vw, 64px);
  border: 1px solid rgba(217, 166, 255, .18);
  border-radius: 32px;
  background:
    radial-gradient(circle at 78% 18%, rgba(177, 75, 255, .27), transparent 31%),
    radial-gradient(circle at 94% 88%, rgba(255, 77, 141, .20), transparent 32%),
    linear-gradient(135deg, #100B19 0%, #21122F 48%, #351541 100%);
  box-shadow: 0 32px 80px -42px rgba(76, 20, 123, .78);
}
.hero-copy h1 { color: #FFFFFF; }
.hero-copy .hero-sub,
.hero-copy .form-note { color: #C9C0D8; }
.hero-copy .eyebrow {
  background: rgba(177, 75, 255, .16);
  color: #D9A6FF;
  border: 1px solid rgba(217, 166, 255, .20);
}
.hero-copy .seats-badge { color: #FF8AB5; }
.hero .btn-primary { background: linear-gradient(135deg, #8A35EE, #D02A7B); }
.hero .btn-outline {
  color: #ECE8F5;
  box-shadow: inset 0 0 0 1px rgba(217, 166, 255, .34);
}
.hero .btn-play {
  color: #2A1638;
  background: linear-gradient(135deg, #FFFFFF, #E8D9FA);
  box-shadow: 0 12px 28px -18px rgba(217, 166, 255, .8);
}
.hero .phone-mock {
  background: rgba(29, 24, 40, .94);
  border-color: rgba(217, 166, 255, .20);
  box-shadow: 0 28px 70px -34px rgba(177, 75, 255, .8);
}
.hero .phone-notch { background: #4B405C; }
.hero .chat-meta { color: #9E94AF; }
.hero .chat-bubble.in { background: #30273F; color: #ECE8F5; }
.hero .chat-bubble.out { background: linear-gradient(135deg, #8A35EE, #D02A7B); color: #fff; }

.live-proof-card,
.how-card,
.feature-card,
.safety-card,
.faq-item,
.province-card,
.locality-list li {
  border-color: color-mix(in srgb, var(--accent) 18%, var(--border));
  box-shadow: 0 18px 42px -34px rgba(83, 28, 132, .6);
}
.how-card,
.feature-card,
.safety-card {
  background: linear-gradient(155deg, var(--surface) 0%, color-mix(in srgb, var(--badge-bg) 28%, var(--surface)) 100%);
}
.how-num,
.feature-icon {
  background: linear-gradient(145deg, #EEE3FA, #E0C9F4);
  color: #7426B8;
}
.features {
  background: linear-gradient(180deg, rgba(122, 43, 224, .07), rgba(176, 30, 107, .05));
  border-block: 1px solid color-mix(in srgb, var(--accent) 12%, var(--border));
}
.founder { background: linear-gradient(135deg, #21122F 0%, #5C2091 52%, #A61E6B 100%); }
.final-cta-inner {
  padding: clamp(32px, 5vw, 56px);
  border-radius: 28px;
  background: linear-gradient(135deg, #171020, #352044 58%, #54204D);
  box-shadow: 0 28px 70px -40px rgba(75, 20, 117, .8);
}
.final-cta h2 { color: #FFFFFF; }
.final-cta p { color: #C9C0D8; }

.site-footer {
  border-top-color: rgba(217, 166, 255, .14);
  background: #14101C;
}
.site-footer .logo { color: #ECE8F5; }
.site-footer p { color: #9E94AF; }
.site-footer a:not(.logo) { color: #D9A6FF; }

body.nav-open .nav {
  background: #1D1828;
  border-bottom-color: #3A3248;
}

[data-theme="dark"] body {
  background:
    radial-gradient(circle at 12% 8%, rgba(177, 75, 255, .14), transparent 28rem),
    radial-gradient(circle at 88% 26%, rgba(255, 77, 141, .10), transparent 26rem),
    var(--bg);
}
[data-theme="dark"] .how-num,
[data-theme="dark"] .feature-icon { background: #3A2350; color: #D9A6FF; }

@media (max-width: 900px) {
  .hero-inner { padding: 34px 28px 42px; }
}

@media (max-width: 640px) {
  .hero { padding-top: 20px; }
  .hero-inner { padding: 26px 20px 32px; border-radius: 24px; }
  .final-cta-inner { padding: 32px 20px; border-radius: 22px; }
}
