/* =========================================================
   BudgetMonies — Debt Payoff Calculator
   Finance-friendly, credible. Deep teal + mint accent.
   ========================================================= */

:root {
  /* Color */
  --ink:        #0c1a1a;     /* near-black text */
  --ink-2:      #2e3f3f;     /* secondary text */
  --muted:      #5b6b6b;     /* tertiary */
  --line:       #d9e3e0;     /* hairline */
  --line-2:     #c4d2cd;
  --surface:    #ffffff;
  --surface-2:  #f5f8f6;     /* page bg */
  --surface-3:  #ebf1ee;     /* subtle band */

  --brand:      #0b3a3a;     /* deep teal */
  --brand-ink:  #082828;
  --brand-soft: #e3efea;

  --accent:     #1f8c5a;     /* trustworthy green */
  --accent-ink: #15663f;
  --mint:       #7fd5a8;     /* highlight on dark */

  --warn:       #b85c00;
  --warn-bg:    #fff4e5;
  --warn-line:  #f0c98a;

  --danger:     #b3261e;

  /* Spacing/scale */
  --container: 1120px;
  --radius:    14px;
  --radius-sm: 8px;

  /* Type */
  --font-ui:      'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-display: 'Source Serif 4', Georgia, serif;

  --shadow-sm: 0 1px 2px rgba(11,58,58,.06), 0 1px 1px rgba(11,58,58,.04);
  --shadow:    0 8px 24px rgba(11,58,58,.08), 0 2px 6px rgba(11,58,58,.05);
  --shadow-lg: 0 24px 60px rgba(11,58,58,.14), 0 6px 18px rgba(11,58,58,.08);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; }
body {
  font-family: var(--font-ui);
  color: var(--ink);
  background: var(--surface-2);
  line-height: 1.55;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
@media (max-width: 600px) { .wrap { padding: 0 16px; } }

a { color: var(--accent-ink); }
a:hover { color: var(--brand); }

/* Skip link */
.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--brand); color: #fff; padding: 10px 14px; z-index: 100;
}
.skip:focus { left: 12px; top: 12px; }

/* Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 18px; padding-bottom: 18px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--brand); }
.brand-mark { color: var(--brand); }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 22px; letter-spacing: -0.01em; color: var(--brand-ink); }
.brand-sub  { font-size: 12px; color: var(--muted); letter-spacing: .02em; }
.header-tag { font-size: 13px; color: var(--muted); }

/* Hero */
.hero {
  background:
    radial-gradient(1200px 400px at 80% -10%, rgba(31,140,90,.10), transparent 60%),
    linear-gradient(180deg, #fbfdfc 0%, var(--surface-2) 100%);
  border-bottom: 1px solid var(--line);
}
.hero-grid {
  display: grid; grid-template-columns: 1.4fr .9fr; gap: 48px;
  padding: 72px 24px 56px;
  align-items: center;
}
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 32px; padding: 48px 16px 36px; }
}
.eyebrow {
  display: inline-block;
  font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent-ink); background: var(--brand-soft);
  padding: 6px 12px; border-radius: 999px; margin: 0 0 18px;
}
.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(34px, 4.6vw, 54px);
  line-height: 1.05; letter-spacing: -0.02em;
  margin: 0 0 18px;
  color: var(--brand-ink);
}
.hero h1 .ink { color: var(--accent-ink); font-style: italic; }
.lede { font-size: 18px; color: var(--ink-2); margin: 0 0 22px; max-width: 60ch; }
.hero-checks {
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: 8px;
}
.hero-checks li {
  position: relative; padding-left: 28px; color: var(--ink-2);
}
.hero-checks li::before {
  content: ""; position: absolute; left: 0; top: 9px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent); box-shadow: inset 0 0 0 3px #fff;
}

.hero-stat {
  background: var(--brand);
  color: #fff;
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}
.hero-stat::after {
  content: ""; position: absolute; inset: auto -40px -40px auto;
  width: 200px; height: 200px; background: radial-gradient(circle, rgba(127,213,168,.25), transparent 60%);
}
.stat-card { display: flex; flex-direction: column; gap: 6px; position: relative; z-index: 1; }
.stat-label { font-size: 13px; color: rgba(255,255,255,.75); letter-spacing: .04em; text-transform: uppercase; }
.stat-value {
  font-family: var(--font-display);
  font-size: 46px; font-weight: 600; letter-spacing: -0.02em;
  color: var(--mint);
  line-height: 1;
}
.stat-foot { font-size: 14px; color: rgba(255,255,255,.85); }
.stat-note { font-size: 12px; color: rgba(255,255,255,.6); margin: 18px 0 0; position: relative; z-index: 1; }

