/*
  Living Inheritance design system
  Brand Identity Guide v1.0 (July 2026)
  Brand: Living Inheritance | Descriptor: The Family Wisdom Archive
  Legal: Mountains of Harmony Publishing
*/
:root {
  /* Brand color system — paper, forest, time */
  --green: #123e32;           /* Inheritance Green */
  --green-deep: #0c2a22;
  --green-soft: rgba(18, 62, 50, 0.08);
  --bg: #f4f0e7;              /* Archive Ivory */
  --paper: #faf8f3;
  --ink: #1b1d19;             /* Original Ink */
  --muted: #5c635c;
  --line: #e0d9cc;
  --brass: #a38355;           /* Aged Brass — accent only */
  --sage: #8da69a;            /* Quiet Sage */
  --clay: #8a5c48;            /* Family Clay — warmth / emphasis */
  --accent: var(--green);
  --shadow: 0 18px 40px rgba(27, 29, 25, 0.06);
  --shadow-tint: 0 1px 0 rgba(255, 255, 255, 0.55) inset;
  --radius: 4px;
  --radius-sm: 2px;
  --radius-pill: 999px;
  /* Typography: editorial serif + humanist sans (guide open alternatives) */
  --serif: "Source Serif 4", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: Inter, "Avenir Next", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --max: 1180px;
  --max-wide: 1280px;
  --max-editorial: 1320px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --logo-min-width: 180px;
}

/*
  Customer product (app + ceremony + marketing/projects) = light archival.
  Only Intelligence Studio follows system dark.
*/
@media (prefers-color-scheme: dark) {
  body.studio-mode {
    --bg: #121614;
    --paper: #1a1f1c;
    --ink: #eef1ee;
    --muted: #9aa39c;
    --line: #2c3430;
    --green: #5faf93;
    --green-deep: #7bc4a8;
    --green-soft: rgba(95, 175, 147, 0.12);
    --clay: #c4a090;
    --shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
    --shadow-tint: 0 1px 0 rgba(255, 255, 255, 0.04) inset;
  }
}

/* Force light archival tokens: public site, project onboarding, ceremony, customer app */
body.marketing-mode,
body.ceremony-mode,
body.app-mode:not(.studio-mode) {
  --bg: #f4f0e7;
  --paper: #faf8f3;
  --ink: #1b1d19;
  --muted: #5c635c;
  --line: #e0d9cc;
  --green: #123e32;
  --green-deep: #0c2a22;
  --green-soft: rgba(18, 62, 50, 0.08);
  --sage: #8da69a;
  --brass: #a38355;
  --clay: #8a5c48;
  color-scheme: light;
  background: var(--bg);
  color: var(--ink);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: var(--sans);
  line-height: 1.55;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--green); }
a:hover { color: var(--green-deep); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.shell { min-height: 100vh; display: flex; flex-direction: column; }

/* Chrome — height cap ≤80px, single line desktop */
.chrome {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  min-height: 64px;
  max-height: 80px;
  padding: 0.65rem 1.5rem;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
}
.chrome-left, .chrome-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}
/* Brand lockup — Inheritance Thread + wordmark + descriptor */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--green);
  text-decoration: none;
  white-space: nowrap;
  line-height: 1.1;
  padding: 0.2rem 0;
  min-width: min(var(--logo-min-width), 42vw);
}
.logo-mark {
  display: block;
  width: 1.35rem;
  height: 2rem;
  flex-shrink: 0;
  color: inherit;
}
.logo-mark img,
.logo-mark svg {
  display: block;
  width: 100%;
  height: 100%;
}
.logo-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.12rem;
  min-width: 0;
}
.logo-name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--green);
}
.logo-descriptor {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
}
.logo:hover { text-decoration: none; opacity: 0.9; }
/* App: wordmark only (omit descriptor when brand is known) */
body.app-mode .logo-descriptor,
body.studio-mode .logo-descriptor {
  display: none;
}
body.app-mode .logo-name {
  text-transform: none;
  letter-spacing: -0.02em;
  font-size: 1rem;
  font-weight: 600;
}
.foot-descriptor {
  margin: 0.2rem 0 0.55rem;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--sage);
}
.foot-legal {
  margin: 0.75rem 0 0;
  font-size: 0.8rem;
}

.primary-nav {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.1rem;
  overflow: hidden;
}
.primary-nav a {
  font-family: var(--sans);
  font-size: 0.84rem;
  color: var(--muted);
  text-decoration: none;
  padding: 0.4rem 0.65rem;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}
.primary-nav a:hover,
.primary-nav a.active {
  color: var(--green);
  background: var(--green-soft);
}

body.marketing-mode #apiStatus,
body.marketing-mode #userPill { display: none; }
body.app-mode:not(.studio-mode) #apiStatus { display: none; }

.utility-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.util-link {
  font-family: var(--sans);
  font-size: 0.84rem;
  color: var(--muted);
  text-decoration: none;
}
.util-link:hover,
.util-link.active { color: var(--green); }

.icon-btn {
  font-family: var(--sans);
  font-size: 0.78rem;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 8px;
  padding: 0.4rem 0.55rem;
  cursor: pointer;
  color: var(--ink);
}

.pill {
  font-family: var(--sans);
  font-size: 0.72rem;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
}
.pill.ok {
  color: var(--green);
  border-color: color-mix(in srgb, var(--green) 30%, transparent);
  background: var(--green-soft);
}

.context-bar {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0.5rem auto 0;
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--muted);
}
.breadcrumb {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}
.breadcrumb a { color: var(--green); text-decoration: none; }

.main {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: 0.5rem 0 3rem;
  flex: 1;
}
/* Marketing: full-bleed chrome bar, constrained inner content */
body.marketing-mode {
  background:
    radial-gradient(ellipse 120% 80% at 50% -10%, rgba(250, 248, 243, 0.9), transparent 55%),
    var(--bg);
}
body.marketing-mode::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
body.marketing-mode .main {
  width: min(var(--max-editorial), calc(100% - 6rem));
  max-width: 1320px;
  padding: 0.25rem 0 5.5rem;
}
body.marketing-mode .chrome {
  width: 100%;
  max-width: none;
  margin: 0;
  padding-left: max(2rem, calc((100% - 1320px) / 2 + 0.5rem));
  padding-right: max(2rem, calc((100% - 1320px) / 2 + 0.5rem));
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-radius: 0;
}
body.marketing-mode .primary-nav a {
  border-radius: 0;
  padding: 0.35rem 0.55rem;
  letter-spacing: 0.01em;
}
body.marketing-mode .primary-nav a:hover,
body.marketing-mode .primary-nav a.active {
  background: transparent;
  color: var(--green);
  box-shadow: inset 0 -2px 0 var(--green);
}
body.marketing-mode .context-bar { display: none; }
body.marketing-mode .site-footer {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 3rem max(2rem, calc((100% - 1320px) / 2 + 0.5rem)) 2rem;
  background: var(--green); /* Inheritance Green */
  border-top: 0;
  color: #e8ebe6;
}
body.marketing-mode .site-footer .foot-brand strong,
body.marketing-mode .site-footer .foot-col a {
  color: #f4f0e7; /* Archive Ivory on green */
}
body.marketing-mode .site-footer .foot-brand p,
body.marketing-mode .site-footer .foot-descriptor,
body.marketing-mode .site-footer .foot-col h4,
body.marketing-mode .site-footer .foot-meta,
body.marketing-mode .site-footer .foot-meta a {
  color: var(--sage);
}
body.marketing-mode .site-footer .foot-brand strong {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 1.05rem;
}
body.marketing-mode .site-footer .foot-col a:hover {
  color: #f4f0e7;
}
body.marketing-mode .site-footer .foot-meta {
  border-top-color: rgba(243, 240, 232, 0.12);
}
body.marketing-mode .site-footer .foot-brand,
body.marketing-mode .site-footer .foot-cols,
body.marketing-mode .site-footer .foot-meta {
  max-width: 1320px;
}
@media (max-width: 900px) {
  body.marketing-mode .main {
    width: min(100%, calc(100% - 2rem));
  }
  body.marketing-mode .chrome,
  body.marketing-mode .site-footer {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* Marketing pages */
.announce {
  font-family: var(--sans);
  font-size: 0.86rem;
  text-align: left;
  padding: 0.7rem 0;
  margin: 0.35rem 0 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  align-items: center;
}
.announce-sep { opacity: 0.5; }

/* Conversion homepage product demo (not landscape hero) */
.product-demo {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem 1.15rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.demo-photo {
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: var(--green-soft);
}
.demo-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%; /* keep faces and photo in frame */
  display: block;
}
.demo-audio {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.demo-audio.compact { margin: 0.35rem 0 0.75rem; }
.demo-audio strong { display: block; font-size: 0.95rem; }
.demo-play {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 0;
  background: var(--green);
  color: #fff;
  font-size: 0.85rem;
  cursor: pointer;
  flex-shrink: 0;
}
.demo-play:hover { background: var(--green-deep); }
.demo-wave {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 1.5rem;
  opacity: 0.55;
}
.demo-wave span {
  flex: 1;
  background: var(--green);
  border-radius: 2px;
  min-height: 20%;
  animation: wavePulse 1.4s ease-in-out infinite;
}
.demo-wave span:nth-child(1) { height: 35%; animation-delay: 0s; }
.demo-wave span:nth-child(2) { height: 70%; animation-delay: 0.1s; }
.demo-wave span:nth-child(3) { height: 45%; animation-delay: 0.2s; }
.demo-wave span:nth-child(4) { height: 90%; animation-delay: 0.15s; }
.demo-wave span:nth-child(5) { height: 55%; animation-delay: 0.05s; }
.demo-wave span:nth-child(6) { height: 75%; animation-delay: 0.25s; }
.demo-wave span:nth-child(7) { height: 40%; animation-delay: 0.12s; }
@keyframes wavePulse {
  0%, 100% { opacity: 0.45; transform: scaleY(0.85); }
  50% { opacity: 1; transform: scaleY(1); }
}
@media (prefers-reduced-motion: reduce) {
  .demo-wave span { animation: none; }
}
.demo-place { margin: 0; font-size: 0.88rem; color: var(--muted); }
.demo-wisdom {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.15rem;
  line-height: 1.4;
  color: var(--ink);
  border-left: 2px solid var(--green);
  padding-left: 0.85rem;
}

.trust-strip {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0.85rem 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}
.trust-strip li::before {
  content: "";
  display: inline-block;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--green);
  margin-right: 0.45rem;
  vertical-align: 0.15rem;
}

.loss-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1.25rem;
}
.loss-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.9rem 1rem;
  background: var(--paper);
}
.loss-card h3 {
  margin: 0 0 0.35rem;
  font-size: 0.98rem;
}
.loss-card p { margin: 0; color: var(--muted); font-size: 0.9rem; line-height: 1.4; }
@media (max-width: 800px) {
  .loss-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .loss-grid { grid-template-columns: 1fr; }
}

.transform-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1rem;
}
.transform-col {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
  background: var(--paper);
}
.transform-col.highlight {
  border-color: var(--green);
  box-shadow: var(--shadow);
}
.transform-col .q {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.05rem;
}
.check-list.tight { margin: 0.35rem 0 0; }
@media (max-width: 800px) {
  .transform-grid { grid-template-columns: 1fr; }
}

.ease-grid {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 1rem;
}
.ease-grid li {
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  font-size: 0.95rem;
}
@media (max-width: 600px) {
  .ease-grid { grid-template-columns: 1fr; }
}

.four-steps {
  list-style: none;
  margin: 1.25rem 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}
.four-steps li {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  background: var(--paper);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.four-steps .step-n {
  display: inline-flex;
  width: 1.75rem;
  height: 1.75rem;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green-deep);
  font-weight: 600;
  font-size: 0.85rem;
}
.four-steps strong { display: block; font-size: 1.05rem; margin-bottom: 0.25rem; }
.four-steps p { margin: 0; color: var(--muted); font-size: 0.9rem; line-height: 1.4; }
.ui-chip {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--green-deep);
}
@media (max-width: 900px) {
  .four-steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .four-steps { grid-template-columns: 1fr; }
}

.flagship-band .flagship-list {
  columns: 2;
  gap: 1.5rem;
  margin: 1rem 0 1.5rem;
  padding-left: 1.1rem;
  color: var(--muted);
}
.flagship-list li { margin: 0.3rem 0; break-inside: avoid; }
.founding-card {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 1.25rem;
  border: 1px solid var(--green);
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem;
  background: var(--paper);
}
.price-display {
  font-size: 2rem;
  font-weight: 600;
  margin: 0.25rem 0;
  color: var(--green-deep);
}
.founding-actions {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  justify-content: center;
}
@media (max-width: 800px) {
  .flagship-band .flagship-list { columns: 1; }
  .founding-card { grid-template-columns: 1fr; }
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
  margin: 1rem 0;
}
.gallery-tile {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  background: var(--paper);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-height: 5.5rem;
}
.gallery-tile span { color: var(--muted); font-size: 0.88rem; line-height: 1.35; }
.gallery-photo {
  margin: 1rem 0 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  max-height: 280px;
}
.gallery-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}

.objection-list { display: flex; flex-direction: column; gap: 0.5rem; }
.objection {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  background: var(--paper);
}
.objection summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
.objection summary::-webkit-details-marker { display: none; }
.objection p { margin: 0.55rem 0 0; color: var(--muted); line-height: 1.45; }

.proof-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin: 1rem 0;
}
@media (max-width: 800px) {
  .proof-grid { grid-template-columns: 1fr; }
}

