/* SLBI CMA v3 — Premium Real Estate Marketing Design System
   Palette: deep navy + terra cotta + muted gold on warm cream
   Typography: Source Serif Pro (display) + Inter (body) + tabular nums
   Print-friendly via @media print
*/

/* ---------- Reset + base ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:        #0F2E4F;
  --navy-soft:   #1c4575;
  --navy-deep:   #08203B;
  --terra:       #C2603B;
  --terra-soft:  #d68563;
  --gold:        #B8965B;
  --gold-soft:   #d4b785;
  --cream:       #FAF8F3;
  --warm-white:  #F7F4EE;
  --warm-gray:   #D9D4CB;
  --warm-gray-2: #BFB7A8;
  --charcoal:    #2A2A2A;
  --charcoal-2:  #555555;
  --muted:       #8a8378;
  --green:       #4d7a3e;
  --red:         #a13a2c;
  --yellow:      #b8841d;
  --shadow-sm:   0 1px 2px rgba(15,46,79,0.06), 0 1px 3px rgba(15,46,79,0.10);
  --shadow-md:   0 4px 10px rgba(15,46,79,0.08), 0 2px 4px rgba(15,46,79,0.05);
  --shadow-lg:   0 14px 30px rgba(15,46,79,0.12), 0 4px 8px rgba(15,46,79,0.08);
  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   14px;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', 'Source Sans 3', -apple-system, 'Segoe UI', sans-serif;
  background: var(--cream);
  color: var(--charcoal);
  line-height: 1.55;
  font-weight: 400;
  font-feature-settings: 'tnum' 1, 'ss01' 1;
}

/* ---------- Page wrapper ---------- */
.page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px 80px;
  background: var(--cream);
}

/* ---------- Typography ---------- */
.serif    { font-family: 'Source Serif Pro', 'Playfair Display', Georgia, serif; }
.tnum     { font-variant-numeric: tabular-nums; }
.smallcaps{ text-transform: uppercase; letter-spacing: 0.13em; font-size: 11px; font-weight: 600; }
.smallcaps-md { text-transform: uppercase; letter-spacing: 0.16em; font-size: 13px; font-weight: 600; }

h1, h2, h3, h4 {
  font-family: 'Source Serif Pro', Georgia, serif;
  color: var(--navy);
  font-weight: 700;
  line-height: 1.15;
}

h1 { font-size: 52px; letter-spacing: -0.015em; }
h2 { font-size: 32px; letter-spacing: -0.01em; margin-bottom: 8px; }
h3 { font-size: 22px; letter-spacing: -0.005em; margin-bottom: 6px; font-weight: 600; }
h4 { font-size: 17px; font-weight: 600; margin-bottom: 6px; }

p  { color: var(--charcoal); font-size: 15px; }

/* ---------- Top brand bar ---------- */
.brand-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--warm-gray);
  padding: 18px 0 14px;
  margin-bottom: 0;
}
.brand-bar .mark {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-weight: 700;
  font-size: 21px;
  color: var(--navy);
  letter-spacing: 0.02em;
}
.brand-bar .mark .tag {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  color: var(--terra);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-left: 12px;
}
.brand-bar .right {
  color: var(--charcoal-2);
  font-size: 13px;
  letter-spacing: 0.06em;
}

/* ---------- Cover page ---------- */
.cover {
  padding: 80px 0 64px;
  position: relative;
}

