:root {
  /* Cerla · Midnight colour tokens. Only these colours, or mixes of them, are used. */
  --ui-bg: #000000;
  --ui-surface: #110D13;
  --ui-surface-raised: #1C161F;
  --ui-field: #0C090D;
  --ui-line: #241D27;
  --ui-line-control: #6E5E72;
  --ui-glow: #A4338024;
  --text-primary: #F7F0F6;
  --text-secondary: #B7A9B5;
  --text-muted: #8E8290;
  --text-on-brand: #FFE4FF;
  --brand-primary: #A43380;
  --brand-secondary: #38285F;
  --brand-light: #FFE4FF;
  --brand-accent: #ED5B9A;
  --status-error: #F47857;
  --bg: var(--ui-bg);
  --text: var(--text-primary);
  --text-2: var(--text-secondary);
  --text-3: var(--text-muted);
  --plum: var(--brand-secondary);
  --blush: var(--text-on-brand);
  --pink: var(--brand-accent);
  --line-control: var(--ui-line-control);
  --error: var(--status-error);
  /* Button states, mixed from the tokens. Label contrast stays above 4.5:1 in every state. */
  --btn-hover: color-mix(in srgb, var(--brand-primary) 75%, var(--brand-secondary));
  --btn-press: color-mix(in srgb, var(--btn-hover) 80%, var(--ui-bg));
  --radius-control: 6px;
  --radius-inset: 4px;
  --radius-nav: 7px;
  --signup-fill: var(--ui-field);
  --nav-fill: rgba(34, 39, 62, .45);
  --nav-blur: 17.5px;
  --nav-ink: var(--text-primary);
  --margin: clamp(24px, 4.45cqi, 64px);
  --col-gap: 24px;
  --font-display: "Suisse Intl", Arial, sans-serif;
  --font-ui: "Suisse Intl", Arial, sans-serif;
  --ease: cubic-bezier(.22, .7, .18, 1);
  color-scheme: only dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; scrollbar-gutter: stable; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font-ui); font-synthesis: none;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--brand-accent); outline-offset: 2px; }
/* Links: text-primary and underlined at rest; brand-accent with a 2px underline on hover. */
.link, .note a, .foot-links a { color: var(--text-primary); text-decoration: underline; text-decoration-thickness: 1px;
  text-underline-offset: 3px; border-radius: 2px; transition: color .2s ease, text-decoration-color .2s ease; }
:is(.link, .note a, .foot-links a):hover { color: var(--brand-accent); text-decoration-thickness: 2px; }

.page { --screen-h: 100svh; container: page / inline-size; position: relative; isolation: isolate; overflow: hidden;
  min-height: max(640px, var(--screen-h)); display: flex; flex-direction: column; background: var(--bg); }

/* Banner canvas, its shade and the corner glow sit behind the content. The shade gradients live in soft-fade.css. */
.art-full { position: absolute; inset: 0; z-index: -3; }
.shade-full { position: absolute; inset: 0; z-index: -2; pointer-events: none; }
.glow { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse 60% 65% at 100% 0%, var(--ui-glow), transparent 76%); }

