:root {
  --paper: #f6f5f1;
  --sheet: #fcfbf8;
  --ink: #16181a;
  --ink-2: #4a4f55;
  --ink-3: #868b90;
  --ink-4: #b9bcbf;
  --hush: rgba(22, 24, 26, 0.09);
  --hush-2: rgba(22, 24, 26, 0.05);
  --hush-3: rgba(22, 24, 26, 0.16);
  --ring: #3d9a7a;
  --ring-halo: rgba(61, 154, 122, 0.28);
  --ring-tint: rgba(61, 154, 122, 0.1);
  --confirm: #c98a2b;
  --confirm-halo: rgba(201, 138, 43, 0.28);
  --confirm-tint: rgba(201, 138, 43, 0.12);
  --confirm-ink: #7a5212;

  /* Production widget (packages/react/src/styles.css, light scheme). */
  --sally-panel: #ffffff;
  --sally-well: #eef1f4;
  --sally-ink: #1a1d23;
  --sally-ink-2: #3d4654;
  --sally-ink-3: #5c6570;
  --sally-faint: #8b949e;
  --sally-hairline: rgba(26, 29, 35, 0.1);
  --sally-hairline-strong: rgba(26, 29, 35, 0.16);
  --sally-mint-ink: #04140f;
  --sally-lift:
    0 0 0 1px rgba(26, 29, 35, 0.06),
    0 1px 2px -1px rgba(26, 29, 35, 0.08),
    0 10px 24px rgba(26, 29, 35, 0.1);

  /* Studio (apps/studio-web/app/globals.css). */
  --studio-canvas: #0c1116;
  --studio-panel: #151c24;
  --studio-raised: #1b242e;
  --studio-ink: #e8eef4;
  --studio-ink-2: #b7c3d0;
  --studio-faint: #5c6b79;
  --studio-guide: #7eb9a4;
  --studio-confirm: #c4a05c;

  --font: "IBM Plex Sans", ui-sans-serif, system-ui, sans-serif;
  --t-caption: 13px;
  --t-body: 16px;
  --t-lead: 20px;
  --t-h3: 16px;
  --t-h2: 31px;
  --t-display: clamp(40px, 5.2vw, 64px);

  --glide: cubic-bezier(0.23, 1, 0.32, 1);
  --measure: 34rem;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { background: var(--paper); scroll-behavior: smooth; }

body {
  font-family: var(--font);
  font-size: var(--t-body);
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 3px;
  border-radius: 4px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 6px;
  text-decoration: none;
  z-index: 10;
}
.skip:focus { top: 16px; }

.wrap {
  width: min(1120px, calc(100% - 48px));
  margin-inline: auto;
}

/* Header */

.top {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 88px;
}

.mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.mark-ring {
  width: 14px;
  height: 14px;
  border: 2px solid var(--ring);
  border-radius: 5px;
}

.top-nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
}
.top-nav a,
.top-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-3);
  text-decoration: none;
  transition: color 160ms var(--glide);
}
.top-nav a:hover { color: var(--ink); }
.top-link { color: var(--ink); padding-right: 0; }
.top-link:hover { color: var(--ink-2); }

/* Hero */

.hero {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 24px;
  align-items: end;
  padding-block: 56px 128px;
}

.hero-copy { grid-column: 1 / span 7; }
.hero-side { grid-column: 8 / span 5; }

.eyebrow {
  margin-bottom: 20px;
  font-size: var(--t-caption);
  font-weight: 500;
  color: var(--ink-3);
}