/* Confirmation sequence pages */
.sequence-card {
  max-width: 720px;
}
.mini-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--brand);
  margin-bottom: 24px;
}
.mini-brand span {
  display: grid;
  line-height: 1.1;
}
.mini-brand strong {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--brand-ink);
}
.mini-brand small {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .02em;
}
.sequence-list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 12px;
  counter-reset: sequence;
}
.sequence-list li {
  counter-increment: sequence;
  display: grid;
  grid-template-columns: 38px 1fr;
  column-gap: 14px;
  align-items: start;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.sequence-list li::before {
  content: counter(sequence);
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--mint);
  font-weight: 700;
}
.sequence-list strong,
.sequence-list span {
  grid-column: 2;
}
.sequence-list strong {
  color: var(--brand-ink);
}
.sequence-list span {
  color: var(--muted);
  font-size: 14px;
}
.confirm-panel {
  display: grid;
  gap: 6px;
  padding: 18px;
  margin-top: 24px;
  border: 1px solid rgba(31,140,90,.28);
  background: var(--brand-soft);
  border-radius: var(--radius-sm);
  color: var(--ink-2);
}
.confirm-panel strong {
  color: var(--accent-ink);
}
.inbox-shortcuts {
  display: grid;
  gap: 10px;
  margin: 20px 0 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, rgba(255,255,255,.78), rgba(244,250,247,.82));
}
.inbox-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--brand-ink);
}
.inbox-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.inbox-btn {
  display: grid;
  justify-items: center;
  align-items: center;
  gap: 7px;
  min-height: 78px;
  padding: 10px 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(9, 43, 43, .08);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.inbox-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(9, 43, 43, .12);
  border-color: rgba(31,140,90,.34);
}
.mail-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  box-shadow: 0 6px 14px rgba(9, 43, 43, .10);
}
.mail-icon svg {
  width: 38px;
  height: 38px;
  display: block;
}
@media (max-width: 560px) {
  .inbox-buttons {
    grid-template-columns: 1fr;
  }
  .inbox-btn {
    grid-template-columns: 38px 1fr;
    justify-items: start;
    min-height: 58px;
    padding: 10px 12px;
  }
}

/* Section headings */
.section-h {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(24px, 2.6vw, 32px);
  letter-spacing: -0.01em;
  margin: 0 0 8px;
  color: var(--brand-ink);
}
.section-sub { color: var(--muted); margin: 0 0 24px; }

/* Calculator card */
.calc { padding: 56px 0 24px; }
.calc form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}
@media (max-width: 600px) { .calc form { padding: 18px; } }

.table-head, .debt-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 0.8fr 1fr 44px;
  gap: 12px;
  align-items: end;
}
.table-head {
  font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em;
  color: var(--muted);
  padding: 4px 4px 8px;
  border-bottom: 1px dashed var(--line);
}
.debt-rows { display: grid; gap: 12px; margin-top: 12px; }
.debt-row { padding: 8px 0; }
.debt-row.removing { opacity: 0; transform: translateY(-6px); transition: all .2s ease; }

@media (max-width: 720px) {
  .table-head { display: none; }
  .debt-row {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "name name"
      "balance apr"
      "min remove";
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface-2);
  }
  .debt-row .f-name { grid-area: name; }
  .debt-row .f-balance { grid-area: balance; }
  .debt-row .f-apr { grid-area: apr; }
  .debt-row .f-min { grid-area: min; }
  .debt-row .f-remove { grid-area: remove; justify-self: end; align-self: end; }
  .debt-row .mlabel { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; font-weight: 500; }
}
.mlabel { display: none; }

