/* ============================================================
   Home Revival Pros — Carbon-copy of bathroom-costs.com
   ============================================================ */

:root {
  --error: #f23a52;
  --accent: #006bb8;
  --accent-dark: #004c84;
  --button-bg: #e63946;
  --button-bg-hover: #b22d39;
  --footer-bg: #e4ebf1;
  --baseBodyBg: #eee;
  --mainTextColor: #252b31;
  --button-text-color: #ffffff;
  --secondaryTextColor: #75838e;
  --check-blue: #1a7ac4;
  --check-green: #1ec584;
  --border: #d8e1ec;
  --progress-active: #006bb8;
  --progress-inactive: #d8e1ec;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--mainTextColor);
  background: var(--accent);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.45;
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 16px; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* ===================== TOP LOGO BAR ===================== */
.top-bar {
  background: #ffffff;
  padding: 14px 16px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.top-bar__logo {
  height: 110px;
  width: auto;
  max-width: 420px;
  display: block;
  object-fit: contain;
  margin: -28px 0; /* the PNG has whitespace padding baked in — pull margins in to compensate */
}
@media (max-width: 600px) {
  .top-bar__logo { height: 92px; max-width: 340px; margin: -22px 0; }
}

/* ===================== HERO + CARD OVERLAY PATTERN ===================== */
/* The hero image is shared across most pages, with the white card floating on top. */
.hero-section {
  position: relative;
  background-image:
    url('https://images.unsplash.com/photo-1600585154340-be6161a56a0c?w=1400&h=900&fit=crop');
  background-size: cover;
  background-position: center;
  padding: 0 0 60px;
  min-height: 360px;
}
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(238,238,238,0.0) 70%, rgba(238,238,238,1) 100%);
  pointer-events: none;
}

/* The hero image area visible above the card */
.hero-image {
  height: 180px;
  background-image: url('/assets/hero-bathroom.png');
  background-size: cover;
  background-position: center;
}

/* ===================== FORM CARD (overlays hero) ===================== */
.form-card {
  max-width: 460px;
  margin: -28px 22px 0;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 8px 28px rgba(15,23,33,0.10), 0 2px 6px rgba(15,23,33,0.06);
  padding: 0 16px 18px;
  position: relative;
  z-index: 2;
  /* overflow: hidden removed — was clipping the progress bar shadow */
}
/* Round just the top corners of the progress bar to match the card edge */
.form-card > .progress-steps:first-child {
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  overflow: hidden;
}
@media (min-width: 600px) {
  .form-card { margin-left: auto; margin-right: auto; }
}