h1 {
  font-size: var(--t-display);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.lede {
  max-width: var(--measure);
  font-size: 18px;
  line-height: 1.5;
  color: var(--ink-2);
  text-wrap: pretty;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 28px;
}

.cta {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 10px;
  background: var(--ink);
  color: var(--paper);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.005em;
  text-decoration: none;
  transition: background-color 160ms var(--glide), transform 120ms var(--glide);
}
.cta:hover { background: #2a2d30; }
.cta:active { transform: scale(0.97); }

.cta-quiet {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  box-shadow: inset 0 -1px 0 var(--hush-3);
  transition: color 160ms var(--glide), box-shadow 160ms var(--glide);
}
.cta-quiet:hover { color: var(--ink); box-shadow: inset 0 -1px 0 var(--ink); }

/* Stage */

.stage {
  grid-column: 1 / -1;
  margin-top: 64px;
}

.chapters {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.chapter {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 10px;
  align-items: baseline;
  min-height: 64px;
  padding: 12px 14px 16px;
  border: 1px solid var(--hush);
  border-radius: 10px;
  background: transparent;
  color: var(--ink-3);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color 160ms var(--glide), border-color 160ms var(--glide), color 160ms var(--glide);
}
.chapter:hover { color: var(--ink-2); border-color: var(--hush-3); }
.chapter[aria-pressed="true"] {
  background: var(--sheet);
  border-color: var(--hush-3);
  color: var(--ink);
}
.chapter-k {
  grid-row: 1 / span 2;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
}
.chapter-name { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.chapter-sub { grid-column: 2; font-size: var(--t-caption); color: var(--ink-3); }
.chapter-bar {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 8px;
  height: 2px;
  border-radius: 2px;
  background: var(--hush-2);
  overflow: hidden;
}
.chapter-bar i {
  display: block;
  height: 100%;
  background: var(--ring);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 400ms var(--glide);
}
.chapter[aria-pressed="false"] .chapter-bar { opacity: 0; }

/* The mock host app: Ledgerline, an accounts-payable product. */

.app {
  position: relative;
  background: var(--sheet);
  border: 1px solid var(--hush);
  border-radius: 14px;
  overflow: hidden;
  font-size: 13px;
  line-height: 1.4;
  color: var(--ink-2);
  user-select: none;
}

.app-top {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 52px;
  padding: 0 18px;
  border-bottom: 1px solid var(--hush-2);
}
.app-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: 150px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.app-logo {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  background: var(--ink);
  box-shadow: inset 0 -6px 0 #3b4046;
}
.app-search {
  display: inline-flex;
  align-items: center;
  width: min(300px, 34%);
  height: 30px;
  padding: 0 12px;
  border-radius: 8px;
  background: var(--paper);
  border: 1px solid var(--hush-2);
  color: var(--ink-4);
  font-size: 12px;
}
.app-user {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  color: var(--ink);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.2;
}
.app-user small {
  display: block;
  font-size: 11px;
  font-weight: 400;
  color: var(--ink-3);
}
.app-avatar {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--hush-2);
  font-size: 10px;
  font-weight: 600;
  color: var(--ink-2);
}

.app-body {
  display: grid;
  grid-template-columns: 188px 1fr;
  height: 520px;
}

.app-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 10px;
  border-right: 1px solid var(--hush-2);
}
.nav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  border-radius: 6px;
  color: var(--ink-3);
}
.nav-item.is-here {
  color: var(--ink);
  font-weight: 500;
  background: var(--hush-2);
}
.nav-group { color: var(--ink-2); }
.chev {
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 200ms var(--glide);
}
.nav-kids {
  display: none;
  flex-direction: column;
  gap: 2px;
  padding-left: 12px;
}
.app[data-nav-open="true"] .nav-kids {
  display: flex;
  animation: kids-in 240ms var(--glide);
}
.app[data-nav-open="true"] .chev { transform: rotate(45deg); }

@keyframes kids-in {
  from { opacity: 0; transform: translateY(-4px); }
}

.app-main {
  position: relative;
  display: grid;
  padding: 22px 26px;
  min-width: 0;
}

.view {
  grid-area: 1 / 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 240ms var(--glide), visibility 0s linear 240ms;
}
.view.is-on {
  opacity: 1;
  visibility: visible;
  transition: opacity 240ms var(--glide);
}

.view-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 32px;
}
.view-head b {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.muted { font-size: 12px; color: var(--ink-3); }

.tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 14px;
  border: 1px solid var(--hush);
  border-radius: 10px;
}
.tile span, .tile small { font-size: 12px; color: var(--ink-3); }
.tile b {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.table { display: flex; flex-direction: column; }
.tr {
  display: grid;
  grid-template-columns: 1.1fr 1.5fr 1fr 1.5fr;
  gap: 12px;
  align-items: center;
  min-height: 42px;
  padding: 0 6px;
  border-bottom: 1px solid var(--hush-2);
  color: var(--ink);
}
.tr > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tr > span:last-child { display: flex; align-items: center; gap: 8px; }
.th {
  min-height: 32px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.num { font-variant-numeric: tabular-nums; }
.tr .num { text-align: right; justify-self: end; }
.tr-new { display: none; }
.app[data-vendor-added="true"] [data-view-id="vendors"] .tr-new,
.app[data-bill-added="true"] [data-view-id="bills"] .tr-new {
  display: grid;
  animation: row-in 1400ms var(--glide);
}
@keyframes row-in {
  from { background: var(--ring-tint); }
}

.chip {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--hush-2);
  color: var(--ink-2);
  font-size: 11px;
  font-style: normal;
  font-weight: 500;
}
.chip-wait { background: var(--confirm-tint); color: var(--confirm-ink); }
.chip-new { background: var(--ring-tint); color: #26684f; }

.btn {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 14px;
  border-radius: 7px;
  border: 1px solid var(--hush-3);
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  transition: transform 120ms var(--glide);
}
.btn-primary {
  border-color: transparent;
  background: var(--ink);
  color: var(--paper);
}
.btn-off { height: 26px; padding: 0 10px; font-size: 12px; opacity: 0.4; }
.is-press { transform: scale(0.96); }

.form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 380px;
}
.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-size: 12px; font-weight: 500; color: var(--ink-2); }
.label i { font-style: normal; font-weight: 400; color: var(--ink-3); margin-left: 4px; }
.input {
  position: relative;
  display: flex;
  align-items: center;
  height: 36px;
  padding: 0 34px 0 11px;
  border-radius: 7px;
  border: 1px solid var(--hush-3);
  background: var(--paper);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
}
.input:empty::before { content: attr(data-ph); color: var(--ink-4); }
.input-select::after {
  content: "";
  position: absolute;
  right: 13px;
  top: 13px;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid var(--ink-3);
  border-bottom: 1.5px solid var(--ink-3);
  transform: rotate(45deg);
}
.input[data-filled="true"]::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 10px;
  width: 16px;
  height: 16px;
  border: 0;
  border-radius: 50%;
  transform: none;
  background: var(--ring) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.3 2.3 4.7-4.9' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat;
  animation: pop 260ms var(--glide);
}
.input[data-skipped="true"] { color: var(--ink-3); }
.input[data-skipped="true"]:empty::before { content: "Skipped"; color: var(--ink-3); font-style: italic; }
@keyframes pop {
  from { opacity: 0; transform: scale(0.95); }
}