.founder-band p { max-width: 62ch; line-height: 1.55; color: var(--muted); }
.founder-band p:first-of-type { color: var(--ink); }

.path-quiz {
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem;
  background: var(--paper);
}
.quiz-q {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0.35rem 0 0.85rem;
}
.quiz-opts {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.quiz-opts button {
  text-align: left;
  font: inherit;
  padding: 0.75rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  cursor: pointer;
  color: var(--ink);
}
.quiz-opts button:hover {
  border-color: var(--green);
  background: var(--green-soft);
}
.quiz-result h3 { margin: 0.35rem 0 0.5rem; font-size: 1.35rem; }

.hero {
  padding: 1.25rem 0 1.75rem;
  max-width: 40rem;
}
.hero.compact { padding-top: 1rem; }

/* Asymmetric split hero (marketing home) */
.hero-split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  min-height: min(70dvh, 620px);
  padding: 0.75rem 0 2rem;
  max-width: none;
}
.hero-split.hero-product {
  align-items: stretch;
}
.hero-split .hero-copy {
  max-width: 36rem;
  padding-top: 0.25rem;
}
.hero-split h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.85rem, 3.6vw, 2.75rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  font-weight: 600;
  max-width: 18ch;
}
.hero-split .lede {
  margin: 0 0 0.85rem;
  font-size: 1.08rem;
  line-height: 1.5;
  color: var(--muted);
  max-width: 40ch;
}
.brand-line,
.hero-split .brand-line {
  margin: 0 0 1.25rem;
  font-family: var(--serif);
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.4;
  color: var(--green-deep);
  max-width: 36ch;
}
.hero.compact .brand-line {
  max-width: 42ch;
  margin-top: 0.5rem;
}
.hero-split .hero-reassure {
  margin: 0.85rem 0 0;
  font-size: 0.9rem;
}
.hero-visual {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 5;
  max-height: 560px;
  background: var(--paper);
}
.hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
@media (max-width: 860px) {
  .hero-split {
    grid-template-columns: 1fr;
    min-height: 0;
    gap: 1.5rem;
    padding: 0.75rem 0 2rem;
  }
  .hero-split h1 { max-width: none; font-size: clamp(1.9rem, 7vw, 2.4rem); }
  .hero-visual { aspect-ratio: 16 / 10; max-height: 320px; }
}

.eyebrow {
  margin: 0 0 0.65rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--green);
  font-weight: 500;
}
.hero h1, .page h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(2rem, 4.5vw, 2.85rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  font-weight: 600;
}
.lede {
  margin: 0 0 1.1rem;
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 65ch;
}
.soft {
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--muted);
}
.caption {
  margin-top: 1.25rem;
  font-style: normal;
  color: var(--muted);
  font-size: 0.95rem;
}
.lead-line {
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  color: var(--ink);
  max-width: 28ch;
}

.block {
  margin: 3.5rem 0;
  max-width: 44rem;
}
.block.wide { max-width: none; }
.block.band {
  max-width: none;
  padding: 2rem 1.75rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: none;
}
.block h2 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.45rem, 2.6vw, 1.85rem);
  letter-spacing: -0.025em;
  line-height: 1.2;
  font-weight: 600;
}
.block p { margin: 0 0 0.85rem; color: var(--ink); max-width: 65ch; }
.block.final-cta {
  text-align: left;
  padding: 2.5rem 0 0.5rem;
  border-top: 1px solid var(--line);
  max-width: 36rem;
  margin-top: 4rem;
}

/* Problem editorial strip */
.problem-band {
  max-width: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
  margin: 1rem 0 3.5rem;
  padding: 2rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.problem-band h2 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2.15rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
  max-width: 16ch;
}
.problem-band .problem-body p {
  color: var(--muted);
  margin: 0 0 0.85rem;
  max-width: 52ch;
}
.problem-band .problem-body p:last-of-type { margin-bottom: 0.75rem; color: var(--ink); }
.problem-band .campaign-line {
  margin: 0.5rem 0 1rem;
  font-family: var(--serif);
  font-size: 1.15rem;
  font-style: italic;
  color: var(--green-deep);
  max-width: 28ch;
}
@media (max-width: 768px) {
  .problem-band { grid-template-columns: 1fr; gap: 1rem; }
  .problem-band h2 { max-width: none; }
}

/* Product flow: conversation → archive → expressions */
.product-flow {
  list-style: none;
  margin: 1.5rem 0 1.25rem;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.65rem;
}
.product-flow li {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.9rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  position: relative;
}
.product-flow .flow-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green-deep);
  font-size: 0.75rem;
  font-weight: 600;
}
.product-flow strong {
  font-size: 0.92rem;
  line-height: 1.25;
  color: var(--ink);
}
.product-flow span:last-child {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.35;
}
@media (max-width: 900px) {
  .product-flow { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .product-flow { grid-template-columns: 1fr; }
}

.distinction-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  margin-top: 1.25rem;
}
.distinction-tile h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}
.distinction-tile p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}
.lede-soft {
  color: var(--muted);
  max-width: 58ch;
  line-height: 1.55;
}
@media (max-width: 800px) {
  .distinction-grid { grid-template-columns: 1fr; }
}

.foot-descriptor {
  margin: 0.15rem 0 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--green-deep);
}

/* Multi-day chapters (Zero-to-One blueprint §7.3) */
.chapter-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.75rem;
}
.chapter-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-top: 1px solid var(--line);
}
.chapter-row:first-child { border-top: none; padding-top: 0; }
.review-card .wisdom-preview {
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.45;
  margin: 0.5rem 0;
}

/* Story Home (Master Architecture §6.2) */
.story-home .continue-card {
  border: 1px solid var(--green);
  box-shadow: var(--shadow);
}
.story-home .continue-card .theme-line {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-style: italic;
  line-height: 1.4;
  margin: 0.35rem 0 0.85rem;
  color: var(--ink);
  max-width: 40ch;
}
.story-home .home-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1rem;
}
.story-home .home-three-col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}
.story-home .quiet-card h2 {
  font-size: 1.1rem;
  margin: 0.25rem 0 0.4rem;
}
@media (max-width: 800px) {
  .story-home .home-two-col,
  .story-home .home-three-col {
    grid-template-columns: 1fr;
  }
}

/* Authenticated header: Continue your story */
.app-continue-cta {
  margin-left: 0.5rem;
  white-space: nowrap;
}
@media (max-width: 900px) {
  .app-continue-cta { display: none; }
}

/* Mobile bottom nav: Home | Archive | Talk | Create | Family */
.app-mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 40;
  background: var(--paper);
  border-top: 1px solid var(--line);
  padding: 0.35rem 0.4rem calc(0.35rem + env(safe-area-inset-bottom));
  justify-content: space-around;
  align-items: flex-end;
  gap: 0.15rem;
}
.mobile-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.25rem;
  font-size: 0.72rem;
  color: var(--muted);
  text-decoration: none;
  border-radius: var(--radius-sm);
  min-height: 2.75rem;
}
.mobile-nav-item.active {
  color: var(--green-deep);
  font-weight: 600;
}
.mobile-nav-item.is-primary {
  transform: translateY(-0.45rem);
  background: var(--green);
  color: #fff;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.8rem;
  min-width: 3.6rem;
  box-shadow: var(--shadow);
}
.mobile-nav-item.is-primary.active {
  color: #fff;
}
body.has-mobile-app-nav .main {
  padding-bottom: 5rem;
}
@media (max-width: 768px) {
  body.has-mobile-app-nav .app-mobile-nav {
    display: flex;
  }
  body.app-mode .primary-nav .app-continue-cta {
    display: none;
  }
}

/* Preserve bento — mixed cells, not 4 equal cards */
.preserve-bento {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 0.85rem;
  max-width: none;
  margin-top: 1.25rem;
}
.preserve-bento .bento-visual {
  grid-row: 1 / span 2;
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  min-height: 280px;
  background: var(--paper);
}
.preserve-bento .bento-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.preserve-bento .bento-cell {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem 1.25rem;
}
.preserve-bento .bento-cell.tint {
  background: var(--green);
  border-color: var(--green);
  color: #f4f7f5;
}
.preserve-bento .bento-cell.tint h3 { color: #f4f7f5; }
.preserve-bento .bento-cell.tint p { color: rgba(244, 247, 245, 0.85); }
.preserve-bento h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.preserve-bento p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  max-width: none;
}
@media (max-width: 900px) {
  .preserve-bento {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  .preserve-bento .bento-visual {
    grid-row: auto;
    grid-column: 1 / -1;
    min-height: 200px;
    aspect-ratio: 16 / 9;
  }
}
@media (max-width: 560px) {
  .preserve-bento { grid-template-columns: 1fr; }
}

/* Journey steps — vertical, not card row */
.journey {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
  max-width: 40rem;
  display: grid;
  gap: 0;
}
.journey li {
  display: grid;
  grid-template-columns: 2.5rem 1fr;
  gap: 0.85rem;
  padding: 1.1rem 0;
  border-bottom: 1px solid var(--line);
}
.journey li:last-child { border-bottom: 0; }
.journey .j-num {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--green);
  padding-top: 0.2rem;
}
.journey strong {
  display: block;
  color: var(--ink);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: -0.015em;
  margin-bottom: 0.25rem;
}
.journey span {
  display: block;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* Method quote panel */
.method-panel {
  max-width: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 2rem;
  align-items: center;
  padding: 2.25rem 0;
}
.method-panel blockquote {
  margin: 0;
  padding: 1.5rem 1.5rem 1.5rem 1.35rem;
  border-left: 2px solid var(--green);
  background: var(--green-soft);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: normal;
  font-size: 1.15rem;
  line-height: 1.45;
  letter-spacing: -0.015em;
  color: var(--ink);
}
@media (max-width: 768px) {
  .method-panel { grid-template-columns: 1fr; gap: 1.25rem; }
}

/* Split media section (archive) */
.split-media {
  max-width: none;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1.5rem, 4vw, 2.75rem);
  align-items: center;
}
.split-media figure {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  aspect-ratio: 4 / 3;
  background: var(--paper);
}
.split-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.split-media .check-list { max-width: 36rem; }
@media (max-width: 768px) {
  .split-media { grid-template-columns: 1fr; }
  .split-media figure { aspect-ratio: 16 / 10; }
}

/* Audience — asymmetric duo + full width third */
.audience-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 0.85rem;
  max-width: none;
  margin-top: 1.1rem;
}
.audience-grid .tile:last-child {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
}
@media (max-width: 700px) {
  .audience-grid { grid-template-columns: 1fr; }
  .audience-grid .tile:last-child {
    grid-column: auto;
    grid-template-columns: 1fr;
  }
}

/* Trust row — sparse, not card grid */
.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.65rem;
  margin: 1rem 0 1.25rem;
  padding: 0;
  list-style: none;
  max-width: none;
}
.trust-row li {
  font-family: var(--sans);
  font-size: 0.84rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  color: var(--muted);
  background: var(--paper);
}

/* Reveal on load (MOTION 4) */
@media (prefers-reduced-motion: no-preference) {
  .hero-split .hero-copy,
  .hero-split .hero-visual {
    animation: rise-in 0.7s var(--ease) both;
  }
  .hero-split .hero-visual { animation-delay: 0.08s; }
  @keyframes rise-in {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
  }
}

.grid-2, .grid-3, .grid-4 {
  display: grid;
  gap: 0.9rem;
  max-width: none;
}
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
  .primary-nav { display: none; }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4, .price-grid, .bench-grid { grid-template-columns: 1fr; }
}

.tile, .card, .price-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem;
  box-shadow: none;
}
.tile h3, .price-card h2 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
}
.tile p, .price-card p { margin: 0 0 0.65rem; color: var(--muted); font-size: 0.98rem; }

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin: 0.85rem 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.68rem 1.15rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  text-decoration: none !important;
  cursor: pointer;
  background: transparent;
  color: var(--ink);
  white-space: nowrap;
  transition: transform 0.15s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.btn:active { transform: scale(0.98); }
.btn.primary {
  background: var(--green);
  color: #f4f7f5;
}
.btn.primary:hover { background: var(--green-deep); color: #f4f7f5; }
.btn.ghost {
  border-color: var(--line);
  background: var(--paper);
}
.btn.ghost:hover { border-color: var(--green); color: var(--green); }
.btn.small { padding: 0.42rem 0.85rem; font-size: 0.82rem; }
button.btn { appearance: none; }

.check-list, .steps {
  margin: 0.4rem 0 1rem;
  padding-left: 1.15rem;
  color: var(--muted);
}
.check-list li, .steps li { margin: 0.35rem 0; }
.check-list.dim { opacity: 0.9; }
.steps li {
  display: grid;
  gap: 0.15rem;
  margin: 0.75rem 0;
}
.steps strong { color: var(--ink); font-weight: 600; }
.steps span { color: var(--muted); }

.chip-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0;
  margin: 0.5rem 0 1rem;
}
.chip-list li {
  font-family: var(--sans);
  font-size: 0.82rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(0,0,0,0.04);
  border: 1px solid var(--line);
  color: var(--muted);
}

blockquote {
  margin: 1rem 0;
  padding: 0.9rem 1rem;
  border-left: 2px solid var(--green);
  background: var(--green-soft);
  color: var(--ink);
  font-style: normal;
}
blockquote.message { font-style: normal; font-family: var(--sans); }

