/* The marketing site: home, how it works, societies, and the legal pages' frame.
   Tokens live in tokens.css (load it first). The event and friend pages use /style.css instead and
   are deliberately untouched by this file.

   The look is the app's (docs/design-system.md, CLAUDE.md → Brand): one flat purple for heroes,
   bands and the footer, with lime only on purple; cream pages with quiet white cards (a 1px grey
   edge, no shadow); Bricolage for headings and actions, the reader's own font for reading.

   The CSP allows no inline styles, so every look is a class here — never a style="" attribute. */

/* --- Base ---------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--bone);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  text-wrap: balance;
  margin: 0;
}

p {
  margin: 0;
  text-wrap: pretty;
}

ul,
ol,
dl,
dd {
  margin: 0;
  padding: 0;
  list-style: none;
}

figure {
  margin: 0;
}

a {
  color: inherit;
}

img {
  max-width: 100%;
}

svg {
  display: block;
}

/* Icons from /images/icons.svg. */
.i {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.i-12 {
  width: 12px;
  height: 12px;
  stroke-width: 2;
}

.i-14 {
  width: 14px;
  height: 14px;
}

.i-16 {
  width: 16px;
  height: 16px;
}

.i-20 {
  width: 20px;
  height: 20px;
}

[hidden] {
  display: none !important;
}

::selection {
  background: var(--brand);
  color: var(--ink-inverse);
}

:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--bone), 0 0 0 4px var(--brand);
  border-radius: var(--r-control);
}

/* On purple the ring is lime, as in the app. */
.on-brand :focus-visible {
  box-shadow: 0 0 0 2px var(--brand), 0 0 0 4px var(--accent);
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 600;
  text-decoration: none;
}

.skip:focus {
  top: 1rem;
}

/* --- Type scale ---------------------------------------------------------- */

.t-d1,
.t-d2,
.t-d3,
.t-d4 {
  font-family: var(--font-display);
  font-weight: 800;
}

.t-d1 {
  font-size: var(--display-1);
  line-height: 1.02;
  letter-spacing: -0.035em;
}

.t-d2 {
  font-size: var(--display-2);
  line-height: 1.05;
  letter-spacing: -0.032em;
}

.t-d3 {
  font-size: var(--display-3);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.t-d4 {
  font-size: var(--display-4);
  line-height: 1.15;
  letter-spacing: -0.025em;
}

.t-title {
  font-family: var(--font-display);
  font-size: var(--title);
  line-height: 1.3;
  letter-spacing: -0.015em;
  font-weight: 700;
}

.t-lg {
  font-size: var(--body-lg);
  line-height: 1.6;
}

.t-sm {
  font-size: var(--body-sm);
}

.t-cap {
  font-size: var(--caption);
  line-height: 1.5;
}

.t-label {
  font-family: var(--font-display);
  font-size: var(--label);
  line-height: 1;
  letter-spacing: 0.14em;
  font-weight: 700;
  text-transform: uppercase;
}

.muted {
  color: var(--ink-muted);
}

.tint {
  color: var(--brand-tint);
}

/* --- Layout -------------------------------------------------------------- */

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding-block: 4rem;
}

@media (min-width: 640px) {
  .section {
    padding-block: 5rem;
  }
}

@media (min-width: 1024px) {
  .section {
    padding-block: 7rem;
  }
}

.section > .wrap {
  position: relative;
}

.g-bone {
  background: var(--bone);
}

.g-surface {
  background: var(--surface);
}

.g-brand {
  background: var(--brand);
  color: var(--ink-inverse);
}

/* Two light sections in a row meet on a hairline, the way the app's groups do. */
.g-bone + .g-bone,
.g-bone + .g-surface,
.g-surface + .g-bone,
.g-surface + .g-surface {
  border-top: 1px solid var(--surface-line);
}

.stack {
  display: flex;
  flex-direction: column;
}

.row {
  display: flex;
  flex-wrap: wrap;
}

.split {
  display: grid;
  gap: 2.5rem;
  align-items: start;
}

@media (min-width: 1024px) {
  .split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: 3.5rem;
  }

  .split.sticky-left {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 4rem;
  }

  .split.even {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4rem;
  }

  .split.center {
    align-items: center;
  }

  .sticky-top {
    position: sticky;
    top: 7rem;
    align-self: start;
  }
}

/* --- Eyebrows and pills -------------------------------------------------- */

/* A small label over a heading, only where it says something the heading doesn't. */
.eyebrow {
  font-family: var(--font-display);
  font-size: var(--label);
  line-height: 1;
  letter-spacing: 0.14em;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.eyebrow.inv {
  color: var(--accent);
}

.eyebrow.centered {
  text-align: center;
}

/* A number or a short tag: purple carrying lime, as the app's stamps do. */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  min-width: 2.25rem;
  padding: 0.3rem 0.625rem;
  border-radius: var(--r-pill);
  font-family: var(--font-display);
  font-size: var(--label);
  line-height: 1;
  letter-spacing: 0.08em;
  font-weight: 700;
  text-transform: uppercase;
}

.pill.brand {
  background: var(--brand);
  color: var(--accent);
}

/* --- Cards and icon tiles ------------------------------------------------ */

/* Quiet, as in the app: white on cream, a 1px grey edge, no shadow. */
.card {
  background: var(--surface);
  border: 1px solid var(--surface-line);
  border-radius: var(--r-card);
}

.card-hover {
  transition: border-color var(--dur-fast) var(--ease);
}

.card-hover:hover {
  border-color: rgba(46, 20, 124, 0.45);
}

/* Lime on a purple tile: the app icon in miniature. */
.icon-tile {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  border-radius: var(--r-inner);
  background: var(--brand);
  color: var(--accent);
}

.icon-tile.sm {
  width: 2.375rem;
  height: 2.375rem;
}

/* --- Buttons ------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: var(--r-pill);
  font-family: var(--font-display);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border: 1.5px solid transparent;
  white-space: nowrap;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: none;
}

.btn .arw {
  transition: transform var(--dur-fast) var(--ease);
}

.btn:hover .arw {
  transform: translateX(2px);
}

.btn-lg {
  padding: 0.875rem 1.5rem;
  font-size: var(--body);
}

.btn-md {
  padding: 0.625rem 1.25rem;
  font-size: var(--body-sm);
}

.btn-sm {
  padding: 0.5rem 0.875rem;
  font-size: var(--caption);
}

/* Lime carries purple, and only ever sits on purple. */
.btn-accent {
  background: var(--accent);
  color: var(--brand);
}

.btn-accent:hover {
  background: var(--accent-deep);
}

/* The same role on cream. */
.btn-action {
  background: var(--action);
  color: var(--on-action);
}

.btn-action:hover {
  background: var(--action-hover);
}

/* A second action on purple: a lilac outline around cream words. */
.btn-outline-brand {
  border-color: var(--brand-line);
  color: var(--ink-inverse);
  background: transparent;
}

.btn-outline-brand:hover {
  border-color: var(--brand-tint);
  background: rgba(245, 242, 233, 0.08);
}

/* --- Apple's and Google's badges, unaltered. Height stays at or above Apple's 40px; google-play-badge.png
   is cut to Apple's proportions, so the two match at any height. */
.store-badge {
  display: inline-flex;
  flex-shrink: 0;
  border-radius: 0.6rem;
  transition: transform var(--dur-fast) var(--ease);
}

.store-badge:hover {
  transform: translateY(-2px);
}

.store-badge img {
  display: block;
  width: auto;
  height: 3.25rem;
}

.store-badge.sm img {
  height: 2.75rem;
}

/* Inline, so on a narrow screen the arrow follows the last word instead of the far edge. */
.inline-link {
  display: inline;
  font-family: var(--font-display);
  font-size: var(--body);
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
  text-underline-offset: 4px;
}

.inline-link:hover {
  text-decoration: underline;
}

.inline-link .arw {
  display: inline-block;
  margin-left: 0.375rem;
  vertical-align: -0.15em;
  transition: transform var(--dur-fast) var(--ease);
}

.inline-link:hover .arw {
  transform: translateX(2px);
}

.on-brand .inline-link {
  color: var(--accent);
}

/* --- Header -------------------------------------------------------------- */

/* Clear over the purple hero; once off it (or on a page without one, or with the menu open) it
   becomes the app's own header: a purple bar with a lime line under it. */
.site-header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  border-bottom: 2px solid transparent;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.scrolled .site-header,
.header-solid .site-header,
.menu-open .site-header {
  background: var(--brand);
  border-bottom-color: var(--accent);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: var(--header-h);
  padding-block: 0.75rem;
  transition: min-height 0.3s var(--ease);
}

.scrolled .nav-shell,
.header-solid .nav-shell,
.menu-open .nav-shell {
  min-height: 4rem;
}

.nav-links {
  display: none;
  gap: 0.5rem;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }
}

/* Nav links are pills, so they read as things to press: a lilac outline at rest, brighter on hover
   or keyboard focus, filled with a lime dot on the current page. The header is purple in every
   state, so these hold when it turns solid. Quieter than the lime "Get the app" on purpose. */
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--brand-line);
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--ink-inverse);
  transition: transform var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease);
}

.nav-link:hover,
.nav-link:focus-visible {
  border-color: var(--brand-tint);
  background: rgba(245, 242, 233, 0.08);
  transform: translateY(-2px);
}

/* Keep the pill shape under the shared focus ring. */
.nav-link:focus-visible {
  border-radius: var(--r-pill);
}

.nav-link[aria-current='page'] {
  background: rgba(245, 242, 233, 0.12);
}

.nav-link[aria-current='page']::before {
  content: '';
  width: 6px;
  height: 6px;
  flex-shrink: 0;
  border-radius: var(--r-pill);
  background: var(--accent);
}

