/* maiabee site. One family (Archivo, variable width and weight, OFL, fonts/OFL.txt), two colours that mean
   "careful" in nature: the yellow and black of a bee. No inline styles or scripts anywhere: the CSP forbids them. */
@font-face {
  font-family: 'Archivo';
  src: url('/fonts/archivo-wdth.woff2') format('woff2');
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  --yellow: #ffc400;
  --ink: #000;
  --paper: #fff;
  --muted: #4d4d4d;
  --link: #6b4100;
  --error: #a4161a;
  --wall: 6px;
  color-scheme: light;
}

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

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

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-stretch: 100%;
  font-size: 1.125rem;
  line-height: 1.6;
}

a { color: var(--link); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

.wrap { width: min(100% - 3rem, 72rem); margin-inline: auto; }

/* The yellow bands: top of every page, and the join section. */
.band { background: var(--yellow); }

.top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 72px; }
/* The lockup: the labyrinth mark and the wordmark, inline SVG drawn in ink (public/logo.svg is the same, standalone). */
.wordmark { display: inline-flex; align-items: center; gap: 0.7rem; color: var(--ink); text-decoration: none; }
/* whole pixels: a fractional header height leaves a seam between the header band and the hero band */
.wordmark .mark { display: block; height: 36px; width: 36px; }
.wordmark .word { display: block; height: 33px; width: auto; }
.top a.jump { color: var(--ink); font-weight: 650; }

/* Home: the headline and the maze. */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: 3rem;
  padding-block: 2.5rem 4.5rem;
}
h1 {
  margin: 0 0 1.5rem;
  font-stretch: 62%;
  font-weight: 900;
  font-size: clamp(3.1rem, 7.6vw, 6.4rem);
  line-height: 0.9;
  letter-spacing: -0.012em;
  text-wrap: balance;
}
.lede { margin: 0 0 2rem; max-width: 34rem; font-size: 1.3rem; line-height: 1.5; }

.button {
  display: inline-block;
  border: 0;
  border-radius: 0;
  padding: 0.85rem 1.5rem;
  background: var(--ink);
  color: var(--yellow);
  font: inherit;
  font-stretch: 87.5%;
  font-weight: 750;
  font-size: 1.125rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}