.masthead { height: clamp(76px, calc(var(--screen-h) * .107), 96px); padding: 0 var(--margin); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.nav-pill { display: flex; align-items: center; gap: 0; height: 54px; padding: 0 10px; border: 0; border-radius: var(--radius-nav);
  background: var(--nav-fill); box-shadow: none;
  -webkit-backdrop-filter: blur(var(--nav-blur)); backdrop-filter: blur(var(--nav-blur)); }
.nav-pill a { position: relative; isolation: isolate; display: flex; align-items: center; gap: 6px; height: 54px; padding: 0 14px;
  font: 400 13px/1.07 var(--font-display); letter-spacing: -.025em; text-transform: uppercase; color: var(--nav-ink);
  text-decoration: none; background: none; transition: color .2s; }
.nav-pill a::before { content: ""; position: absolute; z-index: -1; inset: 10px 0; border-radius: 4px; background: #DBE5ED;
  opacity: 0; transform: scale(.9, .7); pointer-events: none;
  transition: transform .2s cubic-bezier(.645, .045, .355, 1), opacity .2s cubic-bezier(.645, .045, .355, 1); }
.nav-pill a:is(:hover, :focus-visible) { background: transparent; color: var(--nav-ink); }
.nav-pill a:is(:hover, :focus-visible)::before { opacity: .15; transform: scale(1); }
.nav-pill a:focus-visible { outline: none; text-decoration-line: underline; text-decoration-color: var(--pink);
  text-decoration-thickness: 2px; text-underline-offset: 5px; }
@container page (max-width: 760px) {
  .nav-pill { height: 44px; padding: 0; }
  .nav-pill a { height: 44px; padding: 0 9px; gap: 5px; font-size: 12px; border-radius: var(--radius-nav); }
  .nav-pill a::before { content: none; }
  .nav-pill:has(a:is(:hover, :focus-visible)) { background: color-mix(in srgb, var(--bg) 70%, transparent); }
}
@container page (max-width: 360px) { .nav-pill a { padding: 0 7px; } }

.stage { flex: 1; display: grid; align-content: center; row-gap: clamp(18px, calc(var(--screen-h) * .03), 34px);
  padding: clamp(4px, calc(var(--screen-h) * .008), 16px) 0 clamp(16px, calc(var(--screen-h) * .03), 32px); }
.promise, .below { padding: 0 var(--margin); display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); }
.promise > * { grid-column: 1 / span 10; }

.status { justify-self: start; margin: 0 0 24px; display: inline-flex; align-items: center; gap: 8px; min-height: 30px; padding: 6px 12px;
  border-radius: var(--radius-control); background: var(--plum); color: var(--blush); font: 500 13px/18px var(--font-ui); letter-spacing: .005em; }
.status .dot { flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--pink); }
.status-label { transform: translateY(1px); }
h1 { margin: 0; font-family: var(--font-display); font-weight: 300; font-size: clamp(40px, min(6.4cqi, calc(var(--screen-h) * .118)), 112px);
  line-height: 1; letter-spacing: -.05em; color: var(--text); text-wrap: balance; max-width: 11.6em; }

.horizon { position: relative; height: clamp(120px, calc(var(--screen-h) * .25), 250px); }
.art-full canvas { display: block; width: 100%; height: 100%; }

.below { align-items: start; row-gap: 24px; }
.lede { grid-column: 1 / span 4; margin: 6px 0 0; font: 400 clamp(17px, 1.35cqi, 20px)/1.5 var(--font-ui); color: var(--text-2); text-wrap: pretty; }
.signup { grid-column: 7 / span 6; }
.signup-form { display: grid; gap: 10px; }
.signup-form label { font: 500 14px/20px var(--font-ui); color: var(--text-primary); }

.field-row { display: flex; align-items: center; gap: 4px; padding: 4px; border-radius: var(--radius-control); background: var(--signup-fill);
  border: 1px solid var(--line-control); transition: border-color .2s; }
.field-row:has(.input:focus-visible) { outline: 2px solid var(--brand-accent); outline-offset: 2px; }
.field-row.invalid { border-color: var(--error); }
.input { flex: 1 1 200px; min-width: 0; height: 48px; padding: 0 14px; border: 0; border-radius: var(--radius-inset); background: transparent;
  color: var(--text); font: 400 17px/1 var(--font-ui); }
.input::placeholder { color: var(--text-3); opacity: 1; }
.input:focus-visible { outline: none; }
.btn-primary { position: relative; isolation: isolate; overflow: hidden; flex: none; height: 48px; padding: 0 20px; border: 0;
  border-radius: var(--radius-inset); background: var(--brand-primary); color: var(--text-primary);
  font: 500 16px/1 var(--font-ui); letter-spacing: -.005em; cursor: pointer; transition: background-color .25s ease; }
