/* ============================================================
   MyQuoteQuest — Shared Stylesheet
   Palette: Trust & Tranquility — Navy #143A75 | Orange #FF5733 | Bone #FFFBF3
   ============================================================ */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --navy:    #143A75;
  --navy-dk: #0f2d5e;
  --orange:  #FF5733;
  --orange-dk: #e04420;
  --bone:    #FFFBF3;
  --lavender: #DCD5C9;
  --white:   #FFFFFF;
  --gray-50: #FFFBF3;
  --gray-100:#F3F4F6;
  --gray-200:#E5E7EB;
  --gray-400:#9CA3AF;
  --gray-600:#4B5563;
  --gray-800:#1F2937;
  --radius:  10px;
  --shadow:  0 4px 24px rgba(20,58,117,0.10);
  --font:    'Segoe UI', system-ui, -apple-system, sans-serif;
}

html { font-size: 16px; }

body {
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--gray-50);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ---- HEADER / NAV ---- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 0 1.5rem;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--navy);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-icon svg {
  width: 20px;
  height: 20px;
  fill: var(--white);
}

.logo-text {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -0.02em;
}

.logo-text span {
  color: var(--orange);
}

.header-badge {
  font-size: 0.75rem;
  color: var(--gray-600);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.header-badge svg {
  width: 14px;
  height: 14px;
  stroke: var(--navy);
  fill: none;
}

/* ---- HERO / LANDING ---- */
.hero {
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem 2rem;
  text-align: center;
}

.hero-card {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 3rem 2.5rem;
  max-width: 520px;
  width: 100%;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #EEF3FB;
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 100px;
  padding: 0.3rem 0.85rem;
  margin-bottom: 1.25rem;
}

.hero-eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--orange);
  display: inline-block;
}

.hero h1 {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  color: var(--navy);
  margin-bottom: 0.75rem;
  letter-spacing: -0.03em;
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--gray-600);
  margin-bottom: 2rem;
}

/* ---- FORM ELEMENTS ---- */
.form-group {
  margin-bottom: 1rem;
  text-align: left;
}

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 0.4rem;
}

select, input[type="text"], input[type="date"],
input[type="email"], input[type="tel"],
input[type="number"] {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-family: var(--font);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--gray-800);
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none;
  -webkit-appearance: none;
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 24 24'%3E%3Cpath stroke='%234B5563' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2.5rem;
}

select:focus, input:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(74,90,149,0.12);
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.875rem 2rem;
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
  text-decoration: none;
  font-family: var(--font);
  letter-spacing: -0.01em;
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--orange);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(255,87,51,0.35);
  width: 100%;
}

.btn-primary:hover {
  background: var(--orange-dk);
  box-shadow: 0 6px 18px rgba(255,87,51,0.45);
}

.btn-secondary {
  background: var(--gray-100);
  color: var(--gray-600);
  border: 1.5px solid var(--gray-200);
}

.btn-secondary:hover {
  background: var(--gray-200);
}

/* ---- TRUST LINE ---- */
.trust-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--gray-400);
  margin-top: 0.85rem;
}

.trust-line svg {
  width: 14px;
  height: 14px;
  stroke: var(--gray-400);
  fill: none;
}

/* ---- TRUST BADGES ---- */
.trust-badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

.trust-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  color: var(--gray-600);
  font-weight: 500;
}

.trust-badge svg {
  width: 22px;
  height: 22px;
  stroke: var(--navy);
  fill: none;
  opacity: 0.7;
}

/* ---- FOOTER ---- */
.site-footer {
  text-align: center;
  padding: 2rem 1.5rem;
  font-size: 0.78rem;
  color: var(--gray-400);
  line-height: 1.7;
  max-width: 680px;
  margin: 0 auto;
}

.site-footer a {
  color: var(--navy);
  text-decoration: none;
  font-weight: 500;
}

.site-footer a:hover { text-decoration: underline; }

.footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 0.8rem;
}

.footer-sep {
  color: var(--gray-200);
}

/* ============================================================
   QUOTE FORM PAGE
   ============================================================ */

.quote-page {
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 2rem 1.5rem 3rem;
}

/* ---- PROGRESS BAR ---- */
.progress-wrap {
  width: 100%;
  max-width: 560px;
  margin-bottom: 1.75rem;
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.progress-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--gray-400);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: color 0.2s;
}

.progress-label.active { color: var(--navy); }
.progress-label.done   { color: var(--orange); }

.progress-bar-track {
  height: 6px;
  background: var(--gray-200);
  border-radius: 100px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--navy), var(--orange));
  border-radius: 100px;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-step-text {
  font-size: 0.78rem;
  color: var(--gray-400);
  margin-top: 0.4rem;
  text-align: right;
}

