/* ============================================================
   Optima Roofing — shared stylesheet
   Design system, self-hosted fonts, shared components, a11y.
   ============================================================ */

/* ── SELF-HOSTED FONT (Inter, variable, Latin) ── */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

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

:root {
  --navy: #1a2e4a;
  --navy-dark: #0f1e30;
  --gold: #806012;          /* text/links on white — 5.8:1 AA */
  --gold-hover: #6f550e;    /* button hover */
  --gold-accent: #8f6c13;   /* button fills — white text passes AA (4.9:1) */
  --gold-light: #e8b84e;    /* bright accent for icons/text on navy (dark bg) only */
  --gray-bg: #f4f6f8;
  --gray-mid: #e2e8f0;
  --text: #1a202c;
  --text-muted: #495568;    /* darkened for 4.5:1 contrast */
  --white: #ffffff;
  --green: #178a4c;
  --red: #c0261f;           /* emergency alert */
  --red-hover: #9e1e18;
  --radius: 12px;
  --shadow-card: 0 2px 12px rgba(0,0,0,0.06);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── ACCESSIBILITY: focus + reduced motion ── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--gold-accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: var(--white);
  padding: 12px 20px;
  z-index: 1000;
  border-radius: 0 0 8px 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ── NAV ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--gray-mid);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  height: 72px;
}
.logo { display: flex; align-items: center; text-decoration: none; }
.logo-img { height: 52px; width: auto; display: block; }

.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a {
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); border-bottom-color: var(--navy); }

.nav-actions { display: flex; align-items: center; gap: 10px; }

.btn-call {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--gold);
  color: var(--white);
  text-decoration: none;
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  transition: background 0.2s;
  white-space: nowrap;
  min-height: 44px;
}
.btn-call:hover { background: var(--gold-hover); }
.btn-call svg { width: 16px; height: 16px; fill: var(--white); }

.btn-cta-nav {
  display: inline-flex;
  align-items: center;
  background: var(--navy);
  color: var(--white);
  text-decoration: none;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  transition: background 0.2s;
  white-space: nowrap;
  min-height: 44px;
}
.btn-cta-nav:hover { background: var(--navy-dark); }

/* ── HERO ── */
.hero {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; }
.hero-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(10,20,35,0.86) 55%, rgba(10,20,35,0.42) 100%);
}
.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.hero-copy { max-width: 560px; }

.hero-rating { display: flex; align-items: center; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.hero-rating .stars { color: #fbbf24; font-size: 18px; letter-spacing: 2px; }
.hero-rating span { color: rgba(255,255,255,0.92); font-size: 14px; font-weight: 500; }
.g-logo { width: 18px; height: 18px; display: inline-block; vertical-align: middle; object-fit: contain; }

.hero-copy h1 {
  font-size: clamp(32px, 4.5vw, 52px);
  font-weight: 800;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 20px;
}
.hero-sub {
  color: rgba(255,255,255,0.9);
  font-size: 17px;
  margin-bottom: 28px;
  line-height: 1.7;
}
.hero-checks { list-style: none; margin-bottom: 28px; display: flex; flex-direction: column; gap: 10px; }
.hero-checks li {
  display: flex; align-items: center; gap: 10px;
  color: rgba(255,255,255,0.92); font-size: 16px; font-weight: 500;
}
.hero-checks svg { width: 20px; height: 20px; fill: var(--gold-light); flex-shrink: 0; }

.hero-cta-wrap { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }

.btn-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--gold-accent);
  color: var(--white);
  text-decoration: none;
  padding: 16px 28px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 700;
  transition: background 0.2s;
  min-height: 52px;
}
.btn-hero:hover { background: var(--gold-hover); }
.btn-hero svg { width: 18px; height: 18px; fill: var(--white); }