.nav-end {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* The header's button: lime on purple, the same on every page. */
.btn-header {
  background: var(--accent);
  color: var(--brand);
  font-size: 0.9375rem;
  padding: 0.5625rem 1.125rem;
}

.btn-header:hover {
  background: var(--accent-deep);
}

/* "Log in" (the web app's sign-in) sits beside it from 768px as a quieter nav pill; on phones it's
   in the Menu. */
.nav-login {
  display: none;
}

@media (min-width: 768px) {
  .nav-login {
    display: inline-flex;
  }
}

/* The lockup from mobile/src/components/wordmark.tsx: the supplied logo PNG (never redrawn,
   tinted or cropped), then "Motive" in Bricolage ExtraBold. Everything is a ratio of the type size:
   at 24 the logo is 36 with 9 rounding, 10 of gap, −1 tracking. `.brand` in /style.css copies the
   same ratios: change the three together. */
.wordmark {
  --type: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: calc(var(--type) * 0.4167);
  text-decoration: none;
  flex-shrink: 0;
}

.wordmark .logo {
  display: block;
  width: calc(var(--type) * 1.5);
  height: calc(var(--type) * 1.5);
  border-radius: calc(var(--type) * 0.375);
}

.wordmark .name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--type);
  line-height: 1.15;
  letter-spacing: calc(var(--type) * -0.0417);
  color: var(--ink-inverse);
}

/* On phones the nav folds into this: a pill like the nav links, with the word "Menu" beside the icon. */
.menu-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  height: 2.5rem;
  padding: 0 0.875rem 0 0.75rem;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--brand-line);
  background: transparent;
  color: var(--ink-inverse);
  font-family: var(--font-display);
  font-size: var(--caption);
  font-weight: 600;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}

.menu-btn:hover,
.menu-btn[aria-expanded='true'] {
  border-color: var(--brand-tint);
  background: rgba(245, 242, 233, 0.08);
}

.menu-btn:focus-visible {
  border-radius: var(--r-pill);
}

@media (min-width: 768px) {
  .menu-btn {
    display: none;
  }
}

/* Narrow phones: the logo, "Get the app" and the Menu pill share one row, so everything tightens a
   little rather than wrapping. */
@media (max-width: 400px) {
  .site-header .wordmark {
    --type: 1.25rem;
  }

  .nav-end {
    gap: 0.25rem;
  }

  .btn-header {
    padding-inline: 0.75rem;
    font-size: var(--caption);
  }

  .menu-btn {
    padding: 0 0.625rem 0 0.5rem;
    gap: 0.25rem;
  }
}

@media (max-width: 340px) {
  .site-header .wordmark {
    --type: 1.125rem;
  }

  .btn-header {
    padding-inline: 0.625rem;
  }
}

/* The open menu belongs to the purple bar: full-width pills, at least 44px tall to tap. */
.mobile-menu {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding-bottom: 1rem;
}

.mobile-menu .nav-link {
  display: flex;
  min-height: 2.75rem;
  padding: 0.625rem 1rem;
  font-size: var(--body);
}

.mobile-menu .nav-link:hover,
.mobile-menu .nav-link:focus-visible {
  transform: none;
}

@media (min-width: 768px) {
  .mobile-menu {
    display: none !important;
  }
}

/* Pages without a purple hero (privacy, terms) start below the header. */
.header-solid main {
  padding-top: calc(var(--header-h) + 1.5rem);
}

/* --- Heroes -------------------------------------------------------------- */

/* Flat purple, ending on a lime line like the app's header. */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--brand);
  color: var(--ink-inverse);
  padding-block: 7rem 4rem;
  border-bottom: 3px solid var(--accent);
}

@media (min-width: 640px) {
  .hero {
    padding-block: 9rem 5rem;
  }
}

@media (min-width: 1024px) {
  .hero.home {
    padding-block: 9.5rem 6rem;
  }
}

.hero h1 {
  margin-top: 1.5rem;
  color: var(--ink-inverse);
}

.hero .eyebrow + h1 {
  margin-top: 1rem;
}

.hero .lede {
  margin-top: 1.5rem;
  max-width: 36rem;
  color: var(--brand-tint);
}

.hero .ctas {
  gap: 0.75rem;
  margin-top: 2.25rem;
  align-items: center;
}

.h1-home {
  max-width: 15ch;
}

.h1-how {
  max-width: 18ch;
}

.h1-soc {
  max-width: 22ch;
}

.hero .strapline {
  margin-top: 1rem;
  font-family: var(--font-display);
  font-size: var(--display-4);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--accent);
}

.hero-grid,
.how-grid {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr) 20rem;
    gap: 3rem;
  }

  .how-grid {
    grid-template-columns: minmax(0, 1fr) 19rem;
    gap: 3rem;
  }
}

/* The phone is hidden at phone width, where it would push the download button off screen. The
   views section further down shows phones at every width. */
.hero-phone {
  display: none;
}

@media (min-width: 640px) {
  .hero-phone {
    display: block;
  }
}

.badge-live {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.875rem;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--brand-line);
  font-family: var(--font-display);
  font-size: var(--caption);
  font-weight: 600;
  color: var(--brand-tint);
}

.live-dot {
  position: relative;
  display: inline-flex;
  width: 7px;
  height: 7px;
  flex-shrink: 0;
}

.live-dot i {
  position: absolute;
  inset: 0;
  border-radius: var(--r-pill);
  background: var(--accent);
}

.live-dot i:first-child {
  animation: ring 2.4s var(--ease) infinite;
}

@keyframes ring {
  0% {
    transform: scale(0.85);
    opacity: 0.7;
  }

  70%,
  100% {
    transform: scale(1.9);
    opacity: 0;
  }
}

/* --- Underlined words: a lime stroke under the last words of a heading ---------------------------
   On purple it sits under the words; on cream the words turn purple and the stroke runs behind
   them like a highlighter, so lime never stands alone on cream. */

.underline {
  position: relative;
  display: inline-block;
  isolation: isolate;
}

.scribble {
  position: absolute;
  left: -0.08em;
  width: calc(100% + 0.16em);
  bottom: -0.2em;
  height: 0.32em;
  overflow: visible;
  pointer-events: none;
}

.scribble path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 0.1em;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

.two-tone .underline {
  color: var(--brand);
}

.two-tone .scribble {
  z-index: -1;
  bottom: -0.02em;
  height: 0.36em;
}

.two-tone .scribble path {
  stroke-width: 0.2em;
}

/* --- A statement that fills in word by word as you scroll (site.js) ------- */

