:root {
  --ink: #202a28;
  --muted: #65716c;
  --paper: #f4f6f0;
  --panel: #fbfcf8;
  --line: #dce3da;
  --sage: #b9d3bd;
  --deep-sage: #557765;
  --forest: #1e4035;
  --amber: #d1a15d;
  --blue: #a9cdd1;
  --coral: #d98c76;
  --shadow: 0 14px 34px rgba(37, 58, 49, .07);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.55;
}
button, input { font: inherit; }
button { cursor: pointer; }
.wrap { width: min(1180px, calc(100% - 48px)); margin: 0 auto; }

.topbar { height: 76px; padding: 0 34px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(220, 227, 218, .82); background: rgba(244, 246, 240, .9); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--forest); text-decoration: none; font-size: 20px; font-weight: 760; letter-spacing: -.04em; }
.brand-mark { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--forest); color: #eef4e9; font-family: Georgia, serif; font-size: 17px; font-style: italic; }
.brand-dot { color: var(--coral); }
.topbar-note { color: var(--muted); font-size: 12px; letter-spacing: .02em; }
.status-dot { display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%; background: #73a77d; box-shadow: 0 0 0 4px rgba(115, 167, 125, .13); }

.hero { padding: 82px 0 68px; }
.eyebrow, .section-kicker { color: var(--deep-sage); font-size: 10px; font-weight: 800; letter-spacing: .17em; text-transform: uppercase; }
.hero h1 { max-width: 740px; margin: 15px 0 21px; color: var(--forest); font-family: Georgia, "Times New Roman", serif; font-size: clamp(48px, 7vw, 86px); font-weight: 400; letter-spacing: -.065em; line-height: .94; }
.hero h1 em { color: var(--coral); font-style: italic; }
.hero-copy { max-width: 570px; margin: 0; color: #5f6e68; font-size: 18px; line-height: 1.55; }
.hero-meta { display: flex; gap: 29px; margin-top: 39px; color: var(--muted); font-size: 12px; }
.hero-meta strong { margin-right: 4px; color: var(--forest); font-size: 15px; }

.workspace { display: grid; grid-template-columns: 305px 1fr; gap: 33px; align-items: start; }
.panel { border: 1px solid var(--line); border-radius: 18px; background: var(--panel); box-shadow: var(--shadow); }
.preferences { position: sticky; top: 20px; padding: 25px; }
.panel-heading, .results-head, .comparison-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
h2 { margin: 5px 0 0; color: var(--forest); font-family: Georgia, "Times New Roman", serif; font-size: 28px; font-weight: 400; letter-spacing: -.04em; line-height: 1.05; }
.muted { margin: 15px 0 25px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.text-button { border: 0; padding: 2px 0; background: transparent; color: var(--coral); font-size: 12px; font-weight: 700; }
.text-button:hover, .text-button:focus-visible { text-decoration: underline; }
.preference-list { display: grid; gap: 20px; }
.preference-row { display: block; }
.preference-label { display: flex; align-items: center; gap: 8px; margin-bottom: 9px; color: #36423e; font-size: 12px; }
.preference-label output { margin-left: auto; color: var(--deep-sage); font-size: 11px; font-weight: 800; text-transform: uppercase; }
.pref-icon { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; font-family: Georgia, serif; font-size: 14px; }
.pref-icon.cost { background: #f3e6cb; color: #9b6f31; }
.pref-icon.calm { background: #dbeae0; color: #557765; }
.pref-icon.access { background: #dbecef; color: #4e7f85; }
.pref-icon.green { background: #e9e3d2; color: #7d7147; }
input[type="range"] { width: 100%; height: 4px; appearance: none; border-radius: 5px; background: linear-gradient(90deg, var(--deep-sage) var(--fill, 50%), #dfe7de var(--fill, 50%)); outline: none; }
input[type="range"]::-webkit-slider-thumb { width: 17px; height: 17px; appearance: none; border: 3px solid var(--panel); border-radius: 50%; background: var(--deep-sage); box-shadow: 0 1px 4px rgba(30, 64, 53, .35); }
input[type="range"]::-moz-range-thumb { width: 12px; height: 12px; border: 3px solid var(--panel); border-radius: 50%; background: var(--deep-sage); box-shadow: 0 1px 4px rgba(30, 64, 53, .35); }
input[type="range"]:focus-visible { box-shadow: 0 0 0 3px rgba(85, 119, 101, .25); }
.preference-note { display: flex; gap: 9px; margin-top: 29px; padding-top: 18px; border-top: 1px solid var(--line); }
.note-icon { display: grid; flex: 0 0 auto; place-items: center; width: 18px; height: 18px; margin-top: 2px; border: 1px solid var(--deep-sage); border-radius: 50%; color: var(--deep-sage); font-size: 11px; font-weight: 800; }
.preference-note p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.45; }

.results-head { margin-bottom: 18px; }
.view-note, .comparison-context { color: var(--muted); font-size: 11px; }
.legend-swatch { display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--sage); }
.lens-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; min-height: 36px; margin-bottom: 14px; }
.summary-label { margin-right: 5px; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.summary-pill { padding: 4px 9px; border: 1px solid #c7d9ca; border-radius: 99px; background: #e6f0e4; color: var(--deep-sage); font-size: 11px; font-weight: 700; }
.summary-pill.soft { border-color: #e2e1d0; background: #f1f0e4; color: #77724f; }
.location-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.location-card { position: relative; min-height: 241px; padding: 20px; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.location-card:hover, .location-card:focus-within { transform: translateY(-2px); border-color: #b7cdbc; box-shadow: 0 11px 25px rgba(37, 58, 49, .08); }
.location-card.missing { background: #f8f9f5; }
.location-top { display: flex; justify-content: space-between; gap: 10px; }
.location-region { margin-bottom: 4px; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.location-name { margin: 0; color: var(--forest); font-family: Georgia, serif; font-size: 25px; font-weight: 400; letter-spacing: -.04em; }
.fit-badge { align-self: flex-start; padding: 5px 9px; border-radius: 99px; background: #e6f0e4; color: var(--deep-sage); font-size: 10px; font-weight: 800; white-space: nowrap; }
.fit-badge.balanced { background: #f3ecd9; color: #8c6b35; }
.fit-badge.gap { background: #f2e1dc; color: #a76653; }
.location-tagline { min-height: 42px; margin: 13px 0 17px; color: #58665f; font-size: 12px; line-height: 1.45; }
.mini-bars { display: grid; gap: 7px; }
.mini-bar-row { display: grid; grid-template-columns: 76px 1fr 28px; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.mini-bar { height: 5px; overflow: hidden; border-radius: 10px; background: #e4ebe2; }
.mini-bar span { display: block; height: 100%; border-radius: 10px; background: var(--sage); }
.mini-bar-row strong { color: var(--deep-sage); font-size: 10px; text-align: right; }
.card-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 17px; padding-top: 12px; border-top: 1px solid #e7ece5; }
.confidence { color: var(--muted); font-size: 10px; }
.confidence i { display: inline-block; width: 6px; height: 6px; margin-right: 4px; border-radius: 50%; background: #6fa67a; }
.confidence i.warn { background: var(--amber); }
.card-link { border: 0; background: transparent; color: var(--coral); font-size: 11px; font-weight: 700; }
.card-link:hover, .card-link:focus-visible { text-decoration: underline; }

.comparison-panel { margin-top: 28px; padding: 24px 25px 19px; }
.tradeoff-chart { display: grid; gap: 14px; margin-top: 27px; }
.chart-row { display: grid; grid-template-columns: 88px 1fr 50px; align-items: center; gap: 12px; }
.chart-name { color: #46534d; font-family: Georgia, serif; font-size: 14px; }
.chart-track { height: 12px; overflow: hidden; border-radius: 2px; background: #e6ece4; }
.chart-fill { height: 100%; border-radius: 2px; background: var(--sage); transition: width .35s ease; }
.chart-fill.emphasis { background: var(--deep-sage); }
.chart-fill.gap { background: #e7c4b9; }
.chart-value { color: var(--muted); font-size: 10px; text-align: right; }
.chart-caption { display: flex; align-items: center; gap: 8px; margin: 20px 0 0; color: var(--muted); font-size: 10px; }
.caption-line { display: inline-block; width: 21px; height: 1px; background: var(--coral); }

.evidence-section { padding: 105px 0 76px; }
.section-intro { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.section-intro p { max-width: 390px; margin: 0; color: var(--muted); font-size: 13px; }
.evidence-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.evidence-card { display: flex; min-height: 207px; flex-direction: column; padding: 18px; border: 1px solid var(--line); border-radius: 15px; background: var(--panel); }
.evidence-card:hover { border-color: #b7cdbc; }
.evidence-type { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.evidence-symbol { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; background: #e6f0e4; color: var(--deep-sage); font-family: Georgia, serif; font-size: 15px; }
.evidence-card h3 { margin: 16px 0 6px; color: var(--forest); font-family: Georgia, serif; font-size: 20px; font-weight: 400; letter-spacing: -.03em; }
.evidence-card p { margin: 0; color: #617069; font-size: 12px; line-height: 1.45; }
.evidence-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 17px; }
.source-label { color: var(--muted); font-size: 10px; }
.evidence-button { border: 0; background: transparent; color: var(--coral); font-size: 10px; font-weight: 800; }

.safeguards { display: grid; grid-template-columns: 74px 1fr; gap: 22px; padding: 44px 0 62px; border-top: 1px solid var(--line); }
.safeguard-mark { color: var(--coral); font-family: Georgia, serif; font-size: 54px; line-height: 1; }
.safeguards h2 { font-size: 33px; }
.safeguards p { max-width: 680px; margin: 14px 0 20px; color: var(--muted); font-size: 13px; }
.guardrail-list { display: flex; flex-wrap: wrap; gap: 9px 23px; color: #54635b; font-size: 11px; }
.guardrail-list b { margin-right: 4px; color: var(--coral); font-size: 10px; }
.footer { display: flex; justify-content: space-between; gap: 20px; padding: 24px 0 34px; border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.brand-small { color: var(--forest); font-weight: 800; letter-spacing: -.03em; }

.evidence-dialog { width: min(480px, calc(100% - 32px)); padding: 0; border: 0; border-radius: 18px; background: var(--panel); color: var(--ink); box-shadow: 0 25px 70px rgba(24, 47, 38, .28); }
.evidence-dialog::backdrop { background: rgba(22, 43, 35, .35); backdrop-filter: blur(3px); }
.dialog-inner { position: relative; padding: 30px; }
.dialog-close { position: absolute; top: 15px; right: 18px; width: 28px; height: 28px; border: 0; border-radius: 50%; background: #e9efe7; color: var(--forest); font-size: 22px; line-height: 1; }
.dialog-inner h2 { margin: 15px 0 9px; }
.dialog-copy { color: var(--muted); font-size: 13px; }
.dialog-facts { display: grid; gap: 10px; margin: 22px 0 0; padding-top: 17px; border-top: 1px solid var(--line); }
.dialog-fact { display: flex; justify-content: space-between; gap: 15px; font-size: 12px; }
.dialog-fact span:first-child { color: var(--muted); }
.dialog-fact span:last-child { color: var(--forest); font-weight: 700; text-align: right; }

@media (max-width: 900px) {
  .workspace { grid-template-columns: 1fr; }
  .preferences { position: static; }
  .preference-list { grid-template-columns: repeat(2, 1fr); column-gap: 25px; }
  .preference-note { margin-top: 22px; }
  .evidence-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 610px) {
  .wrap { width: min(100% - 30px, 1180px); }
  .topbar { height: 64px; padding: 0 15px; }
  .topbar-note { display: none; }
  .hero { padding: 57px 0 49px; }
  .hero h1 { font-size: clamp(47px, 14vw, 71px); }
  .hero-copy { font-size: 16px; }
  .hero-meta { flex-wrap: wrap; gap: 9px 20px; margin-top: 29px; }
  .preference-list, .location-grid, .evidence-grid { grid-template-columns: 1fr; }
  .results-head, .section-intro { display: block; }
  .view-note { margin-top: 12px; }
  .comparison-context { display: block; margin-top: 11px; }
  .chart-row { grid-template-columns: 72px 1fr 45px; gap: 8px; }
  .section-intro p { margin-top: 14px; }
  .safeguards { grid-template-columns: 40px 1fr; gap: 12px; }
  .safeguard-mark { font-size: 38px; }
  .safeguards h2 { font-size: 28px; }
  .guardrail-list { display: grid; gap: 7px; }
  .footer { display: block; }
  .footer div + div { margin-top: 7px; }
}