input[type="text"],
input[type="email"],
input[type="number"] {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(31,140,90,.15);
}
input::placeholder { color: #9aa8a4; }

.input-prefix {
  display: flex; align-items: center; gap: 0;
  border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.input-prefix:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(31,140,90,.15); }
.input-prefix span {
  padding: 0 12px; color: var(--muted); font-weight: 500; border-right: 1px solid var(--line);
}
.input-prefix input { border: 0; box-shadow: none !important; background: transparent; }
.input-prefix input:focus { border: 0; box-shadow: none; }

label, legend {
  font-size: 13px; font-weight: 600; color: var(--ink-2);
  margin-bottom: 6px; display: block;
}
.hint { font-size: 12px; color: var(--muted); margin: 6px 0 0; }

.icon-btn {
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid var(--line-2);
  color: var(--muted);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .15s ease;
}
.icon-btn:hover { color: var(--danger); border-color: var(--danger); background: #fff5f4; }

.row-actions { margin: 16px 0 6px; }

.strategy-grid {
  display: grid; grid-template-columns: 1fr 1.7fr; gap: 24px;
  margin-top: 28px; padding-top: 24px; border-top: 1px dashed var(--line);
}
@media (max-width: 720px) { .strategy-grid { grid-template-columns: 1fr; } }

.field { display: block; }
fieldset.field { border: 0; padding: 0; margin: 0; }
legend { padding: 0; }

.seg {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
}
@media (max-width: 600px) { .seg { grid-template-columns: 1fr; } }
.seg label {
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  cursor: pointer;
  background: var(--surface);
  transition: all .15s ease;
  display: block;
  margin-bottom: 0;
}
.seg label span {
  font-weight: 600; color: var(--ink); font-size: 14px; display: block;
}
.seg label small {
  display: block; font-size: 12px; color: var(--muted); margin-top: 4px; line-height: 1.4;
}
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) {
  border-color: var(--accent);
  background: #f1faf5;
  box-shadow: 0 0 0 3px rgba(31,140,90,.12);
}
.seg label:has(input:checked) span { color: var(--accent-ink); }
.seg label:hover { border-color: var(--accent); }

.submit-bar {
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
  margin-top: 28px; padding-top: 24px; border-top: 1px dashed var(--line);
}

/* Buttons */
.btn {
  font: inherit; font-weight: 600; cursor: pointer;
  border-radius: var(--radius-sm);
  padding: 12px 18px;
  border: 1px solid transparent;
  transition: transform .08s ease, background .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
  text-decoration: none; display: inline-flex; align-items: center; gap: 8px;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 2px 0 var(--accent-ink);
}
.btn-primary:hover { background: var(--accent-ink); }
.btn-primary:focus-visible { outline: 3px solid rgba(31,140,90,.35); outline-offset: 2px; }
.btn-primary[disabled] { opacity: .6; cursor: wait; }
.btn-ghost {
  background: transparent;
  color: var(--brand);
  border-color: var(--line-2);
}
.btn-ghost:hover { border-color: var(--brand); }
.btn-lg { padding: 14px 22px; font-size: 16px; }

/* Results */
.results {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface-3) 100%);
  padding: 48px 0 64px;
  border-top: 1px solid var(--line);
  margin-top: 24px;
}
.kpi-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
  margin-top: 12px;
}
@media (max-width: 900px) { .kpi-grid { grid-template-columns: repeat(2, 1fr); } }
.kpi {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}
.kpi.accent {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}
.kpi.accent .kpi-label { color: rgba(255,255,255,.75); }
.kpi.accent .kpi-value { color: var(--mint); }
.kpi.accent .kpi-sub   { color: rgba(255,255,255,.7); }
.kpi-label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.kpi-value {
  display: block; margin-top: 8px;
  font-family: var(--font-display);
  font-weight: 600; font-size: 32px; letter-spacing: -0.02em; color: var(--brand-ink);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.kpi-sub { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); }

.compare-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 24px;
}
@media (max-width: 900px) { .compare-grid { grid-template-columns: 1fr; } }
.compare {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}
.compare h3 {
  font-size: 14px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--muted); margin: 0 0 10px; font-weight: 600;
}
.compare-num {
  font-family: var(--font-display);
  font-size: 28px; font-weight: 600; letter-spacing: -0.01em;
  color: var(--brand-ink); margin: 0;
  font-variant-numeric: tabular-nums;
}
.compare-sub { color: var(--ink-2); margin: 6px 0 0; font-size: 14px; }
.compare.highlight { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(31,140,90,.10); }
.compare.savings { background: #f1faf5; border-color: var(--accent); }
.compare.savings .compare-num { color: var(--accent-ink); }

.order-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  margin-top: 24px;
}
.order-card h3 {
  font-family: var(--font-display); font-size: 22px; font-weight: 600; margin: 0 0 4px;
  color: var(--brand-ink);
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.tag {
  font-family: var(--font-ui);
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: var(--brand-soft); color: var(--accent-ink);
  padding: 4px 10px; border-radius: 999px;
}
.order-blurb { color: var(--ink-2); margin: 0 0 16px; }
.order-list { padding-left: 0; list-style: none; counter-reset: o; display: grid; gap: 8px; }
.order-list li {
  counter-increment: o;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  padding: 12px 14px 12px 48px;
  position: relative;
  border: 1px solid var(--line);
}
.order-list li::before {
  content: counter(o);
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--brand); color: var(--mint);
  font-weight: 700; font-size: 13px;
  display: flex; align-items: center; justify-content: center;
}
.order-list .meta { color: var(--muted); font-size: 13px; }

/* Warn banner */
.warn {
  background: var(--warn-bg);
  border: 1px solid var(--warn-line);
  color: #6c3a00;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  margin: 0 0 18px;
}
.warn strong { color: var(--warn); }