.cover .eyebrow {
  color: var(--terra);
  letter-spacing: 0.20em;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.cover h1 {
  margin: 0 0 16px;
  max-width: 880px;
  color: var(--navy-deep);
  font-size: 56px;
}

.cover .subhead {
  display: flex;
  gap: 40px;
  margin: 18px 0 36px;
  flex-wrap: wrap;
}
.cover .subhead .item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.cover .subhead .label {
  color: var(--gold);
  letter-spacing: 0.16em;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}
.cover .subhead .val {
  color: var(--charcoal);
  font-weight: 500;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.hero-image {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  margin: 8px 0 36px;
  background: var(--warm-gray);
}
.hero-image-wrap {
  position: relative;
  width: 100%;
  height: 480px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin: 8px 0 36px;
}
.hero-image-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
}
.hero-image-wrap .corner-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--navy);
  color: var(--cream);
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* At-a-glance stat strip */
.stat-strip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  background: var(--warm-white);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 0;
  overflow: hidden;
  margin: 0 0 24px;
}
.stat-cell {
  padding: 22px 26px;
  border-right: 1px solid var(--warm-gray);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-cell:last-child { border-right: 0; }
.stat-cell .label {
  color: var(--terra);
  letter-spacing: 0.15em;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}
.stat-cell .val {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.stat-cell .sub {
  color: var(--charcoal-2);
  font-size: 12px;
}

/* ---------- Section dividers ---------- */
section {
  padding: 56px 0 8px;
  border-top: 1px solid var(--warm-gray);
  margin-top: 24px;
}
section:first-of-type { border-top: 0; padding-top: 0; }
.section-eyebrow {
  color: var(--terra);
  letter-spacing: 0.20em;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 12px;
}

/* ---------- Executive summary ---------- */
.exec-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 36px;
  align-items: start;
  margin-top: 28px;
}

.exec-narrative {
  font-size: 16px;
  line-height: 1.65;
  color: var(--charcoal);
  font-family: 'Source Serif Pro', Georgia, serif;
}
.exec-narrative p { font-size: 17px; margin-bottom: 14px; }

.deal-class-card {
  padding: 28px;
  background: var(--warm-white);
  border-left: 5px solid var(--gold);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
.deal-class-card.deal-green  { border-left-color: var(--green); }
.deal-class-card.deal-yellow { border-left-color: var(--yellow); }
.deal-class-card.deal-red    { border-left-color: var(--red); }

.deal-class-card .badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 24px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: var(--gold);
  color: white;
  margin-bottom: 14px;
}
.deal-class-card.deal-green  .badge { background: var(--green); }
.deal-class-card.deal-yellow .badge { background: var(--yellow); }
.deal-class-card.deal-red    .badge { background: var(--red); }

.deal-class-card .metric {
  margin-bottom: 14px;
}
.deal-class-card .metric .label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.deal-class-card .metric .val {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

/* ---------- Config matrix ---------- */
.config-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 28px 0 16px;
}
.config-card {
  background: var(--warm-white);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 24px 22px;
  position: relative;
}
.config-card.is-best {
  border-color: var(--terra);
  background: white;
  box-shadow: var(--shadow-md);
  transform: scale(1.02);
}
.config-card.is-best::before {
  content: 'BEST';
  position: absolute;
  top: -10px;
  right: 20px;
  background: var(--terra);
  color: white;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
}
.config-card .name {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 19px;
  font-weight: 700;
  color: var(--navy);
}
.config-card .descr {
  color: var(--charcoal-2);
  font-size: 12px;
  margin-bottom: 16px;
}
.config-card .row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid var(--warm-gray);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.config-card .row:last-child { border-bottom: 0; }
.config-card .row .key { color: var(--charcoal-2); }
.config-card .row .val { font-weight: 600; color: var(--navy); }
.config-card .row.profit .val { color: var(--green); font-weight: 700; }
.config-card .row.profit-red .val { color: var(--red); font-weight: 700; }

/* ---------- Build concept diagram ---------- */
.concept-card {
  background: var(--warm-white);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 28px;
  margin: 24px 0;
}
.lot-diagram {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin: 22px 0 8px;
}
.lot-block {
  padding: 18px 22px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--navy);
  background: white;
  position: relative;
}
.lot-block.front  { background: linear-gradient(135deg, #fef9ed 0%, #faf3df 100%); border-color: var(--gold); }
.lot-block.new    { background: linear-gradient(135deg, #f4eee8 0%, #ece1d2 100%); border-color: var(--terra); }
.lot-block .tag {
  color: var(--terra);
  font-size: 10px;
  letter-spacing: 0.14em;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.lot-block.front .tag { color: var(--gold); }
.lot-block .descr {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--navy);
}
.lot-block .meta {
  display: flex;
  gap: 18px;
  margin-top: 6px;
  font-size: 12px;
  color: var(--charcoal-2);
  font-variant-numeric: tabular-nums;
}

/* ---------- Pricing prediction table ---------- */
.pred-table {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0 12px;
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-variant-numeric: tabular-nums;
}
.pred-table thead th {
  background: var(--navy);
  color: var(--cream);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  padding: 14px 16px;
  text-align: left;
}
.pred-table th.right, .pred-table td.right { text-align: right; }
.pred-table tbody td {
  padding: 16px;
  border-bottom: 1px solid var(--warm-gray);
  font-size: 14px;
  color: var(--charcoal);
}
.pred-table tbody tr:last-child td { border-bottom: 0; }
.pred-table tbody tr.total { background: var(--warm-white); font-weight: 700; }
.pred-table tbody tr.total td { color: var(--navy); }

.range-bar {
  position: relative;
  height: 22px;
  background: var(--warm-gray);
  border-radius: 4px;
  margin: 6px 0 2px;
}
.range-fill {
  position: absolute;
  height: 100%;
  background: linear-gradient(90deg, var(--gold-soft), var(--terra));
  border-radius: 4px;
}
.range-point {
  position: absolute;
  top: -3px;
  width: 4px;
  height: 28px;
  background: var(--navy);
  border-radius: 2px;
}
.range-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

/* Adjustment ledger */
.adj-ledger {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  margin: 16px 0;
  background: var(--warm-white);
  padding: 18px;
  border-radius: var(--radius-md);
  border-left: 4px solid var(--terra);
}
.adj-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  padding: 6px 0;
  border-bottom: 1px dotted var(--warm-gray);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.adj-row:last-child { border-bottom: 0; padding-top: 12px; font-weight: 700; color: var(--navy); }
.adj-row .pct { text-align: right; }
.adj-row .pct.pos { color: var(--green); }
.adj-row .pct.neg { color: var(--red); }
.adj-row .reason { color: var(--charcoal-2); font-size: 12px; }

/* ---------- Trend charts ---------- */
.trend-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 28px 0 8px;
}
.trend-card {
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}
.trend-card .title {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 2px;
}
.trend-card .sub {
  color: var(--charcoal-2);
  font-size: 12px;
  margin-bottom: 12px;
}
.trend-card .chart-wrap {
  height: 200px;
  position: relative;
}
.trend-card .footer {
  display: flex;
  gap: 22px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--warm-gray);
  font-variant-numeric: tabular-nums;
}
.trend-card .footer .stat .key {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.10em;
  font-weight: 600;
}
.trend-card .footer .stat .v {
  font-weight: 700;
  color: var(--navy);
  font-size: 16px;
}
.trend-card .footer .stat .v.pos { color: var(--green); }
.trend-card .footer .stat .v.neg { color: var(--red); }
.trend-card .footer .stat .v.flat { color: var(--charcoal-2); }
.trend-arrow {
  display: inline-block;
  margin-right: 4px;
}

/* ---------- Comp card grid ---------- */
.comp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin: 26px 0 8px;
}
.comp-card {
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.comp-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.comp-card .photo {
  height: 170px;
  background: linear-gradient(135deg, var(--warm-gray) 0%, var(--warm-gray-2) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.12em;
  font-weight: 600;
  text-transform: uppercase;
  position: relative;
}
.comp-card .photo .placeholder-icon {
  font-size: 32px;
  color: var(--warm-gray-2);
  font-family: 'Source Serif Pro', Georgia, serif;
}
.comp-card .photo .corner-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(15,46,79,0.92);
  color: white;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 10px;
  letter-spacing: 0.10em;
  font-weight: 600;
  text-transform: uppercase;
}
.comp-card .body {
  padding: 14px 18px 18px;
}
.comp-card .addr {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.25;
  margin-bottom: 2px;
}
.comp-card .city {
  color: var(--charcoal-2);
  font-size: 11px;
  margin-bottom: 12px;
}
.comp-card .price-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}
.comp-card .price {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--navy);
}
.comp-card .ppsf {
  color: var(--terra);
  font-weight: 700;
  font-size: 13px;
}
.comp-card .spec-row {
  display: flex;
  gap: 14px;
  padding: 8px 0;
  border-top: 1px solid var(--warm-gray);
  border-bottom: 1px solid var(--warm-gray);
  margin: 8px 0;
  font-variant-numeric: tabular-nums;
}
.comp-card .spec-row .spec .key {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.comp-card .spec-row .spec .v {
  color: var(--charcoal);
  font-weight: 600;
  font-size: 13px;
}
.comp-card .footer {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.comp-grid.empty {
  display: block;
  padding: 36px;
  text-align: center;
  background: var(--warm-white);
  border-radius: var(--radius-md);
  border: 1px dashed var(--warm-gray-2);
  color: var(--muted);
  font-style: italic;
  margin: 22px 0;
}

/* ---------- AMI context ---------- */
.ami-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin: 22px 0;
}
.ami-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-variant-numeric: tabular-nums;
}
.ami-table th {
  background: var(--navy);
  color: white;
  text-align: left;
  padding: 12px 14px;
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  font-weight: 600;
}
.ami-table td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--warm-gray);
  font-size: 13px;
}
.ami-table td.right { text-align: right; }
.ami-table tr:last-child td { border-bottom: 0; }