.reveal-words {
  max-width: 30ch;
  font-family: var(--font-display);
  font-size: var(--display-4);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.reveal-words .w {
  color: rgba(36, 21, 59, 0.22);
  transition: color 0.25s var(--ease);
}

.reveal-words .w.on {
  color: var(--ink);
}

/* --- Heading blocks ------------------------------------------------------ */

.heading-block > h2 {
  margin-top: 1rem;
  max-width: 32ch;
}

.heading-block > .lead {
  margin-top: 1.25rem;
  max-width: 60ch;
}

.heading-block.centered {
  max-width: 44rem;
  margin-inline: auto;
  text-align: center;
}

.heading-block.centered > h2 {
  max-width: none;
}

.heading-block.centered > .lead {
  margin-inline: auto;
}

.on-brand .heading-block > .lead {
  color: var(--brand-tint);
}

.on-brand h2,
.on-brand h3 {
  color: var(--ink-inverse);
}

.block-gap {
  margin-top: 2.5rem;
}

/* --- Problem rows (home, how it works) ------------------------------------ */

.prose {
  gap: 1.25rem;
  max-width: 44rem;
}

.rows {
  border-top: 1px solid var(--surface-line);
}

.rows > li {
  display: flex;
  gap: 1rem;
  padding-block: 1.25rem;
  border-bottom: 1px solid var(--surface-line);
}

.rows p {
  margin-top: 0.25rem;
}

/* --- Steps (societies: getting listed) ------------------------------------ */

.steps {
  display: grid;
  gap: 1rem;
}

@media (min-width: 640px) {
  .steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.step-card {
  height: 100%;
  padding: 1.5rem;
  border-radius: var(--r-card);
  border: 1px solid var(--surface-line);
  background: var(--surface);
}

@media (min-width: 640px) {
  .step-card {
    padding: 1.75rem;
  }
}

.step-card h3 {
  margin-top: 1rem;
}

.step-card p {
  margin-top: 0.5rem;
  font-size: var(--body-sm);
  color: var(--ink-muted);
}

/* --- Timeline (How it works) --------------------------------------------- */
/* Without the script the line is full and every step is lit; site.js adds .tl-live and drives
   --tl-progress, and a step lights up once the line reaches its dot. */

.timeline {
  --tl-progress: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
  padding-left: 2.5rem;
}

.timeline::before,
.timeline::after {
  content: '';
  position: absolute;
  left: 0.6rem;
  top: 0.75rem;
  width: 2px;
  border-radius: var(--r-pill);
}

.timeline::before {
  bottom: 0.75rem;
  background: var(--surface-line);
}

.timeline::after {
  height: calc((100% - 1.5rem) * var(--tl-progress));
  background: var(--brand);
}

.tl-row {
  position: relative;
  display: grid;
  gap: 1rem;
  transition: opacity var(--dur-fast) var(--ease);
}

.tl-head {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.tl-dot {
  position: absolute;
  z-index: 1;
  left: -2.4rem;
  top: 0.3rem;
  width: 16px;
  height: 16px;
  border-radius: var(--r-pill);
  background: var(--accent);
  border: 2px solid var(--brand);
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}

.tl-num {
  font-family: var(--font-display);
  font-size: var(--label);
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--ink-muted);
}

.tl-title {
  font-family: var(--font-display);
  font-size: var(--display-4);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.tl-body .step-lead {
  max-width: 60ch;
  font-size: var(--body-lg);
  color: var(--ink);
}

.tl-body .step-detail {
  margin-top: 0.75rem;
  max-width: 60ch;
  font-size: var(--body-sm);
  color: var(--ink-muted);
}

.tl-live .tl-row:not(.done) {
  opacity: 0.55;
}

.tl-live .tl-row:not(.done) .tl-dot {
  background: var(--bone);
  border-color: var(--surface-line);
}

@media (min-width: 900px) {
  .timeline {
    padding-left: 0;
  }

  .timeline::before,
  .timeline::after {
    left: 15.6rem;
  }

  .tl-row {
    grid-template-columns: 15rem 1fr;
    gap: 3.5rem;
  }

  .tl-head {
    position: sticky;
    top: 7rem;
    align-self: start;
  }

  .tl-dot {
    left: 15.15rem;
  }
}

/* --- Societies (home): a few of them as rows from the app's Societies tab ---------------------- */

.soc-list {
  display: grid;
  column-gap: 3rem;
}

@media (min-width: 768px) {
  .soc-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.soc-row {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding-block: 0.875rem;
  border-bottom: 1px solid var(--surface-line);
}

@media (min-width: 768px) {
  .soc-row:nth-child(3),
  .soc-row:nth-child(6) {
    border-bottom: 0;
  }

  .soc-row:nth-child(n + 4) {
    grid-column: 2;
  }

  .soc-row:nth-child(4) {
    grid-row: 1;
  }

  .soc-row:nth-child(5) {
    grid-row: 2;
  }

  .soc-row:nth-child(6) {
    grid-row: 3;
  }
}

@media (max-width: 767px) {
  .soc-row:last-child {
    border-bottom: 0;
  }
}

/* No logo: up to two initials on one of the kit's four tints (components/avatar.tsx). */
.soc-disc {
  display: grid;
  place-items: center;
  width: 2.875rem;
  height: 2.875rem;
  flex-shrink: 0;
  border-radius: var(--r-pill);
  border: 1px solid var(--surface-line);
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--brand);
}

.soc-disc.two {
  font-size: 1rem;
}

.tint-1 {
  background: #e6ddf1;
}

.tint-2 {
  background: #f2d6dd;
}

.tint-3 {
  background: #f4d6b5;
}

.tint-4 {
  background: #e3eebd;
}

.soc-text {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
}

.soc-name {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--ink);
}

.soc-cat {
  font-size: var(--caption);
  color: var(--ink-faint);
}

/* The app's Chip: flat, a 1.5px purple outline, lime when it's the thing to do. */
.chip {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  height: 2.375rem;
  padding: 0 0.875rem;
  border: 1.5px solid var(--brand);
  border-radius: var(--r-control);
  background: var(--surface);
  font-family: var(--font-display);
  font-size: var(--body-sm);
  font-weight: 600;
  color: var(--brand);
}

.chip.on {
  background: var(--accent);
}

/* --- FAQ (details/summary: works without JS; name="" makes it single-open) ------------------------ */

.acc {
  border-top: 1px solid var(--surface-line);
}

.acc details {
  border-bottom: 1px solid var(--surface-line);
  interpolate-size: allow-keywords;
}

.acc summary,
.faq-acc summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding-block: 1.125rem;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.acc summary::-webkit-details-marker,
.faq-acc summary::-webkit-details-marker {
  display: none;
}

@media (min-width: 640px) {
  .acc summary,
  .faq-acc summary {
    font-size: 1.125rem;
  }
}

/* The plus in a circle: the app's icon button (white, a 1.5px purple outline), lime once open. */
.acc-sign,
.faq-plus {
  display: grid;
  place-items: center;
  flex: none;
  width: 2rem;
  height: 2rem;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--brand);
  background: var(--surface);
  color: var(--brand);
  transition: transform var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease);
}

.acc summary:hover .acc-sign,
.faq-acc summary:hover .faq-plus {
  background: var(--brand-wash);
}

.acc details[open] .acc-sign,
.faq-acc details[open] .faq-plus {
  transform: rotate(45deg);
  background: var(--accent);
}

.acc details::details-content,
.faq-acc details::details-content {
  block-size: 0;
  overflow: hidden;
  opacity: 0;
  transition: block-size 0.3s var(--ease), opacity 0.3s var(--ease), content-visibility 0.3s allow-discrete;
}

.acc details[open]::details-content,
.faq-acc details[open]::details-content {
  block-size: auto;
  opacity: 1;
}

.acc details p,
.faq-acc details p {
  max-width: 58ch;
  padding: 0 3rem 1.25rem 0;
  color: var(--ink-muted);
}

.acc details p a,
.faq-acc details p a {
  color: var(--brand);
  font-weight: 600;
  text-underline-offset: 3px;
}

/* --- FAQ (home): topics on the left, questions on the right ---------------
   The topics are radio inputs and :has() picks the group, so it works without a script. Where :has()
   isn't supported the topics stay hidden and every group shows. At phone width the topics are a
   row of chips; from 900px they're a list in a white card, the picked one lime. */

.faq {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
}

.faq-ask {
  margin-top: 0.75rem;
  color: var(--ink-muted);
}

.faq-ask a {
  color: var(--brand);
  font-weight: 600;
  text-underline-offset: 3px;
}

.faq-topics {
  display: none;
}

.faq-topics input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.faq-topics label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex: none;
  padding: 0.55rem 0.9rem;
  border: 1.5px solid var(--surface-line);
  border-radius: var(--r-control);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: var(--body-sm);
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}

.faq-topics label i {
  display: none;
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--surface-line);
}

.faq-topics input:checked + label {
  border-color: var(--brand);
  background: var(--accent);
  color: var(--brand);
  font-weight: 700;
}

.faq-topics input:checked + label i {
  background: var(--brand);
}

.faq-topics input:focus-visible + label {
  box-shadow: 0 0 0 2px var(--bone), 0 0 0 4px var(--brand);
}

@supports selector(:has(*)) {
  .faq-topics {
    display: flex;
    gap: 0.375rem;
    margin-top: 1.75rem;
    margin-inline: calc(var(--gutter) * -1);
    padding: 0.35rem var(--gutter);
    overflow-x: auto;
    scrollbar-width: none;
  }

  .faq:has(#faq-t1:checked) .faq-group:not(.g1),
  .faq:has(#faq-t2:checked) .faq-group:not(.g2),
  .faq:has(#faq-t3:checked) .faq-group:not(.g3),
  .faq:has(#faq-t4:checked) .faq-group:not(.g4) {
    display: none;
  }
}

.faq-group + .faq-group {
  margin-top: 2.75rem;
}

.faq-label {
  padding-bottom: 0.75rem;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--ink);
}

.faq-acc details {
  border-top: 1px solid var(--surface-line);
  interpolate-size: allow-keywords;
}

.faq-acc details:last-child {
  border-bottom: 1px solid var(--surface-line);
}

.faq-more {
  display: inline-block;
  margin-top: 1.25rem;
}

@media (min-width: 900px) {
  .faq {
    grid-template-columns: 17.5rem minmax(0, 1fr);
    gap: 5rem;
  }

  .faq-main {
    padding-top: 0.75rem;
  }

  @supports selector(:has(*)) {
    .faq-topics {
      display: grid;
      gap: 0.125rem;
      margin-inline: 0;
      padding: 0.375rem;
      border-radius: var(--r-card);
      border: 1px solid var(--surface-line);
      background: var(--surface);
    }
  }

  .faq-topics label {
    min-height: 2.875rem;
    padding: 0.7rem 0.9rem;
    border: 0;
    border-radius: var(--r-inner);
    font-size: 0.9375rem;
  }

  .faq-topics input:checked + label {
    border: 0;
  }

  .faq-topics label i {
    display: block;
  }
}

/* --- Comparison (societies) ---------------------------------------------- */

.cmp-head {
  display: none;
}

.cmp-row {
  display: grid;
  gap: 0.5rem;
  padding-block: 1.125rem;
  border-bottom: 1px solid var(--surface-line);
}

.cmp-row:last-child {
  border-bottom: 0;
}

.cmp-cell {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  font-size: var(--body-sm);
}

@media (min-width: 640px) {
  .cmp-cell {
    font-size: var(--body);
  }
}

.cmp-mark {
  display: grid;
  place-items: center;
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.15rem;
  border-radius: var(--r-pill);
}

.cmp-mark.no {
  color: var(--ink-faint);
}

/* A lime tick on a purple disc, as the app's own ticks. */
.cmp-mark.yes {
  background: var(--brand);
  color: var(--accent);
}

.cmp-mark.yes .i {
  stroke-width: 2.6;
}

.only-mobile {
  display: block;
  margin-bottom: 0.25rem;
}

.cmp-with {
  color: var(--brand);
}

@media (min-width: 640px) {
  .cmp-head {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.25rem;
    padding-bottom: 0.875rem;
    border-bottom: 1px solid var(--surface-line);
    color: var(--ink-faint);
  }

  .cmp-row {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
    gap: 1.25rem;
  }

  .cmp-row .only-mobile {
    display: none;
  }
}

/* --- The problem (societies): four columns split by hairlines ----------- */

.problem-grid {
  display: grid;
}

@media (min-width: 640px) {
  .problem-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    row-gap: 2rem;
  }
}

@media (min-width: 1024px) {
  .problem-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.problem {
  padding: 1.5rem 0;
  border-top: 1px solid var(--surface-line);
}

@media (min-width: 640px) {
  .problem {
    padding: 0.25rem 1.5rem 0.5rem;
    border-top: 0;
    border-left: 1px solid var(--surface-line);
  }
}

.problem-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.problem-num {
  color: var(--ink-faint);
}

.problem h3 {
  margin-top: 1rem;
}

.problem p {
  margin-top: 0.5rem;
}

/* --- Pain cards (how it works: friends) ---------------------------------- */

.three-cards {
  display: grid;
  gap: 1rem;
}

@media (min-width: 768px) {
  .three-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.pain-card {
  height: 100%;
  padding: 1.5rem;
}

.pain-card h3 {
  margin-top: 1rem;
}

.pain-card p {
  margin-top: 0.375rem;
}

/* --- Download and register bands ------------------------------------------ */

.download-ctas {
  gap: 1rem;
  margin-top: 2rem;
  align-items: center;
}

/* The QR code only helps someone reading this on a computer: a cream card on the purple band. */
.qr-card {
  display: none;
}

@media (min-width: 1024px) {
  .qr-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    justify-self: end;
    max-width: 27rem;
    padding: 1.25rem 1.5rem 1.25rem 1.25rem;
    border-radius: 1.5rem;
    background: var(--bone);
    color: var(--ink);
  }
}

.qr-card img {
  width: 8.5rem;
  height: 8.5rem;
  flex-shrink: 0;
  border-radius: var(--r-inner);
  background: var(--surface);
  padding: 0.375rem;
}

.qr-card .t-label {
  color: var(--brand);
}

.qr-card .t-sm {
  margin-top: 0.5rem;
  color: var(--ink-muted);
}

.block {
  display: block;
}

/* --- Footer -------------------------------------------------------------- */

.site-footer {
  position: relative;
  background: var(--brand);
  color: var(--ink-inverse);
  padding-top: 3.5rem;
  border-top: 1px solid var(--brand-line);
}

.footer-grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 2fr);
    gap: 4rem;
  }
}