/* ===================== BACK BUTTON ===================== */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 0;
  color: var(--secondaryTextColor);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 4px;
  margin: 4px 0 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color 150ms ease;
}
.back-btn:hover { color: var(--accent); }
.back-btn::before {
  content: '←';
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

/* ===================== 4-SEGMENT PROGRESS BAR (glued to card top, with shadow) ===================== */
.progress-steps {
  display: flex;
  gap: 0;
  margin: 0 -16px 24px;
  padding: 0;
  background: #f0f4f9;
  position: relative;
  box-shadow: 0 8px 14px -2px rgba(15,23,33,0.28);
  z-index: 4;
}
.progress-step {
  flex: 1;
  height: 7px;
  background: var(--progress-inactive);
  transition: background 200ms ease;
}
.progress-step.active {
  background: var(--progress-active);
}
.progress-step:first-child { border-top-left-radius: 0; }
.progress-step:last-child { border-top-right-radius: 0; }

/* ===================== HEADINGS (inside card) ===================== */
.eyebrow-small {
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  color: var(--secondaryTextColor);
  margin: 0 0 6px;
  text-transform: uppercase;
}
.card-h1 {
  text-align: center;
  color: var(--mainTextColor);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}
.card-eyebrow-blue {
  text-align: center;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  margin: 0 0 12px;
  text-transform: uppercase;
}
.card-h1 + .card-eyebrow-blue { margin-top: 0; }

/* Small divider line under the eyebrow */
.divider-bar {
  width: 50px;
  height: 2px;
  background: var(--check-blue);
  margin: 0 auto 14px;
}

/* ===================== Q1 SERVICE CARDS ===================== */
.question__block { margin-bottom: 14px; }
.question__block-title {
  font-size: 14px; font-weight: 700;
  color: var(--mainTextColor); margin: 0 0 10px;
}

.checkradio__with-icon-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.checkradio__with-icon-label {
  display: flex; flex-direction: column; align-items: center;
  padding: 10px 4px 8px;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  transition: border-color 150ms ease, background 150ms ease, box-shadow 150ms ease, transform 100ms ease;
  position: relative;
}
.checkradio__with-icon-label:hover {
  border-color: var(--accent);
  background: rgba(0,107,184,0.03);
}
.checkradio__with-icon-label.selected {
  border-color: var(--accent);
  background: rgba(0,107,184,0.10);
  box-shadow: 0 0 0 3px rgba(0,107,184,0.18), 0 4px 12px rgba(0,107,184,0.18);
  transform: translateY(-1px);
}
.checkradio__with-icon-label.selected .checkradio__with-icon-text {
  color: var(--accent);
  font-weight: 700;
}
/* Tint the SVG icon blue when selected */
.checkradio__with-icon-label.selected .checkradio__icon {
  filter: brightness(0) saturate(100%) invert(28%) sepia(85%) saturate(1664%) hue-rotate(187deg) brightness(95%) contrast(101%);
}
/* Checkmark badge in top-right when selected */
.checkradio__with-icon-label.selected::after {
  content: '✓';
  position: absolute;
  top: -8px; right: -8px;
  width: 22px; height: 22px;
  background: var(--accent);
  color: #fff;
  font-weight: 800; font-size: 12px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(0,107,184,0.4);
}
.checkradio__input { position: absolute; opacity: 0; pointer-events: none; }
.checkradio__icon {
  width: 38px; height: 38px;
  background-repeat: no-repeat; background-position: center; background-size: contain;
  display: block;
  margin-bottom: 6px;
  transition: filter 150ms ease;
}
.checkradio__with-icon-text {
  font-size: 12px; font-weight: 600;
  color: var(--mainTextColor);
  line-height: 1.25;
  transition: color 150ms ease;
}

/* ===================== INPUTS ===================== */
.base-input__ico-wrap { position: relative; }
.base-input {
  width: 100%;
  height: 42px;
  padding: 0 36px 0 12px;
  font-size: 14px;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: #fff;
  color: var(--mainTextColor);
  font-family: inherit;
  -webkit-appearance: none; appearance: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.base-input::placeholder { color: var(--secondaryTextColor); }
.base-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,107,184,0.10);
}
.base-input__icon-hint {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px;
  background: #c8d2dc;
  color: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800; cursor: help;
}
.base-input__icon-hint::before { content: '?'; }

/* ===================== CTA BUTTON ===================== */
.cta-1 {
  display: flex; align-items: center; justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px 20px;
  background: var(--button-bg);
  color: var(--button-text-color);
  font-size: 18px;
  font-weight: 800;
  border: 0; border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: 0;
  box-shadow: 0 4px 14px rgba(230,57,70,0.25);
  transition: background 150ms ease, transform 80ms ease, box-shadow 150ms ease;
  -webkit-tap-highlight-color: transparent;
}
.cta-1:hover { background: var(--button-bg-hover); box-shadow: 0 6px 20px rgba(230,57,70,0.32); }
.cta-1:active { transform: translateY(1px); }
.cta-1:disabled { background: #b0bcc9; box-shadow: none; cursor: not-allowed; }
.cta-1::after {
  content: '→';
  font-weight: 800; font-size: 22px;
  transition: transform 200ms ease;
}
.cta-1:hover:not(:disabled)::after { transform: translateX(3px); }
.w-100 { width: 100%; }

.beQuick {
  text-align: center;
  font-size: 13px;
  color: var(--secondaryTextColor);
  margin-top: 12px;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.beQuick__icon {
  width: 14px; height: 14px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--secondaryTextColor);
}
.beQuick__icon::before { content: '⏱'; font-size: 13px; }

/* ===================== Q3-Q6 RADIO OPTIONS ===================== */
.opt-list { display: flex; flex-direction: column; gap: 8px; }
.opt {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease, box-shadow 150ms ease;
  -webkit-tap-highlight-color: transparent;
}
.opt:hover {
  border-color: var(--accent);
  background: rgba(0,107,184,0.03);
}
.opt.selected {
  border-color: var(--accent);
  background: rgba(0,107,184,0.10);
  box-shadow: 0 0 0 3px rgba(0,107,184,0.18), 0 2px 8px rgba(0,107,184,0.15);
}
.opt.selected .text {
  color: var(--accent);
  font-weight: 700;
}
.opt .radio {
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2px solid #b0bcc9;
  flex-shrink: 0; position: relative;
  transition: all 150ms ease;
}
.opt.selected .radio {
  border-color: var(--accent);
  background: var(--accent);
}
.opt.selected .radio::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}
.opt .text { font-size: 15px; font-weight: 500; color: var(--mainTextColor); transition: color 150ms ease; }

