/* Alfi web foundations and shared primitives. See docs/design/web-design-system.md. */
@font-face { font-family: "Open Runde"; src: url("/assets/fonts/OpenRunde-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Open Runde"; src: url("/assets/fonts/OpenRunde-Medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Open Runde"; src: url("/assets/fonts/OpenRunde-Semibold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Open Runde"; src: url("/assets/fonts/OpenRunde-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
:root {
  color-scheme: light;
  --font: "Open Runde", ui-rounded, system-ui, sans-serif;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px;
  --space-5: 24px; --space-6: 32px; --space-7: 48px; --space-8: 64px;
  --radius-control: 12px; --radius-tile: 16px; --radius-card: 20px; --radius-pill: 999px;
  --type-caption: .8125rem; --type-label: .9375rem; --type-body: 1.0625rem;
  --type-lede: clamp(1.125rem, 2vw, 1.25rem);
  --type-title: clamp(1.875rem, 4.3vw, 3rem);
  --type-display: clamp(3rem, 7vw, 5.5rem);
  --gutter: clamp(20px, 5vw, 64px); --measure: 1120px;
  --section-space: clamp(80px, 11vw, 144px);
  --block-space: clamp(64px, 7vw, 88px);
  --motion-fast: 140ms; --motion-standard: 240ms;
  --ease-out: cubic-bezier(.22, 1, .36, 1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--alfi-surface); color: var(--alfi-ink); font: 400 var(--type-body)/1.6 var(--font); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2, h3, .type-display, .type-title { font-weight: 600; letter-spacing: -.045em; text-wrap: balance; }
h1, .type-display { font-size: var(--type-display); line-height: 1.02; }
h2, .type-title { font-size: var(--type-title); line-height: 1.12; }
h3 { font-size: 1.25rem; line-height: 1.3; letter-spacing: -.025em; }
p { text-wrap: pretty; }
a { color: inherit; text-underline-offset: 4px; }
:focus-visible { outline: 3px solid var(--alfi-accent); outline-offset: 4px; }
[hidden] { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.trap { position: absolute; left: -9999px; }
.skip-link { position: fixed; top: 12px; left: 12px; z-index: 100; padding: 12px 20px; background: var(--alfi-surface); transform: translateY(-180%); }
.skip-link:focus { transform: none; }
.container { width: min(calc(100% - 2 * var(--gutter)), var(--measure)); margin-inline: auto; }
/* Small marker accents, never full surface fills or yellow body text. */
.text-highlight { color: var(--alfi-ink); background: linear-gradient(transparent 52%, var(--highlight, var(--alfi-highlight-yellow)) 52%, var(--highlight, var(--alfi-highlight-yellow)) 94%, transparent 94%); padding-inline: .06em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.text-highlight--sky { --highlight: var(--alfi-highlight-sky); }
.text-highlight--mint { --highlight: var(--alfi-highlight-mint); }
.text-highlight--coral { --highlight: var(--alfi-highlight-coral); }
.text-highlight--apricot { --highlight: var(--alfi-highlight-apricot); }
/* Hero only: a hand-drawn red stroke that draws in once. */
.text-underline { padding-bottom: .12em; background: var(--alfi-underline-stroke) left bottom / 100% .34em no-repeat; box-decoration-break: clone; -webkit-box-decoration-break: clone; animation: underline-draw 700ms var(--ease-out) 250ms both; }
@keyframes underline-draw { from { background-size: 0% .34em; } to { background-size: 100% .34em; } }
.eyebrow { font-size: var(--type-label); font-weight: 500; letter-spacing: 0; }
.section { padding-block: var(--section-space); }
.section__head { max-width: 660px; margin-bottom: var(--space-7); }
.section__lede { margin-top: var(--space-4); color: var(--alfi-muted); font-size: var(--type-lede); }
.fineprint { color: var(--alfi-muted); font-size: var(--type-caption); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 48px; padding: 12px 24px; border: 1px solid transparent; border-radius: var(--radius-pill); background: var(--alfi-action); color: var(--alfi-on-action); font-size: var(--type-label); font-weight: 600; line-height: 1.3; text-decoration: none; cursor: pointer; transition: transform var(--motion-fast) var(--ease-out); }
.button:active:not(:disabled) { transform: scale(.98); }
.button--small { min-height: 44px; padding: 10px 20px; }
.button--secondary { background: var(--alfi-surface); border-color: var(--alfi-control-line); color: var(--alfi-ink); }
.button--text { background: transparent; color: var(--alfi-ink); padding-inline: 8px; }
/* Underline only the words, never an arrow beside them. */
.button--text .button__label { text-decoration: underline; }
.button:disabled { cursor: not-allowed; opacity: .6; }
.pill { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 44px; padding: 10px 18px; border: 1px solid var(--alfi-control-line); border-radius: var(--radius-pill); background: var(--alfi-surface); color: var(--alfi-ink); font: 500 var(--type-label)/1.3 var(--font); cursor: pointer; }
.pill[aria-pressed="true"] { background: var(--alfi-selected); border-color: var(--alfi-selected); color: var(--alfi-on-selected); }
.pill img { width: 18px; height: 18px; }
.pill[aria-pressed="true"] .mono { filter: invert(1); }
.field { min-width: 0; min-height: 52px; padding: 12px 20px; border: 1px solid var(--alfi-field-line); border-radius: var(--radius-control); background: var(--alfi-surface); color: var(--alfi-ink); font: inherit; }
.field::placeholder { color: var(--alfi-muted); }
.signup { position: relative; margin-top: var(--space-6); }
.signup__row { display: flex; gap: var(--space-3); }
.signup__row .field { flex: 1; }
.signup__status { margin-top: var(--space-3); color: var(--alfi-muted); font-size: var(--type-label); }
.signup__status:empty { display: none; }
.signup__status[data-tone="error"] { color: var(--alfi-danger); }
.signup[data-state="done"] > :not(.signup__status) { display: none; }
.signup[data-state="done"] .signup__status { padding: var(--space-4); border-radius: var(--radius-control); background: var(--alfi-success-soft); color: var(--alfi-success); }
.signup__privacy { margin-top: var(--space-4); color: var(--alfi-muted); font-size: .75rem; }
.choices { min-width: 0; display: flex; flex-wrap: wrap; gap: var(--space-2); padding: 0; margin: 0 0 var(--space-5); border: 0; }
.choices legend { margin-bottom: var(--space-3); font-size: var(--type-label); }
.choices label { cursor: pointer; }
.choices input { position: absolute; opacity: 0; }
.choices span { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px; padding: 10px 16px; border: 1px solid var(--alfi-control-line); border-radius: var(--radius-pill); font-size: var(--type-caption); }
.choices img { width: 18px; height: 18px; object-fit: contain; }
.choices input:checked + span { background: var(--alfi-selected); color: var(--alfi-on-selected); border-color: var(--alfi-selected); }
.choices input:checked + span .mono { filter: invert(1); }
.choices input:focus-visible + span { outline: 3px solid var(--alfi-accent); outline-offset: 3px; }
/* A desktop window frame for assistant and app surfaces. Window-button colors are standard desktop chrome. */
.window { overflow: hidden; border: 1px solid var(--alfi-line); border-radius: var(--radius-tile); background: var(--alfi-surface); box-shadow: 0 18px 40px -26px rgb(55 53 47 / .35); }
.window__bar { position: relative; display: flex; align-items: center; height: 38px; padding: 0 14px; border-bottom: 1px solid var(--alfi-line); background: var(--alfi-surface-soft); }
.window__lights { display: flex; gap: 6px; }
.window__lights i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.window__lights i:nth-child(2) { background: #febc2e; }
.window__lights i:nth-child(3) { background: #28c840; }
.window__title { position: absolute; left: 50%; display: inline-flex; align-items: center; gap: 6px; color: var(--alfi-ink); font-size: .8125rem; font-weight: 600; white-space: nowrap; transform: translateX(-50%); }
.window__title img { width: 16px; height: 16px; }
.window__body { display: grid; align-content: start; gap: var(--space-3); padding: var(--space-4); }
/* A neutral iPhone-style frame for real app captures (status bar drawn, capture chrome cropped). */
.device { --device-w: 260px; position: relative; width: min(100%, var(--device-w)); aspect-ratio: 9 / 19.5; margin-inline: auto; padding: 9px; border-radius: calc(var(--device-w) * .17); background: #1d1d1f; box-shadow: inset 0 0 0 1.5px #4a4a4d, 0 30px 60px -28px rgb(29 29 31 / .45); }
.device__screen { position: relative; height: 100%; overflow: hidden; padding-top: 38px; border-radius: calc(var(--device-w) * .135); background: #fff; }
.device__screen::before { content: ""; position: absolute; top: 9px; left: 50%; z-index: 2; width: 31%; height: 22px; border-radius: 999px; background: #000; transform: translateX(-50%); }
.device__status { position: absolute; top: 12px; left: 0; right: 0; z-index: 1; display: flex; justify-content: space-between; align-items: center; padding: 0 22px 0 28px; color: #000; font: 600 12px/1 var(--font); }
.device__status i { position: relative; width: 21px; height: 10px; border: 1.5px solid #000; border-radius: 3px; }
.device__status i::after { content: ""; position: absolute; inset: 1.5px 4px 1.5px 1.5px; border-radius: 1px; background: #000; }
.device__screen > img { display: block; width: 100%; height: auto; }
/* Cropped variant: the top of the phone, fading out at the bottom. */
.device--peek { --peek-h: 420px; aspect-ratio: auto; height: var(--peek-h); padding-bottom: 0; border-bottom-left-radius: 0; border-bottom-right-radius: 0; -webkit-mask-image: linear-gradient(#000 80%, transparent); mask-image: linear-gradient(#000 80%, transparent); }
.device--peek .device__screen { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
section[id] { scroll-margin-top: 96px; }
@media (max-width: 600px) {
  .signup__row { flex-direction: column; }
  .section__head { margin-bottom: var(--space-6); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