.form-foot { display: flex; gap: 8px; margin-top: 4px; }

/* Highlight ring: packages/web/src/highlight.ts defaults. Amber = waiting on the user. */

.ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  border: 2px solid var(--ring);
  border-radius: 6px;
  box-shadow: 0 0 0 4px var(--ring-halo);
  opacity: 0;
  pointer-events: none;
  z-index: 3;
  transition:
    transform 450ms var(--glide),
    width 450ms var(--glide),
    height 450ms var(--glide),
    opacity 200ms var(--glide),
    border-color 200ms var(--glide),
    box-shadow 200ms var(--glide);
}
.ring.is-on { opacity: 1; }
.ring.is-wait {
  border-color: var(--confirm);
  box-shadow: 0 0 0 4px var(--confirm-halo);
}

/* The user's pointer. */

.cursor {
  position: absolute;
  top: 0;
  left: 0;
  width: 18px;
  height: 18px;
  z-index: 6;
  opacity: 0;
  pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M3 2l11 6.2-4.6 1.1L7.2 14z' fill='%2316181a' stroke='white' stroke-width='1.2' stroke-linejoin='round'/%3E%3C/svg%3E") 0 0 / 18px no-repeat;
  transition: transform 620ms var(--glide), opacity 200ms var(--glide);
}
.cursor.is-on { opacity: 1; }
.cursor::after {
  content: "";
  position: absolute;
  left: -7px;
  top: -7px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--ink);
  opacity: 0;
}
.cursor.is-press::after { animation: tap 420ms var(--glide); }
@keyframes tap {
  from { opacity: 0.5; transform: scale(0.5); }
  to { opacity: 0; transform: scale(1.4); }
}

/* Studio panel: matches the hosted Studio dark tokens. */