.ami-vs-market {
  background: var(--warm-white);
  border-radius: var(--radius-md);
  padding: 22px;
  border-left: 4px solid var(--gold);
}
.ami-bar {
  position: relative;
  height: 28px;
  background: var(--warm-gray);
  border-radius: var(--radius-sm);
  margin: 10px 0;
  overflow: hidden;
}
.ami-bar .seg { position: absolute; top: 0; bottom: 0; }
.ami-bar .seg.cap { background: var(--gold-soft); }
.ami-bar .seg.mkt { background: linear-gradient(90deg, var(--terra), var(--terra-soft)); }
.ami-bar .marker {
  position: absolute;
  top: -4px;
  bottom: -4px;
  width: 2px;
  background: var(--navy);
}
.ami-bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* ---------- Risks ---------- */
.risk-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 22px 0;
}
.risk-card {
  background: var(--warm-white);
  border-left: 4px solid var(--gold);
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  line-height: 1.55;
}
.risk-card.high  { border-left-color: var(--red); }
.risk-card.med   { border-left-color: var(--yellow); }
.risk-card.low   { border-left-color: var(--green); }
.risk-card .label {
  color: var(--terra);
  font-size: 10px;
  letter-spacing: 0.16em;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.risk-card.high .label { color: var(--red); }
.risk-card.med  .label { color: var(--yellow); }
.risk-card.low  .label { color: var(--green); }
.risk-card .body { color: var(--charcoal); }

/* ---------- Quick links bar ---------- */
.quick-links {
  display: flex;
  gap: 10px;
  margin: 20px 0 30px;
  flex-wrap: wrap;
}
.quick-links a {
  display: inline-flex;
  align-items: center;
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  background: var(--navy);
  color: var(--cream);
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 0.08em;
  font-weight: 600;
  text-transform: uppercase;
  transition: background 0.15s ease;
}
.quick-links a:hover { background: var(--navy-soft); }
.quick-links a.alt   { background: var(--terra); }
.quick-links a.alt:hover { background: var(--terra-soft); }
.quick-links a.ghost {
  background: transparent;
  color: var(--navy);
  border: 1px solid var(--warm-gray-2);
}
.quick-links a.ghost:hover { background: var(--warm-white); }

/* ---------- Footer ---------- */
.report-footer {
  margin-top: 80px;
  padding: 32px 0;
  border-top: 1px solid var(--warm-gray);
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 12px;
}
.report-footer .mark {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--navy);
}

