/* ---------------------------------------------------------------------------
   Hermes Agent Buildathon — Waitlist
   Minimal, editorial, high-fashion. Inverted (white) version of the black poster.
--------------------------------------------------------------------------- */

:root {
  --bg: #ffffff;
  --ink: #0a0a0a;
  --muted: #6b6b6b;
  --line: #e6e6e6;
  --motif: #eeeeee;

  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --page-max: 640px;
}

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

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

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Faint concentric radial motif behind the hero — barely visible. */
.motif {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: repeating-radial-gradient(
    circle at 50% 38%,
    var(--motif) 0,
    var(--motif) 1px,
    transparent 1px,
    transparent 34px
  );
  opacity: 0.6;
  mask-image: radial-gradient(circle at 50% 38%, #000 0, transparent 72%);
  -webkit-mask-image: radial-gradient(circle at 50% 38%, #000 0, transparent 72%);
}

.page {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 56px 24px 40px;
  text-align: center;
}

/* Eyebrow ----------------------------------------------------------------- */
.eyebrow {
  margin: 0 0 28px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Headline ---------------------------------------------------------------- */
.headline {
  margin: 0 auto;
  max-width: 12ch;
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(2.6rem, 9vw, 4.75rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.subhead {
  margin: 22px auto 0;
  max-width: 34ch;
  font-size: 1.02rem;
  color: var(--muted);
}

/* Countdown --------------------------------------------------------------- */
.countdown {
  margin: 44px 0 40px;
}

.clock {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  justify-content: center;
}

.unit {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.digits {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(2rem, 8vw, 3rem);
  line-height: 1;
  letter-spacing: 0.01em;
  /* Tabular figures so the digits don't jump as they tick. */
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  min-width: 2ch;
}

.label {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.sep {
  font-weight: 500;
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  line-height: 1;
  color: var(--muted);
  transform: translateY(-2px);
}

/* State when the countdown reaches zero. */
body.is-live .clock {
  opacity: 0.35;
}

/* Tally form embed -------------------------------------------------------- */
.form-wrap {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  min-height: 320px;
}

.form-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--muted);
}

.form-wrap.loaded .form-loading {
  display: none;
}

#tally-frame {
  position: relative;
  z-index: 1;
  width: 100%;
  border: 0;
  background: transparent;
}

/* Footer ------------------------------------------------------------------ */
.footer {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 0.75rem;
  color: var(--muted);
}

.footer p {
  margin: 0;
}

/* Accessibility ----------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}

/* Small screens ----------------------------------------------------------- */
@media (max-width: 480px) {
  .page {
    padding: 40px 20px 32px;
  }
  .clock {
    gap: 6px;
  }
}