.btn-hero-outline {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: transparent; color: var(--white);
  text-decoration: none; padding: 15px 26px;
  border-radius: 8px; font-size: 15px; font-weight: 600;
  border: 2px solid rgba(255,255,255,0.5);
  transition: border-color 0.2s; cursor: pointer; font-family: inherit;
}
.btn-hero-outline:hover { border-color: rgba(255,255,255,0.85); }

/* ── EMERGENCY: giant call button + alert bar ── */
.alert-bar {
  display: block;
  background: var(--red);
  color: var(--white);
  text-decoration: none;
  text-align: center;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  position: sticky;
  top: 0;
  z-index: 150;
}
.alert-bar:hover { background: var(--red-hover); }
.alert-bar strong { text-decoration: underline; white-space: nowrap; }

.btn-giant-call {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  background: var(--red);
  color: var(--white);
  text-decoration: none;
  padding: 22px 28px;
  border-radius: 12px;
  font-size: 24px;
  font-weight: 800;
  min-height: 72px;
  box-shadow: 0 8px 28px rgba(192,38,31,0.45);
  transition: background 0.2s, transform 0.1s;
  margin-bottom: 14px;
}
.btn-giant-call:hover { background: var(--red-hover); }
.btn-giant-call:active { transform: scale(0.99); }
.btn-giant-call svg { width: 26px; height: 26px; fill: var(--white); flex-shrink: 0; }
.call-note { font-size: 14px; color: rgba(255,255,255,0.7); text-align: center; }

/* ── FORM CARD ── */
.quote-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 28px;
  width: 380px;
  flex-shrink: 0;
  box-shadow: 0 24px 64px rgba(0,0,0,0.25);
}
.quote-card h2 { font-size: 22px; font-weight: 800; color: var(--text); margin-bottom: 6px; }
.quote-card .card-sub { font-size: 14px; color: var(--text-muted); margin-bottom: 22px; }

.form-tag {
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 8px;
}

.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.form-group label .opt { color: var(--text-muted); font-weight: 400; }

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--gray-mid);
  border-radius: 8px;
  font-size: 16px; /* 16px prevents iOS zoom-on-focus */
  font-family: inherit;
  color: var(--text);
  transition: border-color 0.2s;
  outline: none;
  background: var(--white);
  appearance: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--navy); }
.form-group input::placeholder,
.form-group textarea::placeholder { color: #94a3b8; }
.form-group textarea { resize: vertical; min-height: 90px; }

/* field-level validation */
.form-group.invalid input,
.form-group.invalid select,
.form-group.invalid textarea { border-color: var(--red); }
.field-error {
  display: none;
  font-size: 12px;
  color: var(--red);
  margin-top: 5px;
  font-weight: 500;
}
.form-group.invalid .field-error { display: block; }

.select-wrap { position: relative; }
.select-wrap::after {
  content: '';
  position: absolute;
  right: 14px; top: 50%;
  transform: translateY(-50%);
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--text-muted);
  pointer-events: none;
}