/* ---- QUOTE CARD ---- */
.quote-card {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 2.5rem 2.5rem 2rem;
  max-width: 560px;
  width: 100%;
}

.step-header {
  margin-bottom: 1.75rem;
}

.step-header h2 {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
  margin-bottom: 0.3rem;
}

.step-header p {
  font-size: 0.9rem;
  color: var(--gray-600);
}

/* ---- STEP PANELS ---- */
.step-panel {
  display: none;
}
.step-panel.active {
  display: block;
  animation: fadeSlide 0.3s ease;
}

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- GENDER TOGGLE ---- */
.gender-toggle {
  display: flex;
  gap: 0.75rem;
}

.gender-btn {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--gray-600);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-family: var(--font);
}

.gender-btn:hover {
  border-color: var(--navy);
  color: var(--navy);
}

.gender-btn.selected {
  background: #EEF3FB;
  border-color: var(--navy);
  color: var(--navy);
}

/* ---- HEIGHT / WEIGHT ROW ---- */
.row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

/* ---- TOBACCO TOGGLE ---- */
.yesno-toggle {
  display: flex;
  gap: 0.75rem;
}

.yesno-btn {
  flex: 1;
  padding: 0.75rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--gray-600);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--font);
}

.yesno-btn:hover { border-color: var(--navy); color: var(--navy); }
.yesno-btn.selected { background: #EEF3FB; border-color: var(--navy); color: var(--navy); }
.yesno-btn.selected-yes { background: #FFF3EE; border-color: var(--orange); color: var(--orange); }

/* ---- COVERAGE TILES ---- */
.tile-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 0.6rem;
}

.tile-btn {
  padding: 0.75rem 0.5rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--gray-600);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
  font-family: var(--font);
}

.tile-btn:hover { border-color: var(--navy); color: var(--navy); }

.tile-btn.selected {
  background: #EEF3FB;
  border-color: var(--navy);
  color: var(--navy);
}

/* ---- NAV BUTTONS ---- */
.form-nav {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.75rem;
  align-items: center;
}

.form-nav .btn-secondary { flex: 0 0 auto; min-width: 100px; }
.form-nav .btn-primary   { flex: 1; }

.btn-back-only { margin-top: 1.75rem; }

/* ---- ERROR ---- */
.field-error {
  font-size: 0.78rem;
  color: #DC2626;
  margin-top: 0.3rem;
  display: none;
}

.field-error.visible { display: block; }

input.error, select.error {
  border-color: #DC2626;
}

/* ============================================================
   RESULTS PAGE
   ============================================================ */

.results-page {
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  text-align: center;
}

.results-card {
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 3.5rem 2.5rem;
  max-width: 480px;
  width: 100%;
}

/* ---- SPINNER ---- */
.spinner {
  width: 60px;
  height: 60px;
  margin: 0 auto 2rem;
  position: relative;
}

.spinner::before,
.spinner::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 4px solid transparent;
}

.spinner::before {
  border-top-color: var(--navy);
  animation: spin 1s linear infinite;
}

.spinner::after {
  border-bottom-color: var(--orange);
  animation: spin 1.5s linear infinite reverse;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.results-card h2 {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.results-card p {
  color: var(--gray-600);
  font-size: 0.95rem;
  line-height: 1.7;
}

.coming-soon-badge {
  display: inline-block;
  background: #FFF3EE;
  color: var(--orange);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 100px;
  padding: 0.3rem 0.9rem;
  margin-top: 1.5rem;
  border: 1.5px solid rgba(255,87,51,0.25);
}

/* ============================================================
   POLICY PAGES (Privacy / Terms)
   ============================================================ */

.policy-page {
  max-width: 740px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

.policy-page h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 0.5rem;
  letter-spacing: -0.03em;
}

.policy-date {
  font-size: 0.85rem;
  color: var(--gray-400);
  margin-bottom: 2.5rem;
}

.policy-page h2 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  margin: 2rem 0 0.6rem;
}

.policy-page p, .policy-page li {
  font-size: 0.95rem;
  color: var(--gray-600);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}

.policy-page ul, .policy-page ol {
  padding-left: 1.5rem;
}

.policy-page a { color: var(--navy); }

.policy-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--navy);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  margin-bottom: 2rem;
}

.policy-back:hover { text-decoration: underline; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 600px) {
  .hero-card,
  .quote-card,
  .results-card {
    padding: 2rem 1.25rem 1.5rem;
    border-radius: 14px;
  }

  .hero h1 { font-size: 1.6rem; }

  .row-2 { grid-template-columns: 1fr 1fr; }

  .tile-group {
    grid-template-columns: repeat(3, 1fr);
  }

  .trust-badges { gap: 1rem; }

  .header-badge { display: none; }

  .step-header h2 { font-size: 1.25rem; }
}