.footer-about {
  max-width: 24rem;
}

.footer-about > p {
  margin-top: 1rem;
}

.footer-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
}

@media (min-width: 640px) {
  .footer-nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.footer-nav h2 {
  font-family: var(--font-display);
  font-size: var(--label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--accent);
}

.footer-nav ul {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.footer-nav a {
  font-size: var(--body-sm);
  color: var(--brand-tint);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease);
}

.footer-nav a:hover {
  color: var(--ink-inverse);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.social {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.social a {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--brand-line);
  color: var(--brand-tint);
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}

.social a:hover {
  border-color: var(--brand-tint);
  color: var(--ink-inverse);
}

.footer-legal {
  margin-top: 3rem;
  padding-block: 1.5rem;
  border-top: 1px solid rgba(207, 195, 247, 0.22);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  font-size: var(--caption);
  color: var(--brand-tint);
}

.footer-legal a {
  text-decoration: none;
}

.footer-legal a:hover {
  color: var(--ink-inverse);
  text-decoration: underline;
}

@media (min-width: 640px) {
  .footer-legal {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* --- Reveal -------------------------------------------------------------- */
/* Visible by default: site.js adds .js only once the observer is wired, so the page with JS off, or
   before the script runs, shows everything. */

.js .reveal {
  opacity: 0;
  transform: translateY(16px);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity var(--dur-base) var(--ease), transform var(--dur-base) var(--ease);
}

.js .reveal.d1 {
  transition-delay: 0.07s;
}

.js .reveal.d2 {
  transition-delay: 0.14s;
}

.js .reveal.d3 {
  transition-delay: 0.21s;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }
}

/* --- Legal pages ---------------------------------------------------------- */
/* privacy.html, terms.html and delete-account.html keep their markup and text; this only gives it a
   reading measure. */

.legal {
  max-width: 44rem;
  margin: 0 auto;
  padding: 1rem var(--gutter) 5rem;
  font-size: var(--body);
  line-height: 1.65;
}

.legal h1 {
  font-family: var(--font-display);
  font-size: var(--display-2);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.032em;
}

.legal h2 {
  margin-top: 2.5rem;
  font-size: var(--display-4);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
}

.legal h3 {
  margin-top: 1.75rem;
  font-size: var(--title);
  font-weight: 700;
}

.legal p,
.legal ul,
.legal ol {
  margin-top: 0.875rem;
  color: var(--ink);
}

.legal ul {
  padding-left: 1.25rem;
  list-style: disc;
}

.legal ol {
  padding-left: 1.25rem;
  list-style: decimal;
}

.legal li + li {
  margin-top: 0.375rem;
}

.legal a {
  color: var(--brand);
  font-weight: 600;
  text-underline-offset: 3px;
}

.legal .small,
.legal .muted {
  color: var(--ink-muted);
  font-size: var(--body-sm);
}

/* ===========================================================================
   The phone drawings. The frame is the site's; what's inside is drawn the app's way, from its code:
   the purple header with its lime line (components/app-header.tsx), quiet white cards with a 1px
   grey edge (event-card.tsx, event-poster.tsx, event-tile.tsx, featured-event.tsx), flat chips and
   buttons with 8px corners, and iOS's own tab bar. Every size below is the app's own, in points,
   times --u: one point of a 390-point-wide iPhone screen, so a drawing scales with its phone.
   Names, events and places in them are invented.
   ========================================================================= */

.phone {
  position: relative;
  width: 100%;
  max-width: 19rem;
  margin-inline: auto;
  border-radius: 2.75rem;
  background: #120d1c;
  padding: 0.5rem;
}

.screen {
  container-type: inline-size;
  position: relative;
  overflow: hidden;
  aspect-ratio: 390 / 820;
  border-radius: 2.25rem;
  background: var(--bone);
  /* Resolved by each element that uses it, against this screen: one point of the app. */
  --u: calc(100cqw / 390);
}

@supports not (width: 1cqw) {
  .screen {
    --u: 0.738px;
  }
}

.phone.short .screen {
  aspect-ratio: 390 / 780;
}

.app {
  font-family: var(--font-body);
  line-height: 1.25;
  color: var(--ink);
  -webkit-user-select: none;
  user-select: none;
}

/* Set on the screen's children, not the screen: container units resolve against an ancestor. */
.app > * {
  font-size: calc(13 * var(--u));
}

.app p {
  text-wrap: auto;
}

/* --- iOS: the status bar and the tab bar ---------------------------------- */

.st-bar {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: calc(54 * var(--u));
  padding: calc(6 * var(--u)) calc(34 * var(--u)) 0 calc(40 * var(--u));
  font-family: var(--font-body);
  font-size: calc(16 * var(--u));
  font-weight: 600;
  line-height: 1;
  color: var(--ink);
}

/* The Dynamic Island. */
.st-bar::before {
  content: '';
  position: absolute;
  left: 50%;
  top: calc(11 * var(--u));
  width: calc(122 * var(--u));
  height: calc(35 * var(--u));
  transform: translateX(-50%);
  border-radius: var(--r-pill);
  background: #0b0812;
}

.st-bar.light {
  color: var(--ink-inverse);
}

/* Over a cover, at the very top of a pushed screen. */
.st-bar.over {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
}

.bat {
  display: block;
  width: calc(26 * var(--u));
  height: calc(13 * var(--u));
  padding: calc(1.5 * var(--u));
  border: calc(1.3 * var(--u)) solid currentColor;
  border-radius: calc(4 * var(--u));
  opacity: 0.9;
}

.bat::before {
  content: '';
  display: block;
  width: 72%;
  height: 100%;
  border-radius: calc(2 * var(--u));
  background: currentColor;
}

/* NativeTabs: iOS's own bar, in the app's colours. */
.tabbar {
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  height: calc(84 * var(--u));
  padding-top: calc(7 * var(--u));
  background: #f9f8f4;
  border-top: calc(0.6 * var(--u)) solid rgba(36, 21, 59, 0.2);
}

.tabbar::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: calc(8 * var(--u));
  width: calc(134 * var(--u));
  height: calc(5 * var(--u));
  transform: translateX(-50%);
  border-radius: var(--r-pill);
  background: #0b0812;
}

.tabbar span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(3 * var(--u));
  font-size: calc(10 * var(--u));
  font-weight: 500;
  color: #8e8b96;
  white-space: nowrap;
}

.tabbar .on {
  color: var(--brand);
}

.tabbar .i {
  width: calc(25 * var(--u));
  height: calc(25 * var(--u));
  stroke-width: 1.8;
}

/* --- The app's pieces --------------------------------------------------- */

/* The purple bar across the top of every tab, with its lime line. */
.ah {
  position: relative;
  z-index: 2;
  background: var(--brand);
  border-bottom: calc(2 * var(--u)) solid var(--accent);
  color: var(--ink-inverse);
}

.ah-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(12 * var(--u));
  min-height: calc(62 * var(--u));
  padding: 0 calc(20 * var(--u)) calc(2 * var(--u));
}

.ah-lead {
  display: flex;
  align-items: center;
  gap: calc(10 * var(--u));
  min-width: 0;
}

.ah-logo {
  display: block;
  width: calc(36 * var(--u));
  height: calc(36 * var(--u));
  border-radius: calc(9 * var(--u));
}

.ah-title {
  font-family: var(--font-display);
  font-size: calc(24 * var(--u));
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: calc(-1 * var(--u));
  white-space: nowrap;
}

/* Your face ringed in lime, then a few of your societies' logos tucked under it. */
.ah-me {
  display: flex;
  align-items: center;
}

.ah-me > * + * {
  margin-left: calc(-10 * var(--u));
}

.ah-me .face {
  z-index: 4;
  border: calc(1.5 * var(--u)) solid var(--accent);
}

.ah-me .disc {
  border: calc(1.5 * var(--u)) solid var(--brand);
}

.ah-me .disc:nth-child(2) {
  z-index: 3;
}

.ah-me .disc:nth-child(3) {
  z-index: 2;
}

/* Sizes, in points: faces, discs and covers take one of these. */
.s20 { --d: 20; }
.s24 { --d: 24; }
.s28 { --d: 28; }
.s36 { --d: 36; }

