/* Page compositions. Tokens and reusable controls live in design-system/. */
.nav { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); }
.brand { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--alfi-ink); text-decoration: none; font-size: 24px; font-weight: 700; letter-spacing: -.04em; }
.nav nav { display: flex; align-items: center; gap: var(--space-6); }
.nav__link { font-size: var(--type-label); text-decoration: none; padding-block: 12px; }
.hero { padding-block: clamp(40px, 5vw, 64px) 64px; text-align: center; }
.hero .eyebrow { margin-bottom: var(--space-5); }
.hero h1 br { display: none; }
/* The promise and Alfi stay on one line; the headline scales down on small phones to fit. */
.hero__promise { white-space: nowrap; }
@media (max-width: 480px) { .hero h1 { font-size: min(var(--type-display), 10.2vw); } }
/* Alfi sits right after the promise. It pops in once after the underline draws; no looping. */
.hero__mascot { display: inline-block; width: 1.1em; height: auto; margin-left: .14em; vertical-align: -.16em; transform: rotate(7deg); animation: mascot-pop 560ms var(--ease-out) 900ms both; }
@keyframes mascot-pop { 0% { opacity: 0; transform: translateY(.25em) scale(.55) rotate(-10deg); } 65% { opacity: 1; transform: translateY(-.05em) scale(1.08) rotate(10deg); } 100% { opacity: 1; transform: rotate(7deg); } }
.hero__lede { margin: var(--space-5) auto 0; max-width: 580px; font-size: var(--type-lede); line-height: 1.55; text-wrap: balance; }
.hero__actions { display: flex; justify-content: center; flex-wrap: wrap; align-items: center; gap: var(--space-5); margin-top: var(--space-6); }
.workflow__intro { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-5); margin-bottom: var(--space-5); }
.workflow__intro h2 { font-size: 1.375rem; letter-spacing: -.025em; }
.demo-switcher { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2); }
.demo { display: grid; grid-template-columns: 1fr 1fr; border-radius: var(--radius-card); overflow: hidden; background: var(--alfi-surface); border: 1px solid var(--alfi-line); }
.demo__conversation { padding: clamp(24px, 4.5vw, 64px); display: flex; flex-direction: column; }
.demo__label { color: var(--alfi-muted); font-size: .6875rem; font-weight: 600; letter-spacing: .1em; }
.demo h3 { margin-top: var(--space-3); font-size: 1.375rem; }
.demo__request { font-size: clamp(1.375rem, 2.5vw, 1.75rem); font-weight: 500; line-height: 1.4; letter-spacing: -.025em; margin-top: var(--space-5); max-width: 360px; }
.demo__receipt { margin-top: var(--space-7); }
.receipt__heading { display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-4); font-size: var(--type-label); font-weight: 500; }
.receipt__items { list-style: none; margin: var(--space-3) 0 0 48px; padding: 0; font-size: var(--type-label); }
.receipt__items li { display: flex; justify-content: space-between; gap: var(--space-3); padding-block: 7px; border-bottom: 1px solid var(--alfi-line); }
.receipt__items li span:last-child { color: var(--alfi-success); }
.demo__explanation { margin-top: auto; padding-top: var(--space-6); color: var(--alfi-muted); font-size: var(--type-caption); }
.demo__result { padding: var(--space-6); text-align: center; border-left: 1px solid var(--alfi-line); background: var(--alfi-surface); }
.demo__result .demo__label { color: var(--alfi-sky-ink); }
.device--demo { --device-w: 270px; margin-top: var(--space-5); }
.demo__placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: var(--space-4); color: var(--alfi-muted); }
.demo__placeholder > span { font-size: 2.5rem; color: var(--alfi-accent); }
.demo__controls { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-4); padding: 16px 24px; border-bottom: 1px solid var(--alfi-line); background: var(--alfi-surface); }
.demo__controls .button { color: var(--alfi-accent); border-color: var(--alfi-control-line); min-height: 44px; font-size: var(--type-caption); }
.demo[data-playing="true"][data-stage="2"] [data-receipt], .demo[data-playing="true"][data-stage="3"] [data-result]:not([hidden]) { animation: result-in 400ms var(--ease-out) both; }
@keyframes result-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
/* Use cases. Each scene shows a request, Alfi's reply and where it lands.
   Color identifies the action through markers and small details; surfaces stay white. */