.harmony { display: grid; gap: 0.75rem; max-width: none; }
.harmony-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.9rem;
  padding: 1rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
}
.harmony-card .letter {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--green);
  color: #f4f7f5;
  font-family: var(--sans);
  font-weight: 600;
}
.harmony-card h3 { margin: 0 0 0.35rem; }
.harmony-card p { margin: 0 0 0.45rem; color: var(--muted); }
.example {
  font-family: var(--sans);
  font-size: 0.86rem !important;
  color: var(--ink) !important;
}
.example span {
  display: inline-block;
  margin-right: 0.35rem;
  color: var(--green);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.big-steps {
  list-style: none;
  padding: 0;
  margin: 0;
  max-width: 42rem;
}
.big-steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  margin: 0 0 1.4rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid var(--line);
}
.big-steps .num {
  font-family: var(--sans);
  font-weight: 600;
  color: var(--green);
  font-size: 1.1rem;
  width: 1.5rem;
}
.big-steps h2 {
  margin: 0 0 0.35rem;
  font-size: 1.2rem;
}
.big-steps p { margin: 0; color: var(--muted); }

.price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.9rem;
  margin: 1rem 0 2rem;
}
.price-card .tag {
  font-family: var(--sans);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--clay);
  margin: 0 0 0.35rem;
}
.price-card .price {
  font-size: 1.45rem;
  color: var(--ink);
  font-weight: 600;
  margin: 0.2rem 0 0.6rem;
}
.price-card ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.86rem;
}
.warn-note { color: var(--clay) !important; }

/* ===== Pricing page (customer-facing packages) ===== */
.pricing-page {
  max-width: none;
  width: 100%;
}
body.marketing-mode .main:has(.pricing-page) {
  width: min(1240px, calc(100% - 2rem));
}
.pricing-hero {
  max-width: 44rem;
  padding: 1.25rem 0 2rem;
}
.pricing-hero h1 {
  font-size: clamp(2.1rem, 4vw, 3rem);
  letter-spacing: -0.035em;
  line-height: 1.08;
  margin: 0 0 0.85rem;
}
.pricing-hero .lede { max-width: 48ch; }
.pricing-section-head {
  max-width: 44rem;
  margin-bottom: 1.5rem;
}
.pricing-section-head h2 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.45rem, 2.5vw, 1.9rem);
  letter-spacing: -0.025em;
}
.plan-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
  margin: 0 0 3rem;
}
@media (max-width: 980px) {
  .plan-cards { grid-template-columns: 1fr; }
}
.plan-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.3rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  position: relative;
}
.plan-card.featured {
  border-color: color-mix(in srgb, var(--green) 40%, var(--line));
  background: linear-gradient(180deg, color-mix(in srgb, var(--green) 8%, var(--paper)), var(--paper) 42%);
  transform: scale(1.02);
  box-shadow: var(--shadow);
  z-index: 1;
}
@media (max-width: 980px) {
  .plan-card.featured { transform: none; }
}
.plan-badge {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  margin: 0;
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--green);
  background: var(--green-soft);
  border-radius: var(--radius-pill);
  padding: 0.25rem 0.55rem;
}
.plan-label {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--muted);
}
.plan-card h3 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.plan-guide {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--green);
  font-weight: 500;
}
.plan-price {
  margin: 0.25rem 0 0.15rem;
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.plan-price span {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}
.plan-price.large { font-size: 2.25rem; }
.plan-outcome {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.45;
  flex: 0 0 auto;
}
.plan-best {
  margin: 0.15rem 0 0.35rem;
  font-size: 0.92rem;
  color: var(--ink);
  line-height: 1.4;
}
.plan-primary {
  margin: 0.25rem 0 0.35rem;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.92rem;
}
.plan-primary li { margin: 0.3rem 0; }
.plan-more {
  font-family: var(--sans);
  font-size: 0.86rem;
  color: var(--muted);
  margin: 0.15rem 0 0.35rem;
}
.plan-more summary {
  cursor: pointer;
  color: var(--green);
  list-style: none;
}
.plan-more summary::-webkit-details-marker { display: none; }
.plan-more ul {
  margin: 0.5rem 0 0;
  padding-left: 1.1rem;
}
.plan-result { margin-top: 0.35rem; }
.plan-result-title {
  margin: 0.55rem 0 0.35rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.plan-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: auto;
  padding-top: 0.75rem;
}
.plan-note { margin: 0.25rem 0 0; font-size: 0.82rem; }

.pricing-premium {
  margin: 1rem 0 2.5rem;
  padding: 1.75rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.heirloom-band {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--green) 7%, var(--paper)), var(--paper) 55%);
}
.chronicle-band {
  background: var(--bg);
}
.premium-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 1.75rem;
  margin-top: 0.75rem;
}
@media (max-width: 860px) {
  .premium-grid { grid-template-columns: 1fr; }
}
.premium-grid h2 {
  margin: 0 0 0.35rem;
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  letter-spacing: -0.03em;
}

.pricing-choose,
.pricing-compare,
.pricing-terms,
.pricing-addons,
.pricing-faq,
.pricing-trust {
  margin: 2.75rem 0;
}
.pricing-choose h2,
.pricing-compare h2,
.pricing-terms h2,
.pricing-addons h2,
.pricing-faq h2,
.pricing-trust h2 {
  margin: 0 0 1rem;
  font-size: clamp(1.4rem, 2.4vw, 1.75rem);
  letter-spacing: -0.025em;
}
.choose-table-wrap,
.compare-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  margin-bottom: 1rem;
}
.choose-table,
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 0.9rem;
}
.choose-table th,
.choose-table td,
.compare-table th,
.compare-table td {
  text-align: left;
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.choose-table th,
.compare-table thead th {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--bg);
}
.compare-table tbody th {
  font-weight: 500;
  color: var(--ink);
  background: transparent;
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.88rem;
  min-width: 10rem;
}
.compare-table td { color: var(--muted); white-space: nowrap; }

.terms-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}
@media (max-width: 700px) {
  .terms-grid { grid-template-columns: 1fr; }
}
.term-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem;
  background: var(--paper);
}
.term-card h3 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.term-card p { margin: 0; color: var(--muted); }

.addon-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}
@media (max-width: 1000px) {
  .addon-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .addon-grid { grid-template-columns: 1fr; }
}
.addon-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  background: var(--paper);
}
.addon-card h3 {
  margin: 0 0 0.35rem;
  font-size: 0.98rem;
}
.addon-card p { margin: 0 0 0.45rem; color: var(--muted); font-size: 0.9rem; }
.addon-price {
  font-family: var(--sans);
  font-size: 0.82rem !important;
  color: var(--green) !important;
  font-weight: 500;
}

.faq-acc { display: grid; gap: 0.45rem; max-width: 48rem; }
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 0.85rem 1rem;
}
.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  letter-spacing: -0.015em;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item p {
  margin: 0.55rem 0 0;
  color: var(--muted);
  max-width: 65ch;
}

.pricing-trust .trust-row { margin-bottom: 1rem; }
.pricing-final { max-width: 40rem; }

.mobile-sticky-cta {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(10px);
}
.mobile-sticky-cta .btn { width: 100%; }
@media (max-width: 700px) {
  .mobile-sticky-cta { display: block; }
  .pricing-page { padding-bottom: 5rem; }
}

/* Upgrade panel after complimentary approval */
.upgrade-panel {
  margin-top: 1.5rem;
  padding: 1.25rem 1.3rem;
  border-radius: var(--radius);
  border: 1px solid color-mix(in srgb, var(--green) 28%, var(--line));
  background: var(--green-soft);
}
.upgrade-panel h2 {
  margin: 0 0 0.45rem;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}
.upgrade-panel p { margin: 0 0 0.85rem; color: var(--ink); max-width: 42ch; }

.qa {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
}
.qa h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}
.qa p { margin: 0; color: var(--muted); }

.table-wrap { overflow: auto; max-width: none; }
table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 0.86rem;
}
th, td {
  text-align: left;
  padding: 0.55rem 0.45rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th {
  color: var(--muted);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
code {
  font-family: var(--mono);
  font-size: 0.8em;
  background: rgba(0,0,0,0.04);
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
}

.choice-grid .choice {
  text-align: left;
  cursor: pointer;
  font: inherit;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.15rem;
  box-shadow: var(--shadow);
  color: var(--ink);
}
.choice h3 { margin: 0 0 0.35rem; font-size: 1.1rem; }
.choice p { margin: 0; color: var(--muted); }
.choice.selected,
.choice:hover {
  border-color: var(--green);
  box-shadow: 0 0 0 1px var(--green);
}

.contact-form label {
  display: block;
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
}
.contact-form input,
.contact-form select,
.contact-form textarea,
.card input,
.card select,
.card textarea,
.bench-grid input,
.bench-grid select,
.bench-grid textarea {
  display: block;
  width: 100%;
  margin-top: 0.3rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.7rem;
  font: inherit;
  background: var(--paper);
  color: var(--ink);
}

.narrow { max-width: 32rem; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper);
  padding: 2.5rem 1.5rem 1.75rem;
  margin-top: auto;
}
.foot-brand {
  max-width: var(--max);
  margin: 0 auto 1.5rem;
}
.foot-brand strong {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 1.05rem;
}
.foot-brand p {
  margin: 0;
  max-width: 36rem;
  color: var(--muted);
  font-size: 0.98rem;
}
.foot-cols {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
}
@media (max-width: 800px) {
  .foot-cols { grid-template-columns: 1fr 1fr; }
}
.foot-col h4 {
  margin: 0 0 0.55rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
}
.foot-col a {
  display: block;
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--ink);
  text-decoration: none;
  margin: 0.3rem 0;
}
.foot-col a:hover { color: var(--green); }
.foot-meta {
  max-width: var(--max);
  margin: 1.75rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(0,0,0,0.08);
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.25rem;
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--muted);
}
.foot-meta a { color: var(--muted); }

/* Drawer */
.nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(30, 24, 18, 0.35);
  z-index: 40;
  display: none;
}
.nav-backdrop.open { display: block; }
.nav-drawer {
  position: fixed;
  inset: 0 auto 0 0;
  width: min(340px, 90vw);
  background: var(--paper);
  border-right: 1px solid var(--line);
  z-index: 50;
  transform: translateX(-105%);
  transition: transform 0.18s ease;
  overflow: auto;
  padding: 1.1rem 1rem 2rem;
}
.nav-drawer.open { transform: translateX(0); }
.drawer-group { margin-bottom: 1.1rem; }
.drawer-group h4 {
  margin: 0 0 0.35rem;
  font-family: var(--sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
}
.drawer-group a {
  display: block;
  font-family: var(--sans);
  font-size: 0.9rem;
  color: var(--ink);
  text-decoration: none;
  padding: 0.35rem 0.25rem;
  border-radius: 6px;
}
.drawer-group a:hover,
.drawer-group a.active {
  background: var(--green-soft);
  color: var(--green);
}

/* Bench / dev */
.bench-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
}
.bench-grid .wide { grid-column: 1 / -1; }
.bench-grid h2 {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
}
.kv {
  margin-top: 0.6rem;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  background: rgba(0,0,0,0.03);
  border: 1px dashed var(--line);
  font-family: var(--mono);
  font-size: 0.74rem;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--muted);
}
.question-box {
  margin: 0.5rem 0 0.85rem;
  padding: 1rem;
  border-radius: 12px;
  background: rgba(44, 85, 72, 0.07);
  border: 1px solid rgba(44, 85, 72, 0.15);
  font-size: 1.1rem;
}
.question-box .meta {
  margin-top: 0.4rem;
  font-family: var(--sans);
  font-size: 0.75rem;
  color: var(--muted);
}

.dev-log {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto 2rem;
  font-family: var(--sans);
  font-size: 0.82rem;
  color: var(--muted);
}
.dev-log summary { cursor: pointer; }
#globalLog {
  max-height: 160px;
  overflow: auto;
  font-family: var(--mono);
  font-size: 0.7rem;
  white-space: pre-wrap;
}
#globalLog .err { color: var(--clay); }
#globalLog .ok { color: var(--green); }

/* ===== Story Intelligence Lab ===== */
/* ===== Story Studio (task-state workspace) ===== */
.studio {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 0 0 4.5rem;
  position: relative;
}
.studio-top {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) auto minmax(0, 1fr);
  gap: 0.75rem 1rem;
  align-items: center;
  min-height: 56px;
  max-height: 72px;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 0.75rem;
}
.studio-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.55rem;
  min-width: 0;
}
.studio-brand strong {
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.studio-sub {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.82rem;
  white-space: nowrap;
}
.studio-sub em {
  font-style: normal;
  color: var(--muted);
  opacity: 0.85;
}
.studio-tabs {
  display: flex;
  gap: 0.15rem;
  justify-content: center;
  flex-wrap: nowrap;
}
.studio-tabs button,
.lab-tabs button {
  font-family: var(--sans);
  font-size: 0.84rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  white-space: nowrap;
}
.studio-tabs button.active,
.studio-tabs button:hover,
.lab-tabs button.active,
.lab-tabs button:hover {
  background: var(--green-soft);
  color: var(--green);
}
.studio-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.4rem;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}
.conn-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #b0b8b3;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.04);
}
.conn-dot.ok {
  background: var(--green);
  box-shadow: 0 0 0 3px var(--green-soft);
}
.scenario-chip {
  font-family: var(--sans);
  font-size: 0.72rem;
  color: var(--muted);
  max-width: 10rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 0.22rem 0.55rem;
  background: var(--paper);
}
.icon-insp {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  cursor: pointer;
  font-size: 0.85rem;
  line-height: 1;
}
.icon-insp:hover { color: var(--green); border-color: var(--green); }
.more-wrap { position: relative; }
.more-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  min-width: 220px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 0.45rem;
  z-index: 40;
  display: grid;
  gap: 0.25rem;
}
.more-menu[hidden] { display: none !important; }
.more-row {
  display: grid;
  gap: 0.25rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  color: var(--muted);
  padding: 0.35rem 0.45rem;
  margin: 0;
}
.more-row select {
  width: 100%;
  margin: 0;
  font-size: 0.82rem;
  padding: 0.35rem 0.45rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
}
.more-item {
  text-align: left;
  font-family: var(--sans);
  font-size: 0.84rem;
  border: 0;
  background: transparent;
  color: var(--ink);
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
}
.more-item:hover:not(:disabled) { background: var(--green-soft); color: var(--green); }
.more-item:disabled { opacity: 0.45; cursor: not-allowed; }
#labFocus.on {
  border-color: var(--green);
  color: var(--green);
  background: var(--green-soft);
}