.button:hover { background: #262626; }
.button[disabled] { cursor: progress; background: #3d3d3d; }

/* The maze: walls in ink, an agent that stops at the turn to the real way out, then runs straight on for a flag at
   the end of the corridor; a door drops behind it, the flag was bait, and an alert goes out. The un-animated state
   below is the end of the story (what reduced motion shows); the animation starts from the beginning of it. */
.maze { margin: 0; }
.maze svg { display: block; width: 100%; height: auto; max-width: 30rem; margin-inline: auto; overflow: visible; }
.maze .walls { fill: none; stroke: var(--ink); stroke-width: var(--wall); stroke-linecap: square; }
.maze .trail { fill: none; stroke: var(--ink); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 0 10; }
/* The trail is revealed with clip-path: inset(). A flat line's geometry box has no height, so an engine that measured
   the inset against it would clip the whole trail away; the unpainted box gives the group a geometry box equal to its
   stroke box (x -10 to 274, the dots' outer edges), whichever box the engine uses. */
.maze .trail rect { stroke: none; }
.maze .door { stroke: var(--ink); stroke-width: var(--wall); stroke-linecap: square; }
.maze .agent { fill: var(--ink); }
.maze .flag { fill: var(--ink); stroke: var(--ink); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; opacity: 0; }
.maze .ping { fill: none; stroke: var(--ink); stroke-width: 0; }
.maze .agent, .maze .ping { transform-box: fill-box; transform-origin: center; }
.maze .flag { transform-box: fill-box; transform-origin: left bottom; }
.maze figcaption { margin-top: 1rem; font-size: 1rem; text-align: center; }

/* One timeline: every part shares the duration and the delay, and the beats are keyframe offsets (4.4 s in all, so
   the motion is over in under 5 s and needs no pause control). The trail's keyframes repeat the agent's offsets and
   easings, so its edge stays under the agent. The door drops when the agent's back edge clears it (46.09%). */
@media (prefers-reduced-motion: no-preference) {
  .maze .agent, .maze .trail, .maze .door, .maze .flag, .maze .ping {
    animation-duration: 4.4s;
    animation-delay: 0.4s;
    animation-fill-mode: both;
  }
  .maze .agent { animation-name: maze-agent; }
  .maze .trail { animation-name: maze-trail; }
  .maze .door { animation-name: maze-door; }
  .maze .flag { animation-name: maze-flag; }
  .maze .ping { animation-name: maze-ping; }
  .maze .ping.late { animation-name: maze-ping-late; }
}
@keyframes maze-agent {
  0% { transform: translate(-280px, 0px) scale(0); animation-timing-function: cubic-bezier(0.3, 1.6, 0.6, 1) }
  4.09% { transform: translate(-280px, 0px) scale(1); animation-timing-function: linear }
  11.36% { transform: translate(-280px, 0px) scale(1); animation-timing-function: cubic-bezier(0.45, 0, 0.35, 1) }
  28.41% { transform: translate(-80px, 0px) scale(1); animation-timing-function: ease-in-out }
  31.82% { transform: translate(-80px, 8px) scale(1); animation-timing-function: ease-in-out }
  35.23% { transform: translate(-80px, 0px) scale(1); animation-timing-function: linear }
  37.5% { transform: translate(-80px, 0px) scale(1); animation-timing-function: cubic-bezier(0.55, 0, 0.2, 1) }
  51.14% { transform: translate(0px, 0px) scale(1); animation-timing-function: linear }
  60.23% { transform: translate(0px, 0px) scale(1); animation-timing-function: cubic-bezier(0.5, 0, 1, 1) }
  63.64% { transform: translate(-8px, 0px) scale(1); animation-timing-function: cubic-bezier(0, 0, 0.3, 1) }
  68.18% { transform: translate(0px, 0px) scale(1); animation-timing-function: linear }
  100% { transform: translate(0px, 0px) scale(1) }
}
@keyframes maze-trail {
  0% { clip-path: inset(0 100% 0 0); animation-timing-function: linear }
  11.36% { clip-path: inset(0 99.3% 0 0); animation-timing-function: cubic-bezier(0.45, 0, 0.35, 1) }
  28.41% { clip-path: inset(0 28.87% 0 0); animation-timing-function: linear }
  37.5% { clip-path: inset(0 28.87% 0 0); animation-timing-function: cubic-bezier(0.55, 0, 0.2, 1) }
  51.14% { clip-path: inset(0 0% 0 0); animation-timing-function: linear }
  100% { clip-path: inset(0 0 0 0) }
}
@keyframes maze-door {
  0% { transform: translate(0, -40px); animation-timing-function: linear }
  46.09% { transform: translate(0, -40px); animation-timing-function: cubic-bezier(0.5, 0, 1, 1) }
  49.5% { transform: translate(0, 0); animation-timing-function: cubic-bezier(0, 0, 0.3, 1) }
  51.09% { transform: translate(0, -3px); animation-timing-function: cubic-bezier(0.5, 0, 1, 1) }
  52.68% { transform: translate(0, 0); animation-timing-function: linear }
  63.64% { transform: translate(0, 0); animation-timing-function: cubic-bezier(0, 0, 0.3, 1) }
  65% { transform: translate(-2px, 0); animation-timing-function: ease-in-out }
  67.73% { transform: translate(0, 0); animation-timing-function: linear }
  100% { transform: translate(0, 0) }
}
@keyframes maze-flag {
  0% { opacity: 1; transform: scale(1); animation-timing-function: linear }
  46.84% { opacity: 1; transform: scale(1); animation-timing-function: cubic-bezier(0.5, 0, 1, 1) }
  49.11% { opacity: 1; transform: scale(0); animation-timing-function: linear }
  100% { opacity: 0; transform: scale(0) }
}
@keyframes maze-ping {
  0% { transform: scale(0.15); stroke-width: 0; animation-timing-function: linear }
  68.18% { transform: scale(0.15); stroke-width: 0; animation-timing-function: linear }
  68.64% { transform: scale(0.187); stroke-width: 18.35; animation-timing-function: linear }
  72.73% { transform: scale(0.480); stroke-width: 5.84; animation-timing-function: linear }
  77.27% { transform: scale(0.724); stroke-width: 2.90; animation-timing-function: linear }
  81.82% { transform: scale(0.887); stroke-width: 1.58; animation-timing-function: linear }
  86.36% { transform: scale(0.975); stroke-width: 0.72; animation-timing-function: linear }
  90.91% { transform: scale(1.000); stroke-width: 0.00; animation-timing-function: linear }
  100% { transform: scale(1); stroke-width: 0 }
}
@keyframes maze-ping-late {
  0% { transform: scale(0.15); stroke-width: 0; animation-timing-function: linear }
  75% { transform: scale(0.15); stroke-width: 0; animation-timing-function: linear }
  75.45% { transform: scale(0.187); stroke-width: 18.35; animation-timing-function: linear }
  79.55% { transform: scale(0.480); stroke-width: 5.84; animation-timing-function: linear }
  84.09% { transform: scale(0.724); stroke-width: 2.90; animation-timing-function: linear }
  88.64% { transform: scale(0.887); stroke-width: 1.58; animation-timing-function: linear }
  93.18% { transform: scale(0.975); stroke-width: 0.72; animation-timing-function: linear }
  97.73% { transform: scale(1.000); stroke-width: 0.00; animation-timing-function: linear }
  100% { transform: scale(1); stroke-width: 0 }
}

/* The argument, one claim per section: heading on the left, prose on the right. */
.claims { padding-block: 4.5rem 2rem; }
.claim {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 3rem;
  padding-bottom: 3.5rem;
}
h2 {
  margin: 0;
  font-stretch: 70%;
  font-weight: 850;
  font-size: clamp(2rem, 3.6vw, 2.75rem);
  line-height: 1;
  letter-spacing: -0.005em;
  text-wrap: balance;
}
.claim p, .message p { margin: 0 0 1rem; max-width: 36rem; }

/* Join */
.join { padding-block: 4rem; }
.join .claim { padding-bottom: 0; }
.form { margin-top: 1.5rem; max-width: 36rem; }
.form label { display: block; font-weight: 650; margin-bottom: 0.4rem; }
.row { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.row input {
  flex: 1 1 16rem;
  min-width: 0;
  border: 2px solid var(--ink);
  border-radius: 0;
  padding: 0.75rem 0.9rem;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
}
.turnstile { margin-top: 1rem; min-height: 65px; }
.fine { margin-top: 1rem; font-size: 0.95rem; line-height: 1.5; }
.join a { color: var(--ink); }
.hint { margin-top: 0.75rem; color: var(--error); font-weight: 650; }

/* Outcome and notice pages */
.message { padding-block: 4rem 5rem; }
.message > * { max-width: 40rem; }
.message h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); }
.message h2 { font-stretch: 75%; font-size: 1.6rem; margin: 2.5rem 0 0.75rem; }
.message ul { padding-left: 1.25rem; max-width: 36rem; }
.message li { margin-bottom: 0.5rem; }
.message form { margin-top: 1.5rem; }
mark.owner { background: #ffe58a; padding: 0 0.2em; }

footer { padding-block: 2rem 3rem; font-size: 0.95rem; color: var(--muted); }
footer .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 2rem; }
footer a { color: var(--muted); }
/* The X link is the logo alone; the link box stays 24px square, the smallest target WCAG 2.5.8 allows. */
footer .social { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; }
footer .social svg { display: block; width: 17px; height: 17px; fill: currentColor; }
footer .social:hover { color: var(--ink); }

main { flex: 1 0 auto; }

[hidden] { display: none !important; }

@media (max-width: 52rem) {
  .hero, .claim { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .hero { padding-block: 1.5rem 3.5rem; }
  .maze svg { max-width: 24rem; }
  .claims { padding-block: 3rem 1rem; }
  .claim { padding-bottom: 2.5rem; }
}