/* ===================== FEATURE LIST (Compare Quotes & Save) ===================== */
.feature-list__section {
  background: var(--baseBodyBg);
  padding: 30px 16px;
}
.feature-list__grid {
  max-width: 920px; margin: 0 auto;
}
.feature-list__grid--noimg {
  max-width: 540px;
  text-align: left;
}
.feature-list__title-icon {
  display: inline-block;
  width: 36px; height: 36px;
  background: var(--accent);
  -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2"><rect x="3" y="3" width="7" height="7" rx="1"/><polyline points="5.5 6.5 6.5 7.5 8 5.5"/><rect x="14" y="3" width="7" height="7" rx="1"/><rect x="3" y="14" width="7" height="7" rx="1"/><rect x="14" y="14" width="7" height="7" rx="1"/></svg>') center / contain no-repeat;
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2"><rect x="3" y="3" width="7" height="7" rx="1"/><polyline points="5.5 6.5 6.5 7.5 8 5.5"/><rect x="14" y="3" width="7" height="7" rx="1"/><rect x="3" y="14" width="7" height="7" rx="1"/><rect x="14" y="14" width="7" height="7" rx="1"/></svg>') center / contain no-repeat;
  margin-bottom: 8px;
  border-left: 3px solid var(--accent);
  padding-left: 4px;
}
.feature-list__title-h2 {
  font-size: 22px; font-weight: 800; margin: 0 0 16px;
  letter-spacing: -0.02em; color: var(--mainTextColor); line-height: 1.2;
}
.feature-list__image {
  width: 100%; aspect-ratio: 4/3;
  object-fit: cover; border-radius: 8px;
  background: #ccc; margin-bottom: 18px;
}
.feature-list__text-p {
  color: var(--mainTextColor);
  font-size: 14px; margin: 0 0 14px; font-weight: 500;
}
.feature-list__text-ul {
  list-style: none; margin: 0; padding: 0;
}
.feature-list__text-ul li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 14px; padding: 8px 0; font-weight: 500;
}
.feature-list__text-ul li::before {
  content: '✓';
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  background: var(--check-blue); color: #fff;
  border-radius: 50%; font-size: 12px; font-weight: 800;
  flex-shrink: 0;
  /* badge-style edge */
  clip-path: polygon(50% 0%, 95% 25%, 100% 75%, 50% 100%, 5% 75%, 0% 25%);
}

/* ===================== MOST POPULAR TYPES ===================== */
.types__section { background: var(--baseBodyBg); padding: 8px 16px 36px; }
.types__header { max-width: 920px; margin: 0 auto 18px; text-align: center; }
.types__h2 { font-size: 22px; font-weight: 800; margin: 0 0 8px; letter-spacing: -0.02em; }
.types__p { color: var(--secondaryTextColor); font-size: 14px; margin: 0; line-height: 1.5; }
.types__col {
  max-width: 920px; margin: 0 auto;
  display: grid; gap: 10px;
  grid-template-columns: repeat(2, 1fr);
}
.types__card {
  display: block; background: #fff; border-radius: 8px;
  overflow: hidden; text-decoration: none; color: inherit;
  position: relative;
  transition: transform 150ms ease, box-shadow 150ms ease;
}
.types__card:hover { transform: translateY(-2px); box-shadow: 0 8px 16px rgba(15,23,33,0.10); }
.types__card-image {
  display: block; aspect-ratio: 5/4;
  background-size: cover; background-position: center;
  background-color: #eee;
}
.types__card-title {
  position: absolute;
  bottom: 8px; left: 8px; right: 8px;
  display: block;
  background: rgba(255,255,255,0.95);
  padding: 6px 8px;
  border-radius: 4px;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}

/* ===================== ACTION BANNER (Local Specialists) ===================== */
.action-banner__section {
  position: relative;
  background: #1a2837;
  color: #fff;
  padding: 36px 16px;
  overflow: hidden;
}
.action-banner__bg {
  position: absolute; inset: 0; z-index: 0;
  background-size: cover; background-position: center;
  background-image: linear-gradient(rgba(15,23,33,0.65), rgba(15,23,33,0.75)),
                    url('https://images.unsplash.com/photo-1581578731548-c64695cc6952?w=1200&h=600&fit=crop');
}
.action-banner__content {
  position: relative; z-index: 1;
  max-width: 540px; margin: 0 auto;
  text-align: center;
}
.action-banner__badge {
  display: inline-block;
  font-size: 11px; font-weight: 800; letter-spacing: 0.12em;
  color: #ffd5d8;
  margin-bottom: 8px;
}
.action-banner__h2 {
  font-size: clamp(20px, 3vw, 26px);
  font-weight: 800; margin: 0 0 10px;
  letter-spacing: -0.02em;
}
.action-banner__p {
  font-size: 14px; margin: 0 0 18px;
  color: rgba(255,255,255,0.92);
}
.action-banner__cta { max-width: 320px; margin: 0 auto; }
.action-banner__note {
  font-size: 11px; color: rgba(255,255,255,0.7);
  margin: 12px 0 0;
}