/* Legacy lab aliases */
.lab { width: min(1440px, 100%); margin: 0 auto; position: relative; }
.lab-top { display: none; }
.lab-hero-line { display: none; }
.conn {
  font-family: var(--sans);
  font-size: 0.75rem;
  color: var(--muted);
  padding: 0.25rem 0.5rem;
  border-radius: 999px;
  border: 1px solid var(--line);
}
.conn.ok { color: var(--green); border-color: color-mix(in srgb, var(--green) 30%, transparent); }

.studio-workspace,
.lab-workspace {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr) 260px;
  gap: 0.75rem;
  min-height: 68vh;
  align-items: stretch;
}
.studio.focus-mode .studio-top,
.studio.focus-mode .studio-rail.left,
.studio.focus-mode .studio-drawer-bar,
.studio.focus-mode .studio-drawer {
  display: none;
}
.studio.focus-mode .studio-workspace {
  grid-template-columns: minmax(0, 1fr) 0;
  gap: 0;
}
.studio.focus-mode .studio-rail.right {
  position: fixed;
  right: 0;
  top: 0;
  bottom: 0;
  width: min(300px, 90vw);
  z-index: 35;
  transform: translateX(calc(100% - 12px));
  transition: transform 0.2s var(--ease);
  background: var(--paper);
  border-left: 1px solid var(--line);
  padding: 1rem 0.85rem;
  box-shadow: var(--shadow);
  overflow: auto;
}
.studio.focus-mode .studio-rail.right:hover,
.studio.focus-mode .studio-rail.right:focus-within {
  transform: none;
}
@media (max-width: 1100px) {
  .studio-workspace,
  .lab-workspace { grid-template-columns: 1fr; }
  .studio-top {
    grid-template-columns: 1fr;
    max-height: none;
  }
  .studio-tabs { justify-content: flex-start; }
  .studio-actions { justify-content: flex-start; }
}

.studio-rail,
.lab-rail {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
}
.studio-rail.left,
.studio-rail.right {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.9rem 0.85rem;
  align-self: start;
  max-height: calc(100dvh - 9rem);
  overflow: auto;
}
.studio-center {
  min-width: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.15rem 1.15rem;
}
.studio-lobby {
  grid-column: 1 / -1;
  max-width: 40rem;
  padding: 1.5rem 0.5rem 2rem;
}
.studio-lobby h1 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  letter-spacing: -0.03em;
  margin: 0 0 0.75rem;
}

.ctx-compact h3,
.ctx-expanded h3 {
  margin: 0 0 0.15rem;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.ctx-meta {
  margin: 0.55rem 0 0;
  font-size: 0.88rem;
  color: var(--ink);
  line-height: 1.4;
}
.ctx-label {
  display: block;
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.15rem;
}
.ctx-actions {
  display: grid;
  gap: 0.35rem;
  margin-top: 0.9rem;
}
.ctx-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
}

.rail-card {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0 0 0.85rem;
  box-shadow: none;
  border-bottom: 1px solid var(--line);
}
.rail-card:last-child { border-bottom: 0; padding-bottom: 0; }
.rail-card h3 { margin: 0 0 0.2rem; font-size: 1.05rem; }
.rail-kicker {
  margin: 0.75rem 0 0.4rem;
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
}
.rail-card .rail-kicker:first-child { margin-top: 0; }
.goal { margin: 0; font-size: 0.95rem; color: var(--ink); line-height: 1.4; }
.mode-pills { display: flex; flex-direction: column; gap: 0.3rem; }
.mode-pills.horizontal { flex-direction: row; flex-wrap: wrap; }
.mode-pill {
  font-family: var(--sans);
  font-size: 0.78rem;
  text-align: left;
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 8px;
  padding: 0.35rem 0.5rem;
  cursor: pointer;
  color: var(--muted);
}
.mode-pill.on {
  border-color: var(--green);
  color: var(--green);
  background: var(--green-soft);
}

/* Right tabs */
.right-tabs {
  display: flex;
  gap: 0.15rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.35rem;
}
.right-tab {
  font-family: var(--sans);
  font-size: 0.78rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.35rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
}
.right-tab.on,
.right-tab:hover {
  color: var(--green);
  background: var(--green-soft);
}
.right-body { min-width: 0; }

/* Conversation timeline */
.timeline { display: grid; gap: 1.25rem; }
.tl-guide .tl-role,
.tl-role {
  display: block;
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 0.35rem;
}
.tl-q {
  margin: 0;
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.tl-q.live { font-weight: 500; }
.tl-answer {
  margin-top: 0.75rem;
  padding: 0.85rem 0.95rem;
  border-radius: var(--radius);
  background: var(--bg);
  border: 1px solid var(--line);
}
.tl-answer-meta {
  display: flex;
  gap: 0.35rem;
  align-items: baseline;
  font-family: var(--sans);
  font-size: 0.82rem;
  margin-bottom: 0.4rem;
}
.tl-quote {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font-style: normal;
  color: var(--ink);
  line-height: 1.5;
}
.tl-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.65rem;
  opacity: 0.55;
  transition: opacity 0.15s var(--ease);
}
.tl-answer:hover .tl-actions,
.tl-answer:focus-within .tl-actions { opacity: 1; }
.tl-wait { margin: 0.85rem 0 0.25rem; }
.tl-listening {
  margin: 0.75rem 0 0.25rem;
  text-align: center;
}
.tl-listening #labWave {
  width: 100%;
  max-width: 520px;
  height: 72px;
  margin: 0.35rem auto;
  display: block;
  border-radius: 10px;
}
.tl-processing {
  margin: 1rem 0;
  padding: 1rem 1.1rem;
  border-radius: var(--radius);
  background: var(--green-soft);
  border: 1px solid color-mix(in srgb, var(--green) 18%, transparent);
}
.processing-title {
  margin: 0 0 0.55rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.process-steps {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.88rem;
}
.process-steps li { margin: 0.25rem 0; }

/* Input chrome */
.input-chrome {
  margin-top: 1.1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
}
.mode-seg-group {
  display: inline-flex;
  gap: 0.15rem;
  padding: 0.15rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--bg);
  margin-bottom: 0.75rem;
}
.mode-seg {
  font-family: var(--sans);
  font-size: 0.8rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.mode-seg.on {
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(20, 28, 24, 0.06);
}
.input-panel .row { margin-top: 0.55rem; }
.off-banner {
  margin: 0 0 0.75rem;
  font-size: 1.15rem;
  font-weight: 600;
  color: #8a2b2b;
  text-align: center;
  letter-spacing: -0.02em;
}
.off-record-state {
  padding: 1rem;
  border-radius: var(--radius);
  background: rgba(138, 43, 43, 0.06);
  border: 1px solid rgba(138, 43, 43, 0.2);
}
.overflow-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.5rem;
  justify-content: center;
}

/* Candidates (right rail) */
.cands { display: grid; gap: 0.65rem; }
.cand {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.75rem 0.8rem;
  background: var(--bg);
}
.cand.rec {
  border-color: color-mix(in srgb, var(--green) 35%, transparent);
  background: var(--green-soft);
}
.cand header {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.cand.rec header { color: var(--green); }
.cand p { margin: 0 0 0.45rem; font-size: 0.92rem; line-height: 1.4; }
.cand .why {
  font-family: var(--sans);
  font-size: 0.8rem;
  color: var(--muted);
}

/* Method chips */
.harm-row, .depth-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.harm-chip {
  font-family: var(--sans);
  font-size: 0.72rem;
  padding: 0.28rem 0.5rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  color: var(--muted);
  background: var(--bg);
}
.harm-chip.active, .harm-chip.emerging {
  border-color: color-mix(in srgb, var(--green) 30%, transparent);
  color: var(--green);
  background: var(--green-soft);
}
.depth-step {
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--muted);
}
.depth-step.on { color: var(--green); font-weight: 600; }
.depth-arrow { color: var(--line); font-size: 0.75rem; }

/* Bottom drawer */
.studio-drawer-bar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0.65rem;
  z-index: 25;
  display: flex;
  gap: 0.25rem;
  padding: 0.3rem;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}
.drawer-tab {
  font-family: var(--sans);
  font-size: 0.78rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  white-space: nowrap;
}
.drawer-tab.on,
.drawer-tab:hover {
  background: var(--green-soft);
  color: var(--green);
}
.drawer-count {
  display: inline-block;
  min-width: 1.1rem;
  margin-left: 0.2rem;
  font-size: 0.7rem;
  opacity: 0.85;
}
.studio-drawer {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 3.1rem;
  width: min(920px, calc(100% - 1.5rem));
  max-height: min(42vh, 360px);
  overflow: auto;
  z-index: 26;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 0.85rem 1rem 1rem;
}
.studio-drawer[hidden] { display: none !important; }
.drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.drawer-head h3 {
  margin: 0;
  font-size: 0.95rem;
  letter-spacing: -0.02em;
}
body.studio-mode .main {
  width: min(1440px, calc(100% - 1.5rem));
}
body.studio-mode .chrome {
  /* studio has its own header; keep app chrome light */
}
.theme-list, .thread-list, .arc-list {
  margin: 0;
  padding-left: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.theme-list.dim { opacity: 0.85; }
.theme-list li, .thread-list li { margin: 0.25rem 0; }
.arc-list { list-style: none; padding: 0; }
.arc-list li {
  font-family: var(--sans);
  font-size: 0.82rem;
  padding: 0.3rem 0.5rem;
  border-radius: 8px;
  color: var(--muted);
  margin: 0.15rem 0;
}
.arc-list li.active {
  background: rgba(44, 85, 72, 0.12);
  color: var(--green-deep);
  font-weight: 600;
}
.arc-list li.done { color: var(--ink); }
.thread-list { list-style: none; padding: 0; }
.thread-list li {
  display: flex;
  gap: 0.45rem;
  align-items: flex-start;
  margin: 0.35rem 0;
  font-size: 0.88rem;
}
.dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  margin-top: 0.35rem;
  background: var(--line);
  flex-shrink: 0;
}
.dot.active, .dot.open { background: var(--green); }
.dot.developed { background: var(--ink); }
.dot.emerging { background: var(--clay); }
.dot.latent { background: #cfc5b5; }

.mini-table { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 0.78rem; }
.mini-table td { padding: 0.28rem 0; border-bottom: 1px solid rgba(0,0,0,0.05); color: var(--muted); }
.mini-table td:last-child { text-align: right; }
.state {
  font-size: 0.72rem;
  text-transform: capitalize;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  background: rgba(0,0,0,0.04);
}
.state.active, .state.reached { background: rgba(44,85,72,0.12); color: var(--green-deep); }
.state.emerging, .state.next { background: rgba(139,90,60,0.12); color: var(--clay); }
.state.developed { background: rgba(31,26,20,0.08); color: var(--ink); }

.lab-center { min-width: 0; }
.story-room {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.35rem 1.4rem 1.5rem;
  box-shadow: var(--shadow);
  min-height: 64vh;
}
.story-room.lobby h1 {
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  max-width: 18ch;
}
.room-status {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-family: var(--sans);
  font-size: 0.8rem;
}
.guide-state {
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: rgba(0,0,0,0.04);
  color: var(--muted);
}
.guide-state.listening { background: rgba(44,85,72,0.12); color: var(--green-deep); }
.guide-state.speaking { background: rgba(139,90,60,0.12); color: var(--clay); }
.guide-state.processing { background: rgba(0,0,0,0.06); }

.question-stage { margin-bottom: 1.25rem; }
.q-label {
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 0.5rem;
}
.question-live {
  margin: 0;
  padding: 1rem 1.15rem;
  border-left: 3px solid var(--green);
  background: rgba(44, 85, 72, 0.06);
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  line-height: 1.35;
  font-style: normal;
}
.privacy-line { margin: 0.65rem 0 0; }

.voice-stage {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.85rem;
  background: rgba(246, 241, 232, 0.65);
  margin-bottom: 1rem;
}
#labWave {
  width: 100%;
  height: 88px;
  display: block;
  border-radius: 10px;
  background: rgba(44,85,72,0.04);
}
.caption-line {
  font-family: var(--sans);
  font-size: 0.86rem;
  color: var(--muted);
  min-height: 1.3em;
  margin: 0.55rem 0;
}
.room-controls { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.type-stage { margin-top: 0.5rem; }
.response-label {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--ink);
  margin-bottom: 0.35rem;
}
.response-field {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  font-family: var(--serif);
  font-size: 1.05rem;
  line-height: 1.5;
  min-height: 7rem;
  background: #fff;
  color: var(--ink);
  resize: vertical;
}