/* On hover a soft brand-light glow crosses the button once, left to right. 18% is the most the label's 4.5:1 contrast allows. */
.btn-primary::after { content: ""; position: absolute; z-index: -1; top: -30%; bottom: -30%; left: 0; width: 46%; pointer-events: none;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--brand-light) 18%, transparent), transparent);
  opacity: 0; transform: translateX(-110%); }
@media (hover: hover) {
  .btn-primary:hover { background: var(--btn-hover); }
  .btn-primary:hover::after { animation: btn-light .95s cubic-bezier(.45, .05, .25, 1) both; }
}
.btn-primary:focus-visible { background: var(--btn-hover); }
.btn-primary:active { background: var(--btn-press); }
@keyframes btn-light { 0% { opacity: 0; transform: translateX(-110%); } 18%, 78% { opacity: 1; } 100% { opacity: 0; transform: translateX(240%); } }
.note { margin: 2px 0 0; font: 400 14px/1.5 var(--font-ui); color: var(--text-2); }

.foot { padding: 0 var(--margin) 22px; display: flex; align-items: center; justify-content: space-between; gap: 8px 24px; flex-wrap: wrap;
  font: 400 14px/20px var(--font-ui); color: var(--text-3); }
.foot p { margin: 0; }
.foot-links { display: flex; align-items: center; gap: 4px 24px; flex-wrap: wrap; }
.foot-links a { padding: 12px 0; }

/* Apply entrance states at first style resolution, not after banner.js arrives. */
@media (prefers-reduced-motion: no-preference) {
  .page .promise > *, .page .below > * { animation: arrive .7s var(--ease) both; }
  .page .promise > h1 { animation-delay: .05s; }
  .page .below > .lede { animation-delay: .5s; }
  .page .below > .signup { animation-delay: .62s; }
  .page .art-full { animation: art-arrive .9s cubic-bezier(.2, 0, .2, 1) both; }
}
@media (prefers-reduced-motion: reduce) {
  .page .promise > *, .page .below > * { animation: arrive-fade .6s ease both; }
  .page .promise > h1 { animation-delay: .05s; }
  .page .below > .lede { animation-delay: .35s; }
  .page .below > .signup { animation-delay: .45s; }
}
@keyframes arrive { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes arrive-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes art-arrive { from { opacity: .2; } to { opacity: 1; } }

@container page (max-width: 899px) {
  .lede { grid-column: 1 / -1; max-width: 32em; }
  .signup { grid-column: 1 / -1; max-width: 560px; }
  .promise > * { grid-column: 1 / -1; }
}
@container page (max-width: 559px) {
  .masthead { height: 76px; }
  .stage { align-content: start; row-gap: 14px; padding-top: 8px; }
  .status { margin-bottom: 16px; }
  h1 { font-size: clamp(32px, 10.4cqi, 46px); line-height: 1.02; letter-spacing: -.045em; }
  .horizon { height: clamp(96px, calc(var(--screen-h) * .14), 132px); }
  .below { row-gap: 22px; }
  .lede { margin: 0; font-size: 17px; }
  .field-row { flex-direction: column; align-items: stretch; padding: 0; gap: 10px; background: none; border: 0; border-radius: 0; }
  .field-row:has(.input:focus-visible) { outline: none; }
  .field-row.invalid { border: 0; }
  .input { flex: none; width: 100%; height: 54px; padding: 0 16px; border-radius: var(--radius-control); border: 1px solid var(--line-control); background: var(--signup-fill); }
  .field-row.invalid .input { border-color: var(--error); }
  .input:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; border-color: var(--text-2); }
  .btn-primary { width: 100%; height: 54px; border-radius: var(--radius-control); }
}

/* Reduced motion (device setting): nothing moves. Short fades and colour changes stay, so hover feedback still shows.
   The banner is governed by banner.js and its Pause control. */
@media (prefers-reduced-motion: reduce) {
  .nav-pill a::before, .nav-pill a:is(:hover, :focus-visible)::before { transform: none; }
  .btn-primary::after { display: none; }
}
