/* Layout and components. Tokens live in tokens.css (mirror of BRAND.md). */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); }
a:hover { color: var(--accent-deep); }
h1, h2, h3 { margin: 0; font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; }
p { margin: 0; }
button { font: inherit; }
.mono { font-family: var(--font-mono); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.page { min-height: 100vh; display: flex; flex-direction: column; }
.site-header, .site-main, .site-footer { width: 100%; max-width: 1180px; margin: 0 auto; padding-left: 48px; padding-right: 48px; }
.site-header { display: flex; justify-content: space-between; align-items: center; padding-top: 28px; padding-bottom: 28px; gap: 16px; }
.wordmark { font-family: var(--font-display); font-weight: 600; font-size: 18px; letter-spacing: -0.02em; }
.brand-logo { display: block; max-height: 32px; max-width: 160px; width: auto; height: auto; object-fit: contain; }
.brand-logo.blend { mix-blend-mode: multiply; }
.header-note { font-size: 14px; color: var(--ink-soft); }
.site-main { flex: 1 1 auto; padding-top: 24px; padding-bottom: 72px; }
.site-footer { padding-top: 20px; padding-bottom: 20px; font-size: 13px; color: var(--ink-faint); }

.display { font-size: clamp(2.4rem, 5.2vw, 4.2rem); line-height: 1.04; letter-spacing: -0.03em; text-wrap: balance; max-width: 18ch; }
.lede { font-size: 19px; color: var(--ink-soft); max-width: 58ch; }
.message { display: flex; flex-direction: column; gap: 20px; padding-top: 8vh; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 24px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border-radius: var(--radius-pill); border: 0;
  background: var(--accent); color: #fff; font-size: 16px; font-weight: 500; text-decoration: none; cursor: pointer;
  transition: background var(--dur) var(--ease-out);
}
.btn:hover { background: var(--accent-deep); color: #fff; }
.btn:disabled { opacity: 0.6; cursor: default; }
.btn-outline { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
.btn-outline:hover { background: var(--accent-soft); color: var(--accent-deep); }
.link-quiet { color: var(--ink-soft); text-decoration: underline; text-underline-offset: 3px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; font-weight: 500; color: var(--ink-soft); }
.input {
  min-height: 52px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; color: var(--ink); font: inherit; font-size: 16px; width: 100%;
}
.input.mono { font-family: var(--font-mono); }

@media (max-width: 720px) {
  .site-header, .site-main, .site-footer { padding-left: 16px; padding-right: 16px; }
  body { font-size: 16px; }
  .header-note { display: none; }
}

/* ---- shared bits ---------------------------------------------------- */
.row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.row.spread, .spread { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.stack-tight { display: flex; flex-direction: column; gap: 6px; }
.small { font-size: 14px; }
.soft { color: var(--ink-soft); }
.faint { color: var(--ink-faint); }
.accent { color: var(--accent); }
.divider { height: 1px; background: var(--line); margin: 18px 0; }
.fine { font-size: 13px; color: var(--ink-faint); text-align: center; max-width: 40ch; margin: 0 auto; }
.section-title { font-family: var(--font-display); font-weight: 500; font-size: 18px; }
.small-h { font-size: 15px; font-family: var(--font-sans); font-weight: 600; letter-spacing: 0; margin-bottom: 12px; color: var(--ink-soft); text-transform: uppercase; }
.medium-display { font-size: clamp(2rem, 4vw, 3.2rem); max-width: 22ch; }
.small-display { font-size: clamp(2rem, 4vw, 3rem); max-width: 22ch; }
.btn-danger { background: var(--danger); }
.btn-danger:hover { background: #8f1e18; }
button.link-quiet { background: none; border: 0; padding: 0; cursor: pointer; font-size: 15px; }
.pill, .pill-live, .pill-warn, .pill-danger {
  display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: var(--radius-pill);
  font-size: 13px; font-weight: 500; background: var(--paper-deep); color: var(--ink-soft); width: fit-content;
}
.pill-live { background: var(--accent-soft); color: var(--accent-deep); }
.pill-warn { background: var(--warn-soft); color: var(--warn); }
.pill-danger { background: #f7dfdd; color: var(--danger); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.status-dot.pending { background: var(--warn); animation: blink 1.2s ease-in-out infinite; }
.status-line { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; color: var(--ink-soft); }
.form-msg { font-size: 14px; min-height: 0; }
.form-msg:empty { display: none; }
.form-msg.error { color: var(--danger); }
.form-msg.warn { color: var(--warn); }
.dot { display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: currentColor; margin: 0 1px; animation: blink 1.2s ease-in-out infinite; }
.dot:nth-child(2) { animation-delay: .2s; }
.dot:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }

/* ---- greeting and incoming-call notice (boards 1, phone) ------------ */
.notice-screen { display: grid; grid-template-columns: 1.15fr 1fr; gap: 56px; align-items: center; min-height: 64vh; }
.greeting { display: flex; flex-direction: column; gap: 24px; }
.notice {
  background: var(--ink); color: #f4f1ea; border-radius: 32px; padding: 26px 26px 22px;
  box-shadow: 0 30px 80px rgb(26 29 31 / 28%); display: flex; flex-direction: column; gap: 26px;
  animation: notice-in .6s var(--ease-out) both;
}
.notice[hidden] { display: none; }
.notice .faint { color: #8d9196; }
.notice .pill-live { background: rgb(255 255 255 / 10%); color: var(--accent-on-dark, #bfe6d2); }
.notice-top { display: flex; justify-content: space-between; align-items: center; }
.caller { display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.caller-text { display: flex; flex-direction: column; gap: 4px; }
.caller-name { font-family: var(--font-display); font-size: 26px; font-weight: 500; letter-spacing: -0.02em; }
.caller-sub { color: #b8bcc0; font-size: 15px; }
.ringing { color: #8d9196; font-size: 13px; }
.ring-wrap { position: relative; width: 150px; height: 150px; display: grid; place-items: center; }
.ring { position: absolute; inset: 30px; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; animation: ring 2.1s var(--ease-out) infinite; }
.ring:nth-child(2) { animation-delay: .7s; }
.ring:nth-child(3) { animation-delay: 1.4s; }
.avatar { width: 92px; height: 92px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; animation: wobble 2.1s ease-in-out infinite; position: relative; }
.notice-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.round-action { background: none; border: 0; color: #d9dcdf; display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 14px; cursor: pointer; }
.round { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; border: 0; cursor: pointer; transition: transform var(--dur) var(--ease-out); }
.round-action:hover .round { transform: scale(1.06); }
.round.amber { background: #3a3326; color: #f0b660; }
.round.outline { background: transparent; color: inherit; border: 1.5px solid rgb(255 255 255 / 30%); }
.round.accept-ring { width: 76px; height: 76px; background: var(--accent); color: #fff; animation: breathe 1.8s ease-in-out infinite; box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent); }
.round-action.accept { color: #fff; font-weight: 600; }
.slide { display: none; }
/* Answering: from accept until the call is live (plan 2026-10-23-1545 U1). */
.answer-status { text-align: center; font-size: 17px; color: #f4f1ea; }
/* Kept in the accessibility tree while idle, so the first status is announced. */
.notice:not(.answering) .answer-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.notice.answering .notice-actions, .notice.answering .ringing, .notice.answering .fine { display: none; }
.phone-greeting { display: none; }
.ring-later { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.ring-later[hidden] { display: none; }

@keyframes ring { 0% { transform: scale(.7); opacity: .9; } 100% { transform: scale(1.6); opacity: 0; } }
@keyframes wobble { 0%, 60%, 100% { transform: rotate(0); } 64% { transform: rotate(-9deg); } 68% { transform: rotate(8deg); } 72% { transform: rotate(-6deg); } 76% { transform: rotate(4deg); } 80% { transform: rotate(0); } }
@keyframes breathe { 0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); } 50% { transform: scale(1.06); box-shadow: 0 0 0 14px color-mix(in srgb, var(--accent) 0%, transparent); } }
@keyframes notice-in { from { transform: translateY(18px) scale(.98); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes shimmer { 0% { background-position: -120px 0; } 100% { background-position: 220px 0; } }
@keyframes nudge { 0%, 70%, 100% { transform: translateX(0); } 80% { transform: translateX(14px); } 90% { transform: translateX(0); } }

/* ---- live call (board 3) ---------------------------------------------- */
.live-screen { display: grid; grid-template-columns: 380px 1fr; gap: 32px; align-items: start; }
.live-screen[hidden], .typed-screen[hidden], .state-screen[hidden], .notice-screen[hidden] { display: none; }
.live-card { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; padding: 36px 24px; position: sticky; top: 24px; }
.live-ring { position: relative; width: 120px; height: 120px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 30%, transparent); transition: box-shadow .3s; }
.live-ring.speaking { animation: breathe 1.2s ease-in-out infinite; }
/* The merchant's voice: an ink outline that grows with their mic level, apart from the agent's green breathe. */
.live-ring::after { content: ''; position: absolute; inset: -8px; border-radius: 50%; border: 3px solid var(--ink); opacity: 0; transform: scale(calc(1 + var(--level, 0) * .35)); transition: transform .08s linear, opacity .2s; pointer-events: none; }
.live-ring.hearing::after { opacity: .5; }
.bubble.pending .dots { padding: 6px 0; color: var(--ink-faint); }
.bubble.pending .dot { width: 7px; height: 7px; margin: 0 2px; }
.live-title { font-family: var(--font-display); font-size: 24px; font-weight: 500; }
.live-timer { font-size: 22px; }
.live-controls { display: flex; gap: 14px; align-items: center; margin-top: 8px; }
.live-controls .round { width: 52px; height: 52px; color: var(--ink); border-color: var(--line); background: var(--card); }
.live-controls .round[aria-pressed="true"] { background: var(--warn-soft); color: var(--warn); border-color: var(--warn); }
.transcript-wrap { display: flex; flex-direction: column; gap: 14px; }
.transcript-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.transcript { display: flex; flex-direction: column; gap: 12px; max-height: 62vh; overflow-y: auto; padding-right: 4px; }
.bubble { max-width: 80%; padding: 12px 16px; border-radius: 18px; display: flex; flex-direction: column; gap: 4px; animation: notice-in .3s var(--ease-out) both; }
.bubble .who { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-faint); }
.bubble.agent { background: var(--accent-soft); align-self: flex-start; border-bottom-left-radius: 6px; }
.bubble.user { background: var(--card); border: 1px solid var(--line); align-self: flex-end; border-bottom-right-radius: 6px; }

/* ---- typed (board 4) ---------------------------------------------- */
.typed-screen { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 18px; }
.typed-head { display: flex; flex-direction: column; gap: 6px; }
.typed-card { display: flex; flex-direction: column; gap: 18px; }
.typed-card .transcript { min-height: 240px; }
.typed-form { display: flex; gap: 12px; align-items: flex-end; }
.typed-input { min-height: 56px; padding: 14px 16px; resize: vertical; }
.typed-foot { text-align: right; }

/* ---- edge states ---------------------------------------------- */
.state-screen { display: flex; flex-direction: column; gap: 22px; max-width: 720px; padding-top: 6vh; }
.copy-card { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 16px 20px; }
.copy-card .mono { word-break: break-all; font-size: 14px; }

/* ---- cold form ---------------------------------------------- */
.cold { display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: center; min-height: 60vh; }
.cold-form { display: flex; flex-direction: column; gap: 16px; padding: 28px; box-shadow: var(--shadow); }

/* ---- post-call: read-back, steps, cards (board 5) ------------------ */
.postcall { display: flex; flex-direction: column; gap: 56px; max-width: 900px; }
.readback-section { display: flex; flex-direction: column; gap: 24px; }
.readback { display: flex; flex-direction: column; gap: 14px; font-size: 19px; border-left: 3px solid var(--accent); padding-left: 22px; max-width: 64ch; }
.readback.waiting { color: var(--ink-soft); border-left-color: var(--line); }
.readback.arrived p { animation: notice-in .5s var(--ease-out) both; }

/* ---- dashboard: the initial audit and the goals form (form-only plan U5) ---- */
.audit-body { display: flex; flex-direction: column; gap: 16px; max-width: 64ch; }
.audit-finding { font-size: 19px; border-left: 3px solid var(--accent); padding-left: 22px; }
.audit-waiting { color: var(--ink-soft); }
.audit-body.arrived > * { animation: notice-in .5s var(--ease-out) both; }
.goals-form textarea.input { min-height: 64px; padding: 12px 16px; resize: vertical; line-height: 1.4; }
.steps-section { display: flex; flex-direction: column; gap: 16px; }
.steps-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 6px; }
.steps-head h2 { font-size: 32px; }
.progress { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; min-width: 180px; }
.bar { width: 180px; height: 8px; border-radius: 999px; background: var(--paper-deep); overflow: hidden; }
.bar-fill { height: 100%; width: 0; background: var(--accent); border-radius: 999px; transition: width .6s var(--ease-out); }
.step { background: var(--card); border: 1px solid var(--line); border-radius: 22px; transition: border-color var(--dur), background var(--dur); }
.step.open { border-color: var(--accent); box-shadow: var(--shadow); }
.step.done { background: var(--accent-soft); border-color: transparent; }
.step.locked { opacity: .72; }
.step-head { display: flex; align-items: center; gap: 22px; width: 100%; background: none; border: 0; padding: 22px 24px; text-align: left; cursor: pointer; color: inherit; }
.step-text { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.step-title { font-family: var(--font-display); font-size: 21px; font-weight: 500; letter-spacing: -0.01em; }
.step-sub { color: var(--ink-soft); font-size: 15px; }
.chevron { color: var(--ink-faint); transition: transform var(--dur) var(--ease-out); flex: none; }
.step.open .chevron { transform: rotate(180deg); }
.step.done .chevron { opacity: 0; }
.checkbox {
  position: relative; flex: none; width: 56px; height: 56px; border-radius: 16px; border: 2.5px solid var(--line);
  background: #fff; display: grid; place-items: center; color: #fff; transition: background var(--dur), border-color var(--dur);
}
.checkbox svg { opacity: 0; }
.tick-path { stroke-dasharray: 24; stroke-dashoffset: 24; }
.step.done .checkbox { background: var(--accent); border-color: var(--accent); }
.step.done .checkbox svg { opacity: 1; }
.step.done .tick-path { stroke-dashoffset: 0; }
.step.skipped .checkbox { border-style: dashed; }
.step.celebrate .checkbox { animation: pop .5s var(--ease-out); }
.step.celebrate .tick-path { animation: tick .45s .15s var(--ease-out) both; }
.step.celebrate .burst { animation: burst .7s var(--ease-out); }
.step.celebrate { animation: settle .9s var(--ease-out); }
.burst { position: absolute; inset: -6px; border-radius: 20px; border: 3px solid var(--accent); opacity: 0; pointer-events: none; }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.25); } 70% { transform: scale(.94); } 100% { transform: scale(1); } }
@keyframes tick { from { stroke-dashoffset: 24; } to { stroke-dashoffset: 0; } }
@keyframes burst { 0% { transform: scale(.8); opacity: .9; } 100% { transform: scale(1.8); opacity: 0; } }
@keyframes settle { 0% { background: var(--card); } 100% { background: var(--accent-soft); } }
.step-body { padding: 0 24px 26px 102px; display: flex; flex-direction: column; gap: 18px; }
.step-body[hidden] { display: none; }
.howto { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; color: var(--ink-soft); }
.step-form { display: flex; flex-direction: column; gap: 14px; max-width: 520px; }
.all-done { display: flex; gap: 14px; align-items: flex-start; padding: 18px 22px; border-radius: 18px; background: var(--ink); color: #f4f1ea; animation: notice-in .5s var(--ease-out) both; }
.all-done[hidden] { display: none; }
.all-done .accent { color: var(--accent-on-dark-strong, #8fd6b2); font-size: 22px; line-height: 1; }
.cards-section { display: flex; flex-direction: column; gap: 20px; }
.cards-section h2 { font-size: 28px; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.audit-card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 22px; display: flex; flex-direction: column; gap: 10px; }
.audit-card h3 { font-size: 20px; }
.audit-card p { color: var(--ink-soft); font-size: 15px; flex: 1; }
.card-status { font-size: 13px; color: var(--accent-deep); font-weight: 500; }
.talk-again { text-align: center; }

/* ---- operator ---------------------------------------------- */
.op .site-main { max-width: 1180px; }
.op-header .row { gap: 12px; }
.op-nav { display: flex; gap: 20px; font-size: 15px; }
.op-nav a { color: var(--ink-soft); text-decoration: none; }
.op-nav a.active { color: var(--ink); font-weight: 600; }
.op h1 { font-size: 34px; margin-bottom: 18px; }
.op h2 { font-size: 22px; margin-bottom: 12px; }
.op-grid { display: grid; grid-template-columns: 400px 1fr; gap: 32px; align-items: start; }
.mint-form { display: flex; flex-direction: column; gap: 16px; }
.entry-choice { border: 0; padding: 0; margin: 0; }
.entry-choice legend { font-size: 14px; font-weight: 500; color: var(--ink-soft); margin-bottom: 6px; }
.check { display: flex; gap: 10px; align-items: center; font-size: 15px; color: var(--ink-soft); }
.link-box { flex: 1; min-width: 0; padding: 14px 16px; background: var(--paper); border-radius: 12px; word-break: break-all; font-size: 14px; }
.kv { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; }
.kv li { display: flex; justify-content: space-between; gap: 18px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv li:last-child { border-bottom: 0; }
.kv li > :last-child { color: var(--ink-soft); text-align: right; }
.finding-form { display: flex; flex-direction: column; gap: 12px; }
.finding-input { min-height: 96px; padding: 12px 16px; resize: vertical; }
.op-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.op-table th { text-align: left; font-weight: 600; color: var(--ink-soft); padding: 8px 10px 8px 0; border-bottom: 1px solid var(--line); }
.op-table td { padding: 10px 10px 10px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.record { display: flex; flex-direction: column; gap: 24px; }
.record-grid { display: grid; grid-template-columns: 1fr 380px; gap: 24px; align-items: start; }
.brief { margin: 0; display: grid; grid-template-columns: 200px 1fr; gap: 12px 20px; }
.brief dt { font-weight: 600; font-size: 14px; color: var(--ink-soft); }
.brief dd { margin: 0; }
.record-transcript { display: flex; flex-direction: column; gap: 10px; max-height: 60vh; overflow-y: auto; font-size: 15px; }
.quote { margin: 0; padding-left: 14px; border-left: 3px solid var(--warn); }
.key-card .row { flex-wrap: nowrap; }

/* ---- narrow viewports: full-screen incoming call, slide to answer ---- */
@media (max-width: 860px) {
  .notice-screen, .cold, .live-screen, .op-grid, .record-grid { grid-template-columns: 1fr; gap: 28px; }
  .cards { grid-template-columns: 1fr; }
  .live-card { position: static; }
  .step-body { padding-left: 24px; }
  .brief { grid-template-columns: 1fr; gap: 4px; }
  .brief dd { margin-bottom: 10px; }
}
@media (max-width: 720px) {
  .call-page[data-screen="notice"] .notice:not([hidden]) {
    position: fixed; inset: 0; z-index: 10; border-radius: 0; padding: max(28px, env(safe-area-inset-top)) 22px max(28px, env(safe-area-inset-bottom));
    justify-content: space-between;
  }
  .notice .caller { flex: 1; justify-content: center; }
  .phone-greeting { display: block; font-family: var(--font-display); font-size: 22px; line-height: 1.15; color: #fff; margin-bottom: 14px; text-wrap: balance; }
  .notice .ring-wrap { width: 200px; height: 200px; }
  .notice .avatar { width: 110px; height: 110px; }
  .notice-actions .round-action.accept { display: none; }
  .notice-actions { grid-template-columns: repeat(2, 1fr); }
  .slide {
    display: flex; align-items: center; position: relative; height: 76px; border-radius: 999px; padding: 4px;
    background: rgb(255 255 255 / 12%);
  }
  .slide-knob {
    width: 68px; height: 68px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; display: grid; place-items: center;
    position: relative; z-index: 1; touch-action: none; cursor: grab; animation: nudge 2.4s ease-in-out infinite;
  }
  .slide-knob.dragging { animation: none; transition: none; }
  /* The nudge animation would override the drag position; hold the knob at the end instead. */
  .notice.answering .slide-knob { margin-left: auto; transform: none !important; animation: none; pointer-events: none; }
  .notice.answering .slide-label { display: none; }
  /* Live call: the card collapses into a call bar pinned to the top (plan 2026-10-23-1545 U2).
     A flex column, not a one-column grid, so the sticky card is not held inside its own grid row. */
  .live-screen { display: flex; flex-direction: column; align-items: stretch; gap: 20px; }
  .live-card {
    position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: auto 1fr auto;
    grid-template-areas: "ring timer controls" "ring hint hint"; align-items: center; column-gap: 14px; row-gap: 2px;
    text-align: left; margin: 0 -16px; padding: 10px 16px; border-radius: 0 0 18px 18px; border-width: 0 0 1px; box-shadow: var(--shadow);
  }
  .live-card .live-ring { grid-area: ring; width: 52px; height: 52px; }
  .live-card .live-ring svg { width: 24px; height: 24px; }
  .live-card .live-ring::after { inset: -4px; border-width: 2px; }
  .live-title, .live-card > .faint { display: none; }
  .live-timer { grid-area: timer; font-size: 17px; }
  .live-timer { white-space: nowrap; }
  .live-card [data-live-hint] { grid-area: hint; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .live-controls { grid-area: controls; margin-top: 0; gap: 8px; }
  .live-controls .round { width: 44px; height: 44px; }
  .live-controls .end-call { width: 44px; height: 44px; min-height: 44px; padding: 0; border-radius: 50%; justify-content: center; }
  .live-controls .end-label { display: none; }
  .live-screen .transcript { max-height: none; overflow: visible; }
  .live-screen .bubble { scroll-margin-top: 96px; scroll-margin-bottom: 16px; }
  .slide-knob:not(.dragging) { transition: transform .3s var(--ease-out); }
  .slide-label {
    position: absolute; inset: 0; display: grid; place-items: center; font-size: 17px; color: transparent;
    background: linear-gradient(90deg, #8d9196 0, #fff 50%, #8d9196 100%) no-repeat; background-size: 120px 100%;
    -webkit-background-clip: text; background-clip: text; animation: shimmer 2.2s linear infinite;
    background-color: #8d9196;
  }
  .steps-head h2 { font-size: 26px; }
  .step-head { gap: 16px; padding: 18px; }
  .checkbox { width: 48px; height: 48px; border-radius: 14px; }
  .typed-form { flex-direction: column; align-items: stretch; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  .ring { display: none; }
}

/* Reviews (plan U5, U6; KTD6 phone rules) */
.review-editor { display: flex; flex-direction: column; gap: 20px; }
.review-head h1 { font-size: 32px; }
.workflow-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.workflow-tab {
  display: inline-flex; flex-direction: column; gap: 2px; padding: 8px 14px; border-radius: 12px;
  border: 1px solid var(--line); color: inherit; text-decoration: none;
}
.workflow-tab:hover { border-color: var(--accent); }
.workflow-tab.current { border-color: var(--accent); background: var(--accent-soft); }
.workflow-tab.muted { opacity: .55; }
.review-grid { display: grid; grid-template-columns: 260px 1fr; gap: 24px; align-items: start; }
.section-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.section-nav a { display: flex; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 12px; text-decoration: none; color: var(--ink); border: 1px solid transparent; }
.section-nav a.active { background: var(--card); border-color: var(--line); font-weight: 600; }
.state { font-size: 12px; font-weight: 500; white-space: nowrap; }
.state-look { color: var(--warn); }
.state-updating { color: var(--ink-faint); }
.state-fine { color: var(--accent); }
.look-list { margin: 0; padding: 12px 16px 12px 32px; background: var(--warn-soft); border-radius: 12px; color: var(--warn); font-size: 14px; }
.look-list.bad { background: #f7dfdd; color: var(--danger); }
.versions { position: relative; }
.versions[open] ul { position: absolute; right: 0; top: 28px; z-index: 2; min-width: 320px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 4px 12px; }
.opp-edit input.rank { width: 72px; }
.opp-edit input.rate { width: 88px; display: inline-block; }
.rsection { display: flex; flex-direction: column; gap: 14px; }
.rsection + .rsection { margin-top: 32px; }
.rsection h2 { font-size: 26px; }
.prose p { margin: 0 0 10px; max-width: 60ch; }
.prose-list { margin: 0 0 10px; padding-left: 20px; }
.flags { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.flag { display: grid; grid-template-columns: 120px 1fr 1.4fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.flag:last-child { border-bottom: 0; }
.flag-status { font-size: 13px; font-weight: 600; }
.flag-ok .flag-status { color: var(--ok); }
.flag-warn .flag-status { color: var(--warn); }
.flag-bad .flag-status { color: var(--danger); }
.flag-info .flag-status { color: var(--ink-soft); }
.flag-reason { color: var(--ink-soft); }
.flag-label { display: flex; flex-direction: column; gap: 2px; }
.flag-value { color: var(--ink); }
.rtable table { width: 100%; border-collapse: collapse; font-size: 14px; }
.rtable th { text-align: left; font-weight: 600; color: var(--ink-soft); padding: 8px 10px 8px 0; border-bottom: 1px solid var(--line); }
.rtable td { padding: 9px 10px 9px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.bars { display: flex; flex-direction: column; gap: 8px; }
/* Chart rows share the .bar name with the steps progress bar, so undo its fixed size here. */
.bars .bar { display: flex; flex-direction: column; gap: 4px; width: auto; max-width: 560px; height: auto; border-radius: 0; background: none; overflow: visible; }
.bar-label { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.bar-track { height: 10px; background: var(--paper-deep); border-radius: 999px; overflow: hidden; }
.bars .bar-fill { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.opps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 14px; }
.opp p { margin: 4px 0 0; }
.opp-head { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: baseline; }
.nowrap { white-space: nowrap; }
.opp-value { white-space: nowrap; }
.note { margin: 0; padding: 10px 14px; border-radius: 12px; font-size: 14px; background: var(--paper-deep); }
.note-warn { background: var(--warn-soft); color: var(--warn); }
.tag { display: inline-block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-soft); }
.tag-estimate { color: var(--accent-deep); }
.tag-guess { color: var(--warn); }
.merchant-notes { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 15px; }
.review { display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.choose-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.choose-card { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.choose-card p { margin: 0; }
.picked { background: var(--accent-soft); border-color: var(--accent-soft); }
.evidence li > :last-child { min-width: 110px; }
.send-page { max-width: 760px; }
.review-ready { margin: 0 0 24px; background: var(--accent-soft); border-color: var(--accent-soft); }

@media (max-width: 860px) {
  .review-grid { grid-template-columns: 1fr; }
  .choose-list { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .flag { grid-template-columns: 1fr; gap: 2px; }
  .rtable thead { display: none; }
  .rtable tr { display: block; padding: 8px 0; border-bottom: 1px solid var(--line); }
  .rtable td { display: flex; justify-content: space-between; gap: 12px; border: 0; padding: 3px 0; }
  .rtable td::before { content: attr(data-label); color: var(--ink-soft); font-weight: 500; }
  .opp-head { grid-template-columns: 1fr; gap: 4px; }
}

/* Fixes ready to paste (fix-pack plan KTD19) */
.fixes { display: flex; flex-direction: column; gap: 20px; }
.fix-item { border-top: 1px solid var(--line); padding-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.fix-title { font-size: 17px; }
.fix-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.fix-cols > :only-child { grid-column: 1 / -1; }
.fix-text { white-space: pre-wrap; word-break: break-word; font: inherit; margin: 0 0 8px; padding: 12px; border-radius: 8px; background: var(--surface-2, rgba(0, 0, 0, 0.03)); }
.fix-before .fix-text { opacity: 0.75; }
.btn-small { padding: 6px 12px; font-size: 14px; }
@media (max-width: 640px) { .fix-cols { grid-template-columns: 1fr; } }

/* Meta ads in a creative test (creative-test plan KTD5) */
.ad-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.ad-item { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: start; border-top: 1px solid var(--line); padding-top: 12px; }
.ad-mine { border-left: 3px solid var(--accent, currentColor); padding-left: 10px; }
.ad-thumb { width: 96px; height: 96px; object-fit: cover; border-radius: 8px; background: var(--surface-2, rgba(0, 0, 0, 0.03)); display: flex; align-items: center; justify-content: center; text-align: center; padding: 6px; }
img.ad-thumb { padding: 0; }
.ad-meta p { margin: 4px 0 0; }
.ad-text { word-break: break-word; }