.clips { margin-top: 1.25rem; display: grid; gap: 0.65rem; }
.clip-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 0.85rem;
  background: #fff;
}
.clip-meta { font-family: var(--sans); font-size: 0.72rem; color: var(--muted); margin-bottom: 0.35rem; }
.clip-card audio { width: 100%; margin: 0.25rem 0; }
.clip-text { margin: 0.35rem 0 0; font-size: 0.98rem; color: var(--ink); }

.cand {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.65rem 0.7rem;
  margin: 0.45rem 0;
  background: #fff;
}
.cand.rec { border-color: rgba(44,85,72,0.4); background: rgba(44,85,72,0.05); }
.cand.rej { opacity: 0.55; }
.cand header {
  font-family: var(--sans);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 0.3rem;
}
.cand p { margin: 0 0 0.35rem; font-size: 0.9rem; color: var(--ink); }
.cand .why { font-family: var(--sans); font-size: 0.75rem; color: var(--muted); }

.moment-room h1 { font-size: clamp(1.5rem, 2.5vw, 1.9rem); }
.moment-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin-top: 1rem;
}
@media (max-width: 800px) { .moment-grid { grid-template-columns: 1fr; } }
.moment-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem;
  background: #fff;
}
.moment-card.highlight {
  grid-column: 1 / -1;
  background: rgba(44, 85, 72, 0.06);
  border-color: rgba(44, 85, 72, 0.25);
}
.moment-card h3 { margin: 0 0 0.5rem; font-size: 0.95rem; }
.moment-card .quote { font-style: italic; color: var(--ink); }
.moment-card .wisdom { font-size: 1.15rem; line-height: 1.4; }
.moment-card .ts { font-family: var(--sans); font-size: 0.75rem; color: var(--muted); }
.moment-card audio { width: 100%; margin: 0.35rem 0; }

.lab-full {
  grid-column: 1 / -1;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.25rem 1.4rem;
  box-shadow: var(--shadow);
}
.trace-list { padding-left: 1.2rem; color: var(--muted); }
.trace-list li { margin: 0.75rem 0; }
.trace-seq {
  font-family: var(--mono);
  font-size: 0.78rem;
  background: rgba(0,0,0,0.03);
  padding: 0.75rem;
  border-radius: 10px;
  overflow: auto;
}
.graph-board {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 1rem 0;
}
.graph-node {
  max-width: 220px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
  background: #fff;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  box-shadow: var(--shadow);
}
.graph-node .g-kind {
  display: block;
  font-family: var(--sans);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.graph-node.awaiting_approval { border-color: var(--green); }
.eval-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}
.eval-card {
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem;
  background: #fff;
  cursor: pointer;
  font: inherit;
  box-shadow: var(--shadow);
}
.eval-card h3 { margin: 0 0 0.35rem; font-size: 1rem; }
.eval-card p { margin: 0; color: var(--muted); font-size: 0.9rem; }
.eval-card:hover { border-color: var(--green); }

.lab-inspector {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(420px, 94vw);
  background: var(--paper);
  border-left: 1px solid var(--line);
  z-index: 70;
  box-shadow: -12px 0 40px rgba(0,0,0,0.08);
  display: none;
  flex-direction: column;
}
.lab-inspector.is-open {
  display: flex;
}
/* Ensure [hidden] always wins over display:flex */
.lab-inspector[hidden],
.lab-insp-backdrop[hidden] {
  display: none !important;
}
.lab-insp-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(30,24,18,0.3);
  z-index: 60;
  display: none;
}
.lab-insp-backdrop.is-open {
  display: block;
}
.insp-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
}
.insp-head h2 { margin: 0; font-size: 1.05rem; }
.insp-body {
  overflow: auto;
  padding: 0.75rem 1rem 1.5rem;
  flex: 1;
}
.insp-evt {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  margin-bottom: 0.5rem;
  background: #fff;
}
.insp-evt.ok { border-color: rgba(44,85,72,0.25); }
.insp-evt.err { border-color: rgba(139,90,60,0.35); }
.insp-evt.agent { background: rgba(44,85,72,0.04); }
.insp-evt header {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.insp-evt pre {
  margin: 0.25rem 0 0;
  font-family: var(--mono);
  font-size: 0.68rem;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink);
  max-height: 180px;
  overflow: auto;
}
.insp-evt details summary {
  font-family: var(--sans);
  font-size: 0.72rem;
  cursor: pointer;
  color: var(--green);
}

.lab-toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: #f7f3eb;
  font-family: var(--sans);
  font-size: 0.86rem;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  z-index: 90;
  box-shadow: var(--shadow);
  max-width: 90vw;
}
.lab-toast.err { background: var(--clay); }

/* Lab uses full main width */
.main:has(.lab) {
  width: min(1400px, calc(100% - 1.5rem));
}

/* ===== Customer Story App ===== */
body.app-mode {
  --bg: #f3f4f1;
  --paper: #fafaf8;
}
@media (prefers-color-scheme: dark) {
  body.app-mode {
    --bg: #121614;
    --paper: #1a1f1c;
  }
}
body.app-mode .chrome {
  padding: 0.75rem 1.5rem;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
}
body.app-mode .primary-nav a {
  font-size: 0.92rem;
  padding: 0.45rem 0.75rem;
}
body.app-mode .main {
  width: min(1100px, calc(100% - 2rem));
  padding-top: 1.5rem;
  padding-bottom: 4rem;
}
body.app-mode .pill { display: none; }
body.studio-mode .pill { display: inline-flex; }
body.app-mode .soft-link {
  opacity: 0.7;
  font-size: 0.82rem !important;
}

/* Account menu (app chrome) */
.account-menu {
  position: relative;
}
.account-trigger {
  font-family: var(--sans);
  font-size: 0.84rem;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: var(--radius-pill);
  padding: 0.32rem 0.7rem;
  cursor: pointer;
  color: var(--ink);
}
.account-trigger:hover {
  border-color: var(--green);
  color: var(--green);
}
.account-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  min-width: 12.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 0.35rem;
  z-index: 50;
  display: grid;
  gap: 0.1rem;
}
.account-dropdown[hidden] { display: none !important; }
.account-dropdown a,
.account-dropdown .account-signout,
.drawer-signout,
.account-signout-inline {
  display: block;
  width: 100%;
  text-align: left;
  font-family: var(--sans);
  font-size: 0.86rem;
  color: var(--ink);
  text-decoration: none;
  border: 0;
  background: transparent;
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
}
.account-dropdown a:hover,
.account-dropdown .account-signout:hover,
.drawer-signout:hover {
  background: var(--green-soft);
  color: var(--green);
}
.account-dropdown .account-signout,
.drawer-signout {
  margin-top: 0.2rem;
  border-top: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
  color: var(--muted);
}
.account-signout-inline {
  display: inline;
  width: auto;
  padding: 0;
  color: var(--muted);
}
.account-signout-inline:hover { color: var(--green); }
.more-menu a.more-item {
  text-decoration: none;
  color: var(--ink);
}
body.marketing-mode #userPill { display: none; }

.story-app {
  max-width: 1080px;
  margin: 0 auto;
}
.story-app.roomy {
  max-width: 860px;
}
.story-welcome {
  padding: 1.25rem 0 1.75rem;
  max-width: 40rem;
}
.story-welcome.compact { padding-top: 0.5rem; }
.story-welcome h1 {
  font-size: clamp(2.1rem, 4.2vw, 2.85rem);
  line-height: 1.12;
  max-width: 16ch;
  margin: 0 0 0.85rem;
}
.story-welcome .lede {
  font-size: 1.2rem;
  max-width: 36rem;
}
.reassure {
  font-family: var(--sans);
  font-size: 0.95rem;
  color: var(--muted);
  margin: 0.85rem 0 0;
}
.reassure.center { text-align: center; }
.btn.lg {
  padding: 0.8rem 1.25rem;
  font-size: 1rem;
  min-height: 2.85rem;
}

.story-home-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 1.1rem;
}
@media (max-width: 860px) {
  .story-home-grid { grid-template-columns: 1fr; }
}
.story-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem 1.45rem;
  box-shadow: none;
}
.story-card h2 {
  margin: 0 0 0.65rem;
  font-size: 1.3rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}
.story-card.primary-card {
  grid-column: 1 / -1;
  padding: 1.6rem 1.7rem;
}
.gift-card {
  margin-bottom: 1.1rem;
  border-color: color-mix(in srgb, var(--green) 28%, transparent);
  background: var(--green-soft);
}
.meta-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1.25rem;
  margin: 1rem 0 1.15rem;
}
.meta-list dt {
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 0.15rem;
}
.meta-list dd {
  margin: 0;
  font-size: 1.05rem;
  color: var(--ink);
}
.sit-question {
  margin: 0.35rem 0 0.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 1.25rem;
  line-height: 1.4;
  font-style: normal;
  color: var(--ink);
}
.control-list {
  margin: 0.4rem 0 1rem;
  padding-left: 1.15rem;
  color: var(--muted);
  font-size: 1.02rem;
}
.control-list li { margin: 0.35rem 0; }

.story-dialog {
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 1.4rem 1.5rem;
  max-width: 32rem;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 18px 40px rgba(27, 30, 26, 0.08);
}
.story-dialog::backdrop { background: rgba(27, 30, 26, 0.35); }
.story-dialog h2 {
  margin: 0 0 0.85rem;
  font-family: var(--serif);
  font-size: 1.35rem;
}
.expect-list { color: var(--muted); padding-left: 1.2rem; }
.expect-list li { margin: 0.45rem 0; }

.topic-grid {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 0.75rem 0 1rem;
}
.topic-grid.large { gap: 0.55rem; margin: 1rem 0 1.25rem; }
/* Match /projects journey-choice */
.topic-choice {
  text-align: left;
  font: inherit;
  font-size: 1.02rem;
  padding: 0.9rem 1.1rem;
  border-radius: 2px;
  border: 1px solid var(--line);
  background: var(--paper);
  cursor: pointer;
  color: var(--ink);
  line-height: 1.4;
}
.topic-choice.on,
.topic-choice:hover {
  border-color: var(--green);
  background: color-mix(in srgb, var(--green) 6%, var(--paper));
}

.format-cards {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}
.format-card {
  text-align: left;
  font: inherit;
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 0.95rem 1.1rem;
  background: var(--paper);
  cursor: pointer;
  color: var(--ink);
  box-shadow: none;
}
.format-card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 600;
}
.format-card p { margin: 0; color: var(--muted); font-size: 0.95rem; line-height: 1.45; }
.format-card.on {
  border-color: var(--green);
  background: color-mix(in srgb, var(--green) 6%, var(--paper));
  box-shadow: none;
}

.prep-ready {
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 1.5rem 1.25rem 1.35rem;
  background: var(--paper);
  text-align: center;
}
.prep-block h2 {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--ink);
}
.ceremony .eyebrow,
.ceremony-panel .eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage);
  margin: 0 0 0.55rem;
}
/* Siri / ChatGPT-style reactive voice orb */
.voice-orb {
  --voice: 0;
  --orb-scale: 1;
  --ring-scale: 1;
  --orb-glow: 0.18;
  position: relative;
  width: 112px;
  height: 112px;
  margin: 0.35rem auto 1rem;
  display: grid;
  place-items: center;
  isolation: isolate;
}
.voice-orb-core {
  position: relative;
  z-index: 2;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.72), transparent 42%),
    radial-gradient(circle at 50% 58%, color-mix(in srgb, var(--green) 55%, #8fd0b4), color-mix(in srgb, var(--green) 70%, #0f2a22));
  border: 1px solid color-mix(in srgb, var(--green) 35%, transparent);
  box-shadow:
    0 0 calc(18px + var(--voice) * 36px) rgba(30, 77, 62, var(--orb-glow)),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
  transform: scale(var(--orb-scale));
  transition: transform 0.05s linear, box-shadow 0.08s linear;
  will-change: transform;
}
.voice-orb-ring {
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  border: 1.5px solid color-mix(in srgb, var(--green) 28%, transparent);
  opacity: 0;
  transform: scale(0.72);
  pointer-events: none;
  z-index: 1;
}
.voice-orb.is-listening .voice-orb-ring {
  opacity: calc(0.22 + var(--voice) * 0.55);
  transform: scale(var(--ring-scale));
  transition: transform 0.06s linear, opacity 0.08s linear;
}
.voice-orb.is-listening .voice-orb-ring.r1 {
  inset: 8%;
  opacity: calc(0.12 + var(--voice) * 0.35);
  transform: scale(calc(var(--ring-scale) * 1.08));
  border-color: color-mix(in srgb, var(--green) 18%, transparent);
}
.voice-orb.is-listening .voice-orb-ring.r2 {
  inset: 0;
  opacity: calc(0.08 + var(--voice) * 0.28);
  transform: scale(calc(var(--ring-scale) * 1.18));
  border-color: color-mix(in srgb, var(--green) 14%, transparent);
}
.voice-orb.is-listening .voice-orb-ring.r3 {
  inset: -14%;
  opacity: calc(0.04 + var(--voice) * 0.2);
  transform: scale(calc(var(--ring-scale) * 1.28));
  border-color: color-mix(in srgb, var(--green) 10%, transparent);
}
.voice-orb.is-listening .voice-orb-core {
  animation: orb-breathe 2.4s ease-in-out infinite;
}
.voice-orb.is-speaking .voice-orb-core {
  animation: none;
}
.voice-orb.is-idle .voice-orb-core {
  opacity: 0.88;
  filter: saturate(0.85);
}
@media (prefers-reduced-motion: reduce) {
  .voice-orb.is-listening .voice-orb-core { animation: none; }
  .voice-orb-core,
  .voice-orb-ring { transition: none; }
}
@keyframes orb-breathe {
  0%, 100% { transform: scale(calc(var(--orb-scale) * 1)); }
  50% { transform: scale(calc(var(--orb-scale) * 1.04)); }
}

/* legacy alias if any leftover markup */
.mic-orb {
  width: 72px;
  height: 72px;
  margin: 0 auto 0.85rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.55), transparent 40%),
    radial-gradient(circle at 50% 55%, color-mix(in srgb, var(--green) 35%, transparent), color-mix(in srgb, var(--green) 8%, transparent));
  border: 1px solid color-mix(in srgb, var(--green) 20%, transparent);
}
.center-row { justify-content: center; }
.mic-status { min-height: 2.6em; }