/* A member without a photo: their doodled face on one of the twelve discs (components/face.tsx). */
.face {
  position: relative;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: calc(var(--d, 24) * var(--u));
  height: calc(var(--d, 24) * var(--u));
  border-radius: var(--r-pill);
  overflow: hidden;
  color: #16121f;
}

.face .i {
  width: 100%;
  height: 100%;
}

.f-lilac { background: #e6e0fa; }
.f-pink { background: #ff9edb; }
.f-sky { background: #8ec5ff; }
.f-orange { background: #ff9a4d; }

/* A society without a logo: its initials on a tint (the tint-1 to tint-4 classes above). */
.disc {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: calc(var(--d, 24) * var(--u));
  height: calc(var(--d, 24) * var(--u));
  border-radius: var(--r-pill);
  font-family: var(--font-display);
  font-size: calc(var(--d, 24) * 0.4 * var(--u));
  font-weight: 800;
  line-height: 1;
  color: var(--brand);
}

/* Friends going: faces overlapping, each with a thin edge. */
.faces {
  display: flex;
  align-items: center;
}

.faces .face {
  border: calc(1 * var(--u)) solid var(--surface-line);
}

.faces .face + .face {
  margin-left: calc(-7 * var(--u));
}

.on-purple .faces .face {
  border-color: var(--brand);
}

/* Chip: flat, a 1.5pt purple outline, 8pt corners, lime when on. */
.a-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  height: calc(40 * var(--u));
  padding: 0 calc(14 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: calc(8 * var(--u));
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(14 * var(--u));
  font-weight: 600;
  color: var(--brand);
  white-space: nowrap;
}

.a-chip.tall {
  height: calc(48 * var(--u));
}

.a-chip.on {
  background: var(--accent);
}

.a-chip.square {
  width: calc(48 * var(--u));
  padding: 0;
}

.a-chip .i {
  width: calc(20 * var(--u));
  height: calc(20 * var(--u));
}

.a-search {
  display: flex;
  flex: 1;
  align-items: center;
  gap: calc(8 * var(--u));
  height: calc(48 * var(--u));
  padding: 0 calc(14 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: calc(8 * var(--u));
  background: var(--surface);
  font-size: calc(15 * var(--u));
  color: var(--ink-faint);
  min-width: 0;
}

.a-search .i {
  width: calc(18 * var(--u));
  height: calc(18 * var(--u));
  color: var(--ink-muted);
}

/* Icon buttons: white circles with a purple outline. */
.a-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: calc(40 * var(--u));
  height: calc(40 * var(--u));
  border-radius: var(--r-pill);
  border: calc(1.5 * var(--u)) solid var(--brand);
  background: var(--surface);
  color: var(--brand);
}

.a-icon .i {
  width: calc(19 * var(--u));
  height: calc(19 * var(--u));
  stroke-width: 2;
}

.a-icon.cream {
  background: var(--bone);
}

/* Buttons: a flat purple block (or lime on purple) with 8pt corners. */
.a-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: calc(8 * var(--u));
  height: calc(52 * var(--u));
  border-radius: calc(8 * var(--u));
  background: var(--brand);
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 600;
  color: var(--ink-inverse);
}

.a-btn .i {
  width: calc(19 * var(--u));
  height: calc(19 * var(--u));
  stroke-width: 2;
}

/* A section's title with See all beside it. */
.a-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(16 * var(--u));
}

.a-section-title {
  font-family: var(--font-display);
  font-size: calc(20 * var(--u));
  font-weight: 700;
  letter-spacing: calc(-0.6 * var(--u));
}

.a-see-all {
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 600;
  color: var(--brand);
}

/* The feed's day label: bold, then a hairline to the edge. */
.a-day {
  display: flex;
  align-items: center;
  gap: calc(12 * var(--u));
  padding: calc(16 * var(--u)) 0 calc(12 * var(--u));
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
}

.a-day::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--surface-line);
}

/* --- Covers: drawn posters, never photographs -------------------------- */

.cover {
  position: relative;
  overflow: hidden;
  background: var(--brand);
}

.poster {
  padding: calc(26 * var(--u)) calc(18 * var(--u));
  font-family: var(--font-display);
  font-size: calc(36 * var(--u));
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: calc(-1.2 * var(--u));
  text-transform: uppercase;
  color: var(--brand);
}

.poster.sm {
  padding: calc(18 * var(--u)) calc(14 * var(--u));
  font-size: calc(26 * var(--u));
  letter-spacing: calc(-0.9 * var(--u));
}

/* Under a pushed screen's top bar. */
.poster.lg {
  padding: calc(112 * var(--u)) calc(20 * var(--u)) 0;
  font-size: calc(40 * var(--u));
  letter-spacing: calc(-1.5 * var(--u));
}