/* photo upload */
.file-drop {
  border: 1.5px dashed var(--gray-mid);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  display: block;
}
.file-drop:hover { border-color: var(--gold); background: var(--gray-bg); }
.file-drop svg { width: 22px; height: 22px; fill: var(--gold); margin-bottom: 6px; }
.file-drop-text { font-size: 13px; color: var(--text-muted); font-weight: 500; }
.file-drop-text strong { color: var(--gold); }
.file-drop input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.file-previews { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.file-preview { position: relative; width: 56px; height: 56px; border-radius: 6px; overflow: hidden; }
.file-preview img { width: 100%; height: 100%; object-fit: cover; }
.file-preview button {
  position: absolute; top: 2px; right: 2px;
  width: 18px; height: 18px; border: none; border-radius: 50%;
  background: rgba(0,0,0,0.6); color: #fff; font-size: 12px; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}

/* honeypot — visually hidden but present in DOM */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.btn-submit {
  width: 100%;
  padding: 16px;
  background: var(--gold-accent);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s;
  margin-top: 4px;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.btn-submit:hover { background: var(--gold-hover); }
.btn-submit:disabled { opacity: 0.7; cursor: default; }
.btn-spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}
.btn-submit.loading .btn-spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

.form-note { text-align: center; font-size: 12px; color: var(--text-muted); margin-top: 10px; }

.form-submit-error {
  display: none;
  padding: 12px 14px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: #991b1b;
  font-size: 13px;
  margin-bottom: 16px;
  line-height: 1.5;
}
.form-submit-error a { color: #991b1b; font-weight: 700; white-space: nowrap; }

/* ── TRUST BAR ── */
.trust-bar {
  background: var(--gray-bg);
  border-bottom: 1px solid var(--gray-mid);
  padding: 18px 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}
.trust-item svg { width: 18px; height: 18px; fill: none; stroke: var(--navy); stroke-width: 2; }

/* certification badge strip */
.badge-strip {
  display: flex; align-items: center; justify-content: center;
  gap: 28px; flex-wrap: wrap;
  padding: 8px 0;
}
.badge-strip img {
  max-height: 48px; width: auto;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: filter 0.2s, opacity 0.2s;
}
.badge-strip img:hover, .badge-strip a:focus-visible img { filter: grayscale(0); opacity: 1; }

/* ── SECTION COMMONS ── */
.section { padding: 80px 40px; }
.section-inner { max-width: 1200px; margin: 0 auto; }
.section-tag { font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.section-title { font-size: clamp(28px, 3.5vw, 42px); font-weight: 800; color: var(--text); margin-bottom: 16px; line-height: 1.15; }
.section-sub { font-size: 16px; color: var(--text-muted); max-width: 620px; }
.bg-gray { background: var(--gray-bg); }
.bg-navy { background: var(--navy); }

/* ── "WHAT TO DO NOW" (emergency) ── */
.steps-do {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 20px; margin-top: 40px;
}
.do-card {
  background: var(--white); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow-card);
  border-left: 4px solid var(--gold);
  display: flex; gap: 16px; align-items: flex-start;
}
.do-num {
  width: 34px; height: 34px; flex-shrink: 0;
  background: var(--navy); color: var(--white);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 15px;
}
.do-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.do-card p { font-size: 14px; color: var(--text-muted); line-height: 1.65; }

/* ── LEAK SOURCES (repair) ── */
.leak-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 40px;
}
.leak-card {
  background: var(--white); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow-card);
  border-top: 3px solid var(--gold);
}
.leak-card .leak-icon {
  width: 44px; height: 44px; background: var(--navy);
  border-radius: 10px; display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
}
.leak-card .leak-icon svg { width: 22px; height: 22px; fill: var(--gold-light); }
.leak-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.leak-card p { font-size: 14px; color: var(--text-muted); line-height: 1.65; }

/* ── PRICING TABLE ── */
.price-table {
  margin-top: 40px;
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.price-table th, .price-table td { text-align: left; padding: 16px 24px; font-size: 15px; }
.price-table thead { background: var(--navy); }
.price-table thead th { color: var(--white); font-weight: 700; }
.price-table tbody tr { border-bottom: 1px solid var(--gray-mid); }
.price-table tbody tr:last-child { border-bottom: none; }
.price-table td:last-child { text-align: right; font-weight: 700; color: var(--navy); white-space: nowrap; }
.price-foot { font-size: 13px; color: var(--text-muted); margin-top: 16px; line-height: 1.6; }
.price-placeholder { color: var(--red); font-weight: 700; }

/* ── FINANCING ── */
.finance-band {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 40px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 32px; flex-wrap: wrap;
}
.finance-band h3 { font-size: 24px; font-weight: 800; color: var(--white); margin-bottom: 8px; }
.finance-band h3 span { color: var(--gold-light); }
.finance-band p { color: rgba(255,255,255,0.75); font-size: 15px; max-width: 460px; line-height: 1.6; }
.btn-finance {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--gold-accent); color: var(--white);
  text-decoration: none; padding: 15px 28px; border-radius: 8px;
  font-size: 15px; font-weight: 700; white-space: nowrap; flex-shrink: 0;
  transition: background 0.2s; min-height: 52px;
}
.btn-finance:hover { background: var(--gold-hover); }

/* ── MATERIALS ── */
.materials-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 40px; align-items: center; }
.materials-copy p { font-size: 15px; color: var(--text-muted); line-height: 1.8; margin-bottom: 16px; }

