:root {
  color-scheme: dark;
  --cream: #EDE7DB;
  --muted: rgba(237, 231, 219, 0.72);
  --dim: rgba(237, 231, 219, 0.5);
  --hair: rgba(237, 231, 219, 0.2);
  --ember: #D2562A;
  --ember-dark: #B4461F;
  --serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* One scale unit tied to the smaller of width and height,
     so the whole page fits one screen without scrolling */
  --u: min(1vw, 1.35dvh);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: #080f17; }

body {
  color: var(--cream);
  font-family: var(--sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

/* Photo background, darkened at the top so the type reads cleanly */
.background { position: fixed; inset: 0; pointer-events: none; }
.background img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }
.background::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 55% at 50% 42%, rgba(6, 11, 18, 0.55), rgba(6, 11, 18, 0) 75%),
    linear-gradient(180deg, rgba(6, 11, 18, 0.35), rgba(6, 11, 18, 0.1) 55%, rgba(6, 11, 18, 0.45));
}

.page {
  position: relative;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding:
    max(calc(var(--u) * 3), env(safe-area-inset-top), 1.25rem)
    1.5rem
    max(calc(var(--u) * 3), env(safe-area-inset-bottom), 1.25rem);
  text-align: center;
}

/* Logo lockup: mark centred on the name, tagline under the name */
.lockup {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  column-gap: calc(var(--u) * 1.8);
  text-align: left;
}
.mark {
  grid-column: 1; grid-row: 1;
  width: max(calc(var(--u) * 6), 2.75rem);
  height: auto;
  overflow: visible;
}
.name {
  grid-column: 2; grid-row: 1;
  margin: 0;
  padding-bottom: 0.1em;
  font-family: var(--serif);
  font-weight: 300;
  font-size: max(calc(var(--u) * 5), 1.9rem);
  line-height: 1;
  letter-spacing: -0.02em;
  white-space: nowrap;
  font-variation-settings: "opsz" 72;
}
.tagline {
  grid-column: 2; grid-row: 2;
  margin: calc(var(--u) * 0.5) 0 0 0.06em;
  font-size: max(calc(var(--u) * 1.6), 0.9rem);
  color: var(--muted);
}
.dot { color: var(--ember); }

main { width: min(100%, 62rem); margin-top: calc(var(--u) * 5); }

h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: max(calc(var(--u) * 6), 2.1rem);
  line-height: 1.06;
  letter-spacing: -0.025em;
  text-wrap: balance;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.35);
  font-variation-settings: "opsz" 72;
}

.support {
  margin: calc(var(--u) * 2) auto 0;
  max-width: 44rem;
  font-size: max(calc(var(--u) * 1.75), 1rem);
  line-height: 1.5;
  color: var(--muted);
  text-wrap: balance;
}

/* Countdown */
.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(100%, calc(var(--u) * 62));
  margin: calc(var(--u) * 4.2) auto 0;
}
.unit + .unit { border-left: 1px solid var(--hair); }
.number {
  display: block;
  font-family: var(--serif);
  font-weight: 300;
  font-size: max(calc(var(--u) * 6), 2.2rem);
  line-height: 1;
  font-variant-numeric: lining-nums tabular-nums;
  font-variation-settings: "opsz" 72;
}
.label {
  display: block;
  margin-top: calc(var(--u) * 0.9);
  font-family: var(--serif);
  font-style: italic;
  font-size: max(calc(var(--u) * 1.45), 0.85rem);
  color: var(--muted);
}
.launch-status { margin: 0; font-family: var(--serif); font-style: italic; color: var(--cream); }
.launch-status:not(:empty) { margin-top: calc(var(--u) * 1.5); }

/* Email sign-up */
.capture { position: relative; width: min(100%, 34rem); margin: calc(var(--u) * 4.5) auto 0; }

form {
  display: flex;
  height: max(calc(var(--u) * 5.4), 3.1rem);
  border: 1px solid rgba(237, 231, 219, 0.32);
  border-radius: 6px;
  background: rgba(10, 16, 24, 0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
}
input, button { font: inherit; }
input[type=email] {
  flex: 1;
  min-width: 0;
  padding: 0 1.25rem;
  border: 0;
  background: transparent;
  color: var(--cream);
  font-size: 1rem;
  font-weight: 300;
}
input::placeholder { color: var(--dim); opacity: 1; }
button {
  flex: none;
  padding: 0 1.75rem;
  border: 0;
  background: var(--ember);
  color: #fff;
  font-family: var(--sans);
  font-size: 0.98rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.2s;
}
button:hover { background: var(--ember-dark); }
button:disabled { cursor: wait; opacity: 0.8; }
form:focus-within { border-color: rgba(237, 231, 219, 0.6); }
input:focus-visible { outline: none; }
button:focus-visible { outline: 2px solid #FFB38C; outline-offset: -4px; }

.form-status {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--cream);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}
.form-status[data-kind="error"] { color: #FFC2A8; }

.sr-only, .trap {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}

/* The one motion: the needle finds its bearing, then the content settles in */
.needle { transform-origin: 50px 57px; animation: settle 2.6s cubic-bezier(.3, 1.3, .45, 1) 0.2s both; }
.reveal { animation: appear 1.2s ease-out 0.7s both; }
@keyframes settle {
  0% { transform: rotate(-150deg); opacity: 0; }
  12% { opacity: 1; }
  100% { transform: rotate(0deg); opacity: 1; }
}
@keyframes appear { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .needle, .reveal { animation: none; }
  button { transition: none; }
}

/* Phones */
@media (max-width: 600px) {
  :root { --u: min(2.6vw, 1.15dvh); }
  .br { display: none; }
  .mark { width: 2.9rem; }
  .name { font-size: 2.1rem; }
  .tagline { font-size: 0.92rem; }
  h1 { font-size: min(9.6vw, 2.6rem); line-height: 1.08; }
  .support { font-size: 1rem; max-width: 22rem; }
  .countdown { width: 100%; }
  .number { font-size: min(11vw, 3rem); }
  .label { font-size: 0.85rem; }
  form { flex-direction: column; height: auto; gap: 0.6rem; border: 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; overflow: visible; }
  input[type=email] {
    flex: none;
    width: 100%;
    height: 3.1rem;
    border: 1px solid rgba(237, 231, 219, 0.32);
    border-radius: 6px;
    background: rgba(10, 16, 24, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    font-size: 16px; /* stops iOS zooming in */
  }
  input[type=email]:focus-visible { border-color: rgba(237, 231, 219, 0.6); }
  button { height: 3.1rem; border-radius: 6px; }
}

/* Short phones: tighten the support line */
@media (max-width: 600px) and (max-height: 700px) {
  .support { font-size: 0.92rem; }
  .name { font-size: 1.8rem; }
  .mark { width: 2.5rem; }
}
@media (max-width: 600px) and (max-height: 600px) {
  .support { display: none; }
}

/* Short laptop windows and landscape phones */
@media (min-width: 601px) and (max-height: 560px) {
  .support { display: none; }
}