/* ===================== LEGAL PAGES (Terms, Privacy, Contact) ===================== */
.legal-page {
  max-width: 720px;
  margin: 24px auto 48px;
  padding: 28px 22px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(15,23,33,0.06);
}
.legal-page h1 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 4px;
  color: var(--mainTextColor);
}
.legal-page .legal-updated {
  color: var(--secondaryTextColor);
  font-size: 13px;
  margin: 0 0 24px;
  font-style: italic;
}
.legal-page h2 {
  font-size: 17px;
  font-weight: 800;
  margin: 22px 0 8px;
  color: var(--accent);
  letter-spacing: -0.01em;
}
.legal-page p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--mainTextColor);
  margin: 0 0 12px;
}
.legal-page a {
  color: var(--accent);
  text-decoration: underline;
}
.legal-page a:hover { color: var(--accent-dark); }
.legal-page strong { font-weight: 700; }
@media (max-width: 600px) {
  .legal-page { margin: 12px 10px 30px; padding: 22px 16px; }
  .legal-page h1 { font-size: 24px; }
  .legal-page h2 { font-size: 16px; }
}

/* ===================== FOOTER ===================== */
.main-footer {
  background: var(--footer-bg);
  padding: 28px 16px;
}
.main-footer__container { max-width: 920px; margin: 0 auto; text-align: center; }
.main-footer__p {
  color: var(--secondaryTextColor);
  font-size: 12px; margin: 0 0 8px;
  line-height: 1.5;
}
.main-footer__p-with-links {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  margin-top: 16px;
}
.main-footer__p a { color: var(--secondaryTextColor); text-decoration: underline; }
.main-footer__p a:hover { color: var(--accent); }

/* ===================== CONTACT FIELDS (Page 3 + 4) ===================== */
.form-grid { display: grid; gap: 14px; }
.form-field-label {
  display: flex; align-items: center; gap: 8px;
  font-size: 15px; font-weight: 700;
  color: var(--mainTextColor);
  margin-bottom: 6px;
}
.form-field-label .valid-check {
  display: none;
  width: 18px; height: 18px;
  background: var(--check-green);
  color: #fff; border-radius: 50%;
  align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800;
}
.form-field-label.valid .valid-check { display: inline-flex; }
.form-field-label.valid .valid-check::before { content: '✓'; }

.perfect-badge {
  text-align: center;
  font-size: 13px; font-weight: 800;
  color: var(--accent);
  letter-spacing: 0.08em; text-transform: uppercase;
  margin: 8px 0 6px;
}

/* TCPA */
.tcpa {
  font-size: 10px; color: var(--secondaryTextColor);
  line-height: 1.5; margin-top: 14px;
  background: var(--baseBodyBg);
  border-radius: 6px;
  padding: 10px 12px;
}

/* ===================== LOADING / SEARCHING PAGE ===================== */
.searching-card { text-align: center; }
.searching-card h1 {
  font-size: 22px; font-weight: 800;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}
.searching-card .city {
  font-size: 22px; font-weight: 800;
  color: var(--accent);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
}
.searching-card .sub {
  color: var(--secondaryTextColor); font-size: 14px;
  margin: 0 0 22px;
}
.spinner-wrap { display: flex; justify-content: center; margin-bottom: 22px; }
.spinner {
  width: 48px; height: 48px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.search-checklist {
  text-align: left;
  list-style: none; padding: 0;
  max-width: 280px; margin: 0 auto 18px;
}
.search-checklist li {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 0;
  font-size: 15px; color: var(--mainTextColor);
  font-weight: 500;
  opacity: 0.55;
  transition: opacity 300ms ease;
}
.search-checklist li.done { opacity: 1; }
.search-checklist li.active { opacity: 1; }
.search-checklist li .marker {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px dotted #b0bcc9;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 11px; font-weight: 800;
}
.search-checklist li.done .marker {
  background: var(--accent); border: 2px solid var(--accent);
}
.search-checklist li.done .marker::before { content: '✓'; }
.search-checklist .note {
  color: var(--secondaryTextColor);
  font-size: 13px; line-height: 1.4;
  max-width: 320px; margin: 0 auto;
  text-align: center;
}

@media (max-width: 360px) {
  .checkradio__with-icon-text { font-size: 10px; }
  .card-h1 { font-size: 20px; }
}