.studio {
  color: var(--studio-ink);
  background: var(--studio-panel);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 12px;
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 18px 40px rgba(12, 17, 22, 0.28);
}
.app .studio {
  position: absolute;
  top: 70px;
  right: 18px;
  width: 300px;
  z-index: 4;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 280ms var(--glide), transform 280ms var(--glide);
}
.app[data-studio="true"] .studio { opacity: 1; transform: none; }
.studio-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2px 10px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.studio-tab {
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--studio-raised);
  color: var(--studio-ink-2);
  font-size: 11px;
  font-weight: 500;
}
.studio-kicker {
  padding: 0 2px 8px;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--studio-faint);
}
.studio-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
  border-radius: 8px;
  background: var(--studio-raised);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
.studio-row + .studio-row { margin-top: 6px; }
.studio-row-dim { opacity: 0.55; }
.studio-title { font-weight: 600; font-size: 12.5px; }
.studio-meta { display: flex; align-items: center; gap: 8px; }
.studio-note { color: var(--studio-faint); font-size: 11px; }
.badge {
  display: inline-flex;
  padding: 1px 8px;
  border-radius: 999px;
  border: 1px solid rgba(196, 160, 92, 0.4);
  color: var(--studio-confirm);
  font-size: 10.5px;
  font-style: normal;
  font-weight: 500;
}
.badge-guide { border-color: rgba(126, 185, 164, 0.35); color: var(--studio-guide); }
.badge-live { border-color: rgba(61, 154, 122, 0.55); color: var(--ring); }
.studio-static { max-width: 420px; }

/* Sally widget: mirrors packages/react/src/styles.css + SallyWidget.tsx. */

.sally {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 5;
  width: min(352px, calc(100% - 36px));
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 6px;
  background: var(--sally-panel);
  border: 1px solid var(--sally-hairline);
  border-radius: 999px;
  box-shadow: var(--sally-lift);
  color: var(--sally-ink);
  font-size: 14px;
  line-height: 1.5;
}
.sally[data-open="true"] {
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
}
.sally-head,
.sally-caption,
.sally-source,
.sally-fill { display: none; }
.sally[data-open="true"] .sally-head { display: flex; }
.sally[data-open="true"] .sally-caption:not(:empty) { display: block; }
.sally[data-open="true"] .sally-source:not(:empty) { display: flex; }
.sally[data-open="true"][data-receipt="true"] .sally-fill { display: grid; }

.sally-head {
  align-items: center;
  gap: 8px;
  min-height: 20px;
}
.sally-mark {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 999px;
  background: var(--ring);
}
.sally-brand {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.sally-status {
  margin-right: auto;
  color: var(--sally-ink-3);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.sally[data-routing="true"] .sally-status { color: var(--ring); }
.sally-caption {
  padding: 0 4px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.4;
  text-wrap: pretty;
}
.sally-source {
  margin-top: -4px;
  padding: 0 4px;
  font-size: 12px;
  color: var(--sally-ink-3);
}

.sally-form {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 0 0 8px;
}
.sally[data-open="true"] .sally-form { padding: 0; }
.sally-rest { display: inline-flex; align-items: center; gap: 8px; flex: none; }
.sally[data-open="true"] .sally-rest { display: none; }
.sally-input {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--sally-well);
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
}
.sally[data-open="true"] .sally-input { border-radius: 6px; }
.sally-input:has(> span:empty)::before { content: attr(data-ph); color: var(--sally-faint); }
.sally[data-typing="true"] .sally-input > span::after {
  content: "";
  display: inline-block;
  width: 1px;
  height: 16px;
  margin-left: 1px;
  vertical-align: -3px;
  background: var(--sally-ink);
}

.sally-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  height: 40px;
  min-width: 40px;
  padding: 0 12px;
  border: 1px solid var(--sally-hairline-strong);
  border-radius: 6px;
  background: var(--sally-panel);
  color: var(--sally-ink-2);
  font-size: 13px;
  font-weight: 600;
  transition: transform 120ms var(--glide), box-shadow 200ms var(--glide);
}
.sally-btn-primary {
  background: var(--ring);
  border-color: var(--ring);
  color: var(--sally-mint-ink);
}
.sally-btn-talk { border-radius: 999px; }
.sally-send { display: none; }
.sally[data-send="true"] .sally-send { display: inline-flex; }
.sally-btn-stop,
.sally-skip {
  height: 28px;
  min-width: 44px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 500;
  color: var(--sally-ink-3);
}
.sally-skip {
  display: none;
  border-color: transparent;
  background: transparent;
  color: var(--sally-faint);
}
.sally[data-skip="true"] .sally-skip { display: inline-flex; }
.sally-btn-stop { display: none; }
.sally[data-stop="true"] .sally-btn-stop { display: inline-flex; }
.sally-btn.is-press { transform: scale(0.97); }
.sally-save.is-cue { box-shadow: 0 0 0 4px var(--confirm-halo); border-color: var(--confirm); }