.story-room-customer {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 1.6rem 1.7rem 1.8rem;
  box-shadow: var(--shadow);
}
.story-room-customer.prep h1 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  max-width: 16ch;
  margin: 0 0 0.5rem;
}
.story-room-customer.live {
  min-height: 70vh;
}
.live-top {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1.25rem;
}
.live-pill {
  font-family: var(--sans);
  font-size: 0.82rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: #fff;
}
.live-pill.on {
  color: var(--green-deep);
  border-color: rgba(44,85,72,0.3);
  background: rgba(44,85,72,0.1);
}
.live-question blockquote {
  margin: 0;
  padding: 1.1rem 1.2rem;
  border-left: 3px solid var(--green);
  background: rgba(44, 85, 72, 0.06);
  font-size: clamp(1.25rem, 2.3vw, 1.55rem);
  line-height: 1.35;
  font-style: normal;
}
.live-voice {
  margin: 1.25rem 0;
  padding: 1rem;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(246, 241, 232, 0.65);
}
#storyWave {
  width: 100%;
  height: 100px;
  display: block;
  border-radius: 12px;
  background: rgba(44,85,72,0.05);
}
.live-type label {
  font-size: 1rem;
  color: var(--ink);
  margin-bottom: 0.4rem;
}
.live-audio {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}
.live-audio audio { width: 100%; margin-top: 0.35rem; }

.story-complete {
  max-width: 42rem;
}
.story-complete h1 {
  font-size: clamp(2rem, 3.5vw, 2.6rem);
  line-height: 1.15;
  margin: 0 0 0.75rem;
}
.highlight-card {
  background: rgba(44, 85, 72, 0.07);
  border-color: rgba(44, 85, 72, 0.22);
  margin: 1.25rem 0;
}
.wisdom-line {
  margin: 0;
  font-size: 1.35rem;
  line-height: 1.4;
  font-weight: 600;
}
.continue-card { margin-top: 1.5rem; }
.row.wrap { flex-wrap: wrap; }

/* Studio uses full width; customer home is calmer */
body.studio-mode .main {
  width: min(1480px, calc(100% - 1.25rem));
}
body.studio-mode .studio-workspace,
body.studio-mode .lab-workspace {
  grid-template-columns: 200px minmax(0, 1fr) 260px;
  gap: 0.75rem;
  min-height: 72vh;
}
body.studio-mode .studio .btn {
  min-height: 2.35rem;
}

/* ===== Ceremony mode — same light archival field as /projects ===== */
body.ceremony-mode .shell {
  min-height: 100vh;
  background: var(--bg);
}
body.ceremony-mode .main {
  width: min(720px, calc(100% - 2rem));
  max-width: 720px;
  margin: 0 auto;
  padding: 1.25rem 0 3.5rem;
}
/* Keep light marketing chrome visible so prepare matches project wizards */
body.ceremony-mode .chrome {
  display: flex !important;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
body.ceremony-mode .context-bar,
body.ceremony-mode .site-footer,
body.ceremony-mode .dev-log,
body.ceremony-mode .has-mobile-app-nav .mobile-app-nav {
  display: none !important;
}
body.ceremony-mode .primary-nav,
body.ceremony-mode .utility-nav {
  display: none;
}
body.ceremony-mode .logo-descriptor {
  display: block;
}

.ceremony {
  min-height: min(85vh, 720px);
  display: flex;
  flex-direction: column;
  position: relative;
}
.ceremony-exit {
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--muted);
  text-decoration: none;
  align-self: flex-start;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.1rem;
}
.ceremony-exit:hover { color: var(--green); border-bottom-color: var(--green); }
/* Align with journey-setup: no large SaaS card radius */
.ceremony-panel {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0.25rem 0 1.5rem;
  box-shadow: none;
  flex: 1;
}
.ceremony-panel.narrow {
  max-width: 40rem;
  margin: 0;
}
.ceremony-panel h1 {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
  line-height: 1.15;
  max-width: 18ch;
  margin: 0 0 1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.ceremony-panel.review h1 { max-width: 14ch; }
.ceremony-panel .lede,
.ceremony-panel > p {
  color: var(--muted);
  max-width: 40rem;
  line-height: 1.55;
}
.ceremony-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.5rem;
}
.session-facts {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: grid;
  gap: 0.45rem;
}
.session-facts li {
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--muted);
  padding-left: 1.2rem;
  position: relative;
}
.session-facts li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--green);
  opacity: 0.7;
}
.session-facts.large li { font-size: 1.05rem; }
.theme-line {
  font-size: 1.2rem;
  color: var(--ink);
  margin: 0 0 1rem;
}
.prep-block { margin: 1.5rem 0; }
.prep-block h2 {
  font-size: 1.2rem;
  margin: 0 0 0.75rem;
}
.prep-block.device {
  text-align: center;
  padding: 1.5rem 1.25rem 1.35rem;
  border-radius: var(--radius);
  background: var(--paper);
  border: 1px solid var(--line);
}
.prep-block.device .btn {
  margin-top: 0.35rem;
}
.ceremony-hero .session-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 640px) {
  .ceremony-hero .session-facts { grid-template-columns: 1fr; }
}

/* Focused room — voice-first continuous conversation (light editorial) */
.room-focus {
  max-width: 720px;
  margin: 0 auto;
}
.story-room-shell {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0.5rem 0 1.5rem;
  min-height: min(78dvh, 720px);
  display: flex;
  flex-direction: column;
}
body.ceremony-mode .story-room-shell {
  border-top: 1px solid var(--line);
  padding-top: 1.5rem;
}
.sr-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.sr-title {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.sr-sub { margin: 0.15rem 0 0; font-size: 0.82rem; }
.sr-timer {
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--muted);
  padding: 0.3rem 0.7rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--bg);
}
.sr-timer.live {
  color: var(--green);
  border-color: color-mix(in srgb, var(--green) 30%, transparent);
  background: var(--green-soft);
}
.sr-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.5rem 0 1rem;
}
.sr-role {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green);
}
.sr-status {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.92rem;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.sr-status.listening { color: var(--green); }
.sr-status.thinking { color: var(--muted); font-style: italic; }
.sr-status.off_record { color: #8a2b2b; }
.sr-dot {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.85;
}
.sr-status.listening .sr-dot {
  animation: pulse-dot 1.4s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 0.45; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); }
}
.sr-speech-block {
  max-width: 34rem;
  margin: 0.35rem auto 0.5rem;
}
.sr-guide-line {
  margin: 0.2rem 0 0;
  font-size: clamp(1.15rem, 2.3vw, 1.45rem);
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.sr-reflect {
  margin: 0 0 0.55rem;
  font-size: 1rem;
  line-height: 1.45;
  color: var(--muted);
  font-style: normal;
}
.sr-caption {
  margin: 0.35rem auto 0;
  max-width: 28rem;
  min-height: 1.5em;
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--muted);
}
.sr-caption[hidden] { display: none !important; }
.voice-first[data-room="guide"] .voice-orb {
  animation: orb-breathe 2.4s ease-in-out infinite;
}
.sr-stage .voice-orb {
  margin: 0.75rem auto 0.5rem;
}
.sr-stage #storyWave {
  width: min(100%, 420px);
  height: 56px;
  border-radius: 10px;
  opacity: 0.85;
}
.sr-stage #storyWave.is-quiet { opacity: 0.2; }
.sr-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: center;
  margin-top: 1rem;
  min-height: 3rem;
  align-items: center;
}
.sr-secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
  margin-top: 1.1rem;
}
.linkish {
  border: 0;
  background: transparent;
  font-family: var(--sans);
  font-size: 0.82rem;
  color: var(--muted);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  padding: 0;
}
.linkish:hover { color: var(--green); }
.type-fallback-panel {
  width: min(100%, 28rem);
  margin-top: 0.85rem;
  text-align: left;
}
.type-fallback-panel .response-field { margin: 0.35rem 0 0.55rem; }
.thinking-hint { margin: 0; }
.voice-first[data-room="off_record"] .story-room-shell {
  border-color: color-mix(in srgb, #8a2b2b 35%, var(--line));
  background: color-mix(in srgb, #8a2b2b 4%, var(--paper));
}
.room-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  font-family: var(--sans);
}
.timer {
  font-size: 0.95rem;
  color: var(--muted);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
}
.timer.live {
  color: #8a2b2b;
  border-color: rgba(138, 43, 43, 0.35);
  background: rgba(138, 43, 43, 0.08);
}
.room-stage {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 1.75rem 1.6rem 1.8rem;
  box-shadow: var(--shadow);
  min-height: 70vh;
}
.room-question {
  margin: 0;
  padding: 1.2rem 1.3rem;
  border-left: 3px solid var(--green);
  background: var(--green-soft);
  font-size: clamp(1.35rem, 2.6vw, 1.7rem);
  line-height: 1.35;
  font-style: normal;
}
.voice-stage.clean {
  margin: 1.5rem 0 1rem;
  padding: 1.25rem 1.1rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--bg);
  text-align: center;
}
.voice-stage.clean .voice-orb { margin-bottom: 0.65rem; }
.voice-stage.clean #storyWave {
  margin: 0.25rem auto 0.65rem;
  max-width: 100%;
  opacity: 0.9;
}
.btn.rec-start { background: #8a2b2b; }
.btn.rec-start:hover { background: #6e2222; }
.btn.rec-stop { background: var(--green); }
.type-fallback {
  margin-top: 1.25rem;
  font-family: var(--sans);
  color: var(--muted);
}
.type-fallback summary {
  cursor: pointer;
  margin-bottom: 0.65rem;
}
.span-2 { grid-column: 1 / -1; }
.empty-archive-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.75rem 0 1rem;
}
.preview-chip {
  font-family: var(--sans);
  font-size: 0.85rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(0,0,0,0.03);
  color: var(--muted);
}
.wisdom-preview {
  font-size: 1.25rem;
  line-height: 1.4;
  font-weight: 600;
  margin: 0 0 1rem;
}

/* Reflect */
.reflect {
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 70vh;
}
.reflect h1 { margin-left: auto; margin-right: auto; }
.reflect .lede { margin-left: auto; margin-right: auto; }
.reflect-pulse {
  width: 64px;
  height: 64px;
  margin: 1.5rem auto;
  border-radius: 50%;
  background: rgba(44, 85, 72, 0.15);
  box-shadow: 0 0 0 0 rgba(44, 85, 72, 0.25);
  animation: pulse 1.6s ease-out infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(44, 85, 72, 0.3); }
  70% { box-shadow: 0 0 0 18px rgba(44, 85, 72, 0); }
  100% { box-shadow: 0 0 0 0 rgba(44, 85, 72, 0); }
}
.reflect .session-facts { justify-items: center; }
.reflect .ceremony-actions { justify-content: center; }

/* Processing intermediary (Story Guide preparing Wisdom Moment) */
.process-steps {
  list-style: none;
  margin: 1.5rem 0 1rem;
  padding: 0;
  text-align: left;
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}
.process-step {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0;
  color: var(--muted);
  font-size: 0.98rem;
  border-bottom: 1px solid var(--line);
  transition: color 0.25s var(--ease);
}
.process-step:last-child { border-bottom: 0; }
.process-step.is-active {
  color: var(--ink);
  font-weight: 600;
}
.process-step.is-done {
  color: var(--green);
}
.process-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--line);
  flex-shrink: 0;
}
.process-step.is-active .process-dot {
  background: var(--green);
  box-shadow: 0 0 0 4px var(--green-soft);
}
.process-step.is-done .process-dot {
  background: var(--brass);
}
.process-status {
  text-align: center;
  min-height: 1.4em;
}
.reflect-pulse.is-done {
  opacity: 0.35;
}
.resume-banner {
  background: var(--paper);
  border: 1px solid var(--line);
  border-left: 3px solid var(--brass);
  padding: 1rem 1.1rem;
  margin-bottom: 1.25rem;
  border-radius: 2px;
}
.resume-banner p {
  margin: 0 0 0.75rem;
  color: var(--ink);
}
.processing-panel #btnToReview:disabled {
  opacity: 0.55;
  cursor: wait;
}

/* Source link signature */
.source-link {
  display: inline-flex;
  margin-top: 1rem;
  font-family: var(--sans);
  font-size: 0.95rem;
  color: var(--green-deep);
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(44, 85, 72, 0.35);
  padding: 0.15rem 0;
  cursor: pointer;
}
.source-link:hover { color: var(--green); }
.source-player {
  margin-top: 0.85rem;
  padding: 0.85rem;
  border-radius: 12px;
  background: rgba(0,0,0,0.03);
  border: 1px solid var(--line);
}
.source-player audio { width: 100%; }
.source-transcript {
  margin: 0.55rem 0 0;
  font-style: italic;
  color: var(--ink);
}

