/* Till 2 Table — local pre-launch landing page. No remote fonts, no trackers. */
/* IBM Plex Sans Thai Looped is self-hosted for Thai body copy. */

@font-face {
  font-family: "Fraunces";
  src: url("fonts/Fraunces-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fraunces";
  src: url("fonts/Fraunces-Italic-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Outfit";
  src: url("fonts/Outfit-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Taviraj";
  src: url("fonts/Taviraj-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}


@font-face {
  font-family: "IBM Plex Sans Thai Looped";
  src: url("fonts/IBMPlexSansThaiLooped-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Sans Thai Looped";
  src: url("fonts/IBMPlexSansThaiLooped-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Sans Thai Looped";
  src: url("fonts/IBMPlexSansThaiLooped-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}


:root {
  --night: #090b10;
  --panel: #12141a;
  --raised: #181b24;
  --line: rgba(224, 178, 74, 0.22);
  --line-strong: rgba(224, 178, 74, 0.45);
  --cream: #f6efe3;
  --text: #ede4d6;
  --muted: #9a8e80;
  --amber: #e0b24a;
  --amber-hi: #ffd78a;
  --teal: #4aa3a8;
  --teal-dim: rgba(74, 163, 168, 0.16);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --pad: clamp(1.25rem, 4.5vw, 2.5rem);
  --measure: 42rem;
  --display: "Fraunces", "Times New Roman", Times, serif;
  --ui: "Outfit", "Segoe UI", system-ui, sans-serif;
  --thai: "Taviraj", "Noto Serif Thai", "Thonburi", serif;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

html.i18n-pending { visibility: hidden; }

html[lang="th"] {
  --ui: "IBM Plex Sans Thai Looped", "Outfit", sans-serif;
  --display: "Taviraj", "IBM Plex Sans Thai Looped", serif;
}


body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--ui);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--night);
  background-image:
    url("assets/night-wash.svg"),
    radial-gradient(ellipse 90% 50% at 50% -12%, rgba(242, 184, 74, 0.18), transparent 55%),
    radial-gradient(ellipse 45% 35% at 100% 8%, rgba(74, 163, 168, 0.10), transparent 55%);
  background-repeat: no-repeat;
  background-size: 100% auto, 100% 80vh, 100% 60vh;
  background-position: top center, top, top right;
  -webkit-font-smoothing: antialiased;
}

/* Fine grain, like wet asphalt. Pointer-events none so it never blocks taps. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 30;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.9'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

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

a { color: var(--amber-hi); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--cream); }

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 40;
  background: var(--amber);
  color: var(--night);
  padding: 0.5rem 0.8rem;
  font-weight: 600;
  border-radius: 4px;
}
.skip:focus { top: calc(0.75rem + var(--safe-t)); }

/* Header — a thin neon tube along the top edge */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: calc(0.85rem + var(--safe-t)) calc(var(--pad) + var(--safe-r)) 0.85rem calc(var(--pad) + var(--safe-l));
  background: color-mix(in srgb, var(--night) 82%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 215, 138, 0.28);
}

.wordmark {
  display: block;
  width: min(196px, 62vw);
  height: auto;
  flex-shrink: 0;
  filter: drop-shadow(0 0 14px rgba(224, 178, 74, 0.28));
}
.wordmark img { width: 100%; height: auto; }

.header-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
  flex: 1 1 auto;
  min-width: 0;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  margin: 0;
  padding: 0.1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(18, 20, 26, 0.45);
}

.lang-btn {
  appearance: none;
  margin: 0;
  padding: 0.28rem 0.5rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-family: var(--ui);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1;
  cursor: pointer;
}

.lang-btn[aria-pressed="true"] {
  color: var(--night);
  background: var(--amber);
  box-shadow: 0 0 12px rgba(224, 178, 74, 0.35);
}

.lang-sep {
  color: var(--muted);
  font-size: 0.65rem;
  padding: 0 0.05rem;
  opacity: 0.7;
}


.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  padding: 0.35rem 0.7rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--amber-hi);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  background: rgba(224, 178, 74, 0.06);
  max-width: 100%;
}
.pill::before {
  content: "";
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 3px rgba(224, 178, 74, 0.22), 0 0 10px rgba(224, 178, 74, 0.7);
}

.wrap {
  width: min(100%, calc(var(--measure) + var(--pad) * 2));
  margin: 0 auto;
  padding-left: calc(var(--pad) + var(--safe-l));
  padding-right: calc(var(--pad) + var(--safe-r));
}

/* Hero */
.hero {
  padding: clamp(2.75rem, 8vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4rem);
}

.kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.8rem;
  margin: 0 0 1.35rem;
}

.thai {
  font-family: var(--thai);
  font-weight: 500;
  font-size: clamp(1.35rem, 3.8vw, 1.7rem);
  line-height: 1.85;
  color: var(--amber-hi);
  text-shadow: 0 0 22px rgba(242, 184, 74, 0.35);
  letter-spacing: 0.01em;
}

.kicker-en {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  position: relative;
  top: -0.12em;
}

.hero h1 {
  margin: 0 0 1.35rem;
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(2.45rem, 8.6vw, 4.35rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--cream);
  font-variation-settings: "opsz" 144, "SOFT" 40, "WONK" 1;
}

.lead {
  margin: 0 0 2rem;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text);
  max-width: 36em;
}
.lead p { margin: 0 0 0.85em; }
.lead p:last-child { margin-bottom: 0; color: var(--muted); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  padding: 0.7rem 1.25rem;
  border: 0;
  border-radius: 999px;
  font-family: var(--ui);
  font-size: 0.95rem;
  font-weight: 550;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
}
.btn[disabled],
.btn[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.8;
  background: var(--raised);
  color: var(--muted);
  border: 1px solid var(--line);
}

.note {
  margin: 0.7rem 0 0;
  font-size: 0.875rem;
  color: var(--muted);
}

.flow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.15rem;
  margin: 0.35rem 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.92rem;
  color: var(--cream);
}
.flow li {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.flow li:not(:last-child)::after {
  content: "→";
  color: var(--amber);
  font-size: 0.95rem;
  padding: 0 0.35rem;
  font-family: var(--ui);
  text-shadow: 0 0 10px rgba(224, 178, 74, 0.45);
}

.panel {
  margin: 0 0 1.25rem;
  padding: 1.25rem 1.25rem 1.15rem;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  border: 1px solid var(--line);
  border-radius: 1rem;
  box-shadow: inset 0 1px 0 rgba(255, 215, 138, 0.08);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.section-label {
  margin: 0 0 0.75rem;
  font-size: 0.6875rem;
  font-weight: 550;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}

.hero .section-label { margin-bottom: 0.55rem; }

.metrics {
  margin: 0;
  padding: 0;
  list-style: none;
}
.metrics li {
  margin: 0;
  padding: 0.55rem 0;
  border-top: 1px solid var(--line);
  color: var(--cream);
}
.metrics li:first-child { border-top: 0; padding-top: 0; }
.metrics li:last-child { padding-bottom: 0; }

.till {
  margin: 0 0 2.5rem;
  padding: 1.15rem 1.25rem 1.2rem;
  border: 1px solid var(--line-strong);
  border-radius: 1rem;
  background:
    linear-gradient(180deg, rgba(224, 178, 74, 0.07), rgba(18, 20, 26, 0.6) 40%),
    color-mix(in srgb, var(--panel) 80%, #1a1610);
  box-shadow: 0 0 40px rgba(224, 178, 74, 0.05), inset 0 1px 0 rgba(255, 215, 138, 0.16);
}
.till p { margin: 0; }
.till .main {
  color: var(--cream);
  font-size: 1.05rem;
  line-height: 1.5;
}
.till .aside {
  margin-top: 0.55rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.waitlist {
  padding: 0 0 clamp(2.5rem, 6vw, 3.5rem);
  border-top: 1px solid var(--line);
  padding-top: clamp(2rem, 5vw, 2.75rem);
}
.waitlist h2 {
  margin: 0 0 0.5rem;
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(1.6rem, 4.5vw, 2rem);
  color: var(--cream);
  font-variation-settings: "opsz" 72, "SOFT" 30, "WONK" 0;
  letter-spacing: -0.02em;
}
.waitlist .lead-sm {
  margin: 0 0 1.15rem;
  color: var(--muted);
  max-width: 32em;
}

.site-footer {
  padding: 1.25rem calc(var(--pad) + var(--safe-r)) calc(1.5rem + var(--safe-b)) calc(var(--pad) + var(--safe-l));
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
  text-align: center;
}
.site-footer p { margin: 0; }

@media (max-width: 719px) {
  .kicker {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.1rem;
  }
  .kicker-en { top: 0; }
  .flow {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }
  .flow li {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }
  .flow li:not(:last-child)::after {
    content: "↓";
    padding: 0.1rem 0 0.15rem;
  }
}

@media (min-width: 720px) {
  .flow { font-size: 1rem; }
  .metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 1.5rem;
  }
  .metrics li:nth-child(2) { border-top: 0; padding-top: 0; }
}


/* Thai mode: self-hosted Thai body face, room for tone marks, tighter labels. */
html[lang="th"] body {
  line-height: 1.75;
}

html[lang="th"] .pill,
html[lang="th"] .section-label,
html[lang="th"] .kicker-en {
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 500;
}

html[lang="th"] .kicker-en { display: none; }

html[lang="th"] .hero h1 {
  line-height: 1.28;
  letter-spacing: 0;
  font-variation-settings: normal;
  padding-top: 0.12em;
}

html[lang="th"] .lead {
  line-height: 1.8;
  overflow-wrap: break-word;
}

html[lang="th"] .till .main,
html[lang="th"] .till .aside,
html[lang="th"] .waitlist .lead-sm,
html[lang="th"] .metrics li,
html[lang="th"] .site-footer {
  line-height: 1.7;
  overflow-wrap: break-word;
}

html[lang="th"] .waitlist h2 {
  line-height: 1.35;
  letter-spacing: 0;
  font-variation-settings: normal;
  padding-top: 0.08em;
}

html[lang="th"] .btn {
  font-weight: 600;
  letter-spacing: 0;
}

html[lang="th"] .flow {
  line-height: 1.5;
}

@media (max-width: 419px) {
  .wordmark { width: min(168px, 48vw); }
  .pill { padding: 0.3rem 0.55rem; font-size: 0.625rem; }
  html[lang="th"] .hero h1 {
    font-size: clamp(2.05rem, 9.2vw, 3rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; text-shadow: none !important; filter: none !important; }
}