/* ---------- Index page specific ---------- */
.index-hero {
  padding: 70px 0 40px;
  text-align: left;
}
.index-hero .eyebrow {
  color: var(--terra);
  letter-spacing: 0.22em;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.index-hero h1 { font-size: 64px; max-width: 900px; }
.index-hero p.lede {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 19px;
  color: var(--charcoal);
  max-width: 760px;
  margin-top: 18px;
  line-height: 1.55;
}

.index-filters {
  display: flex;
  gap: 8px;
  margin: 32px 0 26px;
  flex-wrap: wrap;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  background: white;
  border: 1px solid var(--warm-gray-2);
  border-radius: 18px;
  font-size: 12px;
  color: var(--navy);
  cursor: pointer;
  font-weight: 500;
  user-select: none;
  transition: all 0.12s ease;
}
.filter-chip.active {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}
.filter-chip:hover:not(.active) {
  background: var(--warm-white);
  border-color: var(--gold);
}

.parcel-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin: 8px 0 40px;
}

.parcel-card {
  display: block;
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--charcoal);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.parcel-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--gold);
}
.parcel-card .thumb {
  height: 220px;
  background: linear-gradient(135deg, var(--warm-gray), var(--warm-gray-2));
  position: relative;
}
.parcel-card .thumb iframe {
  width: 100%;
  height: 100%;
  border: 0;
}
.parcel-card .badge-corner {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(15,46,79,0.94);
  color: white;
  padding: 5px 11px;
  border-radius: var(--radius-sm);
  font-size: 10px;
  letter-spacing: 0.12em;
  font-weight: 700;
  text-transform: uppercase;
}
.parcel-card .badge-corner.green  { background: var(--green); }
.parcel-card .badge-corner.yellow { background: var(--yellow); }
.parcel-card .badge-corner.red    { background: var(--red); }
.parcel-card .body {
  padding: 20px 22px 22px;
}
.parcel-card .addr {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 21px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
  margin-bottom: 2px;
}
.parcel-card .neigh {
  color: var(--terra);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 14px;
}
.parcel-card .metric-row {
  display: flex;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--warm-gray);
  font-variant-numeric: tabular-nums;
}
.parcel-card .metric .key {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.10em;
  font-weight: 600;
}
.parcel-card .metric .v {
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--navy);
}

