:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --panel-soft: #f9fafb;
  --ink: #15171a;
  --muted: #686f7a;
  --border: #e3e6ea;
  --accent: #1f5f50;
  --accent-soft: #e9f2ef;
  --accent-2: #315b7d;
  --warning: #8a5d15;
  --warning-soft: #fff7e5;
  --danger: #9e3434;
  --shadow: 0 12px 32px rgba(25, 33, 42, 0.06);
  font-family: Arial, "Noto Sans Hebrew", sans-serif;
}
* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); min-height: 100vh; overflow-x: hidden; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid rgba(31, 95, 80, .28);
  outline-offset: 2px;
}
input, select { direction: ltr; unicode-bidi: isolate; }
.topbar {
  position: sticky; top: 0; z-index: 50;
  min-height: 74px; display: flex; align-items: center; justify-content: space-between;
  padding: 12px clamp(18px, 4vw, 56px); background: rgba(255,255,255,.94); border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo { width: 42px; height: 42px; border-radius: 13px; background: var(--ink); color: white; display: grid; place-items: center; font-weight: 800; font-size: 22px; direction: ltr; }
.brand-title { font-size: 18px; font-weight: 800; }
.brand-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.header-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
main { width: min(1540px, calc(100% - 32px)); margin: 0 auto; padding: 34px 0 64px; }
.intro { display: flex; justify-content: space-between; gap: 28px; align-items: end; margin-bottom: 24px; }
.eyebrow { display: inline-block; color: var(--accent); font-weight: 800; font-size: 12px; letter-spacing: .02em; margin-bottom: 7px; }
h1 { font-size: clamp(30px, 4vw, 52px); letter-spacing: -0.04em; line-height: 1.02; margin: 0 0 10px; }
h2 { font-size: 22px; margin: 0; letter-spacing: -.02em; }
h3 { font-size: 23px; margin: 8px 0 6px; }
p { color: var(--muted); line-height: 1.55; }
.intro p { margin: 0; max-width: 720px; font-size: 16px; }
.preset-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; color: var(--muted); font-size: 13px; }
.chip, .btn, .segment { border: 1px solid var(--border); background: white; border-radius: 11px; padding: 9px 13px; color: var(--ink); transition: .18s ease; }
.chip:hover, .btn:hover, .segment:hover { border-color: #c9ced5; transform: translateY(-1px); }
.chip.active, .segment.active { background: var(--ink); color: white; border-color: var(--ink); }
.btn.secondary { background: var(--accent); color: white; border-color: var(--accent); }
.btn.ghost { background: transparent; }
.btn.add { width: 100%; color: var(--accent); background: var(--accent-soft); border-color: transparent; margin-top: 8px; }
.segmented { display: inline-flex; background: var(--bg); border-radius: 12px; padding: 3px; gap: 2px; }
.segmented .segment { border: 0; background: transparent; padding: 8px 11px; border-radius: 9px; }
.segmented .segment.active { background: white; color: var(--ink); box-shadow: 0 1px 5px rgba(0,0,0,.08); }
.segmented.full { display: flex; width: 100%; }
.segmented.full .segment { flex: 1; }
.result-grid { display: grid; grid-template-columns: 1.25fr 1fr .8fr 1.15fr; gap: 12px; margin-bottom: 18px; }
.result-card { background: var(--panel); border: 1px solid var(--border); border-radius: 18px; padding: 20px; box-shadow: var(--shadow); min-height: 145px; display: flex; flex-direction: column; justify-content: space-between; }
.hero-card { background: var(--ink); color: white; border-color: var(--ink); }
.hero-card .result-label, .hero-card .result-sub { color: #c9ced5; }
.result-label { font-size: 13px; color: var(--muted); font-weight: 700; }
.result-value { font-size: clamp(33px, 4vw, 50px); letter-spacing: -.04em; direction: ltr; unicode-bidi: isolate; text-align: right; }
.result-value.small { font-size: clamp(28px, 3vw, 38px); }
.result-sub { color: var(--muted); font-size: 12px; }
.mini-breakdown { display: grid; gap: 9px; margin-top: 8px; }
.mini-breakdown div { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; border-top: 1px solid var(--border); padding-top: 7px; }
.mini-breakdown strong { direction: ltr; unicode-bidi: isolate; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(390px, .8fr); grid-template-areas: "visual controls"; gap: 18px; align-items: start; }
.controls-panel { grid-area: controls; background: var(--panel); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; }
.visual-panel { grid-area: visual; display: grid; gap: 18px; }
.panel-heading { padding: 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--border); }
.status-dot { color: var(--muted); font-size: 11px; white-space: nowrap; }
.status-dot i { display: inline-block; width: 7px; height: 7px; background: #47a36a; border-radius: 50%; margin-left: 4px; }
.control-section { border-bottom: 1px solid var(--border); }
.control-section:last-child { border-bottom: 0; }
.control-section summary { list-style: none; cursor: pointer; font-weight: 800; padding: 17px 20px; position: relative; }
.control-section summary::-webkit-details-marker { display:none; }
.control-section summary::before { content: "⌄"; position: absolute; left: 20px; color: var(--muted); transition: transform .2s; }
.control-section[open] summary::before { transform: rotate(180deg); }
.control-section > :not(summary) { margin-right: 20px; margin-left: 20px; }
.control-section > :last-child { margin-bottom: 20px; }
.section-help { font-size: 12px; margin-top: -5px; margin-bottom: 12px; }
.field { display: grid; gap: 6px; margin-bottom: 13px; font-size: 13px; font-weight: 700; }
.field small, .sub-card small { color: var(--muted); font-weight: 400; line-height: 1.45; }
.field-grid { display: grid; gap: 10px; }
.field-grid.two { grid-template-columns: 1fr 1fr; }
.field-grid.three { grid-template-columns: repeat(3, 1fr); }
.compact-grid .field { min-width: 0; }
input[type=number], select, .number-box { width: 100%; border: 1px solid var(--border); border-radius: 10px; padding: 10px 11px; background: white; color: var(--ink); outline: none; }
input[type=number]:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.money-input, .percent-input { display: flex; flex-direction: row-reverse; align-items: center; border: 1px solid var(--border); border-radius: 10px; background: white; overflow: hidden; }
.money-input:focus-within, .percent-input:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.money-input span, .percent-input span { padding: 0 10px; color: var(--muted); direction: ltr; unicode-bidi: isolate; }
.money-input input, .percent-input input { border: 0; box-shadow: none!important; border-radius: 0; }
.percent-input.narrow { width: 100px; flex: none; }
.slider-pair { display: grid; grid-template-columns: 1fr 100px; gap: 10px; align-items: center; direction: ltr; }
input[type=range] { width: 100%; accent-color: var(--accent); }
.toggle-line { display: flex; gap: 8px; align-items: center; font-size: 13px; color: var(--ink); margin: 12px 0; cursor: pointer; }
.toggle-line input { width: 17px; height: 17px; accent-color: var(--accent); }
.calculated-line { background: var(--panel-soft); padding: 11px 12px; border-radius: 10px; color: var(--muted); font-size: 12px; display: flex; justify-content: space-between; }
.calculated-line strong { color: var(--ink); direction: ltr; unicode-bidi: isolate; }
.phase-card, .break-card { border: 1px solid var(--border); border-radius: 14px; padding: 12px; margin-bottom: 9px; background: var(--panel-soft); }
.phase-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 9px; }
.phase-head strong { font-size: 12px; }
.icon-btn { border: 0; background: transparent; color: var(--danger); padding: 4px 6px; border-radius: 7px; }
.phase-grid { display: grid; grid-template-columns: .85fr .85fr 1fr 1fr; gap: 7px; align-items: end; }
.break-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.mini-field { display: grid; gap: 4px; font-size: 10px; color: var(--muted); }
.mini-field input, .mini-field select { padding: 8px; font-size: 12px; }
.readonly-input { background: #f0f2f4!important; color: var(--muted)!important; cursor: not-allowed; }
.custom-restart-field { margin-top: 8px; }
.sub-card { background: var(--panel-soft); border: 1px solid var(--border); border-radius: 14px; padding: 12px; margin-top: 12px; }
.hidden { display: none!important; }
.sensitivity { display: grid; grid-template-columns: repeat(4,1fr); gap: 6px; }
.sensitivity div { background: var(--panel-soft); border-radius: 9px; padding: 8px 5px; text-align: center; }
.sensitivity span { display:block; color:var(--muted); font-size:10px; }
.sensitivity strong { display:block; font-size:12px; margin-top:3px; direction:ltr; unicode-bidi:isolate; }
.chart-card, .insight-card { background: var(--panel); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow); padding: 20px; }
.sticky-chart { position: relative; }
.card-heading { display: flex; justify-content: space-between; align-items: start; gap: 16px; margin-bottom: 8px; }
.pill { padding: 6px 9px; background: var(--accent-soft); color: var(--accent); border-radius: 999px; font-size: 11px; font-weight: 800; }
canvas { width: 100%; display: block; direction: ltr; }
.chart-legend { display: flex; justify-content: space-between; color: var(--muted); font-size: 11px; margin-top: 8px; }
.legend-dot { width: 8px; height: 8px; display:inline-block; border-radius:50%; margin-left:5px; background: var(--accent); }
.insight-card { background: var(--accent-soft); border-color: transparent; box-shadow: none; }
.insight-card p { margin: 0; color: #36534c; }
.age-table { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; margin-top: 8px; }
.age-table div { padding: 9px; border-radius: 10px; background: var(--panel-soft); display:flex; justify-content:space-between; font-size:11px; gap:8px; }
.age-table strong { direction:ltr; unicode-bidi:isolate; }
.explain-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.explain-item { background: var(--panel-soft); border-radius: 12px; padding: 12px; }
.explain-item span { display:block; font-size:11px; color:var(--muted); }
.explain-item strong { display:block; margin-top:6px; font-size:18px; direction:ltr; unicode-bidi:isolate; }
.scenario-section { margin-top: 26px; background: var(--panel); border:1px solid var(--border); border-radius:20px; padding:22px; box-shadow:var(--shadow); }
.section-title-row { display:flex; justify-content:space-between; gap:20px; align-items:start; }
.section-title-row p { margin:6px 0 0; }
.scenario-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; margin-top:16px; }
.scenario-card { border:1px solid var(--border); border-radius:14px; padding:14px; }
.scenario-card h3 { font-size:16px; margin:0 0 8px; }
.scenario-card .scenario-metrics { display:grid; gap:5px; font-size:11px; color:var(--muted); }
.scenario-card .scenario-metrics div { display:flex; justify-content:space-between; }
.scenario-card strong { color:var(--ink); direction:ltr; unicode-bidi:isolate; }
.scenario-actions { display:flex; gap:6px; margin-top:12px; }
.scenario-actions button { flex:1; border:0; border-radius:8px; padding:7px; font-size:11px; }
.scenario-actions .load { background:var(--accent-soft); color:var(--accent); }
.scenario-actions .delete { background:#f9ecec; color:var(--danger); }
.comparison-wrap { overflow:auto; margin-top:16px; }
table { width:100%; border-collapse:collapse; min-width:680px; }
th, td { padding:10px 12px; border-top:1px solid var(--border); text-align:right; font-size:12px; }
th { color:var(--muted); font-weight:700; }
td:not(:first-child), th:not(:first-child) { direction:ltr; unicode-bidi:isolate; text-align:center; }
.disclaimer { margin-top:18px; padding:18px 20px; background:var(--warning-soft); border:1px solid #efdfb8; border-radius:16px; }
.disclaimer strong { color:var(--warning); }
.disclaimer p { margin:5px 0 0; color:#6f5b35; font-size:12px; }
.toast { position:fixed; bottom:22px; left:22px; background:var(--ink); color:white; padding:10px 14px; border-radius:10px; box-shadow:var(--shadow); transform:translateY(90px); opacity:0; transition:.25s; z-index:100; font-size:12px; }
.toast.show { transform:translateY(0); opacity:1; }
@media (max-width: 1120px) {
  .result-grid { grid-template-columns: 1fr 1fr; }
  .workspace { grid-template-columns: 1fr; grid-template-areas: "controls" "visual"; }
  .sticky-chart { position: static; }
}
@media (max-width: 720px) {
  .topbar { position:relative; align-items:flex-start; padding:12px 16px; flex-wrap:wrap; gap:10px; }
  .brand-sub { display:none; }
  .header-actions { width:100%; justify-content:stretch; flex-wrap:nowrap; gap:6px; }
  .header-actions .segmented { flex:1; min-width:0; }
  .header-actions .segment { flex:1; min-width:0; padding:7px 6px; white-space:nowrap; }
  .header-actions .btn { display:inline-flex; align-items:center; justify-content:center; padding:8px 10px; white-space:nowrap; }
  main { width:min(100% - 20px, 1540px); padding-top:22px; }
  .intro { display:grid; align-items:start; }
  .intro .preset-row { order:2; }
  .result-grid { grid-template-columns:1fr 1fr; }
  .result-card { min-height:125px; padding:15px; }
  .hero-card { grid-column:1/-1; }
  .result-value { font-size:38px; }
  .field-grid.two, .field-grid.three, .phase-grid, .break-grid { grid-template-columns:1fr 1fr; }
  .phase-grid .mini-field:nth-child(3), .phase-grid .mini-field:nth-child(4) { grid-column:auto; }
  .sensitivity { grid-template-columns:1fr 1fr; }
  .age-table { grid-template-columns:1fr 1fr; }
  .explain-grid { grid-template-columns:1fr 1fr; }
  .scenario-grid { grid-template-columns:1fr; }
  .section-title-row { display:grid; }
  .chart-card, .insight-card { padding:16px; }
  .scenario-section { padding:18px; }
}
@media (max-width: 440px) {
  .brand-title { font-size:15px; }
  .logo { width:36px; height:36px; }
  .segmented .segment { padding:7px 8px; font-size:11px; }
  .header-actions { display:grid; grid-template-columns:1fr 1fr; }
  .header-actions .segmented { grid-column:1 / -1; width:100%; }
  .header-actions .btn { width:100%; }
  .result-grid { grid-template-columns:1fr; }
  .hero-card { grid-column:auto; }
  .field-grid.two, .field-grid.three, .phase-grid, .break-grid { grid-template-columns:1fr; }
  .slider-pair { grid-template-columns:1fr 90px; }
  .age-table, .explain-grid { grid-template-columns:1fr; }
}

/* Quick forecast and progressive disclosure */
:root {
  --bg: #f1f0ea;
  --panel-soft: #f6f5f0;
  --ink: #18241f;
  --muted: #667068;
  --border: #d9dcd4;
  --accent: #136f5a;
  --accent-soft: #e1efe9;
  --coral: #e87b5b;
  font-family: "Segoe UI", "Noto Sans Hebrew", sans-serif;
}
body { background: radial-gradient(circle at 88% 2%, #dcebe4 0, transparent 28rem), var(--bg); }
main { width: min(1180px, calc(100% - 32px)); padding-top: 44px; }
.topbar { position: relative; background: rgba(241,240,234,.92); border-bottom-color: rgba(24,36,31,.11); }
.logo { background: var(--accent); border-radius: 50%; }
.step-label { display: block; color: var(--accent); font-size: 12px; font-weight: 900; letter-spacing: .04em; margin-bottom: 12px; }
.quick-start { min-height: calc(100vh - 170px); display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(32px,6vw,88px); align-content: center; padding: 30px 0 70px; }
.quick-copy { align-self: center; }
.quick-copy h1 { max-width: 560px; font-size: clamp(43px,6vw,76px); line-height: .98; }
.quick-copy > p { font-size: 19px; max-width: 520px; margin: 22px 0; }
.quick-form { align-self: center; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 18px; background: rgba(255,255,255,.58); border: 1px solid rgba(24,36,31,.11); border-radius: 26px; box-shadow: 0 22px 70px rgba(35,50,43,.07); }
.quick-field { min-width: 0; min-height: 132px; padding: 17px; display: flex; flex-direction: column; justify-content: space-between; gap: 14px; background: #fff; border: 1px solid var(--border); border-radius: 17px; font-size: 14px; font-weight: 800; }
.quick-field > span:first-child { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.quick-field input[type="number"] { min-height: 48px; font-size: 19px; font-weight: 800; }
.field-number { width: 25px; height: 25px; display: inline-grid; place-items: center; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 10px; }
.privacy-note { display: flex; gap: 10px; align-items: flex-start; max-width: 520px; color: #456057; background: rgba(225,239,233,.75); padding: 12px 14px; border-radius: 13px; font-size: 12px; line-height: 1.55; }
.privacy-note > span:first-child { font-size: 23px; color: var(--accent); line-height: 1; }
.upload-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; align-self: center; }
.upload-card { min-height: 280px; padding: 24px; background: rgba(255,255,255,.76); border: 1px solid rgba(24,36,31,.14); border-radius: 24px; display: flex; flex-direction: column; gap: 9px; cursor: pointer; box-shadow: 0 18px 60px rgba(35,50,43,.07); transition: transform .2s, border-color .2s, background .2s; }
.upload-card:hover, .upload-card:focus-within { transform: translateY(-4px); border-color: var(--accent); background: #fff; }
.upload-card input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.upload-number, .card-index { width: 34px; height: 34px; border: 1px solid var(--border); border-radius: 50%; display: grid; place-items: center; color: var(--accent); font-weight: 900; }
.upload-card strong { font-size: 19px; margin-top: auto; max-width: 180px; }
.upload-card small { color: var(--muted); direction: ltr; text-align: right; }
.upload-action { width: fit-content; color: var(--accent); font-weight: 800; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.file-status { min-height: 32px; margin-top: 4px; font-size: 11px; color: var(--muted); line-height: 1.4; word-break: break-word; }
.quick-actions { grid-column: 2; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 0; }
.quick-actions small { max-width: 420px; color: var(--muted); line-height: 1.5; }
.btn.primary-large { border: 0; background: var(--accent); color: #fff; min-height: 54px; padding: 14px 24px; border-radius: 15px; font-size: 16px; font-weight: 900; box-shadow: 0 10px 24px rgba(19,111,90,.18); }
.text-action { border: 0; background: none; color: var(--ink); text-decoration: underline; text-underline-offset: 4px; padding: 12px 0; }
.forecast-shell, .improve-panel, .advanced-shell { scroll-margin-top: 18px; }
.forecast-shell { padding: 52px 0 20px; animation: reveal .45s ease both; }
.forecast-heading { display: flex; justify-content: space-between; gap: 24px; align-items: end; margin-bottom: 22px; }
.forecast-heading h2, .section-intro h2 { font-size: clamp(30px,4vw,48px); }
.forecast-heading p, .section-intro p { margin: 7px 0 0; }
.result-money-mode { flex: none; }
.forecast-shell .result-grid { grid-template-columns: 1.35fr 1fr .65fr .65fr; }
.forecast-shell .hero-card { background: var(--accent); border-color: var(--accent); }
.provenance-strip { background: rgba(255,255,255,.64); border: 1px solid var(--border); border-radius: 18px; padding: 15px 18px; display: grid; grid-template-columns: repeat(5,1fr); gap: 12px; }
.provenance-item { min-width: 0; }
.provenance-item span { display: block; color: var(--muted); font-size: 11px; }
.provenance-item strong { display: block; margin: 5px 0 7px; direction: ltr; unicode-bidi: isolate; text-align: right; overflow: hidden; text-overflow: ellipsis; }
.source-badge { display: inline-block; width: fit-content; background: #e6eef9; color: #356496; padding: 3px 7px; border-radius: 99px; font-size: 9px; font-weight: 800; white-space: nowrap; }
.source-badge[data-source="system"] { background: #f9e8e7; color: #98524f; }
.source-badge[data-source="user"] { background: #dff1e7; color: #286f4a; }
.source-badge[data-source="payslip"], .source-badge[data-source="pensionReport"] { background: #e2edf9; color: #35699f; }
.explainable { position: relative; cursor: help; }
.explainable::after {
  content: attr(data-tooltip); position: absolute; z-index: 220; bottom: calc(100% + 10px); left: 50%;
  width: max-content; max-width: min(280px, calc(100vw - 28px)); padding: 10px 12px;
  border-radius: 10px; background: #14211c; color: #fff; box-shadow: 0 12px 30px rgba(20,33,28,.2);
  font-size: 12px; font-weight: 500; line-height: 1.5; text-align: right; white-space: normal;
  opacity: 0; visibility: hidden; pointer-events: none; transform: translate(-50%, 5px); transition: .16s ease;
}
.explainable::before {
  content: ""; position: absolute; z-index: 221; bottom: calc(100% + 4px); left: 50%;
  border: 6px solid transparent; border-top-color: #14211c; opacity: 0; visibility: hidden;
  transform: translateX(-50%); transition: .16s ease;
}
.explainable:hover::after, .explainable:focus-visible::after,
.explainable:hover::before, .explainable:focus-visible::before { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.explainable:hover::before, .explainable:focus-visible::before { transform: translateX(-50%); }
.forecast-cta { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 38px 0 22px; }
.forecast-cta small { color: var(--muted); }
.improve-panel, .advanced-shell { padding: 70px 0 10px; animation: reveal .4s ease both; }
.section-intro { max-width: 700px; margin-bottom: 24px; }
.improve-grid { display: grid; grid-template-columns: repeat(6,1fr); gap: 12px; }
.improve-card { grid-column: span 2; background: rgba(255,255,255,.78); border: 1px solid var(--border); border-radius: 20px; padding: 20px; min-width: 0; }
.improve-card:nth-child(4), .improve-card:nth-child(5) { grid-column: span 3; }
.improve-card h3 { font-size: 19px; margin: 22px 0 15px; }
.improve-card p { font-size: 13px; }
.choice-stack, .choice-row { display: flex; gap: 7px; flex-wrap: wrap; }
.choice-stack { flex-direction: column; }
.choice-stack button, .choice-row button { border: 1px solid var(--border); border-radius: 11px; background: #fff; color: var(--ink); padding: 10px 12px; text-align: right; min-height: 44px; }
.choice-row button { flex: 1; text-align: center; }
.choice-stack button.active, .choice-row button.active { color: #fff; background: var(--ink); border-color: var(--ink); }
.inline-note { background: var(--warning-soft); color: #6f5b35; border-radius: 10px; padding: 10px; }
.advanced-toggle { width: 100%; min-height: 58px; margin-top: 14px; border: 1px solid var(--border); border-radius: 16px; background: transparent; color: var(--ink); font-weight: 900; }
.advanced-shell .workspace { grid-template-columns: minmax(0,1.35fr) minmax(360px,.8fr); }
.advanced-shell .scenario-section { margin-bottom: 28px; }
.document-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.compact-upload { min-width: 0; padding: 12px; display: grid; gap: 5px; border: 1px dashed #b9c5be; border-radius: 12px; background: var(--panel-soft); cursor: pointer; }
.compact-upload input { width: 100%; font-size: 11px; }
.compact-upload span, .compact-upload em { color: var(--muted); font-size: 10px; font-style: normal; word-break: break-word; }
.disclaimer { margin-top: 42px; }
@keyframes reveal { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

@media (max-width: 900px) {
  .quick-start { grid-template-columns: 1fr; min-height: auto; padding-top: 20px; }
  .quick-actions { grid-column: 1; margin-top: 0; }
  .forecast-shell .result-grid { grid-template-columns: 1fr 1fr; }
  .provenance-strip { grid-template-columns: repeat(3,1fr); }
  .improve-grid { grid-template-columns: 1fr 1fr; }
  .improve-card, .improve-card:nth-child(4), .improve-card:nth-child(5) { grid-column: span 1; }
  .advanced-shell .workspace { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  main { width: min(100% - 20px,1180px); padding-top: 22px; }
  .quick-copy h1 { font-size: 46px; }
  .quick-copy > p { font-size: 16px; }
  .upload-grid { grid-template-columns: 1fr; }
  .quick-form { grid-template-columns: 1fr; padding: 10px; }
  .quick-field { min-height: 112px; }
  .document-row { grid-template-columns: 1fr; }
  .upload-card { min-height: 190px; }
  .quick-actions { display: grid; }
  .forecast-heading { display: grid; align-items: start; }
  .forecast-shell .result-grid { grid-template-columns: 1fr 1fr; }
  .forecast-shell .hero-card, .forecast-shell .result-card:nth-child(2) { grid-column: 1 / -1; }
  .provenance-strip { grid-template-columns: 1fr 1fr; }
  .improve-grid { grid-template-columns: 1fr; }
  .forecast-cta { text-align: center; }
}