/* ── BEFORE/AFTER SLIDER ── */
.before-after-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; }
.ba-card { text-align: left; }
.ba-label { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 12px; }
.ba-label span { display: block; font-size: 12px; font-weight: 500; color: var(--text-muted); margin-top: 2px; }

.ba-slider {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  height: 220px;
  cursor: ew-resize;
  user-select: none;
  touch-action: pan-y;
}
.ba-slider-before, .ba-slider-after {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  pointer-events: none;
}
.ba-slider-after { clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%); }
.ba-tag {
  position: absolute; top: 10px;
  padding: 4px 10px;
  background: rgba(0,0,0,0.65); color: var(--white);
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em; border-radius: 4px;
  z-index: 3;
}
.ba-tag.before { left: 8px; }
.ba-tag.after { right: 8px; }
.ba-slider-line {
  position: absolute; top: 0; bottom: 0; left: 50%;
  width: 3px; background: var(--white);
  transform: translateX(-50%); z-index: 4;
  box-shadow: 0 0 8px rgba(0,0,0,0.35);
}
.ba-slider-btn {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 44px; height: 44px;
  background: var(--gold-accent); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  z-index: 5; box-shadow: 0 4px 16px rgba(0,0,0,0.35);
  transition: transform 0.15s, background 0.15s;
}
.ba-slider.dragging .ba-slider-btn { transform: translate(-50%, -50%) scale(1.12); background: var(--gold-hover); }
.ba-slider-btn svg { width: 22px; height: 22px; fill: none; stroke: var(--white); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.ba-drag-hint {
  position: absolute; bottom: 10px; left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.55); color: var(--white);
  font-size: 11px; font-weight: 600; letter-spacing: 0.06em;
  padding: 4px 10px; border-radius: 20px; z-index: 6;
  white-space: nowrap; transition: opacity 0.4s; pointer-events: none;
}
.ba-slider.dragging .ba-drag-hint, .ba-slider.interacted .ba-drag-hint { opacity: 0; }

/* ── SERVICE CARDS ── */
.service-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; }
.svc-card { border-radius: var(--radius); overflow: hidden; box-shadow: 0 4px 16px rgba(0,0,0,0.10); background: var(--white); }
.svc-card-body { padding: 24px; }
.svc-icon { width: 48px; height: 48px; background: var(--navy); border-radius: 10px; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.svc-icon svg { width: 24px; height: 24px; fill: var(--gold-light); }
.svc-card-body h4 { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.svc-card-body p { font-size: 13px; color: var(--text-muted); line-height: 1.6; }
.svc-link { display: inline-block; margin-top: 14px; font-size: 13px; font-weight: 700; color: var(--gold); text-decoration: none; }
.svc-link:hover { color: var(--gold-hover); }

/* ── SERVICES LIST ── */
.services-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start; margin-top: 48px; }
.services-copy p { font-size: 15px; color: var(--text-muted); line-height: 1.8; margin-bottom: 16px; }
.services-list { background: var(--gray-bg); border-radius: var(--radius); padding: 32px; }
.services-list h3 { font-size: 18px; font-weight: 700; margin-bottom: 20px; }
.service-item { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--gray-mid); font-size: 14px; font-weight: 500; }
.service-item:last-child { border-bottom: none; }
.check { color: var(--green); font-size: 16px; }