.sally-fill { gap: 8px; padding: 2px 4px 4px; }
.sally-fill-list {
  display: grid;
  gap: 8px;
  padding: 8px 10px;
  list-style: none;
  border-radius: 8px;
  background: var(--sally-well);
}
.sally-fill-list li { display: grid; gap: 2px; animation: pop 260ms var(--glide); }
.sally-fill-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--sally-faint);
}
.sally-fill-value { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.sally-fill-actions { display: flex; justify-content: flex-end; gap: 8px; }
.sally-fill-actions .sally-btn { min-width: 64px; }
.sally-fill-actions .sally-btn-primary { min-width: 88px; }

figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
  font-size: var(--t-caption);
  color: var(--ink-3);
}
.stage-toggle {
  flex: none;
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--ink-3);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}
.stage-toggle:hover { color: var(--ink); }
.no-motion .stage-toggle { display: none; }
figcaption em {
  font-style: normal;
  color: var(--ink-2);
  font-weight: 500;
}

/* Bands */

.band {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 24px;
  row-gap: 32px;
  padding-block: 96px;
  border-top: 1px solid var(--hush);
}

.col-head {
  grid-column: 1 / span 5;
  font-size: var(--t-h2);
  font-weight: 500;
  line-height: 1.16;
  letter-spacing: -0.028em;
  text-wrap: balance;
  max-width: 14em;
}

.col-body {
  grid-column: 7 / span 6;
  color: var(--ink-2);
}
.col-body > * + * { margin-top: 20px; }

.pull {
  font-size: var(--t-lead);
  line-height: 1.45;
  color: var(--ink);
  text-wrap: pretty;
}
.pull em {
  font-style: normal;
  box-shadow: inset 0 -2px 0 var(--ring);
}
.col-body > .pull:not(:first-child) { margin-top: 36px; }

.costs > div,
.teams li {
  padding-block: 16px;
  border-bottom: 1px solid var(--hush-2);
}
.costs > div:first-child,
.teams li:first-child { padding-top: 0; }
.costs dt,
.teams h3 {
  font-size: var(--t-h3);
  font-weight: 600;
  color: var(--ink);
}
.costs dd,
.teams p { margin-top: 4px; text-wrap: pretty; }

