/* === DEAL DETAIL PAGE === */

/* Header */
.detail-header {
  background: var(--navy);
  padding: 3rem 4rem 3.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.detail-header-inner { max-width: 1200px; margin: 0 auto; }

.detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.breadcrumb-link {
  font-size: 0.8125rem;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  text-decoration: none;
  transition: color 0.2s;
}
.breadcrumb-link:hover { color: rgba(255,255,255,0.8); }

.breadcrumb-sep { color: rgba(255,255,255,0.25); font-size: 0.75rem; }

.breadcrumb-sample {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(184,146,74,0.12);
  padding: 0.15rem 0.5rem;
  border-radius: 2px;
}

.detail-hero-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 3rem;
}

.detail-hero-left { flex: 1; }

.detail-eyebrow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.source-icon-sm { font-size: 0.75rem; color: var(--gold-light); }
.detail-source-name {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
}
.detail-asset-class {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.45);
}

.detail-headline {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 700;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 0.5rem;
}

.detail-address {
  font-size: 1rem;
  color: rgba(255,255,255,0.5);
  margin-bottom: 1.25rem;
}

.detail-price-row {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.detail-price {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.detail-units-badge {
  font-size: 0.8125rem;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  background: rgba(255,255,255,0.07);
  padding: 0.25rem 0.65rem;
  border-radius: 2px;
  letter-spacing: 0.04em;
}

.detail-source-link {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--gold-light);
  text-decoration: none;
  transition: color 0.2s;
}
.detail-source-link:hover { color: #fff; }

/* Score Card */
.detail-score-card {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  padding: 2rem 2.5rem;
  text-align: center;
  min-width: 200px;
}

.score-circle {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
}

.score-hot { background: var(--green); }
.score-warm { background: #A87F2A; }
.score-cool { background: var(--text-muted); }

.score-number {
  font-family: var(--font-serif);
  font-size: 2.25rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.score-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
}

.score-context {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.45);
  line-height: 1.5;
  max-width: 180px;
}

/* Main Content */
.detail-main {
  background: var(--cream);
  padding-bottom: 6rem;
}

.detail-main-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3.5rem 4rem 0;
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.detail-section {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2.25rem;
}

.section-heading {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

.section-sub {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

/* Underwriting Grid */
.uw-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.uw-metric {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 1.25rem;
  background: var(--bg-alt);
  border-radius: 3px;
  border: 1px solid var(--border);
}

.uw-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.uw-value {
  font-family: var(--font-serif);
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.1;
}

.uw-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}

.val-good { color: var(--green) !important; }
.val-ok   { color: #A87F2A !important; }
.val-warn { color: var(--red) !important; }

/* Stress Tables */
.stress-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.stress-section { padding: 2rem; }

.stress-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.stress-table th {
  text-align: left;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0.625rem 0.75rem;
  border-bottom: 2px solid var(--border);
}

.stress-table td {
  padding: 0.75rem 0.75rem;
  color: var(--navy);
  border-bottom: 1px solid var(--border);
  font-weight: 500;
}

.stress-row-base td {
  background: rgba(184,146,74,0.06);
  font-weight: 600;
}

.stress-scenario { font-weight: 500; }

.base-tag {
  display: inline-block;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(184,146,74,0.12);
  padding: 0.1rem 0.4rem;
  border-radius: 2px;
  margin-left: 0.375rem;
  vertical-align: middle;
}

.dscr-status {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
  letter-spacing: 0.04em;
}
.dscr-status--good  { background: rgba(45,106,79,0.1); color: var(--green); }
.dscr-status--ok    { background: rgba(168,127,42,0.1); color: #A87F2A; }
.dscr-status--warn  { background: rgba(139,58,58,0.1); color: var(--red); }

.stress-footnote {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 1rem;
}

/* Comps Table */
.comps-table-wrap { overflow-x: auto; }

.comps-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.comps-table th {
  text-align: left;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0.625rem 0.75rem;
  border-bottom: 2px solid var(--border);
}

.comps-table td {
  padding: 0.75rem 0.75rem;
  color: var(--navy);
  border-bottom: 1px solid var(--border);
}

.comp-address { font-weight: 500; }
.comp-rent { font-weight: 600; color: var(--navy); }

.comps-disclaimer {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 1rem;
  font-style: italic;
}

/* Risk Flags */
.risk-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  margin-top: 0.5rem;
}

.risk-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: rgba(139,58,58,0.04);
  border: 1px solid rgba(139,58,58,0.12);
  border-radius: 3px;
}

.risk-icon {
  font-size: 0.875rem;
  color: var(--red);
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.risk-text {
  font-size: 0.9rem;
  color: var(--navy);
  line-height: 1.55;
}

/* Rationale */
.rationale-section { background: var(--navy); border-color: transparent; }

.rationale-header { margin-bottom: 1.5rem; }

.rationale-eyebrow {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 0.5rem;
}

.rationale-heading {
  color: #fff;
  margin-bottom: 0;
}

.rationale-body { display: flex; flex-direction: column; gap: 1.25rem; }

.rationale-para {
  font-size: 1rem;
  color: rgba(255,255,255,0.7);
  line-height: 1.75;
}

.rationale-disclaimer {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.35);
  margin-top: 1.5rem;
  font-style: italic;
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1rem;
}

/* Bottom CTA */
.detail-cta-section {
  background: linear-gradient(135deg, #f7f3ec 0%, #eee8d8 100%);
  border: 1px solid rgba(184,146,74,0.25);
  border-radius: 4px;
  padding: 3rem;
  text-align: center;
}

.detail-cta-inner { max-width: 560px; margin: 0 auto; }

.detail-cta-headline {
  font-family: var(--font-serif);
  font-size: clamp(1.375rem, 2vw, 1.75rem);
  font-weight: 600;
  color: var(--navy);
  line-height: 1.25;
  margin-bottom: 0.875rem;
}

.detail-cta-body {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 1.75rem;
}

.detail-cta-btn {
  display: inline-block;
  background: var(--navy);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  padding: 0.875rem 2.25rem;
  border-radius: 3px;
  text-decoration: none;
  transition: background 0.2s;
}
.detail-cta-btn:hover { background: #0a1e30; }

/* Responsive */
@media (max-width: 1024px) {
  .uw-grid { grid-template-columns: repeat(3, 1fr); }
  .stress-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .detail-header { padding: 2.5rem 1.5rem 3rem; }
  .detail-main-inner { padding: 2rem 1.5rem 0; }
  .detail-section { padding: 1.5rem; }
  .detail-hero-row { flex-direction: column; gap: 2rem; }
  .detail-score-card { width: 100%; flex-direction: row; justify-content: flex-start; padding: 1.5rem; }
  .uw-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-cta-section { padding: 2rem 1.5rem; }
  .stress-grid { grid-template-columns: 1fr; gap: 1rem; }
}

@media (max-width: 480px) {
  .uw-grid { grid-template-columns: 1fr 1fr; }
}