/* Archive mode */
.archive-mode .archive-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1rem;
}
@media (max-width: 800px) {
  .archive-mode .archive-grid { grid-template-columns: 1fr; }
}
.featured-moment h2 {
  font-size: clamp(1.4rem, 2.5vw, 1.85rem);
  line-height: 1.3;
  margin: 0 0 0.65rem;
}
.explore-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.5rem 0 0.75rem;
}
.collection-list {
  margin: 0.4rem 0 0.75rem;
  padding-left: 1.1rem;
  color: var(--muted);
}
.collection-list li { margin: 0.35rem 0; }
.layers {
  margin: 0.4rem 0 0;
  padding-left: 1.15rem;
  color: var(--muted);
}
.layers li { margin: 0.4rem 0; }
.layers li.on { color: var(--ink); font-weight: 600; }

/* Living Archive: Story Album, Publication Studio, Context */
.living-surface .photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
  margin: 1rem 0;
}
.photo-card .photo-thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 0.5rem;
  margin-bottom: 0.75rem;
  background: var(--surface-2, #e8ebe9);
}
.photo-card .photo-thumb.placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 0.9rem;
}
.photo-quote {
  margin: 0.5rem 0;
  padding-left: 0.75rem;
  border-left: 2px solid var(--accent, #1e4d3e);
  font-style: italic;
  color: var(--ink);
}
.pub-type-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.65rem;
}
.pub-type {
  text-align: left;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border, #d0d5d2);
  border-radius: 0.55rem;
  background: var(--surface, #fff);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font: inherit;
  color: inherit;
}
.pub-type span { color: var(--muted); font-size: 0.88rem; line-height: 1.35; }
.pub-type.on {
  border-color: var(--accent, #1e4d3e);
  box-shadow: 0 0 0 1px var(--accent, #1e4d3e);
}
.material-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}
.material-cols h3 { font-size: 0.95rem; margin: 0 0 0.4rem; }
.pub-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  list-style: none;
  margin-left: 0;
}
.export-preview {
  max-height: 28rem;
  overflow: auto;
  white-space: pre-wrap;
  font-size: 0.85rem;
  line-height: 1.45;
  padding: 1rem;
  background: var(--surface-2, #f4f6f5);
  border-radius: 0.5rem;
}
.context-card.layer-historical_context {
  border-top: 3px solid #3d6b8a;
}
.context-card.layer-storyteller_memory {
  border-top: 3px solid #1e4d3e;
}
.context-card.layer-family_contribution {
  border-top: 3px solid #8a6a3d;
}
.context-card.layer-ai_interpretation {
  border-top: 3px solid #6b5a8a;
}
.gen-table-wrap { overflow-x: auto; }
.gen-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.gen-table th,
.gen-table td {
  border: 1px solid var(--border, #d0d5d2);
  padding: 0.65rem 0.75rem;
  vertical-align: top;
  text-align: left;
}
.gen-table th { background: var(--surface-2, #f4f6f5); }
.gen-table td span.soft {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.8rem;
}
.check-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.5rem 0;
}
.moh-dialog {
  border: none;
  border-radius: 0.75rem;
  padding: 0;
  max-width: min(520px, 94vw);
  box-shadow: 0 12px 40px rgba(0,0,0,0.18);
}
.moh-dialog::backdrop { background: rgba(20, 28, 24, 0.45); }
.moh-dialog .dialog-body {
  padding: 1.25rem 1.4rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.moh-dialog label { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.9rem; }
.moh-dialog input,
.moh-dialog textarea,
.moh-dialog select {
  font: inherit;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--border, #d0d5d2);
  border-radius: 0.4rem;
}
.btn.small { font-size: 0.85rem; padding: 0.35rem 0.7rem; }
.layers strong { color: var(--ink); }

/* Response draft selection (checkbox list) */
.response-label-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.35rem 1rem;
  align-items: baseline;
  margin-bottom: 0.65rem;
}
.response-label-row strong {
  font-size: 1.05rem;
}
.empty-drafts {
  padding: 0.75rem 0.85rem;
  border: 1px dashed var(--line);
  border-radius: 12px;
  margin: 0 0 0.85rem;
}
.draft-list {
  display: grid;
  gap: 0.55rem;
  margin: 0 0 1rem;
}
.draft-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.85rem 0.95rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.12s ease, background 0.12s ease;
}
.draft-card:hover {
  border-color: rgba(44, 85, 72, 0.4);
}
.draft-card.selected {
  border-color: var(--green);
  background: rgba(44, 85, 72, 0.06);
  box-shadow: 0 0 0 1px var(--green);
}
.draft-check {
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.2rem;
  accent-color: var(--green);
  cursor: pointer;
}
.draft-body { min-width: 0; }
.draft-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.85rem;
  align-items: center;
  font-family: var(--sans);
  font-size: 0.75rem;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.draft-meta audio {
  max-width: 100%;
  height: 2rem;
}
.draft-text {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.45;
  color: var(--ink);
}
.send-hint {
  margin: 0.35rem 0 0;
}
#labSendText:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ============================================================
   EDITORIAL HOME — documentary / family archive (not SaaS)
   ============================================================ */
.editorial-home {
  color: var(--ink);
  padding-top: 0.35rem;
}
.editorial-home .ed-announce {
  margin: 0 0 2rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--muted);
  letter-spacing: 0.01em;
}

/* Hero: ~7/5 asymmetrical, photo-led */
.ed-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.22fr);
  gap: clamp(1.75rem, 4.5vw, 4rem);
  align-items: end;
  margin-bottom: 3.5rem;
  min-height: min(74dvh, 640px);
}
.ed-hero-copy {
  padding-bottom: 0.75rem;
  max-width: 34rem;
}
.ed-kicker {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
  font-family: var(--sans);
}
.ed-hero h1 {
  margin: 0 0 1.1rem;
  font-family: var(--serif);
  font-size: clamp(2.35rem, 4.6vw, 3.55rem);
  line-height: 1.08;
  letter-spacing: -0.025em;
  font-weight: 600;
  max-width: 11ch;
  color: var(--ink);
}
.ed-lede {
  margin: 0 0 1.6rem;
  font-size: 1.1rem;
  line-height: 1.55;
  color: var(--muted);
  max-width: 36ch;
}
.ed-measure {
  max-width: 40rem;
  line-height: 1.65;
  color: var(--muted);
}
.ed-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.35rem;
  margin-bottom: 1.1rem;
}
.ed-text-link {
  color: var(--green);
  text-decoration: none;
  font-size: 0.95rem;
  border-bottom: 1px solid color-mix(in srgb, var(--green) 35%, transparent);
  padding-bottom: 0.1rem;
}
.ed-text-link:hover { border-bottom-color: var(--green); }
.ed-text-link.muted { color: var(--muted); border-color: var(--line); }
.ed-quiet {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.5;
  max-width: 42ch;
}

/* Photo is the hero object — play attached, no dashboard card */
.ed-hero-photo {
  margin: 0;
  position: relative;
}
.ed-hero-photo-frame {
  position: relative;
  margin: 0;
}
.ed-hero-photo-frame > img {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(74dvh, 660px);
  object-fit: cover;
  object-position: 50% 22%;
  border-radius: 0;
}
.ed-play {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: 1px solid rgba(250, 248, 243, 0.35);
  background: var(--green);
  color: #faf8f3;
  font-size: 0.78rem;
  cursor: pointer;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  padding: 0;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease);
}
.ed-play:hover { background: var(--green-deep); }
.ed-play:active { transform: scale(0.97); }
.ed-play.is-playing,
.ed-listen-btn.is-playing .ed-play {
  background: var(--green-deep);
}
.ed-play-on-photo {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  width: 3.1rem;
  height: 3.1rem;
  box-shadow: 0 10px 28px rgba(15, 42, 33, 0.35);
}
.ed-wave-light.is-animating i,
.ed-listen-btn.is-playing .ed-wave i {
  animation: ed-wave-pulse 0.9s ease-in-out infinite alternate;
}
.ed-listen-btn.is-playing .ed-wave i:nth-child(2) { animation-delay: 0.08s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(3) { animation-delay: 0.16s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(4) { animation-delay: 0.24s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(5) { animation-delay: 0.12s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(6) { animation-delay: 0.2s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(7) { animation-delay: 0.05s; }
.ed-listen-btn.is-playing .ed-wave i:nth-child(8) { animation-delay: 0.18s; }
@keyframes ed-wave-pulse {
  from { opacity: 0.35; transform: scaleY(0.55); }
  to { opacity: 1; transform: scaleY(1); }
}
@media (prefers-reduced-motion: reduce) {
  .ed-listen-btn.is-playing .ed-wave i { animation: none; }
}
.ed-photo-cap {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-top: 0.9rem;
  font-size: 0.92rem;
}
.ed-photo-cap strong { display: block; color: var(--ink); font-weight: 600; }
.ed-photo-cap em {
  display: block;
  font-style: normal;
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 0.15rem;
}
.ed-photo-quote {
  margin: 1rem 0 0;
  padding: 0;
  border: 0;
  font-family: var(--serif);
  font-size: 1.22rem;
  line-height: 1.4;
  color: var(--ink);
  max-width: 26ch;
}

@media (max-width: 900px) {
  .ed-hero {
    grid-template-columns: 1fr;
    min-height: 0;
    gap: 1.5rem;
  }
  .ed-hero h1 { max-width: none; font-size: clamp(2rem, 8vw, 2.65rem); }
  .ed-hero-photo-frame > img { max-height: 380px; }
}

/* Act spacing — generous, publication-like */
.ed-act {
  padding: clamp(3.25rem, 6vw, 4.75rem) 0;
  border-top: 1px solid var(--line);
}
.ed-act h2 {
  margin: 0 0 1.35rem;
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3.1vw, 2.45rem);
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.02em;
  max-width: 18ch;
  color: var(--ink);
}

/* Loss spread: large photo + sequential lines */
.ed-loss {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(1.75rem, 4.5vw, 4rem);
  align-items: center;
}
.ed-loss-photo { margin: 0; }
.ed-loss-photo img {
  width: 100%;
  display: block;
  object-fit: cover;
  max-height: 520px;
  aspect-ratio: 1 / 1;
}
.ed-loss-lines {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
}
.ed-loss-lines li {
  font-family: var(--serif);
  font-size: clamp(1.12rem, 1.8vw, 1.28rem);
  line-height: 1.5;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}
.ed-loss-lines li:first-child { border-top: 1px solid var(--line); }
@media (max-width: 900px) {
  .ed-loss { grid-template-columns: 1fr; }
  .ed-loss-photo img { max-height: 360px; }
}

/* Transformation sequence — exhibition, not panels */
.ed-sequence {
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
  max-width: 44rem;
}
.ed-label {
  margin: 0 0 0.55rem;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
}
.ed-serif-lg {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.5vw, 1.85rem);
  line-height: 1.4;
  color: var(--ink);
}
.ed-serif-md {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.22rem;
  line-height: 1.45;
  color: var(--ink);
  font-style: italic;
}
/* Selective dark: listening mode */
.ed-listen-band {
  background: #123e32;
  color: #e8ede9;
  padding: 1.35rem 1.5rem;
  margin-left: 0;
  max-width: 36rem;
}
.ed-listen-band .ed-label { color: #829487; }
.ed-listen-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  border: 0;
  background: transparent;
  font: inherit;
  color: inherit;
  cursor: pointer;
  padding: 0.35rem 0;
}
.ed-play-light {
  background: #f4f0e7;
  color: #123e32;
  border-color: transparent;
}
.ed-play-light:hover { background: #fff; color: #123e32; }
.ed-wave {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 1.4rem;
  width: 5.5rem;
}
.ed-wave i {
  flex: 1;
  background: var(--green);
  border-radius: 1px;
  display: block;
  min-height: 25%;
  opacity: 0.55;
}
.ed-wave-light i {
  background: #a8c4b4;
  opacity: 0.85;
}
.ed-wave i:nth-child(odd) { height: 45%; }
.ed-wave i:nth-child(even) { height: 85%; }
.ed-wave i:nth-child(3n) { height: 60%; }
/* Approved wisdom: warm paper artifact */
.ed-paper {
  background: var(--paper);
  padding: 1.85rem 1.85rem 1.6rem;
  border-left: 3px solid var(--brass);
  max-width: 38rem;
  box-shadow: 0 1px 0 rgba(27, 30, 26, 0.04);
}
.ed-pull {
  margin: 0 0 1.1rem;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.3vw, 1.8rem);
  line-height: 1.35;
  color: var(--ink);
}
.ed-provenance {
  margin: 0;
  font-size: 0.82rem;
  color: var(--sage);
  letter-spacing: 0.02em;
}

/* Ease: photo + three large statements */
.ed-ease-spread {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(1.75rem, 4.5vw, 4rem);
  align-items: center;
}
.ed-ease-photo { margin: 0; }
.ed-ease-photo img {
  width: 100%;
  display: block;
  object-fit: cover;
  max-height: 480px;
  aspect-ratio: 4 / 3;
}
.ed-ease-item {
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
}
.ed-ease-item:first-of-type { border-top: 1px solid var(--line); }
.ed-ease-item strong {
  display: block;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 2vw, 1.45rem);
  margin-bottom: 0.35rem;
  color: var(--ink);
  font-weight: 600;
}
.ed-ease-item p { margin: 0; color: var(--muted); font-size: 1.02rem; }
@media (max-width: 900px) {
  .ed-ease-spread { grid-template-columns: 1fr; }
}

/* Timeline — editorial, not process cards */
.ed-timeline {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  border-left: 1px solid var(--line);
  max-width: 36rem;
}
.ed-timeline-wide { max-width: 40rem; }
.ed-timeline li {
  display: grid;
  grid-template-columns: 3.25rem 1fr;
  gap: 0.85rem;
  padding: 0 0 1.85rem 1.35rem;
  position: relative;
}
.ed-timeline li:last-child { padding-bottom: 0; }
.ed-timeline li::before {
  content: "";
  position: absolute;
  left: -3.5px;
  top: 0.45rem;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}
.ed-tn {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--sage);
  letter-spacing: 0.06em;
  padding-top: 0.15rem;
}
.ed-timeline strong {
  display: block;
  font-size: 1.02rem;
  margin-bottom: 0.25rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}
.ed-timeline p { margin: 0; color: var(--muted); line-height: 1.5; font-size: 1.02rem; }

/* Commissioned offer — not SaaS pricing table */
.ed-offer .ed-lede { margin-bottom: 2rem; }
.ed-deliverables {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem 2.5rem;
  margin-bottom: 2.75rem;
  padding: 1.75rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.ed-deliverables h3 {
  margin: 0 0 0.85rem;
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ink);
}
.ed-deliverables ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ed-deliverables li {
  padding: 0.4rem 0;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.98rem;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
}
.ed-deliverables li:last-child { border-bottom: 0; }
.ed-invest {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1.5rem;
  margin-bottom: 2.75rem;
}
.ed-price-label {
  margin: 0 0 0.35rem;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage);
}
.ed-price {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.5rem, 4vw, 3.1rem);
  font-weight: 600;
  color: var(--green-deep);
  line-height: 1;
}
.ed-invest-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
}
.ed-guarantee-inline {
  max-width: 42rem;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--line);
}
.ed-guarantee-inline h3 {
  margin: 0 0 0.85rem;
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2.2vw, 1.55rem);
  line-height: 1.3;
  color: var(--ink);
  max-width: 28ch;
}
.ed-plain-list {
  margin: 0.75rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
}
.ed-plain-list li { margin: 0.3rem 0; }
@media (max-width: 800px) {
  .ed-deliverables { grid-template-columns: 1fr; gap: 1.5rem; }
}