.teams { list-style: none; }
.teams h3 { font-size: 18px; letter-spacing: -0.01em; }
.teams .team {
  display: block;
  margin-bottom: 2px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.versus {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.versus th,
.versus td {
  padding: 12px 12px 12px 0;
  border-bottom: 1px solid var(--hush-2);
  text-align: left;
  vertical-align: top;
  text-wrap: pretty;
}
.versus thead th {
  padding-top: 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.versus thead th:last-child { color: #26684f; }
.versus tbody th { width: 7.5rem; font-weight: 500; color: var(--ink-3); }
.versus td:first-of-type { color: var(--ink-3); }
.versus td:last-child { color: var(--ink); font-weight: 500; }
.col-body > .studio-static { margin-top: 32px; }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px 32px;
}
.col-body.grid-2 > * + * { margin-top: 0; }
.grid-2 dt {
  font-weight: 600;
  color: var(--ink);
}
.grid-2 dd { margin-top: 6px; text-wrap: pretty; }

/* The math: one rate times one count per line. */

.rates {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.col-body > .rates { margin-top: 28px; }
.rate {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
  border: 1px solid var(--hush);
  border-radius: 10px;
  background: var(--sheet);
  font-variant-numeric: tabular-nums;
}
.rate-head {
  color: var(--ink);
  line-height: 1.4;
  text-wrap: pretty;
}
.rate-head b {
  display: block;
  margin-bottom: 4px;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.025em;
}
.calc {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 15px;
  color: var(--ink-2);
}
.calc .eq {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid var(--ink);
  color: var(--ink);
  font-weight: 600;
}
.rate-note {
  margin-top: auto;
  font-size: var(--t-caption);
  color: var(--ink-3);
  text-wrap: pretty;
}
.sum {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
  padding-block: 14px;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  color: var(--ink);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.col-body > .sum { margin-top: 24px; }
.sum b {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: #26684f;
  white-space: nowrap;
}
.rate-upside {
  border-style: dashed;
  border-color: var(--ink-4);
  background: none;
}
.col-body > .rate-upside { margin-top: 24px; }
.rate-label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.rate-upside .rate-head b { color: var(--ink-2); }

.fine {
  font-size: 14px;
  color: var(--ink-3);
  text-wrap: pretty;
}
.fine a { color: var(--ink-2); }
.col-body > .fine { margin-top: 28px; }

.stills {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  list-style: none;
}
.stills img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  outline: 1px solid rgba(0, 0, 0, 0.1);
  outline-offset: -1px;
  background: var(--sheet);
}
.stills span {
  display: block;
  margin-top: 10px;
  font-size: var(--t-caption);
  color: var(--ink-3);
}

.steps {
  list-style: none;
  counter-reset: step;
}
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 3rem 1fr;
  column-gap: 8px;
  padding-block: 20px;
  border-bottom: 1px solid var(--hush-2);
}
.steps li:first-child { padding-top: 0; }
.steps li::before {
  content: counter(step, decimal-leading-zero);
  grid-row: 1 / span 2;
  font-size: var(--t-caption);
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
  padding-top: 2px;
}
.steps h3 {
  font-size: var(--t-h3);
  font-weight: 600;
  color: var(--ink);
}
.steps p { margin-top: 4px; }

/* Close */

.close {
  padding-block: 160px 128px;
  border-top: 1px solid var(--hush);
  text-align: center;
}
.close h2 {
  font-size: clamp(32px, 4.4vw, 48px);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.close .lede { margin: 20px auto 40px; }

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-block: 32px 48px;
  border-top: 1px solid var(--hush-2);
  font-size: var(--t-caption);
  color: var(--ink-3);
}
.foot a { text-decoration: none; color: var(--ink-2); }
.foot a:hover { color: var(--ink); }

/* Reveal */

.js .reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 600ms var(--glide), transform 600ms var(--glide);
}
.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* Narrow */

@media (max-width: 1024px) {
  .app-body { grid-template-columns: 160px 1fr; }
  .app-search { display: none; }
}

@media (max-width: 900px) {
  .top-nav { display: none; }
  .top-link { margin-left: auto; }
  .hero { padding-block: 40px 96px; row-gap: 24px; }
  .hero-copy, .hero-side { grid-column: 1 / -1; }
  .stage { margin-top: 40px; }
  .chapter-sub { display: none; }
  .col-head, .col-body { grid-column: 1 / -1; }
  .band { padding-block: 72px; }
  .tiles .tile:nth-child(3) { display: none; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .app .studio { width: 272px; }
}

@media (max-width: 640px) {
  .wrap { width: calc(100% - 32px); }
  .chapters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chapter { min-height: 52px; }
  .app { font-size: 12px; }
  .app-top { height: 44px; padding: 0 12px; }
  .app-brand { width: auto; }
  .app-user > span:last-child { display: none; }
  .app-body { grid-template-columns: 104px 1fr; height: 380px; }
  .app-nav { padding: 10px 6px; }
  .nav-item { padding: 6px 7px; }
  .nav-kids { padding-left: 6px; }
  .app-main { padding: 14px; }
  .tiles { display: none; }
  .tr { grid-template-columns: 1fr auto; }
  .tr > span:nth-child(2),
  .tr > span:nth-child(3) { display: none; }
  .btn-off { display: none; }
  .form { gap: 10px; max-width: none; }
  .input { height: 32px; }
  .app .studio { top: 54px; right: 10px; left: 10px; width: auto; }
  .sally {
    position: relative;
    right: auto;
    bottom: auto;
    width: auto;
    margin: 0 10px 10px;
  }
  .stills { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .rates { grid-template-columns: 1fr; }
  .versus tbody th { width: 5.5rem; }
  .close { padding-block: 112px 96px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { transform: none; transition: opacity 300ms linear; }
  .view, .ring, .cursor, .chapter-bar i, .app .studio, .btn, .sally-btn { transition: none; }
  .app[data-nav-open="true"] .nav-kids,
  .tr-new, .input::after, .sally-fill-list li { animation: none !important; }
  .cta:active { transform: none; }
}