/* ---------- Methodology ---------- */
.method-card {
  background: var(--warm-white);
  border-left: 4px solid var(--gold);
  padding: 28px 32px;
  border-radius: var(--radius-md);
  margin: 26px 0;
  font-family: 'Source Serif Pro', Georgia, serif;
  font-size: 15px;
  line-height: 1.65;
}
.method-card h3 {
  font-family: 'Source Serif Pro', Georgia, serif;
  margin-bottom: 14px;
  color: var(--navy);
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  h1 { font-size: 42px; }
  .cover h1 { font-size: 44px; }
  .stat-strip { grid-template-columns: repeat(3, 1fr); }
  .stat-cell:nth-child(3) { border-right: 0; }
  .stat-cell:nth-child(n+4) { border-top: 1px solid var(--warm-gray); }
  .trend-grid { grid-template-columns: 1fr; }
  .comp-grid { grid-template-columns: repeat(2, 1fr); }
  .config-grid { grid-template-columns: 1fr; }
  .config-card.is-best { transform: none; }
  .exec-grid { grid-template-columns: 1fr; }
  .parcel-gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 700px) {
  .page { padding: 0 18px 60px; }
  h1 { font-size: 34px; }
  .cover h1 { font-size: 36px; }
  .stat-strip { grid-template-columns: 1fr 1fr; }
  .stat-cell { border-right: 0; border-bottom: 1px solid var(--warm-gray); }
  .comp-grid { grid-template-columns: 1fr; }
  .ami-grid { grid-template-columns: 1fr; }
  .risk-list { grid-template-columns: 1fr; }
  .parcel-gallery { grid-template-columns: 1fr; }
}