/* Output gallery — horizontal artifact strip */
.ed-output-scroll {
  margin: 1.75rem -0.25rem 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.5rem;
}
.ed-output-row {
  display: flex;
  gap: 1.15rem;
  width: max-content;
  min-width: 100%;
  padding: 0 0.25rem;
}
.ed-output {
  margin: 0;
  width: min(280px, 72vw);
  flex: 0 0 auto;
  scroll-snap-align: start;
}
.ed-output img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: var(--paper);
  margin-bottom: 0.7rem;
}
.ed-output figcaption strong {
  display: block;
  font-size: 0.98rem;
  margin-bottom: 0.15rem;
  color: var(--ink);
}
.ed-output figcaption span {
  color: var(--muted);
  font-size: 0.88rem;
}

/* Trust + editorial FAQ (rules, not cards) */
.ed-trust-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem 3rem;
  margin: 1.5rem 0 2.75rem;
  max-width: 52rem;
}
.ed-trust-item strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.18rem;
  margin-bottom: 0.4rem;
  color: var(--ink);
}
.ed-trust-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
  font-size: 0.98rem;
  max-width: 32ch;
}
.ed-subhead {
  margin: 2.25rem 0 0.25rem;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.2vw, 1.65rem);
  font-weight: 600;
  color: var(--ink);
  max-width: 22ch;
}
.ed-faq {
  border-top: 1px solid var(--line);
  margin-top: 1rem;
}
.ed-faq details {
  border-bottom: 1px solid var(--line);
  padding: 1.15rem 0;
}
.ed-faq summary {
  cursor: pointer;
  font-size: clamp(1.08rem, 1.6vw, 1.2rem);
  font-weight: 600;
  list-style: none;
  font-family: var(--serif);
  line-height: 1.35;
  color: var(--ink);
  padding-right: 2rem;
  position: relative;
}
.ed-faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 0;
  font-family: var(--sans);
  font-weight: 400;
  color: var(--sage);
  font-size: 1.25rem;
}
.ed-faq details[open] summary::after { content: "\2212"; }
.ed-faq summary::-webkit-details-marker { display: none; }
.ed-faq p {
  margin: 0.9rem 0 0.25rem;
  color: var(--muted);
  max-width: 42rem;
  line-height: 1.6;
  font-size: 1.02rem;
}
@media (max-width: 700px) {
  .ed-trust-grid { grid-template-columns: 1fr; gap: 1.35rem; }
}

/* Founder editorial */
.ed-founder-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1.75rem, 4.5vw, 3.5rem);
  align-items: start;
}
.ed-founder-photo { margin: 0; }
.ed-founder-photo img {
  width: 100%;
  display: block;
  max-height: 460px;
  object-fit: cover;
  object-position: 50% 30%;
  aspect-ratio: 4 / 5;
}
.ed-founder-photo figcaption { margin-top: 0.55rem; }
.ed-founder p { margin: 0 0 1.05rem; }
.ed-sign {
  margin: 1.5rem 0 0 !important;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.35rem;
  color: var(--ink);
}
@media (max-width: 800px) {
  .ed-founder-grid { grid-template-columns: 1fr; }
  .ed-founder-photo img { max-height: 320px; aspect-ratio: 16 / 10; }
}

/* Final CTA */
.ed-final {
  padding: 4.25rem 0 2rem;
  border-top: 1px solid var(--line);
  text-align: left;
}
.ed-final h2 {
  margin: 0 0 1.6rem;
  font-family: var(--serif);
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  line-height: 1.12;
  max-width: 14ch;
  color: var(--ink);
}

/* Marketing primary buttons: sharp archival, not pill SaaS */
/* Brand CTAs: full-pill primary (guide type hierarchy) */
body.marketing-mode .btn.primary,
body.ceremony-mode .btn.primary,
body.app-mode:not(.studio-mode) .btn.primary {
  border-radius: var(--radius-pill);
  background: var(--green);
  border-color: var(--green);
  color: #f4f0e7;
  padding: 0.85rem 1.5rem;
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.82rem;
}
body.marketing-mode .btn.primary:hover,
body.ceremony-mode .btn.primary:hover,
body.app-mode:not(.studio-mode) .btn.primary:hover {
  background: var(--green-deep);
  border-color: var(--green-deep);
  color: #f4f0e7;
}
body.marketing-mode .btn.ghost,
body.ceremony-mode .btn.ghost,
body.app-mode:not(.studio-mode) .btn.ghost {
  border-radius: var(--radius-pill);
  border-color: var(--line);
  font-weight: 500;
}
body.marketing-mode .btn.primary.lg,
body.ceremony-mode .btn.primary.lg {
  padding: 0.95rem 1.75rem;
  font-size: 0.84rem;
}
/* Editorial serif on major display headings */
body.marketing-mode h1,
body.ceremony-mode h1,
body.marketing-mode .ed-hero h1,
body.marketing-mode .journey-head h1 {
  font-family: var(--serif);
  font-weight: 500;
  color: var(--ink);
}
/* Eyebrow: 12–14px sans bold uppercase */
.ed-kicker,
.ed-label,
.journey-step,
.story-card .eyebrow,
.story-welcome .eyebrow,
.ceremony-panel .eyebrow {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green);
}

/* ── Path-aware start + journey wizards ── */
.start-paths .path-grid {
  gap: 1rem;
}
.path-choice {
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 10rem;
}
.path-choice h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.25rem;
}
.path-choice p { margin: 0; color: var(--muted); line-height: 1.45; }
.path-result {
  margin-top: auto !important;
  padding-top: 0.75rem;
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  color: var(--sage) !important;
  border-top: 1px solid var(--line);
}
.path-choice.selected,
.path-choice:hover {
  border-color: var(--green);
}

.journey-setup {
  max-width: 40rem;
  padding-bottom: 4rem;
}
.journey-head {
  margin-bottom: 1.75rem;
}
.journey-head h1 {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
  line-height: 1.15;
  margin: 0.5rem 0 0.75rem;
  font-weight: 600;
}
.journey-step {
  margin: 0.75rem 0 0;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sage);
}
.journey-help {
  color: var(--muted);
  margin: 0 0 1rem;
  line-height: 1.5;
}
.journey-input {
  width: 100%;
  font: inherit;
  font-size: 1.05rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--paper);
  color: var(--ink);
  margin-bottom: 1.25rem;
}
.journey-input:focus {
  outline: 2px solid color-mix(in srgb, var(--green) 40%, transparent);
  border-color: var(--green);
}
.journey-choices {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}
.journey-choice {
  text-align: left;
  font: inherit;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  line-height: 1.4;
}
.journey-choice:hover,
.journey-choice.selected {
  border-color: var(--green);
  background: color-mix(in srgb, var(--green) 6%, var(--paper));
}
.journey-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}
.journey-actions.stack {
  flex-direction: column;
  align-items: stretch;
}
.journey-actions.stack .btn { justify-content: center; }

.invite-preview {
  margin: 0 0 1.75rem;
  padding: 1.5rem 1.5rem 1.25rem;
  background: var(--paper);
  border-left: 3px solid var(--brass);
  font-family: var(--serif);
  font-size: 1.2rem;
  line-height: 1.45;
}
.invite-preview .invite-why {
  font-size: 1.05rem;
  color: var(--muted);
  font-style: italic;
}
.invite-preview .soft {
  font-family: var(--sans);
  font-size: 0.92rem;
  margin-top: 1rem;
}

.sponsor-progress {
  margin: 0.75rem 0 0;
  padding-left: 1.25rem;
  color: var(--muted);
}
.sponsor-progress li {
  margin: 0.45rem 0;
  line-height: 1.4;
}
.sponsor-progress li.is-done {
  color: var(--ink);
  font-weight: 600;
}

body.marketing-mode:has(.journey-setup) .main {
  max-width: 720px;
}

/* Progressive intake */
.progressive-intake .journey-lede {
  max-width: 38ch;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.5;
}
.journey-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 0.45rem;
}
.journey-label .soft { font-weight: 400; }
.boundary-details {
  margin: 1.25rem 0 1.5rem;
  border-top: 1px solid var(--line);
  padding-top: 0.85rem;
}
.boundary-details summary {
  cursor: pointer;
  font-size: 0.98rem;
  color: var(--ink);
  font-weight: 600;
  list-style: none;
}
.boundary-details summary::-webkit-details-marker { display: none; }
.boundary-details[open] summary { margin-bottom: 0.65rem; }
.preview-card {
  background: var(--paper);
  border-left: 3px solid var(--brass);
  padding: 1.25rem 1.35rem;
  margin-bottom: 1.5rem;
}
.preview-summary {
  margin: 0 0 1rem;
  color: var(--muted);
  line-height: 1.55;
  font-size: 1.05rem;
}
.preview-question {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  line-height: 1.4;
  color: var(--ink);
  font-style: italic;
}

/* ── Story Room mobile sticky + keyboard-safe (brand5) ── */
.sr-primary-cta {
  min-height: 3rem;
  min-width: min(100%, 16rem);
  font-size: 1.05rem !important;
  padding: 0.85rem 1.35rem !important;
}
.sr-timer.paused {
  color: var(--muted);
  border-style: dashed;
}
.sr-sticky-bar {
  display: none;
}
.story-room-shell {
  --kb-inset: 0px;
}

@media (max-width: 768px) {
  body.ceremony-mode .story-room-shell {
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom) + var(--kb-inset, 0px));
    min-height: min(100dvh, 100svh);
  }
  .voice-first .sr-controls {
    /* Primary stays large; secondary actions move to sticky bar on small screens */
    flex-direction: column;
    gap: 0.65rem;
  }
  .voice-first .sr-controls .btn.ghost {
    display: none; /* Pause/End live in sticky bar */
  }
  .voice-first .sr-controls .sr-primary-cta {
    width: 100%;
    max-width: 22rem;
  }
  .sr-sticky-bar {
    display: grid;
    grid-template-columns: auto auto 1fr;
    gap: 0.45rem;
    align-items: center;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    padding: 0.55rem 0.75rem calc(0.55rem + env(safe-area-inset-bottom));
    background: color-mix(in srgb, var(--paper) 92%, transparent);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
    box-shadow: 0 -8px 24px rgba(18, 40, 32, 0.06);
  }
  .sr-sticky-bar .sr-primary-cta {
    width: 100%;
    min-width: 0;
    justify-self: stretch;
  }
  .sr-sticky-side {
    min-height: 2.75rem;
    min-width: 4.25rem;
    padding-inline: 0.7rem !important;
  }
  .type-fallback-panel {
    width: 100%;
    max-width: none;
    position: sticky;
    bottom: calc(4.75rem + env(safe-area-inset-bottom) + var(--kb-inset, 0px));
    z-index: 35;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0.75rem 0.85rem;
    box-shadow: var(--shadow);
    margin-bottom: 0.5rem;
  }
  body.sr-type-open .sr-sticky-bar {
    /* Type panel owns the lower chrome; keep End accessible via sticky left */
    opacity: 0.97;
  }
  .type-fallback-panel .response-field {
    font-size: 16px; /* prevent iOS zoom on focus */
    min-height: 5.5rem;
  }
  .sr-guide-line {
    font-size: clamp(1.05rem, 4.5vw, 1.35rem);
  }
  .sr-stage .voice-orb {
    transform: scale(0.92);
  }
}

@media (min-width: 769px) {
  .sr-sticky-bar {
    display: none !important;
  }
}
