/* Nodix holding page. The Nodix colours, flat (no gradients): navy ground,
   white text, gold for the brand and the action. */
:root {
  --ground: #0b1420;
  --surface: #102134;
  --border: #26384a;
  --text: #f5f7fa;
  --muted: #aab4c0;
  --gold: #c49a4a;
  --gold-hover: #d4ad62;
  --navy-ink: #102134;
  --danger: #f87171;
  --ok: #4ade80;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body { margin: 0; height: 100%; }

body {
  background: var(--ground);
  color: var(--text);
  font-family: Montserrat, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

#stage {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  overflow: hidden;
}

#network {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.content {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 16px 32px;
  text-align: center;
  animation: rise 0.8s ease-out both;
}

.logo { margin: 0; width: min(460px, 78vw); line-height: 0; animation: appear 1.6s ease-out both; }
.logo svg { width: 100%; height: auto; }

.type {
  min-height: 1.4em;
  margin: 48px 0 0;
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 500;
  letter-spacing: 0.01em;
}
.caret {
  display: inline-block;
  width: 2px;
  height: 1.05em;
  margin-left: 4px;
  vertical-align: -0.12em;
  background: var(--gold);
  animation: blink 1s steps(1) infinite;
}
.typing-done .caret { animation: blink 1s steps(1) 3 forwards; }

.whisper {
  margin: 14px 0 0;
  max-width: 30rem;
  font-size: 16px;
  color: var(--muted);
  opacity: 0;
  transition: opacity 1.4s ease;
}
.typing-done .whisper { opacity: 1; }

.cta {
  margin-top: 36px;
  padding: 14px 26px;
  border: 1px solid var(--gold);
  border-radius: 6px;
  background: transparent;
  color: var(--gold);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  opacity: 0;
  transition: opacity 1.2s ease 0.6s, background 0.2s, color 0.2s;
}
.typing-done .cta { opacity: 1; }
.cta:hover, .cta:focus-visible { background: var(--gold); color: var(--navy-ink); outline: none; }
.cta:disabled { opacity: 0.6; cursor: default; }

.lekker {
  margin: 22px 0 0;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0;
  transition: opacity 1.2s ease 1.2s;
}
.typing-done .lekker { opacity: 0.85; }

form { margin-top: 32px; width: 100%; max-width: 30rem; text-align: left; animation: appear 0.7s ease-out both; }
form[hidden] { display: none; }

.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--muted); }
.field.wide { grid-column: 1 / -1; }
.field input {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 15px;
  outline: 0;
}
.field input:focus { border-color: var(--gold); }

.where { margin: 0; padding: 0; border: 0; min-width: 0; }
.where legend { padding: 0; margin-bottom: 6px; }
.choice { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; }
.choice label { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 10px; background: var(--surface); color: var(--muted); font-size: 14px; cursor: pointer; }
.choice label + label { border-left: 1px solid var(--border); }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice label:has(input:checked) { background: var(--gold); color: var(--navy-ink); font-weight: 600; }
.choice label:has(input:focus-visible) { outline: 2px solid var(--gold); outline-offset: -2px; }
.abroad[hidden] { display: none; }
.abroad { display: flex; flex-direction: column; gap: 8px; }
.note { margin: 0; font-size: 13px; line-height: 1.45; color: var(--muted); }

.send { display: block; width: 100%; margin-top: 18px; opacity: 1; background: var(--gold); color: var(--navy-ink); transition: background 0.2s; }
.send:hover, .send:focus-visible { background: var(--gold-hover); }

@media (max-width: 480px) { .fields { grid-template-columns: 1fr; } }

.consent {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin-top: 14px;
  text-align: left;
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}
.consent input { margin: 2px 0 0; width: 16px; height: 16px; flex-shrink: 0; accent-color: var(--gold); }

.link {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}
.link:hover { color: var(--text); }

#message { min-height: 1.4em; margin: 12px 0 0; font-size: 14px; text-align: center; }
#message.error { color: var(--danger); }
#message.done { color: var(--text); font-size: 18px; }

footer {
  position: relative;
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 0 16px 24px;
  font-size: 13px;
  color: var(--muted);
}
footer a { color: inherit; text-decoration: none; }
footer a:hover, footer .link:hover { color: var(--text); }
footer .link { text-decoration: none; }

dialog {
  max-width: 26rem;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--ground);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}
dialog::backdrop { background: rgba(11, 20, 32, 0.75); }
dialog h2 { margin: 0 0 12px; font-size: 17px; }
dialog p { margin: 0 0 10px; color: var(--muted); }
dialog a { color: #3b82f6; }
dialog .close {
  margin-top: 8px;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}

.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@keyframes appear { from { opacity: 0; } to { opacity: 1; } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .content, .logo, form { animation: none; }
  .caret { display: none; }
}