/* Gate */
.gate {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  margin-top: 28px;
  box-shadow: var(--shadow);
}
.gate-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px;
}
@media (max-width: 800px) { .gate-grid { grid-template-columns: 1fr; gap: 22px; } }
.gate h3 {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.4vw, 28px); font-weight: 600;
  margin: 0 0 10px; color: var(--brand-ink);
}
.gate-sub { color: var(--ink-2); margin: 0 0 14px; }
.gate-list { padding: 0; list-style: none; display: grid; gap: 6px; color: var(--ink-2); }
.gate-list li { padding-left: 22px; position: relative; }
.gate-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0; color: var(--accent); font-weight: 700;
}
.gate-form input[type="text"],
.gate-form input[type="email"] { margin-bottom: 12px; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 6px 0 14px; font-size: 13px; color: var(--ink-2); font-weight: 400; }
.check input { margin-top: 3px; }
.gate-foot { font-size: 12px; color: var(--muted); margin: 10px 0 0; }
.gate-msg { margin-top: 10px; font-size: 14px; min-height: 1.4em; }
.gate-msg.error { color: var(--danger); }
.gate-msg.success { color: var(--accent-ink); }

/* Why section */
.why { padding: 48px 0; background: var(--surface); border-top: 1px solid var(--line); }
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 800px) { .why-grid { grid-template-columns: 1fr; } }
.why article {
  padding: 24px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.why h3 {
  font-family: var(--font-display);
  font-size: 22px; font-weight: 600; margin: 0 0 8px; color: var(--brand-ink);
}
.why p { color: var(--ink-2); margin: 0; }

/* Disclaimer */
.disclaimer-section {
  background: var(--surface-2);
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.disclaimer-section h3 {
  font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted);
  margin: 0 0 8px; font-weight: 600;
}
.disclaimer-section p { color: var(--muted); font-size: 13px; max-width: 80ch; margin: 0; line-height: 1.6; }

/* Footer */
.site-footer {
  background: var(--brand-ink);
  color: rgba(255,255,255,.75);
  padding: 28px 0;
}
.site-footer p { margin: 0; font-size: 14px; }
.foot-sub { color: rgba(255,255,255,.5); font-size: 12px; margin-top: 4px !important; }

/* Reveal animations */
.reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .45s ease var(--d, 0ms), transform .45s ease var(--d, 0ms);
}
.reveal.is-in { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
}

/* View / loading pages (used by view.php) */
.loader-shell {
  min-height: 70vh;
  display: flex; align-items: center; justify-content: center;
  padding: 40px 16px;
}
.loader-card {
  max-width: 560px; width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px;
  text-align: center;
  box-shadow: var(--shadow);
}
.loader-card h1 {
  font-family: var(--font-display); font-weight: 600;
  font-size: 28px; margin: 0 0 8px; color: var(--brand-ink);
}
.loader-card p { color: var(--ink-2); margin: 0 0 18px; }
.spinner {
  width: 44px; height: 44px; margin: 0 auto 20px;
  border-radius: 50%;
  border: 3px solid var(--brand-soft);
  border-top-color: var(--accent);
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.progress {
  height: 6px; background: var(--brand-soft); border-radius: 999px; overflow: hidden;
  margin: 0 0 12px;
}
.progress > span {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--mint));
  transition: width .4s ease;
}

/* Plan viewer */
.plan-wrap { padding: 40px 0 64px; }
.plan-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  margin-bottom: 24px;
}
.plan-head h1 {
  font-family: var(--font-display); font-weight: 600; letter-spacing: -0.01em;
  font-size: clamp(28px, 3.4vw, 40px); margin: 0; color: var(--brand-ink);
}
.plan-head .actions { display: flex; gap: 8px; }
.plan-section {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
}
.plan-section h2 {
  font-family: var(--font-display); font-weight: 600;
  font-size: 22px; margin: 0 0 12px; color: var(--brand-ink);
}
.plan-section h3 { font-size: 16px; margin: 16px 0 6px; color: var(--brand-ink); }
.plan-section ul, .plan-section ol { padding-left: 22px; }
.plan-section li { margin-bottom: 6px; color: var(--ink-2); }
.plan-section p { color: var(--ink-2); margin: 0 0 10px; }
.script-block {
  background: var(--surface-2);
  border-left: 3px solid var(--accent);
  padding: 14px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 10px 0;
  font-size: 14px;
  color: var(--ink-2);
  white-space: pre-wrap;
}
.phase-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px;
  margin-bottom: 10px;
}
.phase-card .phase-h {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 6px;
}
.phase-card .phase-title { font-weight: 600; color: var(--brand-ink); }
.phase-card .phase-meta  { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
