/* The Anthology RSVP. The Ministry house style (theministry.com): Akkurat,
   black ground, flat hairline surfaces, 2px corners on inputs and panels,
   pill buttons, bold uppercase headings, light body copy. Dark only. */

@font-face { font-family: "Akkurat"; font-style: normal; font-weight: 300; font-display: swap; src: url("/assets/fonts/Akkurat-Light.woff2") format("woff2"); }
@font-face { font-family: "Akkurat"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/fonts/Akkurat.woff2") format("woff2"); }
@font-face { font-family: "Akkurat"; font-style: normal; font-weight: 700; font-display: swap; src: url("/assets/fonts/Akkurat-Bold.woff2") format("woff2"); }

:root {
  --bg: #000000;
  --surface: #0b0b0b;
  --input: #1a1a1a;
  --border: #2a2a2a;
  --border-strong: #525252;
  --text: #ffffff;
  --muted: #a3a3a3;
  --faint: #6a6a6a;
  --danger: #d4323e;
  --radius: 2px;
  --font: "Akkurat", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
html { color-scheme: dark; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-weight: 300;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100svh;
}
a { color: inherit; }

/* ---- Mobile first: poster is screen one, form below ------------------ */
.poster {
  width: 100%;
  aspect-ratio: 1080 / 1350;
  background: #000 url("/assets/anthology-mobile.jpg?v=2") center / cover no-repeat;
}

.card {
  padding: 28px 20px calc(40px + env(safe-area-inset-bottom));
  max-width: 520px;
  margin: 0 auto;
}

.kicker {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
}
.card__title {
  margin: 0 0 12px;
  font-size: 44px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.02em;
  text-transform: uppercase;
}
.card__lead { margin: 0 0 10px; font-size: 16px; }
.card__details {
  margin: 0 0 24px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
}

.form { display: flex; flex-direction: column; gap: 14px; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field__label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
}
.field input, .field textarea {
  width: 100%;
  padding: 12px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--input);
  color: var(--text);
  font: 400 16px/1.3 var(--font); /* 16px stops iOS zooming on focus */
  transition: border-color .3s;
}
.field textarea { resize: vertical; min-height: 64px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--text); }
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.invalid { border-color: var(--danger) !important; }

.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  font-weight: 400;
  cursor: pointer;
}
.check input {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: #ffffff;
}
.check--small { font-size: 13px; font-weight: 300; color: var(--muted); }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.turnstile:empty { display: none; }

.btn {
  margin-top: 4px;
  padding: 14px 24px;
  border: 1.5px solid #ffffff;
  border-radius: 50px;
  background: #ffffff;
  color: #000000;
  font: 700 14px/1 var(--font);
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color .3s, color .3s;
}
.btn:hover:not(:disabled) { background: transparent; color: #ffffff; }
.btn:focus-visible { outline: 2px solid #ffffff; outline-offset: 3px; }
.btn:disabled { opacity: .6; cursor: default; }

.form__error { margin: 0; font-size: 14px; color: var(--danger); font-weight: 400; }
.form__legal { margin: 2px 0 0; font-size: 12px; color: var(--faint); }

.done__title {
  margin: 0 0 10px;
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -.02em;
  text-transform: uppercase;
}
.done__msg { margin: 0 0 8px; font-size: 16px; }

.backdrop { display: none; }

/* Between phone and wide desktop: the same stack, poster held to a sane size. */
@media (min-width: 700px) {
  /* height capped at 75svh (width x 1.25) so the form peeks above the fold */
  .poster { width: min(640px, 60svh); margin: 0 auto; }
}

/* ---- Desktop: 16:9 poster beside the form card ----------------------
   The poster's text sits at the top left AND bottom left, so it must never
   be cover-cropped (fixed 2026-10-02, cover cut the title and address on
   wide short screens). It is always height-fit and pinned left, so nothing
   is lost top or bottom. Any width left over on wide screens is filled by a
   blurred, darkened copy behind it, and the card sits over that.
   The side-by-side layout only applies when the card cannot reach the title
   (title ends at about 0.82 x viewport height), which holds at 1100px wide
   and 4:3 or wider. Squarer or smaller windows get the stacked layout. */
@media (min-width: 1100px) and (min-aspect-ratio: 4/3) {
  .poster { display: none; }
  .backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    background: #000;
  }
  .backdrop::before, .backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("/assets/anthology-desktop.jpg?v=2");
    background-repeat: no-repeat;
  }
  .backdrop::before {
    inset: -40px;
    background-size: cover;
    background-position: center;
    filter: blur(28px) brightness(.45);
  }
  .backdrop::after {
    background-size: auto 100%;
    background-position: left top;
  }
  body { background: #000; }
  .stage {
    min-height: 100svh;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 3vh 3vw;
  }
  .card {
    width: clamp(360px, 28vw, 440px);
    margin: 0;
    padding: 32px 32px 28px;
    background: rgba(0, 0, 0, .72);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: var(--radius);
  }
}

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