/**
 * estimator.css — TF3 Trifecta Solutions
 * Estimator component styles only. Do not import into style.css.
 * CB-011 · Forge · 6 May 2026
 * Brand tokens: #000000 Obsidian · #047747 Vitality Green · #8E99A2 Alloy Grey · #FFFFFF Precision White
 */

/* ── Layout ─────────────────────────────────────────────────────────────── */
.est-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 32px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 80px 80px;
}
.est-right { position: sticky; top: 140px; }
@media (max-width: 1100px) { .est-layout { grid-template-columns: 1fr; } .est-right { position: static; } }
@media (max-width: 768px)  { .est-layout { padding: 0 20px 48px; } }

/* ── Section headers ────────────────────────────────────────────────────── */
.est-section { margin-bottom: 28px; }
.est-section-header { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.est-step-badge {
  background: #047747; color: #000;
  font-family: 'DM Mono', monospace; font-size: 10px; font-weight: 700;
  letter-spacing: 0.1em; padding: 3px 9px; border-radius: 0;
}
.est-step-badge.done { background: #035e38; }
.est-step-title { font-weight: 600; font-size: 14px; color: #fff; text-transform: uppercase; letter-spacing: 0.06em; }
.est-required { font-size: 11px; color: #047747; font-family: 'DM Mono', monospace; letter-spacing: 0.08em; }
.est-optional  { font-size: 11px; color: #8E99A2; }
.est-design-sub { font-size: 11px; color: #8E99A2; letter-spacing: 0.08em; text-transform: uppercase; font-family: 'DM Mono', monospace; margin: 12px 0 8px; }

/* ── Base bundle cards ───────────────────────────────────────────────────── */
.est-base-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
@media (max-width: 900px) { .est-base-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .est-base-grid { grid-template-columns: 1fr; } }

.est-base-card {
  background: #202322; border: 1px solid rgba(255,255,255,0.08);
  border-radius: 0; padding: 20px 16px; cursor: pointer;
  position: relative; transition: border-color 0.15s;
}
.est-base-card:hover { border-color: rgba(4,119,71,0.5); }
.est-base-card.selected { border: 2px solid #047747; background: rgba(4,119,71,0.07); }
.est-base-card--ref { cursor: default; opacity: 0.65; }
.est-base-card--ref:hover { border-color: rgba(255,255,255,0.08); }

.est-recommended-badge {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  background: #047747; color: #fff;
  font-size: 9px; font-weight: 700; letter-spacing: 0.1em;
  padding: 3px 10px; white-space: nowrap; border-radius: 0;
}
.est-base-name { font-family: 'DM Mono', monospace; font-size: 10px; color: #047747; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 6px; margin-top: 8px; }
.est-base-price { font-size: 28px; font-weight: 700; color: #fff; line-height: 1; }
.est-base-price span { font-size: 12px; font-weight: 400; color: #8E99A2; }
.est-base-cta { display: block; margin-top: 12px; font-size: 12px; color: #047747; font-weight: 600; text-decoration: none; }
.est-base-cta--ref { color: #8E99A2; }

/* ── Pill selectors ─────────────────────────────────────────────────────── */
.est-pill-group { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }

.est-pill {
  background: transparent; border: 1px solid rgba(255,255,255,0.15);
  border-radius: 0; color: #fff;
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  padding: 8px 14px; cursor: pointer; transition: border-color 0.15s, background 0.15s;
  text-align: left;
}
.est-pill:hover  { border-color: #047747; background: rgba(4,119,71,0.07); }
.est-pill:focus  { outline: none; border-radius: 0; }
.est-pill.selected { border-color: #047747; background: rgba(4,119,71,0.14); color: #fff; }
.est-pill--scoped.selected { border-color: #8E99A2; background: rgba(142,153,162,0.1); }
.est-pill-price { color: #8E99A2; font-size: 11px; margin-left: 6px; }
.est-pill.selected .est-pill-price { color: #67c29a; }

/* ── Controls (toggles) ────────────────────────────────────────────────── */
.est-controls { display: flex; flex-direction: column; gap: 12px; margin-bottom: 28px; }
.est-toggle { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; color: #8E99A2; }
.est-toggle input { accent-color: #047747; width: 16px; height: 16px; cursor: pointer; }
.est-toggle-note { font-size: 11px; color: #047747; }

/* ── Summary panel ──────────────────────────────────────────────────────── */
.est-summary-panel {
  background: rgba(4,119,71,0.06); border: 1px solid #047747;
  border-radius: 0; padding: 28px;
}
.est-summary-heading {
  font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: 0.14em;
  text-transform: uppercase; color: #8E99A2;
  border-bottom: 1px solid rgba(4,119,71,0.25); padding-bottom: 14px; margin-bottom: 20px;
}
.est-summary-total { font-size: 40px; font-weight: 700; color: #fff; line-height: 1; margin-bottom: 6px; }
.est-summary-annual { font-size: 13px; color: #8E99A2; margin-bottom: 8px; }
.est-summary-note { font-size: 12px; color: #047747; margin-bottom: 6px; line-height: 1.5; }
#est-oneoff-line { font-size: 14px; color: #FFFFFF; }
.est-summary-lines { margin: 16px 0; display: flex; flex-direction: column; gap: 8px; min-height: 40px; }
.est-line { display: flex; justify-content: space-between; font-size: 13px; color: #8E99A2; gap: 8px; }
.est-line-empty { font-size: 13px; color: rgba(142,153,162,0.5); font-style: italic; }
.est-summary-divider { border: none; border-top: 1px solid rgba(255,255,255,0.08); margin: 16px 0; }
.est-summary-legal { font-size: 10px; color: rgba(142,153,162,0.6); margin-top: 14px; line-height: 1.6; }
.est-mixed-note { font-size: 11px; color: #8E99A2; margin: 8px 0; line-height: 1.5; }

/* ── CTA buttons ────────────────────────────────────────────────────────── */
.est-btn-primary {
  display: block; width: 100%; background: #047747; color: #fff;
  border: none; border-radius: 0; padding: 14px 20px;
  font-family: var(--font-body); font-size: 14px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer;
  text-align: center; text-decoration: none; margin-bottom: 10px;
  transition: background 0.2s; -webkit-appearance: none; appearance: none;
  box-sizing: border-box;
}
.est-btn-primary:hover { background: #035e38; color: #fff; }
.est-btn-primary.disabled { background: #2a2a2a; color: #555; cursor: default; pointer-events: none; }
.est-btn-ghost {
  display: block; width: 100%; background: transparent;
  border: 1px solid rgba(255,255,255,0.25); border-radius: 0;
  color: #fff; padding: 13px 20px;
  font-family: var(--font-body); font-size: 14px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer;
  text-align: center; text-decoration: none; margin-bottom: 10px;
  transition: border-color 0.2s;
}
.est-btn-ghost:hover { border-color: rgba(255,255,255,0.6); color: #fff; }

/* ── Quote form ─────────────────────────────────────────────────────────── */
.est-form-heading { font-size: 15px; font-weight: 600; color: #fff; margin-bottom: 14px; }
.est-input {
  display: block; width: 100%; box-sizing: border-box;
  background: #0d0d0d; border: 1px solid rgba(255,255,255,0.15);
  border-radius: 0; color: #fff; padding: 10px 14px;
  font-family: var(--font-body); font-size: 14px;
  margin-bottom: 10px; outline: none;
}
.est-input:focus { border-color: #047747; }
.est-confirm { color: #047747; font-size: 14px; margin-top: 10px; }

/* ── Progress rail ──────────────────────────────────────────────────────── */
.est-progress-rail {
  display: flex; gap: 0; margin-bottom: 32px; border: 1px solid rgba(255,255,255,0.08);
}
.est-progress-step {
  flex: 1; padding: 12px 16px; font-family: 'DM Mono', monospace;
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  color: #8E99A2; border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; align-items: center; gap: 8px; cursor: default;
  transition: background 0.2s;
}
.est-progress-step:last-child { border-right: none; }
.est-progress-step.done { background: rgba(4,119,71,0.08); color: #047747; }
.est-progress-step .est-check { width: 14px; height: 14px; border: 1px solid #8E99A2; border-radius: 0; flex-shrink: 0; }
.est-progress-step.done .est-check { background: #047747; border-color: #047747; }
@media (max-width: 768px) { .est-progress-rail { flex-direction: column; } .est-progress-step { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.08); } }

/* ── Amendment 2: Build type selector ──────────────────────────────────── */
.est-build-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8E99A2;
  margin-bottom: 8px;
}
.est-build-select {
  width: 100%;
  background: #0d0d0d;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 0;
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 14px;
  padding: 10px 14px;
  cursor: pointer;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238E99A2' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.est-build-select:focus { border-color: #047747; }
.est-build-select option { background: #202322; color: #ffffff; }
.est-build-note {
  font-size: 11px;
  color: #047747;
  font-family: 'DM Mono', monospace;
  margin-top: 6px;
  letter-spacing: 0.06em;
}
.est-build-warn {
  background: rgba(204,153,0,0.12);
  border: 1px solid rgba(204,153,0,0.4);
  border-radius: 0;
  color: #ccaa00;
  font-size: 12px;
  padding: 8px 12px;
  margin-bottom: 12px;
  line-height: 1.5;
}

/* ── Build type addon pills ─────────────────────────────────────────────── */
.est-build-addon-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8E99A2;
  margin: 14px 0 8px;
}
.est-build-addons { margin-top: 4px; }