@media (max-width: 400px) {
  .tile-group { grid-template-columns: repeat(2, 1fr); }
  .row-2 { grid-template-columns: 1fr; }
}

/* === LANDING v2 === */
.check-list { list-style:none; padding:0; margin:0 0 2rem; display:flex; flex-direction:column; gap:.75rem; text-align:left; }
.check-list li { display:flex; align-items:center; gap:.6rem; font-size:.97rem; color:var(--gray-800); font-weight:500; }
.check-list svg { width:20px; height:20px; min-width:20px; background:#22c55e; border-radius:50%; stroke:white; fill:none; padding:3px; }
.trust-micro { display:flex; align-items:center; justify-content:center; gap:.3rem; font-size:.8rem; color:var(--gray-400); margin-top:1rem; flex-wrap:wrap; }
.trust-micro svg { width:13px; height:13px; stroke:var(--gray-400); fill:none; }

/* === FUNNEL v2 === */
.funnel-page { min-height:calc(100vh - 64px); background:var(--gray-50); display:flex; flex-direction:column; align-items:center; padding:1.5rem 1.25rem 3rem; }
.funnel-progress { width:100%; max-width:600px; margin-bottom:1.25rem; }
.funnel-progress-top { display:flex; justify-content:space-between; font-size:.8rem; color:var(--gray-600); font-weight:600; margin-bottom:.4rem; }
.funnel-track { height:6px; background:var(--gray-200); border-radius:100px; overflow:hidden; }
.funnel-fill { height:100%; background:#22c55e; border-radius:100px; transition:width .4s cubic-bezier(.4,0,.2,1); }
.funnel-card { background:var(--white); border-radius:18px; box-shadow:var(--shadow); padding:2rem 2rem 2.5rem; max-width:600px; width:100%; }
.funnel-back { display:inline-flex; align-items:center; gap:.3rem; font-size:.88rem; color:var(--gray-600); text-decoration:none; font-weight:500; margin-bottom:1.5rem; cursor:pointer; background:none; border:none; padding:0; font-family:var(--font); }
.funnel-back:hover { color:var(--gray-800); }
.funnel-question { font-size:1.6rem; font-weight:800; color:var(--gray-800); letter-spacing:-.02em; line-height:1.25; margin-bottom:.4rem; }
.funnel-hint { font-size:.92rem; color:var(--gray-600); margin-bottom:1.75rem; }
.funnel-feedback { font-size:.88rem; color:#16a34a; display:flex; align-items:center; gap:.3rem; margin-top:.5rem; min-height:1.25rem; }
.choice-group { display:grid; grid-template-columns:1fr 1fr; gap:.75rem; }
.choice-group.four-col { grid-template-columns:repeat(4,1fr); }
.choice-btn { padding:1.1rem 1rem; border:2px solid var(--gray-200); border-radius:12px; background:var(--white); color:var(--gray-800); font-size:1rem; font-weight:600; cursor:pointer; transition:all .15s; text-align:center; font-family:var(--font); }
.choice-btn:hover, .choice-btn.selected { border-color:var(--navy); color:var(--navy); background:#EEF3FB; }
.tile-row { display:grid; grid-template-columns:repeat(5,1fr); gap:.6rem; }
.tile-row.six-col { grid-template-columns:repeat(6,1fr); }
.hw-group { display:grid; grid-template-columns:1fr 1fr 1fr; gap:.75rem; margin-bottom:1.5rem; }
.contact-fields { display:flex; flex-direction:column; gap:1rem; margin-bottom:1.5rem; }
.contact-row { display:grid; grid-template-columns:1fr 1fr; gap:.75rem; }
.funnel-label { display:block; font-size:.82rem; font-weight:600; color:var(--navy); margin-bottom:.35rem; text-transform:uppercase; letter-spacing:.04em; }
.consent-text { font-size:.75rem; color:var(--gray-400); text-align:center; margin-top:.75rem; line-height:1.5; }
.consent-text a { color:var(--navy); }
@media(max-width:560px){
  .funnel-card{padding:1.5rem 1.25rem 2rem;}
  .funnel-question{font-size:1.35rem;}
  .choice-group.four-col{grid-template-columns:repeat(2,1fr);}
  .tile-row{grid-template-columns:repeat(3,1fr);}
  .tile-row.six-col{grid-template-columns:repeat(3,1fr);}
  .hw-group{grid-template-columns:1fr 1fr;}
  .contact-row{grid-template-columns:1fr;}
  .hero-card{padding:2rem 1.25rem 2rem;}
  .hero-card h1, .hero h1{font-size:1.65rem;}
}
@media(max-width:380px){.tile-row{grid-template-columns:repeat(2,1fr);}}
