/* adae.dev coming soon. Tokens follow the "adae Brand Identity" Figma file:
   Bench and Ink for the page, Graphite for fields on dark, one ink button. */
@font-face { font-family: "Geist"; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/geist-latin-400-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/geist-latin-500-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/geist-latin-600-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Anuphan"; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/anuphan-thai-400-normal.woff2) format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC; }
@font-face { font-family: "Anuphan"; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/anuphan-thai-500-normal.woff2) format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC; }
@font-face { font-family: "Anuphan"; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/anuphan-thai-600-normal.woff2) format("woff2");
  unicode-range: U+02D7, U+0303, U+0331, U+0E01-0E5B, U+200C-200D, U+25CC; }

:root {
  --bg: #F2F3F5;
  --fg: #111317;
  --muted: #5A616C;
  --field: #FFFFFF;
  --line: #D8DCE2;
  --btn-bg: #111317;
  --btn-fg: #FFFFFF;
  --error: #C2362F;
  --ok: #1F8A43;
  --stage: #08090E;
  --font: "Geist", "Anuphan", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111317;
    --fg: #FFFFFF;
    --muted: #A8ACB8;
    --field: #1E2025;
    --line: #272A30;
    --btn-bg: #FFFFFF;
    --btn-fg: #111317;
    --error: #F0705F;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  background: var(--bg);
  color: var(--fg);
  font: 400 16px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  padding: 0 20px;
}
:lang(th) { line-height: 1.65; }
a { color: inherit; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }

.stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 56px 0 32px;
}

.wordmark { margin: 0; line-height: 0; color: var(--fg); }
.wordmark-svg { display: block; width: clamp(200px, 25vw, 360px); height: auto; }
.wordmark--small .wordmark-svg { width: 120px; }

.status {
  margin: 28px 0 0;
  padding: 4px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}
/* Tagline under the wordmark: small, so adae stays the hero. */
.slogan {
  margin: 16px 0 0;
  font-size: clamp(17px, 1.6vw, 22px);
  line-height: 1.35;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.slogan:lang(th) { line-height: 1.5; letter-spacing: 0; }

.teaser {
  position: relative;
  margin-top: 24px;
  width: min(300px, 100%);
  aspect-ratio: 720 / 774;
  border-radius: 20px;
  overflow: hidden;
  background: var(--stage);
}
.teaser video { display: block; width: 100%; height: 100%; object-fit: cover; }
.sound {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.16);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: #FFFFFF;
  cursor: pointer;
}
.sound:hover { background: rgb(255 255 255 / 0.24); }
.sound .on { display: none; }
.sound.is-on .on { display: block; }
.sound.is-on .off { display: none; }

.signup { margin-top: 32px; width: min(440px, 100%); }
.field, .done {
  display: flex;
  align-items: center;
  min-height: 52px;
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.field { gap: 10px; padding: 5px 5px 5px 18px; }
.field:focus-within { border-color: var(--fg); box-shadow: 0 0 0 0.5px var(--fg); }
.field.is-error { border-color: var(--error); box-shadow: 0 0 0 0.5px var(--error); }
.field input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--fg);
  font: inherit;
  font-size: 16px;
  outline: none;
}
.field input::placeholder { color: var(--muted); opacity: 1; }
.notify {
  flex: none;
  height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: 500 15px/1 var(--font);
  cursor: pointer;
}
.notify:disabled { opacity: 0.6; cursor: default; }
.notify:focus-visible { outline-offset: 2px; }
.done { justify-content: center; gap: 10px; padding: 0 14px; }
.done svg { flex: none; }

.helper { margin: 12px 0 0; font-size: 13px; color: var(--muted); }
.helper.is-error { color: var(--error); }
.link { padding: 0; border: 0; background: none; color: inherit; font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.dev-link { display: inline-block; margin-top: 10px; font-size: 13px; color: var(--muted); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; opacity: 0; }

.foot {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 16px;
  padding: 0 0 calc(24px + env(safe-area-inset-bottom, 0px));
  font-size: 13px;
  color: var(--muted);
}

/* Confirmation result and privacy pages */
.stage--result { gap: 0; }
.result-title { margin: 40px 0 0; font-size: 28px; line-height: 1.25; font-weight: 600; letter-spacing: -0.01em; }
.result-body { margin: 12px 0 0; max-width: 34ch; color: var(--muted); }
.result-back { margin-top: 28px; font-size: 15px; }
.result-form { margin-top: 28px; }
.doc { max-width: 620px; margin: 0 auto; padding: 48px 0 64px; text-align: left; }
.doc h1 { margin: 40px 0 8px; font-size: 28px; line-height: 1.25; font-weight: 600; }
.doc h2 { margin: 32px 0 6px; font-size: 17px; font-weight: 600; }
.doc p, .doc li { color: var(--muted); }
.doc .updated { margin: 0; font-size: 13px; color: var(--muted); }
.doc hr { margin: 48px 0 0; border: 0; border-top: 1px solid var(--line); }

@media (max-width: 520px) {
  .stage { padding-top: 40px; }
  .slogan { margin-top: 14px; }
  .status { margin-top: 24px; }
  .teaser { margin-top: 20px; width: 100%; max-width: 350px; }
  .signup { margin-top: 28px; }
}