/* ---------- Print ---------- */
@media print {
  body { background: white; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .page { padding: 0; max-width: none; }
  .quick-links, .index-filters { display: none; }
  section { page-break-inside: avoid; padding-top: 30px; }
  .cover { padding-top: 40px; }
  .hero-image, .hero-image-wrap { height: 360px; box-shadow: none; }
  .config-card.is-best { box-shadow: none; }
  .comp-card { box-shadow: none; break-inside: avoid; }
  .trend-card { box-shadow: none; break-inside: avoid; }
}


/* ========== V4: Valuation Convergence ========== */
.valuation-convergence {
  background: var(--warm-white);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 28px;
  box-shadow: var(--shadow-md);
}
.valuation-convergence h3 {
  font-family: 'Source Serif Pro', Georgia, serif;
  color: var(--navy);
  font-size: 24px;
  margin-bottom: 4px;
}
.valuation-convergence .vc-sub {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 18px;
}

.methods-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}
@media (max-width: 900px) {
  .methods-grid { grid-template-columns: 1fr 1fr; }
}
.method-card {
  background: var(--cream);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 14px 12px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.method-card.headline {
  border: 2px solid var(--terra);
  background: linear-gradient(180deg, #FFF6EE 0%, var(--cream) 100%);
  box-shadow: var(--shadow-md);
}
.method-card .method-name {
  font-family: 'Source Serif Pro', serif;
  font-weight: 700;
  color: var(--navy);
  font-size: 14px;
  margin-bottom: 4px;
  letter-spacing: -0.005em;
}
.method-card .method-label {
  font-size: 9.5px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.13em;
  margin-bottom: 8px;
  font-weight: 600;
}
.method-card .method-price {
  font-family: 'Source Serif Pro', serif;
  font-weight: 700;
  font-size: 22px;
  color: var(--navy);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}
.method-card .method-meta {
  font-size: 10.5px;
  color: var(--charcoal-2);
  line-height: 1.45;
}
.method-card.headline .method-price { color: var(--terra); }
.method-card.headline::before {
  content: 'HEADLINE';
  display: block;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--terra);
  letter-spacing: 0.18em;
  margin-bottom: 4px;
}

.convergence-bar-wrap {
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 18px 22px;
}
.convergence-bar-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 12px;
}
.convergence-bar-title .label {
  font-size: 12px;
  font-weight: 600;
  color: var(--charcoal);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.convergence-band-pill {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: white;
}
.convergence-band-pill.TIGHT { background: var(--green); }
.convergence-band-pill.MODERATE { background: var(--yellow); }
.convergence-band-pill.WIDE { background: var(--red); }
.convergence-band-pill.INSUFFICIENT { background: var(--muted); }

.convergence-bar {
  position: relative;
  height: 36px;
  background: linear-gradient(90deg, #C8E6C9 0%, #FFE0B2 50%, #FFCDD2 100%);
  border-radius: 18px;
  margin: 18px 0 8px;
  overflow: visible;
}
.convergence-bar.uniform-tight { background: linear-gradient(90deg, #C8E6C9 0%, #DFF0D8 100%); }
.convergence-marker {
  position: absolute;
  top: -8px;
  width: 4px;
  height: 52px;
  background: var(--navy);
  border-radius: 2px;
}
.convergence-marker.headline {
  background: var(--terra);
  width: 5px;
}
.convergence-marker .lbl {
  position: absolute;
  top: 56px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9.5px;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: 0.06em;
  white-space: nowrap;
}
.convergence-marker.headline .lbl { color: var(--terra); }
.convergence-range {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
  margin-top: 28px;
  font-variant-numeric: tabular-nums;
}

/* Total stacked summary for parcel */
.parcel-rollup {
  background: var(--navy);
  color: white;
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-lg);
}
.parcel-rollup .label {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.7;
  margin-bottom: 6px;
}
.parcel-rollup .val {
  font-family: 'Source Serif Pro', serif;
  font-weight: 700;
  font-size: 42px;
  letter-spacing: -0.01em;
  color: var(--gold-soft);
  font-variant-numeric: tabular-nums;
}
.parcel-rollup .sub {
  font-size: 12px;
  opacity: 0.7;
  margin-top: 4px;
}

/* Unit table v4 — 5 method columns */
.unit-table-v4 {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-top: 12px;
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.unit-table-v4 th, .unit-table-v4 td {
  padding: 12px 14px;
  font-size: 13px;
  text-align: right;
  border-bottom: 1px solid var(--warm-gray);
  font-variant-numeric: tabular-nums;
}
.unit-table-v4 th {
  background: var(--navy);
  color: white;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}
.unit-table-v4 th:first-child, .unit-table-v4 td:first-child { text-align: left; font-weight: 600; }
.unit-table-v4 td.headline-col {
  background: #F5EDDD;
  font-weight: 700;
  color: var(--navy);
}
.unit-table-v4 tr:last-child td { border-bottom: none; }
.unit-table-v4 tr.total-row td {
  background: var(--cream);
  font-weight: 700;
  border-top: 2px solid var(--navy);
}

/* Methodology callout */
.methodology-callout {
  background: var(--cream);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-top: 18px;
  font-size: 12.5px;
  color: var(--charcoal-2);
  line-height: 1.5;
}
.methodology-callout strong { color: var(--navy); }

/* v4 page-tag */
.v4-tag {
  display: inline-block;
  background: var(--terra);
  color: white;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-left: 8px;
  vertical-align: middle;
}


/* ========== V5: AMI Scenarios Table ========== */
.ami-scenarios-card {
  background: var(--warm-white);
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin: 24px 0;
  box-shadow: var(--shadow-md);
}
.ami-scenarios-card h3 {
  font-family: 'Source Serif Pro', Georgia, serif;
  color: var(--navy);
  font-size: 22px;
  margin-bottom: 4px;
}
.ami-scenarios-card .sub {
  color: var(--charcoal-2);
  font-size: 13px;
  margin-bottom: 18px;
}
.ami-table-v5 {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  font-variant-numeric: tabular-nums;
}
.ami-table-v5 th, .ami-table-v5 td {
  padding: 12px 14px;
  font-size: 13px;
  border-bottom: 1px solid var(--warm-gray);
  text-align: right;
}
.ami-table-v5 th {
  background: var(--navy);
  color: white;
  font-weight: 600;
  font-size: 10.5px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  text-align: center;
}
.ami-table-v5 th:first-child,
.ami-table-v5 td:first-child {
  text-align: left;
  font-weight: 600;
}
.ami-table-v5 tr:last-child td { border-bottom: none; }
.ami-table-v5 tr.best-row {
  background: linear-gradient(180deg, #FFF6EE 0%, #FAF8F3 100%);
  border-left: 5px solid var(--terra);
}
.ami-table-v5 tr.best-row td { font-weight: 700; color: var(--navy); }
.ami-table-v5 .scen-name {
  font-family: 'Source Serif Pro', serif;
  color: var(--navy);
  font-weight: 700;
}
.ami-table-v5 .pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
}
.ami-table-v5 .pill.best { background: var(--terra); color: white; }
.ami-table-v5 .pill.bonus { background: var(--gold); color: white; }
.ami-table-v5 .pill.free { background: var(--green); color: white; }
.ami-table-v5 .pill.binding { background: var(--red); color: white; }

/* ========== V5: Waterfall Tier Cards ========== */
.tier-cards-v5 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin: 18px 0 8px;
}
.tier-card-v5 {
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  box-shadow: var(--shadow-sm);
}
.tier-card-v5 .pool-label {
  font-size: 10px;
  letter-spacing: 0.15em;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--terra);
  margin-bottom: 2px;
}
.tier-card-v5 .pool-name {
  font-family: 'Source Serif Pro', serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 12px;
}
.tier-card-v5 .tier-badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  border-radius: 4px;
  margin-right: 10px;
}
.tier-card-v5 .tier-badge.T1 { background: #c8e6c9; color: #1b5e20; }
.tier-card-v5 .tier-badge.T2 { background: #fff3cd; color: #856404; }
.tier-card-v5 .tier-badge.T3 { background: #ffcdd2; color: #b71c1c; }
.tier-card-v5 .tier-badge.T4, .tier-card-v5 .tier-badge.T5 { background: var(--red); color: white; }
.tier-card-v5 .tier-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 13px;
  border-bottom: 1px dotted var(--warm-gray);
}
.tier-card-v5 .tier-row:last-child { border-bottom: 0; }
.tier-card-v5 .tier-row .key { color: var(--charcoal-2); }
.tier-card-v5 .tier-row .v {
  font-weight: 600;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.tier-card-v5 .pool-headline {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 2px solid var(--navy);
  font-size: 28px;
  font-family: 'Source Serif Pro', serif;
  color: var(--terra);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.tier-card-v5 .nela-banner {
  margin-top: 10px;
  background: #FFF3CD;
  border-left: 3px solid var(--yellow);
  color: #856404;
  padding: 8px 12px;
  font-size: 12px;
  border-radius: 4px;
}

/* ========== V5: Adjustment ledger compact ========== */
.adj-compact {
  background: var(--cream);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-top: 10px;
  font-size: 12px;
}
.adj-compact .row {
  display: flex;
  justify-content: space-between;
  padding: 3px 0;
  font-variant-numeric: tabular-nums;
}
.adj-compact .row .neg { color: var(--red); font-weight: 600; }
.adj-compact .row .pos { color: var(--green); font-weight: 600; }
.adj-compact .row .neutral { color: var(--muted); }

/* ========== V5: Prediction table ========== */
.pred-v5 {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-top: 12px;
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  font-variant-numeric: tabular-nums;
}
.pred-v5 th, .pred-v5 td {
  padding: 12px 14px;
  font-size: 13px;
  text-align: right;
  border-bottom: 1px solid var(--warm-gray);
}
.pred-v5 th {
  background: var(--navy);
  color: white;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}
.pred-v5 th:first-child, .pred-v5 td:first-child { text-align: left; font-weight: 600; }
.pred-v5 td.headline-col {
  background: #F5EDDD;
  font-weight: 700;
  color: var(--navy);
}
.pred-v5 tr.total-row td {
  background: var(--cream);
  font-weight: 700;
  border-top: 2px solid var(--navy);
}
.pred-v5 .pool-pill {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  margin-right: 4px;
}
.pred-v5 .pool-pill.SFR { background: var(--gold); color: white; }
.pred-v5 .pool-pill.TH { background: var(--terra); color: white; }
.pred-v5 .tier-mini {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
}
.pred-v5 .tier-mini.T1 { background: #c8e6c9; color: #1b5e20; }
.pred-v5 .tier-mini.T2 { background: #fff3cd; color: #856404; }
.pred-v5 .tier-mini.T3, .pred-v5 .tier-mini.T4, .pred-v5 .tier-mini.T5 { background: var(--red); color: white; }

/* v5 page-tag */
.v5-tag {
  display: inline-block;
  background: var(--gold);
  color: white;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-left: 8px;
  vertical-align: middle;
}

/* NELA banner on hero */
.nela-hero-banner {
  margin: 0 0 16px;
  background: #FFF3CD;
  border-left: 5px solid var(--yellow);
  padding: 14px 22px;
  border-radius: var(--radius-md);
  font-size: 13px;
  color: #856404;
}
.nela-hero-banner strong { color: var(--navy); }

/* AMI vs Market visualization */
.ami-vis {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 18px 0;
}
.ami-vis-card {
  background: white;
  border: 1px solid var(--warm-gray);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}
.ami-vis-card .title {
  font-family: 'Source Serif Pro', serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 8px;
}
.ami-vis-card .bar {
  position: relative;
  height: 24px;
  background: var(--warm-gray);
  border-radius: 4px;
  margin: 8px 0;
}
.ami-vis-card .bar .fill {
  position: absolute;
  top: 0; bottom: 0; left: 0;
  background: linear-gradient(90deg, var(--gold-soft), var(--terra));
  border-radius: 4px;
}
.ami-vis-card .bar .cap-line {
  position: absolute;
  top: -4px; bottom: -4px;
  width: 2px;
  background: var(--navy);
}
.ami-vis-card .legend {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