[data-use-case="groceries"] { --case-marker: var(--alfi-highlight-apricot); --case-ink: var(--alfi-apricot-ink); --case-soft: var(--alfi-apricot-soft); }
[data-use-case="events"] { --case-marker: var(--alfi-highlight-sky); --case-ink: var(--alfi-sky-ink); --case-soft: var(--alfi-sky-soft); }
[data-use-case="routines"] { --case-marker: var(--alfi-highlight-mint); --case-ink: var(--alfi-mint-ink); --case-soft: var(--alfi-mint-soft); }
[data-use-case="reminders"], .ahead { --case-marker: var(--alfi-highlight-coral); --case-ink: var(--alfi-coral-ink); --case-soft: var(--alfi-coral-soft); }
[data-use-case="recall"] { --case-marker: var(--alfi-highlight-yellow); --case-ink: var(--alfi-yellow-ink); --case-soft: var(--alfi-yellow-soft); }
.use-cases .section__head .eyebrow, .ahead__head > .eyebrow { margin-bottom: var(--space-5); color: var(--alfi-muted); }
.use-cases__note { margin-bottom: var(--space-4); }
.use-case { padding-block: var(--block-space); border-top: 1px solid var(--alfi-line); }
.use-case__copy .eyebrow { color: var(--alfi-muted); font-weight: 600; font-size: var(--type-caption); }
.use-case__copy .eyebrow::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: var(--radius-pill); background: var(--case-marker); }
.use-case__copy h3 { margin-top: var(--space-4); font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.15; }
.use-case__copy > p:last-child { max-width: 390px; margin-top: var(--space-4); color: var(--alfi-muted); }
.availability { display: inline-block; padding: 2px 8px; margin-left: 6px; border: 1px solid var(--alfi-control-line); border-radius: var(--radius-pill); color: var(--alfi-muted); font-size: .6875rem; font-weight: 500; white-space: nowrap; }
/* Layouts vary down the page: split, full width, a pair, centered, then a feature. */
.use-case--split { display: grid; grid-template-columns: 4fr 7fr; gap: var(--space-8); align-items: center; }
.use-case--wide .use-case__copy { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: var(--space-4) var(--space-6); margin-bottom: var(--space-6); }
.use-case-pair { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-7); padding-block: var(--block-space); border-top: 1px solid var(--alfi-line); }
.use-case-pair > * { min-width: 0; }
.use-case--stacked { display: flex; flex-direction: column; gap: var(--space-6); padding-block: 0; border-top: 0; }
.use-case--stacked .scene { flex: 1; align-content: start; }
.use-case-pair > :last-child .scene { --scene-delay: 600ms; }
.use-case--recall { padding-bottom: 0; }
.use-case--recall .use-case__copy { max-width: 560px; margin: 0 auto var(--space-6); text-align: center; }
.use-case--recall .use-case__copy > p:last-child { max-width: none; }
/* Scene parts */
.scene { position: relative; display: grid; gap: var(--space-4); padding: var(--space-5); border: 1px solid var(--alfi-line); border-radius: var(--radius-card); background: var(--alfi-surface); }
.scene__chat { display: grid; gap: var(--space-3); align-content: start; }
.scene__source { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px var(--space-2); min-height: 28px; padding-right: 88px; color: var(--alfi-muted); font-size: var(--type-caption); font-weight: 500; }
.scene__source img { width: 16px; height: 16px; flex: none; }
.scene__source .availability { margin-left: 2px; }
.bubble { max-width: 36ch; padding: 10px 14px; border-radius: 18px; font-size: var(--type-label); line-height: 1.45; }
.bubble--you { justify-self: end; border-bottom-right-radius: 6px; background: var(--alfi-message); color: var(--alfi-on-message); }
.bubble--alfi { justify-self: start; display: flex; align-items: flex-start; gap: 10px; border: 1px solid var(--alfi-line); border-bottom-left-radius: 6px; background: var(--alfi-surface); }
.bubble--alfi > img { width: 24px; height: 24px; flex: none; margin-top: -1px; }
.bubble-slot { position: relative; display: grid; }
.typing { position: absolute; top: 0; left: 0; display: none; align-items: center; gap: 4px; height: 40px; padding: 0 14px; border: 1px solid var(--alfi-line); border-radius: 18px 18px 18px 6px; background: var(--alfi-surface); }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--alfi-control-line); }
.scene__footer { color: var(--case-ink); font-size: var(--type-caption); font-weight: 600; }
.scene__replay { position: absolute; top: 16px; right: 12px; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--alfi-muted); font-size: var(--type-caption); font-weight: 500; cursor: pointer; }
.scene__replay::before { content: "↻"; font-size: 1rem; }
.scene__replay:hover { color: var(--alfi-ink); background: var(--alfi-surface-soft); }
/* A small, realistic piece of the app where each request lands. */
.app-card { padding: var(--space-4); border: 1px solid var(--alfi-line); border-radius: var(--radius-tile); background: var(--alfi-surface); box-shadow: 0 12px 32px -16px rgb(55 53 47 / .22); }
.app-card__head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); padding-bottom: var(--space-3); border-bottom: 1px solid var(--alfi-line); }
.app-card__head strong { font-weight: 600; }
.app-card__head span { color: var(--alfi-muted); font-size: var(--type-caption); }
.app-list { list-style: none; margin: 0; padding: 0; }
.app-list li { display: flex; align-items: center; gap: 10px; padding: 8px 6px; border-bottom: 1px solid var(--alfi-line); border-radius: 8px; font-size: var(--type-label); }
.app-list li:last-child { border-bottom: 0; }
.app-list li::before { content: ""; width: 16px; height: 16px; flex: none; border: 1.5px solid var(--alfi-control-line); border-radius: 50%; }
.app-list--compact { margin-top: var(--space-2); }
.app-list--compact li { padding-block: 5px; font-size: var(--type-caption); }
.tag { margin-left: auto; padding: 1px 8px; border-radius: 6px; background: var(--case-soft); color: var(--case-ink); font-size: .6875rem; font-weight: 600; }
.scene--duo { grid-template-columns: minmax(0, 1fr) 250px; align-items: start; gap: var(--space-5); }
.scene--duo .scene__footer { grid-column: 1 / -1; text-align: right; }
.week { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border: 1px solid var(--alfi-line); border-radius: var(--radius-tile); overflow: hidden; box-shadow: 0 12px 32px -16px rgb(55 53 47 / .22); }
.week__day { display: flex; flex-direction: column; gap: 6px; min-width: 0; min-height: 188px; padding: 10px 6px; border-left: 1px solid var(--alfi-line); }
.week__day:first-child { border-left: 0; }
.week__label { color: var(--alfi-muted); font-size: .6875rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.week__label span { display: block; color: var(--alfi-ink); font-size: 1.125rem; letter-spacing: -.02em; }
.week__day--target .week__label, .week__day--target .week__label span { color: var(--case-ink); }
.week__event { padding: 6px 7px; border-left: 3px solid var(--alfi-line); border-radius: 6px; background: var(--alfi-surface-soft); color: var(--alfi-muted); font-size: .75rem; line-height: 1.35; overflow-wrap: anywhere; }
.week__event strong { display: block; color: var(--alfi-ink); font-weight: 600; }
.week__event--new { border-left-color: var(--case-marker); background: var(--case-soft); color: var(--case-ink); }
.rhythm { list-style: none; margin: var(--space-3) 0 0; padding: var(--space-3) 0 0; display: flex; gap: 6px; border-top: 1px solid var(--alfi-line); }
.rhythm li { display: grid; place-items: center; flex: 1 1 0; max-width: 30px; aspect-ratio: 1; border: 1px solid var(--case-marker); border-radius: 50%; background: var(--case-soft); color: var(--case-ink); font-size: .75rem; font-weight: 600; }
.reminder-time { margin-top: var(--space-3); color: var(--alfi-muted); font-size: var(--type-label); }
.reminder-time span { color: var(--alfi-ink); font-weight: 600; }
.reminder-state { display: grid; margin-top: var(--space-4); }
.reminder-state > * { grid-area: 1 / 1; align-self: center; }
.reminder-state__review { display: flex; gap: var(--space-2); visibility: hidden; }
.reminder-state__done { color: var(--case-ink); font-size: var(--type-label); font-weight: 600; }
.fake-button, .choice { display: inline-flex; align-items: center; min-height: 36px; padding: 6px 16px; border: 1px solid var(--alfi-control-line); border-radius: var(--radius-pill); background: var(--alfi-surface); font-size: var(--type-caption); font-weight: 600; }
.fake-button--primary { border-color: var(--alfi-action); background: var(--alfi-action); color: var(--alfi-on-action); }
.choice-row { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.choice--picked { border-color: var(--alfi-message); background: var(--alfi-message); color: var(--alfi-on-message); }
/* Looking ahead: a heads-up beside the actual For you screen. */
.ahead { border-top: 1px solid var(--alfi-line); }
.ahead__head { max-width: 680px; margin: 0 auto var(--space-7); text-align: center; }
.ahead__body { display: grid; grid-template-columns: 1fr 1fr; align-items: start; gap: var(--space-7); max-width: 760px; margin-inline: auto; }
.bubble--brief { max-width: 44ch; }
.brief-list { list-style: none; margin: var(--space-2) 0 0; padding: 0; display: grid; gap: 4px; }
.brief-list li { display: flex; gap: var(--space-3); }
.brief-list span { min-width: 78px; color: var(--case-ink); font-weight: 600; }
.ahead__note { margin-top: var(--space-4); }
.ahead__product .device { --device-w: 296px; }
.ahead__product figcaption { margin-top: var(--space-4); text-align: center; }
.notice { display: flex; align-items: flex-start; gap: var(--space-3); padding: 12px 14px; border: 1px solid var(--alfi-line); border-radius: 18px; background: var(--alfi-surface); box-shadow: 0 14px 30px -16px rgb(55 53 47 / .32); }
.notice > img { width: 36px; height: 36px; flex: none; padding: 3px; border-radius: 10px; background: var(--alfi-yellow-soft); }
.notice__head { display: flex; flex-wrap: wrap; align-items: center; gap: 2px var(--space-2); color: var(--alfi-muted); font-size: var(--type-caption); }
.notice__head strong { color: var(--alfi-ink); font-weight: 600; }
.notice__head .availability { margin-left: 0; }
.notice p:last-child { margin-top: 2px; font-size: var(--type-label); line-height: 1.45; }
/* Errands: Alfi working in the browser beside a generic store cart. No retailer branding. */
.errands { padding-top: var(--block-space); border-top: 1px solid var(--alfi-line); }
.nowrap { white-space: nowrap; }
.errands__head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: var(--space-4) var(--space-6); margin-bottom: var(--space-6); }
.errands__head .eyebrow { margin-bottom: var(--space-5); color: var(--alfi-muted); }
.errands__head .section__lede { margin: 0; }
.scene--browser { display: block; padding: 0; overflow: hidden; box-shadow: 0 18px 40px -24px rgb(55 53 47 / .3); }
.scene--browser .scene__replay { top: 4px; }
.browser__body { display: grid; grid-template-columns: minmax(0, 7fr) minmax(260px, 4fr); }
.browser__agent { display: grid; align-content: start; gap: var(--space-3); padding: var(--space-4) var(--space-5) var(--space-5); border-left: 1px solid var(--alfi-line); background: var(--alfi-surface-soft); }
.browser__page { padding: 0 var(--space-6) var(--space-5); }
.cart li { padding-block: 10px; }
/* Browser chrome: window buttons, a tab, toolbar with address bar and Alfi pinned as an extension.
   Window-button colors are standard desktop chrome, not palette colors. */
.scene--browser .scene__replay { color: var(--alfi-ink); }
.browser__tabs { display: flex; align-items: flex-end; gap: var(--space-2); height: 46px; padding: 0 104px 0 14px; background: var(--alfi-line); }
.browser__lights { display: flex; gap: 7px; align-self: center; margin-right: var(--space-3); }
.browser__lights i { width: 12px; height: 12px; border-radius: 50%; background: #ff5f57; }
.browser__lights i:nth-child(2) { background: #febc2e; }
.browser__lights i:nth-child(3) { background: #28c840; }
.browser__tab { display: inline-flex; align-items: center; gap: var(--space-2); height: 36px; min-width: 0; max-width: 240px; padding: 0 12px; border-radius: 10px 10px 0 0; background: var(--alfi-surface); color: var(--alfi-ink); font-size: .75rem; font-weight: 500; white-space: nowrap; }
.browser__favicon { width: 14px; height: 14px; flex: none; border-radius: 4px; background: var(--alfi-highlight-apricot); }
.browser__tab-close { margin-left: var(--space-4); color: var(--alfi-muted); }
.browser__newtab { align-self: center; padding: 0 6px; color: var(--alfi-muted); font-size: 1.125rem; }
.browser__toolbar { display: flex; align-items: center; gap: var(--space-3); padding: 8px 14px; background: var(--alfi-surface); }
.browser__nav { display: flex; gap: 12px; color: var(--alfi-muted); font-size: .9375rem; }
.browser__url { display: flex; flex: 1; align-items: center; gap: var(--space-2); min-width: 0; height: 32px; padding: 0 14px; border-radius: var(--radius-pill); background: var(--alfi-surface-soft); color: var(--alfi-ink); font-size: .8125rem; white-space: nowrap; overflow: hidden; }
.browser__url svg { flex: none; color: var(--alfi-muted); }
.browser__ext { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 8px; background: var(--alfi-yellow-soft); box-shadow: inset 0 0 0 1px var(--alfi-highlight-yellow); }
.browser__ext img { width: 20px; height: 20px; }
.browser__infobar { display: flex; align-items: center; gap: var(--space-2); padding: 8px 16px; border-block: 1px solid var(--alfi-line); background: var(--alfi-sky-soft); color: var(--alfi-sky-ink); font-size: .75rem; font-weight: 600; }
.browser__infobar i { width: 7px; height: 7px; border-radius: 50%; background: var(--alfi-sky-ink); }
.agent__head { display: flex; align-items: center; gap: var(--space-2); padding-bottom: var(--space-3); border-bottom: 1px solid var(--alfi-line); font-size: var(--type-label); }
.agent__head img { width: 20px; height: 20px; }
.agent__head span { margin-left: auto; color: var(--alfi-muted); font-size: .75rem; }
.store__header { display: flex; align-items: center; gap: var(--space-4); margin-inline: calc(-1 * var(--space-6)); margin-bottom: var(--space-4); padding: 12px var(--space-6); border-bottom: 1px solid var(--alfi-line); }
.store__name { display: flex; align-items: center; gap: var(--space-2); font-weight: 700; letter-spacing: -.02em; white-space: nowrap; }
.store__name img { width: 22px; height: 22px; }
.store__search { flex: 1; min-width: 0; padding: 7px 14px; border: 1px solid var(--alfi-line); border-radius: var(--radius-pill); color: var(--alfi-muted); font-size: var(--type-caption); white-space: nowrap; overflow: hidden; }
.store__cart { position: relative; display: grid; place-items: center; width: 34px; height: 34px; flex: none; color: var(--alfi-ink); }
.store__count { position: absolute; top: -2px; right: -6px; display: grid; }
.store__count > span { grid-area: 1 / 1; display: grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--radius-pill); background: var(--alfi-action); color: var(--alfi-on-action); font-size: .6875rem; font-weight: 700; }
.cart-btn { position: relative; display: grid; margin-left: auto; }
.cart-btn > span { grid-area: 1 / 1; justify-self: end; padding: 5px 12px; border-radius: var(--radius-pill); font-size: .75rem; font-weight: 600; white-space: nowrap; }
.cart-btn__add { border: 1px solid var(--alfi-action); color: var(--alfi-action); visibility: hidden; }
.cart-btn__done { background: var(--alfi-mint-soft); color: var(--alfi-mint-ink); }
.cart-cursor { position: absolute; right: 4px; bottom: -12px; width: 18px; height: 22px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 22'%3E%3Cpath d='M2 1.5v16l4.3-3.9 3 6.6 2.6-1.1-3-6.5H15z' fill='%2337352f' stroke='white' stroke-width='1.4' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat; opacity: 0; pointer-events: none; }
.cart li::before { width: 36px; height: 36px; border: 1px solid var(--alfi-line); border-radius: 10px; background: var(--alfi-surface-soft); }
.cart__foot { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); margin-top: var(--space-4); padding-top: var(--space-4); border-top: 1px solid var(--alfi-line); color: var(--alfi-muted); font-size: var(--type-label); }
.errands__note { margin-top: var(--space-4); }
/* Motion: each scene plays once as it enters view. Finished state is the default,
   so without JavaScript or with reduced motion everything is simply shown.
   Markup timings (--at) are authored at 1×; --scene-pace compresses the whole
   choreography together so typing, replies and landings stay in sync. */
.scene { --scene-pace: .6; }
@media (prefers-reduced-motion: no-preference) {
  .scenes-ready [data-scene]:not([data-scene-play="true"]) :is(.beat, .land, .pop, .drop, .rhythm li, .cart-btn__done, .count) { opacity: 0; }
  .scenes-ready [data-scene]:not([data-scene-play="true"]) .cart-btn__add { visibility: visible; }
  [data-scene-play="true"] :is(.drop, .beat, .land, .pop, .rhythm li, .typing, .typing i, .reminder-state__review, .fake-button--primary, .choice--picked, .cart-btn__add, .cart-btn__done, .cart-cursor, .count) { --start: calc((var(--at, 0ms) + var(--scene-delay, 0ms)) * var(--scene-pace)); }
  [data-scene-play="true"] .drop { animation: scene-drop 420ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .beat { animation: scene-beat 320ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .land { animation: scene-land 760ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .pop { animation: scene-pop 440ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .rhythm li { animation: scene-fill 280ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .typing { display: inline-flex; animation: scene-typing calc(800ms * var(--scene-pace)) linear var(--start) both; }
  [data-scene-play="true"] .typing i { animation: scene-dot calc(400ms * var(--scene-pace)) ease-in-out var(--start) 2 both; }
  [data-scene-play="true"] .typing i:nth-child(2) { animation-delay: calc(var(--start) + 60ms); }
  [data-scene-play="true"] .typing i:nth-child(3) { animation-delay: calc(var(--start) + 120ms); }
  [data-scene-play="true"] .reminder-state__review { animation: scene-review calc(1400ms * var(--scene-pace)) var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .fake-button--primary { animation: scene-press 240ms var(--ease-out) var(--start); }
  [data-scene-play="true"] .choice--picked { animation: scene-pick 240ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .hub__node::after { animation: hub-line 420ms var(--ease-out) calc(var(--start) + 150ms) both; }
  [data-scene-play="true"] .hub__side--in .hub__node::before { animation: hub-flow-in 700ms ease-in-out calc(var(--start) + 600ms) both; }
  [data-scene-play="true"] .hub__side--out .hub__node::before { animation: hub-flow-out 700ms ease-in-out calc(var(--start) + 600ms) both; }
  [data-scene-play="true"] .cart-btn__add { animation: scene-hold-out var(--start) linear both; }
  [data-scene-play="true"] .cart-btn__done { animation: scene-beat 280ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .cart-cursor { animation: scene-cursor 360ms var(--ease-out) calc(var(--start) - 240ms) both; }
  [data-scene-play="true"] .cart__foot .fake-button--primary { animation: none; }
  [data-scene-play="true"] .count { animation: scene-pop 360ms var(--ease-out) var(--start) both; }
  [data-scene-play="true"] .week__day--target { animation: scene-column calc(1400ms * var(--scene-pace)) var(--ease-out) calc((1800ms + var(--scene-delay, 0ms)) * var(--scene-pace)) both; }
}
@keyframes hub-flow-in { 0% { opacity: 0; transform: translateX(0); } 15%, 85% { opacity: 1; } 100% { opacity: 0; transform: translateX(calc(var(--hub-gap) - 9px)); } }
@keyframes hub-flow-out { 0% { opacity: 0; transform: translateX(0); } 15%, 85% { opacity: 1; } 100% { opacity: 0; transform: translateX(calc(9px - var(--hub-gap))); } }
@keyframes hub-line { from { transform: scaleX(0); } to { transform: none; } }
@keyframes scene-hold-out { 0%, 99.9% { visibility: visible; } 100% { visibility: hidden; } }
@keyframes scene-cursor { 0% { opacity: 0; transform: translate(14px, 12px); } 40% { opacity: 1; transform: none; } 62% { transform: scale(.82); } 80% { opacity: 1; transform: none; } 100% { opacity: 0; transform: none; } }
@keyframes scene-drop { 0% { opacity: 0; transform: translateY(-22px) scale(.96); } 70% { opacity: 1; transform: translateY(2px); } 100% { opacity: 1; transform: none; } }
@keyframes scene-beat { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes scene-land { 0% { opacity: 0; transform: translateX(-12px); background-color: var(--case-soft); } 30% { opacity: 1; transform: none; background-color: var(--case-soft); } 100% { opacity: 1; transform: none; background-color: transparent; } }
@keyframes scene-pop { 0% { opacity: 0; transform: translateY(-18px) scale(.9); } 60% { opacity: 1; transform: translateY(2px) scale(1.03); } 100% { opacity: 1; transform: none; } }
@keyframes scene-fill { from { opacity: 1; background-color: var(--alfi-surface); border-color: var(--alfi-line); color: var(--alfi-muted); transform: scale(.85); } to { opacity: 1; transform: none; } }
@keyframes scene-typing { 0% { opacity: 0; } 15%, 85% { opacity: 1; } 100% { opacity: 0; visibility: hidden; } }
@keyframes scene-dot { 0%, 100% { opacity: .35; transform: none; } 50% { opacity: 1; transform: translateY(-3px); } }
@keyframes scene-review { 0% { opacity: 0; visibility: visible; } 15%, 80% { opacity: 1; visibility: visible; } 100% { opacity: 0; visibility: hidden; } }
@keyframes scene-press { 50% { transform: scale(.92); } }
@keyframes scene-pick { from { border-color: var(--alfi-control-line); background-color: var(--alfi-surface); color: var(--alfi-ink); transform: scale(.94); } to { transform: none; } }
@keyframes scene-column { 0%, 100% { background-color: transparent; } 30% { background-color: var(--case-soft); } }
/* The problem, in their words: everyone asks the one who remembers. */
.problem { display: grid; grid-template-columns: 5fr 6fr; align-items: center; gap: var(--space-8); padding-top: var(--space-8); }
.problem__turn { margin-top: var(--space-5); font-size: var(--type-lede); font-weight: 600; }
.ping { display: flex; align-items: flex-start; gap: var(--space-3); max-width: 40ch; }
.ping__who { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 50%; font-size: .8125rem; font-weight: 600; }
.ping__who--sky { background: var(--alfi-sky-soft); color: var(--alfi-sky-ink); }
.ping__who--apricot { background: var(--alfi-apricot-soft); color: var(--alfi-apricot-ink); }
.ping p { padding: 8px 14px; border: 1px solid var(--alfi-line); border-radius: 18px 18px 18px 6px; background: var(--alfi-surface); font-size: var(--type-label); line-height: 1.45; }
.ping strong { display: block; color: var(--alfi-muted); font-size: .75rem; font-weight: 600; }
/* Surfaces: scenes sit on real-looking windows and phones instead of plain cards. */
.scene.scene--bare { padding: 0; border: 0; border-radius: 0; background: transparent; }
.scene.scene--device { justify-items: center; padding-top: 44px; }
.scene.scene--bare > .scene__replay { top: 0; right: 0; }
.connector { display: inline-flex; align-items: center; justify-self: start; gap: 6px; padding: 3px 10px 3px 6px; border: 1px solid var(--alfi-line); border-radius: var(--radius-pill); background: var(--alfi-surface); color: var(--alfi-muted); font-size: .75rem; font-weight: 600; }
.connector img { width: 16px; height: 16px; }
/* The family thread on a phone. */
.device--chat { --device-w: 290px; }
.chatapp { display: grid; grid-template-rows: auto 1fr auto; height: 100%; }
.chatapp__head { display: grid; justify-items: center; gap: 2px; padding: 2px 12px 10px; border-bottom: 1px solid var(--alfi-line); font-size: .75rem; color: var(--alfi-muted); }
.chatapp__head strong { color: var(--alfi-ink); font-size: .875rem; }
.chatapp__faces { display: flex; }
.chatapp__faces i { display: grid; place-items: center; width: 28px; height: 28px; margin-left: -6px; border: 2px solid #fff; border-radius: 50%; font-size: .75rem; font-style: normal; font-weight: 600; }
.chatapp__faces i:first-child { margin-left: 0; }
.chatapp__thread { display: grid; align-content: start; gap: 10px; padding: 14px 12px; background: var(--alfi-surface-soft); }
.chatapp__thread .ping { gap: var(--space-2); }
.chatapp__thread .ping__who { width: 26px; height: 26px; font-size: .6875rem; }
.chatapp__thread .ping p { font-size: .8125rem; }
.chatapp__composer { display: flex; align-items: center; justify-content: space-between; margin: 0 12px 30px; padding: 7px 8px 7px 14px; border: 1px solid var(--alfi-line); border-radius: var(--radius-pill); color: var(--alfi-muted); font-size: .8125rem; }
.chatapp__composer i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--alfi-line); color: #fff; font-style: normal; font-size: .75rem; }
/* Alfi app screens built in HTML, styled after the real app. */
.app { display: grid; align-content: start; gap: var(--space-3); padding: 2px 12px 14px; }
.app__top { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--space-2); }
.app__top > :last-child { justify-self: end; }
.app__btns { display: flex; gap: 6px; }
.app__btns i { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--alfi-line); border-radius: 50%; background: #fff; color: var(--alfi-ink); font-size: .8125rem; font-style: normal; }
.app__title { text-align: center; line-height: 1.25; }
.app__title strong { display: block; font-size: .9375rem; }
.app__title span { color: var(--alfi-muted); font-size: .6875rem; }
.app-list--app li { padding: 8px 2px; font-size: .8125rem; }
.app-list--app li::before { width: 18px; height: 18px; }
.chip { margin-left: auto; padding: 1px 7px; white-space: nowrap; border-radius: 6px; background: var(--alfi-surface-soft); color: var(--alfi-muted); font-size: .625rem; font-weight: 600; }
.app--chat { gap: 10px; padding-top: 4px; }
.app__chathead { display: flex; align-items: center; justify-content: center; gap: 6px; padding-bottom: 8px; border-bottom: 1px solid var(--alfi-line); font-size: .875rem; }
.app__chathead img { width: 22px; height: 22px; }
.device .bubble { max-width: 88%; padding: 8px 12px; font-size: .8125rem; }
.device .bubble--alfi > img { width: 20px; height: 20px; }
.device .app-card { padding: var(--space-3); box-shadow: none; }
.device .app-card__head strong { font-size: .875rem; }
.device .reminder-time, .device .reminder-state__done { font-size: .8125rem; }
.device .choice { min-height: 30px; padding: 4px 12px; font-size: .75rem; }
.device .notice { padding: 10px 12px; }
.device .notice > img { width: 30px; height: 30px; }
.device .notice p:last-child { font-size: .8125rem; }
.device .brief-list span { min-width: 64px; }
.device .typing { height: 34px; }
.device--reminder { --device-w: 290px; --peek-h: 470px; }
.device--brief { --device-w: 316px; }
.device--brief .bubble { max-width: 100%; }
.device--brief .brief-list li { font-size: .75rem; }
.device--brief .brief-list span { min-width: 58px; }
.device--brief .app-list--compact li { padding-block: 3px; }
.ahead__product { padding-top: 44px; }
.scene--duo .device--peek { --peek-h: 400px; margin-top: var(--space-6); }
.scene--duo .window { align-self: start; }
/* Events: Alfi on the web, chat beside the week. */
.window--alfiweb .window__body { display: grid; grid-template-columns: minmax(220px, 3fr) 8fr; gap: 0; padding: 0; }
.alfiweb__chat { display: grid; align-content: start; gap: var(--space-3); padding: var(--space-4); border-right: 1px solid var(--alfi-line); background: var(--alfi-surface-soft); }
.alfiweb__label { color: var(--alfi-muted); font-size: .75rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.alfiweb__cal { display: grid; gap: var(--space-3); padding: var(--space-4); }
.alfiweb__calhead { display: flex; justify-content: space-between; align-items: baseline; font-size: var(--type-label); }
.alfiweb__calhead span { color: var(--alfi-muted); letter-spacing: .2em; }
.alfiweb__cal .week { box-shadow: none; }
.scene--alfiweb .scene__footer { justify-self: end; }
/* Anytime: three small windows. */
.scene--recall { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); padding-top: var(--space-6); }
.recall .window { height: 100%; }
.recall .bubble { max-width: 100%; }
/* How it works: the Alfi app at the center, connected to assistants and the browser. */
.connect { border-top: 1px solid var(--alfi-line); }
.connect__head { max-width: 680px; margin: 0 auto var(--space-7); text-align: center; }
.connect__head .eyebrow { margin-bottom: var(--space-5); color: var(--alfi-muted); }
.scene--hub { --hub-gap: 56px; grid-template-columns: minmax(0, 1fr) 250px minmax(0, 1fr); align-items: center; column-gap: var(--hub-gap); padding: var(--space-7) var(--space-6); background: var(--alfi-surface-soft); }
.hub__side { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-4); }
.hub__side--in { justify-items: end; }
.hub__side--out { justify-items: start; }
.hub__node { position: relative; display: flex; align-items: center; gap: var(--space-3); width: min(100%, 270px); padding: 12px 16px; border: 1px solid var(--alfi-line); border-radius: var(--radius-tile); background: var(--alfi-surface); box-shadow: 0 8px 20px -14px rgb(55 53 47 / .3); }
.hub__node img { width: 28px; height: 28px; flex: none; object-fit: contain; }
.hub__node span { display: grid; color: var(--alfi-muted); font-size: var(--type-caption); line-height: 1.35; }
.hub__node strong { color: var(--alfi-ink); font-size: var(--type-label); font-weight: 600; }
.hub__node::after { content: ""; position: absolute; top: 50%; width: var(--hub-gap); border-top: 2px dashed var(--alfi-highlight-sky); }
.hub__side--in .hub__node::after { left: 100%; transform-origin: left; }
.hub__side--out .hub__node::after { right: 100%; transform-origin: right; }
.hub__center { min-width: 0; text-align: center; }
.hub__center .device { --device-w: 250px; }
.hub__label { display: grid; margin-top: var(--space-4); color: var(--alfi-muted); font-size: var(--type-caption); }
.hub__label strong { color: var(--alfi-ink); font-size: var(--type-label); font-weight: 600; }
.live-sync { display: inline-flex; align-items: center; justify-content: center; gap: 6px; color: var(--alfi-mint-ink); font-weight: 600; }
.live-sync i { width: 8px; height: 8px; border-radius: 50%; background: var(--alfi-success); box-shadow: 0 0 0 3px var(--alfi-mint-soft); }
/* A dot travels each connector once: into the app from assistants, out to the browser and home. */
.hub__node::before { content: ""; position: absolute; top: calc(50% - 4px); z-index: 1; width: 9px; height: 9px; border-radius: 50%; background: var(--alfi-sky-ink); opacity: 0; }
.hub__side--in .hub__node::before { left: 100%; }
.hub__side--out .hub__node::before { right: 100%; }
/* Use it in the chat, it syncs, look in Alfi: three plain steps under the hub. */
.flow-steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); margin: var(--space-7) 0 0; padding: 0; }
.flow-steps li { counter-increment: step; display: grid; align-content: start; gap: var(--space-2); padding-top: var(--space-4); border-top: 1px solid var(--alfi-line); }
.flow-steps li::before { content: "0" counter(step); color: var(--alfi-muted); font-size: .75rem; font-weight: 600; letter-spacing: .06em; }
.flow-steps strong { font-size: var(--type-lede); font-weight: 600; letter-spacing: -.02em; }
.flow-steps li > span:last-child { color: var(--alfi-muted); font-size: var(--type-label); }
.flow-steps__icon { display: flex; gap: 6px; align-items: center; height: 26px; }
.flow-steps__icon img { width: 22px; height: 22px; }
.flow-steps__sync { width: 12px; height: 12px; border-radius: 50%; background: var(--alfi-success); box-shadow: 0 0 0 4px var(--alfi-mint-soft); }
/* A mid-page ask once the available-now story is told. */
.midcta { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: var(--space-4) var(--space-5); padding-block: var(--space-8); border-top: 1px solid var(--alfi-line); }
.midcta__text { font-size: clamp(1.375rem, 2.6vw, 1.75rem); font-weight: 600; letter-spacing: -.025em; }
/* Three honest answers to the usual doubts, right before the signup. */
.faq { max-width: 760px; padding-block: var(--block-space) 0; }
.faq h2 { margin-bottom: var(--space-5); font-size: clamp(1.5rem, 3vw, 2rem); }
.faq details { border-top: 1px solid var(--alfi-line); }
.faq details:last-of-type { border-bottom: 1px solid var(--alfi-line); }
.faq summary { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); min-height: 56px; padding-block: var(--space-3); font-weight: 500; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--alfi-muted); font-size: 1.375rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding-bottom: var(--space-4); color: var(--alfi-muted); }
.signup__row + .choices { margin: var(--space-5) 0 0; }
.join { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); padding-top: var(--block-space); border-top: 1px solid var(--alfi-line); }
.join > * { min-width: 0; }
.join .eyebrow { color: var(--alfi-muted); margin-bottom: var(--space-5); font-size: var(--type-caption); }
.join .signup { margin-top: 0; }
.join__eligibility { margin-top: var(--space-4); }
.footer { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-5); border-top: 1px solid var(--alfi-line); padding-block: var(--space-6); font-size: var(--type-caption); color: var(--alfi-muted); }
.footer .brand { font-size: 20px; }
.footer > a:not(.brand) { margin-left: auto; display: inline-flex; align-items: center; min-height: 44px; }
.footer__links { margin-left: auto; display: flex; flex-wrap: wrap; gap: 0 var(--space-5); }
.footer__links a { display: inline-flex; align-items: center; min-height: 44px; }
@media (max-width: 600px) { .footer__links { margin-left: 0; width: 100%; } }
@media (max-width: 980px) {
  .scene.scene--hub { grid-template-columns: 1fr; row-gap: var(--space-4); padding: 60px var(--space-4) var(--space-5); }
  .hub__center { order: -1; width: min(100%, 250px); justify-self: center; margin-bottom: var(--space-3); }
  .hub__side, .hub__side--in, .hub__side--out { justify-items: stretch; }
  .hub__node { width: 100%; }
  .hub__node::after, .hub__node::before { display: none; }
}
@media (max-width: 900px) {
  .use-case--split { grid-template-columns: 1fr; gap: var(--space-6); }
  .use-case--split .use-case__copy > p:last-child { max-width: 560px; }
  .join { gap: var(--space-6); }
  .join .signup__row { flex-direction: column; }
}
@media (max-width: 700px) {
  .nav { min-height: 76px; }
  .nav__link { display: none; }
  .hero h1 br { display: block; }
  .hero { padding-block: var(--space-7) var(--space-8); }
  .hero__actions { gap: var(--space-3); }
  .workflow__intro { justify-content: center; text-align: center; }
  .demo { grid-template-columns: 1fr; }
  .demo__conversation { padding: var(--space-6); }
  .demo__request { max-width: none; }
  .demo__receipt { margin-top: var(--space-6); }
  .demo__result { border-left: 0; border-top: 1px solid var(--alfi-line); padding: var(--space-5); }
  .demo__controls { padding-inline: var(--space-5); }
  .demo-switcher .pill { padding-inline: 14px; font-size: var(--type-caption); }
  .join { grid-template-columns: 1fr; gap: var(--space-6); }
  .use-case { padding-block: var(--space-8); }
  .use-case__copy > p:last-child { max-width: none; }
  .use-case--wide .use-case__copy { display: block; }
  .use-case-pair, .ahead__body { grid-template-columns: 1fr; gap: var(--space-7); }
  .scene--duo { grid-template-columns: 1fr; }
  .scene--duo .device--peek { margin-top: 0; }
  .window--alfiweb .window__body { grid-template-columns: 1fr; }
  .alfiweb__chat { border-right: 0; border-bottom: 1px solid var(--alfi-line); }
  .scene--recall { grid-template-columns: 1fr; }
  .flow-steps { grid-template-columns: 1fr; gap: var(--space-5); margin-top: var(--space-6); }

  .use-case-pair { padding-block: var(--space-8); }
  .scene { padding: var(--space-4); }
  .scene__replay { top: 8px; right: 4px; }
  .scene--duo { grid-template-columns: 1fr; }
  .scene--duo .scene__footer { text-align: left; }
  .week { grid-template-columns: 1fr; gap: 6px; border: 0; border-radius: 0; overflow: visible; box-shadow: none; }
  .week__day { flex-direction: row; align-items: center; gap: var(--space-4); min-height: 0; padding: 10px 12px; border: 1px solid var(--alfi-line); border-radius: var(--radius-control); }
  .week__day:first-child { border-left: 1px solid var(--alfi-line); }
  .week__day--empty { display: none; }
  .week__label { display: flex; align-items: baseline; gap: 6px; min-width: 64px; }
  .week__label span { display: inline; }
  .week__event { flex: 1; }
  .ahead__head { text-align: left; margin-bottom: var(--space-6); }
  .problem { grid-template-columns: 1fr; gap: var(--space-4); padding-top: var(--space-7); }
  .problem__copy { display: contents; }
  .problem .section__lede { margin-top: 0; }
  .problem > .scene { order: 1; margin-top: var(--space-3); }
  .problem__turn { order: 2; margin-top: var(--space-3); }
  .ahead__product { margin-top: var(--space-2); padding-top: 0; }
  .errands__head { display: block; }
  .errands__head .section__lede { margin-top: var(--space-4); }
  .scene--browser { padding: 0; }
  .browser__body { grid-template-columns: 1fr; }
  .browser__agent { order: -1; border-left: 0; border-bottom: 1px solid var(--alfi-line); padding: var(--space-4); }
  .browser__page { padding: 0 var(--space-4) var(--space-4); }
  .browser__tabs { padding-right: 92px; }
  .browser__lights { margin-right: var(--space-1); }
  .browser__tab-close, .browser__newtab, .browser__nav, .store__search { display: none; }
  .store__header { margin-inline: calc(-1 * var(--space-4)); padding-inline: var(--space-4); justify-content: space-between; }
  .join { padding-top: 0; border-top: 0; gap: var(--space-7); }
}
@media (max-width: 400px) {
  .device--brief { aspect-ratio: auto; }
  .device--brief .device__screen { height: auto; padding-bottom: 24px; }
}
@media (max-width: 360px) {
  .hero__actions { flex-direction: column; }
  .demo__conversation { padding: var(--space-5); }
  .demo-switcher { gap: 6px; }
  .demo-switcher .pill { padding-inline: 8px; gap: 6px; font-size: .75rem; }
}