/* ── WHY CHOOSE US ── */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; }
.why-card { background: var(--white); border-radius: var(--radius); padding: 28px 24px; box-shadow: var(--shadow-card); border-top: 3px solid var(--gold); }
.why-icon { width: 48px; height: 48px; background: var(--navy); border-radius: 10px; display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.why-icon svg { width: 24px; height: 24px; fill: var(--gold-light); }
.why-card h3 { font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.why-card p { font-size: 14px; color: var(--text-muted); line-height: 1.7; }

/* ── HOW IT WORKS ── */
.steps-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 56px; position: relative; }
.steps-row::before { content: ''; position: absolute; top: 36px; left: calc(16.66% + 16px); right: calc(16.66% + 16px); height: 2px; background: var(--gold-light); opacity: 0.5; }
.step-box { text-align: center; }
.step-num { width: 72px; height: 72px; background: var(--gold-accent); color: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 800; margin: 0 auto 20px; position: relative; z-index: 1; }
.step-box h3 { font-size: 17px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.step-box p { font-size: 14px; color: var(--text-muted); line-height: 1.7; }

/* ── SERVICE AREA ── */
.area-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 40px; }
.area-item { background: var(--white); border-radius: 8px; padding: 14px 16px; display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; box-shadow: 0 1px 6px rgba(0,0,0,0.05); }
.area-item svg { width: 14px; height: 14px; fill: var(--gold); flex-shrink: 0; }

/* ── REVIEWS (static cards, no carousel) ── */
.reviews-section { background: var(--gray-bg); }
.google-rating { display: flex; align-items: center; gap: 8px; font-size: 18px; font-weight: 700; color: var(--text); margin-top: 12px; flex-wrap: wrap; }
.google-rating .stars { color: #fbbf24; }
.google-rating a { color: var(--navy); font-weight: 600; font-size: 14px; text-decoration: underline; }
.reviews-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
.review-card { background: var(--white); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow-card); }
.reviewer { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.reviewer-avatar { width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 700; color: var(--white); flex-shrink: 0; }
.reviewer-info .name { font-size: 15px; font-weight: 700; }
.reviewer-info .location { font-size: 13px; color: var(--text-muted); }
.review-stars { color: #fbbf24; font-size: 15px; margin-bottom: 8px; }
.review-quote { font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.review-body { font-size: 14px; color: var(--text-muted); line-height: 1.7; }
.reviews-cta { margin-top: 32px; display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-size: 14px; font-weight: 600; color: var(--text); }
.reviews-cta:hover { color: var(--navy); }

/* ── ABOUT ── */
.about-section { background: var(--gray-bg); }
.about-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; margin-top: 48px; }
.about-img { border-radius: var(--radius); overflow: hidden; box-shadow: 0 12px 40px rgba(0,0,0,0.15); }
.about-img img { width: 100%; height: 380px; object-fit: cover; display: block; }
.about-copy p { font-size: 15px; color: var(--text-muted); line-height: 1.8; margin-bottom: 16px; }
.about-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 32px; }
.stat { text-align: center; padding: 20px 12px; background: var(--white); border-radius: 10px; }
.stat .number { font-size: 28px; font-weight: 800; color: var(--navy); }
.stat .label { font-size: 12px; color: var(--text-muted); font-weight: 500; margin-top: 4px; }

/* ── FAQ ── */
.faq-section { background: var(--white); }
.faq-layout { display: grid; grid-template-columns: 1fr 2fr; gap: 60px; align-items: start; margin-top: 48px; }
.faq-sidebar h3 { font-size: 22px; font-weight: 800; margin-bottom: 12px; }
.faq-sidebar p { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-bottom: 24px; }
.faq-contact a { display: flex; align-items: center; gap: 8px; text-decoration: none; font-size: 15px; font-weight: 700; color: var(--gold); }
.faq-contact a svg { width: 18px; height: 18px; fill: var(--gold); }
.faq-list { display: flex; flex-direction: column; gap: 4px; }
.faq-item { border: 1.5px solid var(--gray-mid); border-radius: 10px; overflow: hidden; }
.faq-question {
  width: 100%; background: none; border: none; text-align: left;
  padding: 20px 24px; font-size: 15px; font-weight: 600; font-family: inherit; color: var(--text);
  cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  transition: background 0.15s; min-height: 44px;
}
.faq-question:hover, .faq-question.open { background: var(--gray-bg); }
.faq-chevron { width: 20px; height: 20px; flex-shrink: 0; transition: transform 0.25s; fill: none; stroke: var(--text-muted); stroke-width: 2; }
.faq-question.open .faq-chevron { transform: rotate(180deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.3s ease, padding 0.3s ease; }
.faq-answer.open { max-height: 360px; padding: 0 24px 20px; }
.faq-answer p { font-size: 14px; color: var(--text-muted); line-height: 1.75; }

/* ── FINAL CTA BAND ── */
.cta-band { background: var(--navy-dark); color: var(--white); text-align: center; }
.cta-band-inner { max-width: 760px; margin: 0 auto; padding: 72px 40px; }
.cta-band h2 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; margin-bottom: 14px; }
.cta-band h2 span { color: var(--gold-light); }
.cta-band p { color: rgba(255,255,255,0.75); font-size: 16px; margin-bottom: 32px; }
.cta-band-btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ── CONTACT ── */
.contact-section { background: var(--navy); color: var(--white); }
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start; }
.contact-copy .section-tag { color: var(--gold-light); }
.contact-copy .section-title { color: var(--white); }
.contact-copy p { color: rgba(255,255,255,0.75); font-size: 15px; line-height: 1.7; margin-bottom: 32px; }
.contact-info { display: flex; flex-direction: column; gap: 16px; }
.contact-row { display: flex; align-items: center; gap: 14px; font-size: 15px; }
.contact-icon { width: 42px; height: 42px; background: rgba(255,255,255,0.1); border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-icon svg { width: 20px; height: 20px; fill: var(--gold-light); }
.contact-row span { color: rgba(255,255,255,0.9); }
.contact-row strong { color: var(--white); display: block; }
.contact-row a { color: var(--white); text-decoration: none; }
.contact-row a:hover { text-decoration: underline; }
.contact-form { background: var(--white); border-radius: var(--radius); padding: 36px; }
.contact-form h3 { font-size: 20px; font-weight: 800; color: var(--text); margin-bottom: 24px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ── FOOTER ── */
footer { background: var(--navy-dark); color: rgba(255,255,255,0.6); padding: 48px 40px 24px; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1.4fr; gap: 48px; width: 100%; padding-bottom: 32px; margin-bottom: 24px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-brand > img { height: 44px; width: auto; background: var(--white); border-radius: 8px; padding: 4px 8px; }
.footer-brand p { font-size: 13px; color: rgba(255,255,255,0.55); line-height: 1.7; margin-top: 14px; max-width: 260px; }
.footer-col h4 { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.45); margin-bottom: 14px; }
.footer-col-links { display: flex; flex-direction: column; gap: 10px; }
.footer-col-links a { color: rgba(255,255,255,0.6); text-decoration: none; font-size: 14px; transition: color 0.2s; min-height: 24px; display: inline-flex; align-items: center; }
.footer-col-links a:hover { color: var(--white); }
.footer-contact-list { display: flex; flex-direction: column; gap: 12px; }
.footer-contact-row { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; }
.footer-contact-row svg { width: 15px; height: 15px; fill: var(--gold-light); flex-shrink: 0; margin-top: 3px; }
.footer-contact-row a { color: rgba(255,255,255,0.85); text-decoration: none; font-weight: 600; }
.footer-contact-row a:hover { color: var(--white); }
.footer-contact-row span { color: rgba(255,255,255,0.6); }
.btn-footer-cta { display: inline-flex; align-items: center; margin-top: 16px; background: var(--gold-accent); color: var(--white); text-decoration: none; padding: 12px 20px; border-radius: 8px; font-size: 14px; font-weight: 700; transition: background 0.2s; min-height: 44px; }
.btn-footer-cta:hover { background: var(--gold-hover); }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; width: 100%; }
.footer-bottom p { font-size: 12px; color: rgba(255,255,255,0.4); }
.footer-address { font-size: 12px; color: rgba(255,255,255,0.4); margin-top: 6px; font-style: normal; }
.footer-bottom-links { display: flex; gap: 16px; flex-wrap: wrap; }
.footer-bottom-links a { font-size: 12px; color: rgba(255,255,255,0.45); text-decoration: none; }
.footer-bottom-links a:hover { color: rgba(255,255,255,0.75); }

/* ── STICKY MOBILE CALL BAR ── */
.mobile-cta-bar { display: none; }

/* ── LEGAL PAGES (privacy / terms) ── */
.legal-wrap { max-width: 800px; margin: 0 auto; padding: 60px 40px 80px; }
.legal-wrap h1 { font-size: clamp(28px, 4vw, 40px); font-weight: 800; margin-bottom: 8px; }
.legal-wrap .updated { color: var(--text-muted); font-size: 14px; margin-bottom: 36px; }
.legal-wrap h2 { font-size: 20px; font-weight: 700; margin: 32px 0 12px; }
.legal-wrap p, .legal-wrap li { font-size: 15px; color: var(--text-muted); line-height: 1.75; margin-bottom: 12px; }
.legal-wrap ul { padding-left: 22px; margin-bottom: 12px; }
.legal-wrap a { color: var(--gold); }

/* ── THANK YOU PAGE ── */
.ty-wrap { min-height: 70vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 60px 24px; }
.ty-check { width: 88px; height: 88px; margin-bottom: 28px; }
.ty-check circle { fill: none; stroke: var(--green); stroke-width: 3; }
.ty-check path { fill: none; stroke: var(--green); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.ty-wrap h1 { font-size: clamp(28px, 4vw, 40px); font-weight: 800; margin-bottom: 14px; }
.ty-wrap p { font-size: 17px; color: var(--text-muted); max-width: 520px; line-height: 1.7; margin-bottom: 28px; }
.ty-call { display: inline-flex; align-items: center; gap: 8px; background: var(--gold-accent); color: var(--white); text-decoration: none; padding: 16px 30px; border-radius: 8px; font-size: 16px; font-weight: 700; min-height: 52px; }
.ty-call:hover { background: var(--gold-hover); }
.ty-call svg { width: 18px; height: 18px; fill: var(--white); }

/* ── RESPONSIVE ── */
@media (max-width: 960px) {
  body { padding-bottom: 76px; }
  nav { padding: 0 20px; }
  .nav-links { display: none; }
  .btn-cta-nav { display: none; }
  .quote-card { width: 100%; max-width: 480px; }

  .hero-inner { flex-direction: column; align-items: stretch; padding: 44px 20px; gap: 32px; }
  .hero-copy { max-width: 100%; }

  .section { padding: 50px 20px; }
  .steps-do, .leak-grid, .before-after-grid, .service-cards, .why-grid, .steps-row,
  .services-layout, .about-layout, .faq-layout, .contact-layout, .materials-grid,
  .reviews-grid { grid-template-columns: 1fr; }
  .steps-row::before { display: none; }
  .area-grid { grid-template-columns: repeat(2, 1fr); }
  .finance-band { flex-direction: column; align-items: flex-start; }
  .price-table th, .price-table td { padding: 14px 16px; font-size: 14px; }

  footer { padding: 40px 20px 24px; }
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 8px; }

  /* sticky mobile call bar — always visible on landing pages */
  .mobile-cta-bar {
    display: flex;
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
    background: var(--navy-dark);
    border-top: 2px solid rgba(196,154,38,0.4);
    padding: 12px 16px;
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
    gap: 10px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
  }
  .mobile-cta-bar.hide-until-scroll { transform: translateY(100%); opacity: 0; pointer-events: none; transition: transform 0.35s ease, opacity 0.3s ease; }
  .mobile-cta-bar.hide-until-scroll.visible { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .mobile-cta-bar a {
    flex: 1; text-align: center; padding: 14px 10px; border-radius: 8px;
    font-size: 15px; font-weight: 700; font-family: inherit; text-decoration: none;
    display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px;
  }
  .mcta-call { background: var(--gold-accent); color: var(--white); }
  .mcta-call.emergency { background: var(--red); }
  .mcta-quote { background: transparent; color: var(--white); border: 2px solid rgba(255,255,255,0.35); }
  .mobile-cta-bar svg { width: 16px; height: 16px; flex-shrink: 0; }
}

@media (max-width: 480px) {
  .steps-do { grid-template-columns: 1fr; }
  .area-grid { grid-template-columns: 1fr; }
  .hero-copy h1 { font-size: 30px; }
  .btn-giant-call { font-size: 20px; }
}

/* ============================================================
   UX PASS — mobile nav, tap targets, upload feedback, thank-you
   ============================================================ */

/* Hamburger toggle — hidden on desktop (Jakob's Law: mobile menu) */
.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  align-items: center; justify-content: center;
  background: transparent; border: 1.5px solid var(--gray-mid);
  border-radius: 8px; cursor: pointer; padding: 0;
}
.nav-toggle svg { width: 22px; height: 22px; stroke: var(--navy); stroke-width: 2; fill: none; }

/* Photo upload: immediate processing feedback (Doherty Threshold) */
.file-preview.loading { display: flex; align-items: center; justify-content: center; background: var(--gray-bg); }
.file-preview.loading .mini-spin {
  width: 20px; height: 20px;
  border: 2px solid var(--gray-mid); border-top-color: var(--gold);
  border-radius: 50%; animation: spin 0.7s linear infinite;
}

/* Thank-you: "what happens next" (Peak-End Rule) */
.ty-next {
  display: flex; flex-wrap: wrap; gap: 12px;
  justify-content: center; margin: 8px auto 28px; max-width: 640px;
}
.ty-next li {
  list-style: none; flex: 1 1 170px;
  background: var(--gray-bg); border-radius: 10px;
  padding: 16px 18px; text-align: left;
  display: flex; gap: 12px; align-items: flex-start;
}
.ty-next .n {
  width: 26px; height: 26px; flex-shrink: 0;
  background: var(--navy); color: var(--white);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800;
}
.ty-next h3 { font-size: 14px; font-weight: 700; margin-bottom: 3px; }
.ty-next p { font-size: 13px; color: var(--text-muted); line-height: 1.5; margin: 0; }

@media (max-width: 960px) {
  /* Mobile navigation menu (Jakob's Law + Fitts's Law) */
  .nav-toggle { display: inline-flex; }
  .nav-links {
    display: none;
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: var(--white);
    border-bottom: 1px solid var(--gray-mid);
    box-shadow: 0 12px 24px rgba(0,0,0,0.12);
    padding: 8px 0;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; }
  .nav-links a {
    display: flex; align-items: center;
    width: 100%; min-height: 48px;
    padding: 12px 24px; border-bottom: none;
    font-size: 16px;
  }
  .nav-links a:hover, .nav-links a.active { background: var(--gray-bg); border-bottom-color: transparent; }

  /* Footer tap targets (Fitts's Law) */
  .footer-col-links { gap: 4px; }
  .footer-col-links a { min-height: 44px; }
  .footer-bottom-links { gap: 8px 20px; }
  .footer-bottom-links a { min-height: 40px; display: inline-flex; align-items: center; }
}
