/* Night Shift (src/theme/index.ts), light and dark. Geist is served from
   /fonts under the SIL Open Font License (fonts/OFL.txt). */
@font-face { font-family: 'Geist'; font-weight: 400; font-display: swap; src: url('/fonts/Geist_400Regular.ttf') format('truetype'); }
@font-face { font-family: 'Geist'; font-weight: 500; font-display: swap; src: url('/fonts/Geist_500Medium.ttf') format('truetype'); }
@font-face { font-family: 'Geist'; font-weight: 600; font-display: swap; src: url('/fonts/Geist_600SemiBold.ttf') format('truetype'); }
@font-face { font-family: 'Geist'; font-weight: 700; font-display: swap; src: url('/fonts/Geist_700Bold.ttf') format('truetype'); }
@font-face { font-family: 'Geist Mono'; font-weight: 500; font-display: swap; src: url('/fonts/GeistMono_500Medium.ttf') format('truetype'); }
@font-face { font-family: 'Geist Mono'; font-weight: 600; font-display: swap; src: url('/fonts/GeistMono_600SemiBold.ttf') format('truetype'); }

:root {
  --background: #f3f5fa;
  --surface: #ffffff;
  --surface-raised: #e9ecf4;
  --border: #d9dde8;
  --divider: #eef0f6;
  --text: #0b1024;
  --text-muted: #555c6e;
  --text-body: #353b4d;
  --accent: #2f6bff;
  --accent-strong: #1a4fd6;
  --accent-soft: #e8eeff;
  --ink: #0b1024;
  --ink-text: #ffffff;
  --focus: #ffaa1f;
  --warning: #8a5300;
  --warning-soft: #fff1d6;
  --sky: linear-gradient(180deg, #030722 0%, #0a1f7a 40%, #2663f0 75%, #48b8ff 100%);
  --sans: 'Geist', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #0b0d16;
    --surface: #151826;
    --surface-raised: #1f2333;
    --border: #2b3042;
    --divider: #23273a;
    --text: #f2f4f8;
    --text-muted: #a3aabb;
    --text-body: #c9cfdc;
    --accent: #6e9bff;
    --accent-strong: #9cc2ff;
    --accent-soft: #1b2a55;
    --ink: #ffffff;
    --ink-text: #0b0d16;
    --focus: #ffb84d;
    --warning: #ffc96b;
    --warning-soft: #3a2a0c;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--background);
  color: var(--text);
  font: 400 17px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* The home page sits on the night sky. */
body.sky { background: var(--sky); background-attachment: fixed; color: #ffffff; }

/* A band of sky across the top of the invite page. */
.band {
  width: 100%;
  height: 200px;
  background: var(--sky);
  border-radius: 0 0 36px 36px;
}

main {
  width: 100%;
  max-width: 472px;
  padding: 72px 16px 32px;
  flex: 1;
}

.band + main { padding-top: 0; margin-top: -44px; }

.icon {
  display: block;
  width: 72px;
  height: 72px;
  border-radius: 20px;
  margin: 0 0 28px;
}

.badge {
  width: 88px;
  height: 88px;
  border-radius: 26px;
  background: linear-gradient(150deg, #3bc8ff, #2f6bff);
  box-shadow: 0 0 0 6px var(--background);
  display: grid;
  place-items: center;
  margin: 0 0 18px;
}

.badge img { width: 88px; height: 88px; border-radius: 26px; }

/* The brand glyph on an amber disc. */
.glyph {
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: var(--focus);
  box-shadow: 0 0 0 10px rgba(255, 170, 31, 0.16);
  display: grid;
  place-items: center;
  margin: 10px 0 36px 10px;
}

h1 {
  font: 700 36px/1.05 var(--sans);
  letter-spacing: -0.03em;
  margin: 0 0 12px;
}

h1.display { font-size: clamp(40px, 12vw, 56px); line-height: 1; letter-spacing: -0.04em; margin-bottom: 18px; }
h1 .fade { color: #9cc8ff; }

h2 { font: 700 22px/1.2 var(--sans); letter-spacing: -0.02em; margin: 12px 0 6px; }
h3 { font: 600 16px/1.3 var(--sans); margin: 0; }

p { margin: 0 0 16px; color: var(--text-muted); }
p.lead { font-size: 18px; color: rgba(255, 255, 255, 0.82); }
body:not(.sky) p.lead { color: var(--text-muted); }

.card {
  background: var(--surface);
  color: var(--text);
  border-radius: 24px;
  padding: 20px;
  margin: 22px 0 0;
}

.card p { font-size: 15px; }
.card p:last-child { margin-bottom: 0; }

.pill {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--warning-soft);
  color: var(--warning);
  font: 600 13px var(--sans);
}

.label { font: 500 13px var(--sans); color: var(--text-muted); margin: 0 0 6px; }

.code {
  font: 600 36px/1.2 var(--mono);
  letter-spacing: 0.04em;
  margin: 0 0 16px;
  color: var(--text);
  overflow-wrap: anywhere;
}

.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.button {
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 52px;
  padding: 12px 16px;
  border-radius: 16px;
  border: 0;
  font: 600 16px var(--sans);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  background: var(--ink);
  color: var(--ink-text);
}

.button.pill-shaped { min-height: 56px; border-radius: 999px; font-size: 17px; margin-top: 24px; }

.button.secondary {
  background: var(--surface);
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--border);
}

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

.steps { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 10px; counter-reset: step; }
.steps li { display: flex; gap: 12px; font-size: 15px; line-height: 1.4; color: var(--text-body); counter-increment: step; }
.steps li::before {
  content: counter(step);
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  display: grid;
  place-items: center;
  font: 700 12px var(--mono);
}

.rows { padding: 0; overflow: hidden; }
.rows > div { padding: 16px 18px; border-bottom: 1px solid var(--divider); }
.rows > div:last-child { border-bottom: 0; }
.rows p { margin: 4px 0 0; font-size: 14px; line-height: 1.45; }

footer {
  width: 100%;
  max-width: 472px;
  padding: 24px 16px 32px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-align: center;
}

body.sky footer { color: rgba(255, 255, 255, 0.7); }

[hidden] { display: none !important; }

/* The privacy policy and terms: long rows of plain text. */
.legal .rows h2 { font-size: 18px; margin: 0; }
.legal .rows p + p { margin-top: 10px; }
.card a { color: var(--accent-strong); }
footer a { color: inherit; }