.pc-pink { background: #ff9edb; }
.pc-orange { background: #ff9a4d; }
.pc-lilac { background: #cfc3f7; }
.pc-lime { background: #e3eebd; }
.pc-sky { background: #8ec5ff; }

/* No photo: the stamp on purple, as the app does. */
.pc-stamp {
  display: grid;
  place-items: center;
}

.pc-stamp img {
  width: 34%;
  height: auto;
}

/* The kit's lime square tag on a cover, bottom left: the kind of event. */
.tag {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: calc(4 * var(--u));
  padding: calc(4 * var(--u)) calc(8 * var(--u));
  border: calc(1 * var(--u)) solid var(--brand);
  background: var(--accent);
  font-family: var(--font-display);
  font-size: calc(11 * var(--u));
  font-weight: 600;
  line-height: 1.2;
  color: var(--brand);
  white-space: nowrap;
}

.tag .i {
  width: calc(12 * var(--u));
  height: calc(12 * var(--u));
  stroke-width: 2.4;
}

.tag.kind {
  left: calc(12 * var(--u));
  bottom: calc(12 * var(--u));
}

.sm-cover .tag.kind {
  left: calc(8 * var(--u));
  bottom: calc(8 * var(--u));
}

/* The heart: a cream circle on the cover. */
.heart {
  position: absolute;
  top: calc(12 * var(--u));
  right: calc(12 * var(--u));
  display: grid;
  place-items: center;
  width: calc(36 * var(--u));
  height: calc(36 * var(--u));
  border-radius: var(--r-pill);
  border: calc(1.5 * var(--u)) solid var(--brand);
  background: var(--bone);
  color: var(--brand);
}

.heart .i {
  width: calc(18 * var(--u));
  height: calc(18 * var(--u));
  stroke-width: 2;
}

.sm-cover .heart {
  top: calc(8 * var(--u));
  right: calc(8 * var(--u));
  width: calc(30 * var(--u));
  height: calc(30 * var(--u));
}

/* --- EventCard: the Events feed ------------------------------------------ */

.ec {
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  overflow: hidden;
  background: var(--surface);
}

.ec + .ec {
  margin-top: calc(20 * var(--u));
}

.ec .cover {
  height: calc(196 * var(--u));
}

.ec-body {
  display: flex;
  flex-direction: column;
  gap: calc(8 * var(--u));
  padding: calc(16 * var(--u)) calc(16 * var(--u)) calc(12 * var(--u));
}

.ec-when {
  font-family: var(--font-display);
  font-size: calc(13 * var(--u));
  font-weight: 600;
  letter-spacing: calc(0.3 * var(--u));
  color: var(--ink-muted);
}

.ec-title {
  font-family: var(--font-display);
  font-size: calc(20 * var(--u));
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: calc(-0.4 * var(--u));
}

.ec-soc {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  color: var(--ink-muted);
}

.ec-soc .disc {
  border: calc(1 * var(--u)) solid var(--brand);
}

.ec-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(12 * var(--u));
  margin-top: calc(8 * var(--u));
  padding-top: calc(12 * var(--u));
  border-top: calc(1 * var(--u)) solid var(--surface-line);
  color: var(--ink-muted);
}

.ec-place {
  display: flex;
  align-items: center;
  gap: calc(6 * var(--u));
  min-width: 0;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ec-place .i {
  width: calc(15 * var(--u));
  height: calc(15 * var(--u));
  color: var(--brand);
}

.ec-friends {
  display: flex;
  align-items: center;
  gap: calc(6 * var(--u));
  font-family: var(--font-display);
  font-weight: 600;
}

/* --- EventPoster: What's on's rows of small cards ---------------------- */

.ep-rail {
  display: flex;
  gap: calc(12 * var(--u));
  margin-right: calc(-20 * var(--u));
}

.ep {
  flex: none;
  width: calc(288 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  overflow: hidden;
  background: var(--surface);
}

.ep .cover {
  height: calc(158 * var(--u));
}

.ep-body {
  display: flex;
  flex-direction: column;
  gap: calc(4 * var(--u));
  padding: calc(12 * var(--u));
}

.ep-when {
  font-family: var(--font-display);
  font-size: calc(11 * var(--u));
  font-weight: 600;
  letter-spacing: calc(0.3 * var(--u));
  color: var(--ink-muted);
}

.ep-title {
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
  line-height: 1.27;
  letter-spacing: calc(-0.2 * var(--u));
  color: var(--brand);
}

.ep-soc {
  font-size: calc(11 * var(--u));
  color: var(--ink-muted);
}

/* --- EventTile: compact rows (Your plans, the map's sheet, the demos) --- */

.et {
  display: flex;
  align-items: center;
  gap: calc(12 * var(--u));
  min-height: calc(104 * var(--u));
  padding: calc(12 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(18 * var(--u));
  background: var(--surface);
}

.et + .et {
  margin-top: calc(12 * var(--u));
}

.et .thumb {
  flex: none;
  width: calc(80 * var(--u));
  height: calc(80 * var(--u));
  border-radius: calc(12 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
}

.et-text {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
  gap: calc(2 * var(--u));
}

.et-when {
  font-family: var(--font-display);
  font-size: calc(13 * var(--u));
  font-weight: 700;
}

.et-when span {
  font-weight: 600;
  color: var(--ink-muted);
}

.et-title {
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.et-meta {
  color: var(--ink-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.et-social {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  margin-top: calc(2 * var(--u));
  font-family: var(--font-display);
  font-weight: 600;
}

/* --- What's on (the hero phone) ----------------------------------------- */

.wo {
  display: flex;
  flex-direction: column;
  gap: calc(20 * var(--u));
  padding: calc(22 * var(--u)) calc(20 * var(--u)) 0;
}

.wo-hey {
  font-family: var(--font-display);
  font-size: calc(11 * var(--u));
  font-weight: 700;
  letter-spacing: calc(1.6 * var(--u));
  color: var(--ink-muted);
}

.wo-title {
  margin-top: calc(8 * var(--u));
  font-family: var(--font-display);
  font-size: calc(28 * var(--u));
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: calc(-1.2 * var(--u));
}

/* A row of small cards with its title and See all. */
.wo-row {
  display: flex;
  flex-direction: column;
  gap: calc(12 * var(--u));
}

/* The staff-picked event: the kit's purple block. */
.feat {
  display: flex;
  flex-direction: column;
  gap: calc(12 * var(--u));
  padding: calc(24 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--brand);
  color: var(--ink-inverse);
}

.feat-label {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  font-family: var(--font-display);
  font-size: calc(11 * var(--u));
  font-weight: 600;
  letter-spacing: calc(1.3 * var(--u));
  color: var(--accent);
}

.feat-label::before {
  content: '';
  width: calc(6 * var(--u));
  height: calc(6 * var(--u));
  border-radius: var(--r-pill);
  background: var(--accent);
}

.feat-title {
  font-family: var(--font-display);
  font-size: calc(40 * var(--u));
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: calc(-1.6 * var(--u));
}

.feat-meta {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  color: var(--brand-tint);
}

.feat-meta span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.feat-meta .i {
  width: calc(15 * var(--u));
  height: calc(15 * var(--u));
}

.feat-actions {
  display: flex;
  align-items: center;
  gap: calc(16 * var(--u));
  margin-top: calc(4 * var(--u));
}

.feat-btn {
  display: inline-flex;
  align-items: center;
  gap: calc(12 * var(--u));
  height: calc(44 * var(--u));
  padding: 0 calc(16 * var(--u));
  border-radius: calc(8 * var(--u));
  background: var(--accent);
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
  color: var(--brand);
}

.feat-btn .i {
  width: calc(17 * var(--u));
  height: calc(17 * var(--u));
  stroke-width: 2.2;
}

.feat-friends {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  font-family: var(--font-display);
  font-weight: 600;
}

/* --- Events (the views section) ----------------------------------------- */

.ev-controls {
  display: flex;
  flex-direction: column;
  gap: calc(12 * var(--u));
  padding: calc(16 * var(--u)) calc(20 * var(--u)) 0;
}

.ev-row {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
}

.ev-chips {
  display: flex;
  flex: 1;
  gap: calc(8 * var(--u));
  min-width: 0;
  overflow: hidden;
}

.ev-feed {
  padding: 0 calc(20 * var(--u));
}

/* --- Your plans ------------------------------------------------------------ */

.plans {
  display: flex;
  flex-direction: column;
  gap: calc(16 * var(--u));
  padding: calc(12 * var(--u)) calc(20 * var(--u)) 0;
}

.plans-title {
  margin-top: calc(-4 * var(--u));
  font-family: var(--font-display);
  font-size: calc(40 * var(--u));
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: calc(-1.3 * var(--u));
}

.plans-views {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
}

/* Pill tone "bright": where the plans go. */
.synced {
  display: inline-flex;
  align-items: center;
  gap: calc(6 * var(--u));
  margin-left: auto;
  padding: calc(6 * var(--u)) calc(10 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: var(--r-pill);
  background: var(--accent);
  font-family: var(--font-display);
  font-size: calc(12 * var(--u));
  font-weight: 600;
  color: var(--brand);
  white-space: nowrap;
}

.synced .i {
  width: calc(15 * var(--u));
  height: calc(15 * var(--u));
  stroke-width: 2;
}

.plans-range {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(12 * var(--u));
  font-family: var(--font-display);
  font-size: calc(20 * var(--u));
  font-weight: 800;
  letter-spacing: calc(-0.4 * var(--u));
  color: var(--brand);
}

.plans-range .a-icon {
  width: calc(36 * var(--u));
  height: calc(36 * var(--u));
  border-width: calc(2 * var(--u));
}

.plans-range .a-icon:last-child .i {
  transform: scaleX(-1);
}

/* The week strip: today outlined, a purple dot on days with plans. */
.strip {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: calc(4 * var(--u));
}

.strip span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(4 * var(--u));
  padding: calc(8 * var(--u)) 0;
  border: calc(1.5 * var(--u)) solid transparent;
  border-radius: calc(8 * var(--u));
  font-size: calc(11 * var(--u));
  color: var(--ink-muted);
}

.strip b {
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
}

.strip i {
  width: calc(6 * var(--u));
  height: calc(6 * var(--u));
  border-radius: var(--r-pill);
  background: var(--brand);
}

.strip .none i {
  opacity: 0;
}

.strip .today {
  border-color: var(--brand);
}

/* --- The map ----------------------------------------------------------- */

.map {
  position: absolute;
  inset: 0;
  background: #ece9e1;
}

.map svg.streets {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.map-road {
  fill: none;
  stroke: #ffffff;
  stroke-width: 13;
  stroke-linecap: round;
}

.map-lane {
  fill: none;
  stroke: #ffffff;
  stroke-width: 6;
  stroke-linecap: round;
  opacity: 0.85;
}

.map-park {
  fill: #dfe7cf;
}

.map-block {
  fill: #e3dfd3;
}

.map-top {
  position: absolute;
  z-index: 2;
  top: calc(58 * var(--u));
  left: calc(16 * var(--u));
  right: calc(16 * var(--u));
  display: flex;
  align-items: center;
  gap: calc(10 * var(--u));
}

/* All / Events / Eats. */
.seg {
  display: flex;
  padding: calc(3 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: var(--r-pill);
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(14 * var(--u));
  font-weight: 600;
}

.seg span {
  padding: calc(7 * var(--u)) calc(14 * var(--u));
  border-radius: var(--r-pill);
}

.seg .on {
  background: var(--brand);
  color: var(--ink-inverse);
}

/* Pins: rounded labels with what's there and when. */
.pin {
  position: absolute;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: calc(4 * var(--u));
  padding: calc(5 * var(--u)) calc(9 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: calc(8 * var(--u));
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(14 * var(--u));
  font-weight: 600;
  color: var(--brand);
  white-space: nowrap;
}

.pin .i {
  width: calc(15 * var(--u));
  height: calc(15 * var(--u));
  stroke-width: 2;
}

.pin.live {
  background: var(--brand);
  color: var(--ink-inverse);
}

.pin.eat {
  background: var(--accent);
}

.pin-a { left: 9%; top: 26%; }
.pin-b { left: 54%; top: 33%; }
.pin-c { left: 35%; top: 46%; }
.pin-d { left: 60%; top: 57%; }

/* The sheet over the map. */
.map-sheet {
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 0;
  padding: calc(10 * var(--u)) calc(16 * var(--u)) calc(30 * var(--u));
  border-top: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(20 * var(--u)) calc(20 * var(--u)) 0 0;
  background: var(--bone);
}

.map-sheet::before {
  content: '';
  display: block;
  width: calc(36 * var(--u));
  height: calc(5 * var(--u));
  margin: 0 auto calc(12 * var(--u));
  border-radius: var(--r-pill);
  background: var(--surface-line);
}

.map-sheet-title {
  margin-bottom: calc(12 * var(--u));
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 600;
}

/* --- An event's page (how it works) ------------------------------------ */

.evp .cover {
  height: calc(250 * var(--u));
}

.page-top {
  position: absolute;
  z-index: 2;
  top: calc(58 * var(--u));
  left: calc(16 * var(--u));
  right: calc(16 * var(--u));
  display: flex;
  justify-content: space-between;
}

.page-top div {
  display: flex;
  gap: calc(10 * var(--u));
}

.page-body {
  display: flex;
  flex-direction: column;
  gap: calc(10 * var(--u));
  padding: calc(16 * var(--u)) calc(20 * var(--u));
}

/* The society, in a pill: its logo, then its name. */
.soc-pill {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: calc(8 * var(--u));
  padding: calc(4 * var(--u)) calc(12 * var(--u)) calc(4 * var(--u)) calc(4 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: var(--r-pill);
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(14 * var(--u));
  font-weight: 600;
}

.page-title {
  font-family: var(--font-display);
  font-size: calc(28 * var(--u));
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: calc(-0.6 * var(--u));
}

.detail {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  font-size: calc(15 * var(--u));
}

.detail .i {
  width: calc(17 * var(--u));
  height: calc(17 * var(--u));
  color: var(--brand);
  stroke-width: 2;
}

/* The map card: read, not pressed; its "Open in Maps" pill is the button. */
.mapcard {
  position: relative;
  height: calc(120 * var(--u));
  overflow: hidden;
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(16 * var(--u));
  background: var(--brand-wash);
}

.mapcard svg.streets {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.mapcard .map-road {
  stroke-width: 9;
}

.mapcard-pin {
  position: absolute;
  left: 44%;
  top: 34%;
  width: calc(22 * var(--u));
  height: calc(22 * var(--u));
  border-radius: var(--r-pill);
  border: calc(3 * var(--u)) solid var(--surface);
  background: var(--brand);
  box-shadow: 0 0 0 calc(2 * var(--u)) var(--brand);
}

.mapcard-open {
  position: absolute;
  right: calc(10 * var(--u));
  bottom: calc(10 * var(--u));
  display: inline-flex;
  align-items: center;
  gap: calc(4 * var(--u));
  padding: calc(4 * var(--u)) calc(11 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: var(--r-pill);
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(12 * var(--u));
  font-weight: 700;
  color: var(--brand);
}

.mapcard-open .i {
  width: calc(13 * var(--u));
  height: calc(13 * var(--u));
  stroke-width: 2.2;
}

.page-text {
  font-size: calc(15 * var(--u));
  line-height: 1.45;
}

.going-line {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  font-family: var(--font-display);
  font-size: calc(14 * var(--u));
  font-weight: 600;
}

/* The bottom bar of an event page: a purple rule, then the one button. */
.page-bar {
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  bottom: 0;
  padding: calc(16 * var(--u)) calc(20 * var(--u)) calc(34 * var(--u));
  border-top: calc(2 * var(--u)) solid var(--brand);
  background: var(--bone);
}

/* --- An event's admin page (societies) ---------------------------------- */

.host .cover {
  height: calc(210 * var(--u));
}

.host-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(10 * var(--u));
  margin-top: calc(4 * var(--u));
}

.host-stat {
  padding: calc(12 * var(--u)) calc(14 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--brand-wash);
  font-family: var(--font-display);
  font-size: calc(13 * var(--u));
  font-weight: 600;
}

.host-stat b {
  display: block;
  font-size: calc(26 * var(--u));
  font-weight: 800;
  line-height: 1.1;
}

.host-stat.purple {
  border-color: var(--brand);
  background: var(--brand);
  color: var(--ink-inverse);
}

.meter {
  height: calc(12 * var(--u));
  overflow: hidden;
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: var(--r-pill);
  background: var(--brand-wash);
}

.meter i {
  display: block;
  width: 70%;
  height: 100%;
  background: var(--brand);
}

.meter-labels {
  display: flex;
  justify-content: space-between;
  margin-top: calc(-4 * var(--u));
  font-family: var(--font-display);
  font-size: calc(12 * var(--u));
  font-weight: 600;
  color: var(--ink-muted);
}

/* The menu: icon rows in one quiet card. */
.menu-card {
  overflow: hidden;
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--surface);
}

.menu-card p {
  display: flex;
  align-items: center;
  gap: calc(12 * var(--u));
  min-height: calc(48 * var(--u));
  padding: 0 calc(14 * var(--u));
  border-bottom: calc(1 * var(--u)) solid var(--surface-line);
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 600;
}

.menu-card p:last-child {
  border-bottom: 0;
}

.menu-card .i {
  width: calc(20 * var(--u));
  height: calc(20 * var(--u));
  color: var(--brand);
}

/* --- The check-in code: one of the app's purple floods ------------------- */

.door {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: var(--brand);
  color: var(--ink-inverse);
}

.door .a-icon {
  margin: calc(8 * var(--u)) 0 0 calc(20 * var(--u));
}

.door-title {
  margin-top: calc(44 * var(--u));
  padding: 0 calc(24 * var(--u));
  text-align: center;
  font-family: var(--font-display);
  font-size: calc(28 * var(--u));
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: calc(-0.6 * var(--u));
}

.door-time {
  margin-top: calc(6 * var(--u));
  text-align: center;
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 600;
  color: var(--brand-tint);
}

.door-card {
  position: relative;
  margin: calc(26 * var(--u)) calc(30 * var(--u)) 0;
  padding: calc(18 * var(--u));
  border: calc(2 * var(--u)) solid var(--brand);
  border-radius: calc(24 * var(--u));
  background: var(--bone);
}

.door-card > img {
  display: block;
  width: 100%;
  height: auto;
}

/* The mark sits on a disc of the code's background, as in components/qr-code.tsx. */
.door-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 23%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: var(--r-pill);
  background: var(--bone);
}

.door-mark img {
  width: 82%;
  height: 82%;
}

.door-note {
  margin-top: calc(20 * var(--u));
  padding: 0 calc(30 * var(--u));
  text-align: center;
  font-size: calc(15 * var(--u));
  line-height: 1.4;
}

/* --- Rows of phones: the home page's three views, the societies page's two ------------------- */
/* A row of phones at desktop; at phone width they scroll sideways inside their own strip, so the
   page itself never does. */

.views,
.duo {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(19rem, 82%);
  gap: 1.25rem;
  margin-top: 3rem;
  padding: 0.5rem var(--gutter) 1.5rem;
  margin-inline: calc(var(--gutter) * -1);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.views::-webkit-scrollbar,
.duo::-webkit-scrollbar {
  display: none;
}

.views > figure,
.duo > figure {
  scroll-snap-align: center;
}

.views figcaption,
.duo figcaption {
  margin-top: 1.25rem;
  text-align: center;
}

.views figcaption .t-label,
.duo figcaption .t-label {
  color: var(--brand);
}

.views figcaption p + p,
.duo figcaption p + p {
  margin-top: 0.5rem;
}

@media (min-width: 1024px) {
  .views {
    grid-auto-flow: row;
    grid-template-columns: repeat(3, minmax(0, 18.5rem));
    justify-content: center;
    gap: 2.5rem;
    margin-inline: 0;
    padding-inline: 0;
    overflow: visible;
  }
}

@media (min-width: 768px) {
  .duo {
    grid-auto-flow: row;
    grid-template-columns: repeat(2, minmax(0, 18.5rem));
    justify-content: center;
    gap: 3rem;
    margin-inline: 0;
    padding-inline: 0;
    overflow: visible;
  }
}

/* --- In action (home): two looping scenes drawn in HTML and CSS ----------------------------------
   Each stage is drawn at 320 x 420 and scales with its width (container units): --u is a point of the
   app, --p a pixel of the drawing, so the cursor's stops (--a… / --b… on the stage) stay on their
   targets at any size. One 12 s loop drives everything; with reduced motion the scene holds still on
   its finished state. */

/* The heading on the left and one line on the right, then the two scenes side by side. */
.demo-intro {
  display: grid;
  gap: 1rem;
}

.demo-intro p {
  max-width: 34ch;
}

.demo-grid {
  display: grid;
  gap: 2.5rem;
  margin-top: 2.5rem;
}

.demo-item figcaption {
  margin-top: 1.1rem;
}

.demo-item figcaption p {
  margin-top: 0.25rem;
}

@media (min-width: 900px) {
  .demo-intro {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    align-items: end;
    gap: 4rem;
  }

  .demo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 3.5rem;
  }
}

/* A quiet white card holding the steps and the stage. */
.demo-panel {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 1rem;
  padding: 1.25rem 0.875rem 1.5rem;
  border: 1px solid var(--surface-line);
  border-radius: var(--r-card);
  background: var(--surface);
}

/* The three steps, all shown; the one being done turns lime. */
.demo-steps {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.375rem;
}

.demo-steps span {
  padding: 0.4rem 0.8rem;
  border: 1.5px solid var(--brand);
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--brand);
  font-family: var(--font-display);
  font-size: var(--caption);
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  animation: 12s infinite demo-step-1;
}

.demo-steps span:nth-child(2) {
  animation-name: demo-step-2;
}

.demo-steps span:nth-child(3) {
  animation-name: demo-step-3;
}

.demo-apply-steps span {
  animation-name: demo-astep-1;
}

.demo-apply-steps span:nth-child(2) {
  animation-name: demo-astep-2;
}

.demo-apply-steps span:nth-child(3) {
  animation-name: demo-astep-3;
}

@keyframes demo-step-1 { 0%, 16% { background: var(--accent); } 18%, 100% { background: var(--surface); } }
@keyframes demo-step-2 { 0%, 17% { background: var(--surface); } 19%, 46% { background: var(--accent); } 48%, 100% { background: var(--surface); } }
@keyframes demo-step-3 { 0%, 47% { background: var(--surface); } 49%, 95% { background: var(--accent); } 97%, 100% { background: var(--surface); } }
@keyframes demo-astep-1 { 0%, 33% { background: var(--accent); } 35%, 100% { background: var(--surface); } }
@keyframes demo-astep-2 { 0%, 34% { background: var(--surface); } 36%, 56% { background: var(--accent); } 58%, 100% { background: var(--surface); } }
@keyframes demo-astep-3 { 0%, 57% { background: var(--surface); } 59%, 95% { background: var(--accent); } 97%, 100% { background: var(--surface); } }

.demo-stage {
  container-type: inline-size;
  position: relative;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 320 / 420;
  overflow: hidden;
  border: 1px solid var(--surface-line);
  border-radius: 1.4rem;
  background: var(--bone);
  color: var(--ink);
  text-align: left;
  --u: calc(100cqw / 390);
  --p: calc(100cqw / 320);
}

@supports not (width: 1cqw) {
  .demo-stage {
    --u: 0.8205px;
    --p: 1px;
  }
}

.demo-cursor {
  position: absolute;
  z-index: 6;
  left: 0;
  top: 0;
  width: calc(26 * var(--p));
  height: calc(26 * var(--p));
  fill: var(--ink);
  stroke: var(--surface);
  stroke-width: 1.5;
  animation: 12s infinite ease-in-out;
}

/* --- Scene 1: tap Following, find friends going, tap I'm going ---------------- */

.demo-going {
  --a1: calc(250 * var(--p)), calc(330 * var(--p));
  --a2: calc(201 * var(--p)), calc(76 * var(--p));
  --a3: calc(154 * var(--p)), calc(246 * var(--p));
  --a4: calc(154 * var(--p)), calc(384 * var(--p));
}

.demo-going .demo-cursor {
  animation-name: demo-going-cursor;
}

@keyframes demo-going-cursor {
  0% { transform: translate(var(--a1)); opacity: 0; }
  4% { transform: translate(var(--a1)); opacity: 1; }
  11% { transform: translate(var(--a2)) scale(1); }
  13% { transform: translate(var(--a2)) scale(0.8); }
  15%, 28% { transform: translate(var(--a2)) scale(1); }
  36% { transform: translate(var(--a3)) scale(1); }
  38% { transform: translate(var(--a3)) scale(0.8); }
  40%, 52% { transform: translate(var(--a3)) scale(1); }
  60% { transform: translate(var(--a4)) scale(1); }
  65% { transform: translate(var(--a4)) scale(0.8); }
  67%, 92% { transform: translate(var(--a4)) scale(1); opacity: 1; }
  95%, 100% { transform: translate(var(--a4)); opacity: 0; }
}

.demo-going .ev-controls {
  padding-top: calc(14 * var(--u));
}

.demo-follow {
  animation: 12s infinite demo-follow;
}

@keyframes demo-follow { 0%, 13% { background: var(--surface); } 14%, 96% { background: var(--accent); } 98%, 100% { background: var(--surface); } }

.demo-lists {
  position: relative;
  padding: calc(16 * var(--u)) calc(20 * var(--u)) 0;
}

.demo-list-b {
  position: absolute;
  inset: calc(16 * var(--u)) calc(20 * var(--u)) auto;
  opacity: 0;
  animation: 12s infinite demo-list-b;
}

.demo-list-a {
  animation: 12s infinite demo-list-a;
}

@keyframes demo-list-a { 0%, 15% { opacity: 1; } 17%, 97% { opacity: 0; } 99%, 100% { opacity: 1; } }
@keyframes demo-list-b { 0%, 15% { opacity: 0; } 17%, 96% { opacity: 1; } 98%, 100% { opacity: 0; } }

.demo-target {
  animation: 12s infinite demo-target;
}

@keyframes demo-target {
  0%, 35% { box-shadow: 0 0 0 0 transparent; }
  37%, 43% { box-shadow: 0 0 0 calc(3 * var(--u)) var(--brand); }
  45%, 100% { box-shadow: 0 0 0 0 transparent; }
}

/* The event's page slides up over the feed. */
.demo-page {
  position: absolute;
  z-index: 4;
  inset: 0;
  background: var(--bone);
  transform: translateY(102%);
  animation: 12s infinite demo-page;
}

@keyframes demo-page {
  0%, 43% { transform: translateY(102%); }
  48%, 95% { transform: none; }
  99%, 100% { transform: translateY(102%); }
}

.demo-page .cover {
  height: calc(170 * var(--u));
}

.demo-page .page-body {
  gap: calc(8 * var(--u));
  padding-top: calc(14 * var(--u));
}

.demo-label {
  margin-top: calc(4 * var(--u));
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
}

.demo-group {
  overflow: hidden;
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--surface);
}

.demo-group p {
  display: flex;
  align-items: center;
  gap: calc(10 * var(--u));
  min-height: calc(44 * var(--u));
  padding: 0 calc(12 * var(--u));
  border-bottom: calc(1 * var(--u)) solid var(--surface-line);
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
}

.demo-group p:last-child {
  border-bottom: 0;
}

.demo-page .page-bar {
  height: calc(86 * var(--u));
  padding-bottom: calc(16 * var(--u));
}

.demo-bar-btn,
.demo-bar-in {
  position: absolute;
  left: calc(20 * var(--u));
  right: calc(20 * var(--u));
  top: calc(16 * var(--u));
}

.demo-bar-btn {
  animation: 12s infinite demo-bar-btn;
}

.demo-bar-in {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: calc(8 * var(--u));
  height: calc(52 * var(--u));
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 700;
  opacity: 0;
  animation: 12s infinite demo-bar-in;
}

.demo-bar-in .i {
  width: calc(22 * var(--u));
  height: calc(22 * var(--u));
  color: var(--brand);
  stroke-width: 2;
}

@keyframes demo-bar-btn { 0%, 67% { opacity: 1; } 69%, 100% { opacity: 0; } }
@keyframes demo-bar-in { 0%, 67% { opacity: 0; } 69%, 95% { opacity: 1; } 97%, 100% { opacity: 0; } }

/* --- Scene 2: answer the questions, use your last CV, send it --------------- */

.demo-apply {
  --b1: calc(290 * var(--p)), calc(170 * var(--p));
  --b2: calc(154 * var(--p)), calc(302 * var(--p));
  --b3: calc(154 * var(--p)), calc(384 * var(--p));
}

.demo-apply .demo-cursor {
  animation-name: demo-apply-cursor;
}

@keyframes demo-apply-cursor {
  0%, 6% { transform: translate(var(--b1)); opacity: 1; }
  34% { transform: translate(var(--b2)) scale(1); }
  38% { transform: translate(var(--b2)) scale(0.8); }
  41%, 52% { transform: translate(var(--b2)) scale(1); }
  60% { transform: translate(var(--b3)) scale(1); }
  65% { transform: translate(var(--b3)) scale(0.8); }
  67%, 92% { transform: translate(var(--b3)) scale(1); opacity: 1; }
  95%, 100% { transform: translate(var(--b3)); opacity: 0; }
}

.apply-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(12 * var(--u));
  padding: calc(22 * var(--u)) calc(20 * var(--u)) 0;
}

.apply-title {
  font-family: var(--font-display);
  font-size: calc(28 * var(--u));
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: calc(-0.6 * var(--u));
}

.apply-sub {
  margin-top: calc(2 * var(--u));
  color: var(--ink-muted);
}

.apply-form {
  display: flex;
  flex-direction: column;
  gap: calc(8 * var(--u));
  padding: calc(12 * var(--u)) calc(20 * var(--u)) 0;
}

.apply-note {
  margin-bottom: calc(6 * var(--u));
  color: var(--ink-faint);
  line-height: 1.4;
}

.apply-label {
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
}

.apply-field {
  min-height: calc(64 * var(--u));
  padding: calc(12 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--surface);
  font-size: calc(15 * var(--u));
}

.demo-typed {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  vertical-align: top;
  width: 0;
  animation: 12s infinite steps(42, end) demo-typed;
}

@keyframes demo-typed { 0%, 4% { width: 0; } 30%, 96% { width: 100%; } 98%, 100% { width: 0; } }

.apply-count {
  margin-top: calc(-4 * var(--u));
  text-align: right;
  font-size: calc(11 * var(--u));
  color: var(--ink-faint);
}

.apply-cv {
  position: relative;
  height: calc(62 * var(--u));
}

.apply-cv > p {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: calc(12 * var(--u));
  padding: 0 calc(14 * var(--u));
  border: calc(1 * var(--u)) solid var(--surface-line);
  border-radius: calc(12 * var(--u));
  background: var(--surface);
  color: var(--ink-faint);
  font-size: calc(12 * var(--u));
  line-height: 1.35;
}

.apply-cv span {
  min-width: 0;
}

.apply-cv b {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
}

.apply-cv .i {
  width: calc(24 * var(--u));
  height: calc(24 * var(--u));
  color: var(--brand);
}

.apply-cv-empty {
  animation: 12s infinite demo-cv-empty;
}

.apply-cv-file {
  opacity: 0;
  animation: 12s infinite demo-cv-file;
}

@keyframes demo-cv-empty { 0%, 41% { opacity: 1; } 43%, 96% { opacity: 0; } 98%, 100% { opacity: 1; } }
@keyframes demo-cv-file { 0%, 41% { opacity: 0; } 43%, 95% { opacity: 1; } 97%, 100% { opacity: 0; } }

/* Button variant "outline": white, a purple outline. */
.apply-reuse {
  display: flex;
  align-items: center;
  justify-content: center;
  height: calc(44 * var(--u));
  margin-top: calc(4 * var(--u));
  padding: 0 calc(10 * var(--u));
  border: calc(1.5 * var(--u)) solid var(--brand);
  border-radius: calc(8 * var(--u));
  background: var(--surface);
  font-family: var(--font-display);
  font-size: calc(13 * var(--u));
  font-weight: 600;
  color: var(--brand);
  white-space: nowrap;
  animation: 12s infinite demo-reuse;
}

@keyframes demo-reuse { 0%, 41% { opacity: 1; } 43%, 96% { opacity: 0; } 98%, 100% { opacity: 1; } }

.apply-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(86 * var(--u));
}

.apply-send {
  position: absolute;
  left: calc(20 * var(--u));
  right: calc(20 * var(--u));
  top: calc(16 * var(--u));
  animation: 12s infinite demo-send;
}

.apply-sent {
  position: absolute;
  left: calc(20 * var(--u));
  right: calc(20 * var(--u));
  top: calc(8 * var(--u));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(6 * var(--u));
  opacity: 0;
  animation: 12s infinite demo-sent;
}

.apply-sent b {
  display: flex;
  align-items: center;
  gap: calc(8 * var(--u));
  font-family: var(--font-display);
  font-size: calc(17 * var(--u));
  font-weight: 700;
}

.apply-sent .i {
  width: calc(20 * var(--u));
  height: calc(20 * var(--u));
  color: var(--brand);
  stroke-width: 2;
}

.apply-sent span {
  font-family: var(--font-display);
  font-size: calc(15 * var(--u));
  font-weight: 600;
  color: var(--brand);
}

@keyframes demo-send { 0%, 67% { opacity: 1; } 69%, 100% { opacity: 0; } }
@keyframes demo-sent { 0%, 67% { opacity: 0; } 69%, 95% { opacity: 1; } 97%, 100% { opacity: 0; } }

/* Reduced motion: every scene holds its finished state, with no cursor. */
@media (prefers-reduced-motion: reduce) {
  .demo-panel * {
    animation-duration: 12s !important;
    animation-iteration-count: infinite !important;
    animation-play-state: paused !important;
    animation-delay: -9s !important;
  }

  .demo-cursor {
    display: none;
  }
}
