/* Ridge & Rafter Roofing demo design system (regenerated from the GA
   Exterior prototype). The --blue* variable names are kept so the whole
   original component library re-skins from this block alone; their values
   are now the roofing palette: shingle rust, warm surfaces, ink text.
*/
:root {
  --base: #ffffff;
  --surface: #f8f6f2;
  --surface-strong: #f1ebe2;
  --text: #191410;
  --muted: #6b6157;
  --line: #e9e2d7;
  --blue: #b64a12;
  --blue-light: #e07830;
  --blue-dark: #5e2508;
  --shadow: 0 24px 60px rgba(25, 20, 16, 0.12);
  --radius: 12px;
  --max: 1200px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: var(--text);
  background: var(--base);
  line-height: 1.55;
}

body.menu-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 0 max(22px, calc((100vw - var(--max)) / 2));
  border-bottom: 1px solid rgba(229, 234, 240, 0.86);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px);
}

.brand {
  width: 188px;
  min-width: 156px;
}

.brand img {
  height: 42px;
  object-fit: contain;
  object-position: left center;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  flex: 1;
  font-size: 14px;
  font-weight: 600;
}

.desktop-nav a,
.nav-trigger {
  border: 0;
  background: transparent;
  color: var(--text);
  padding: 22px 0;
  transition: color 180ms ease;
}

.desktop-nav a:hover,
.nav-trigger:hover,
.nav-trigger[aria-expanded="true"] {
  color: var(--blue);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.phone-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.phone-link svg {
  width: 17px;
  height: 17px;
  fill: var(--blue);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease,
    color 180ms ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--blue-light));
  box-shadow: 0 14px 28px rgba(10, 77, 162, 0.24);
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
}

.btn-white {
  background: #fff;
  color: var(--blue);
}

.btn-ghost-light {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.46);
}

.btn.large {
  min-height: 48px;
  padding: 0 22px;
  font-size: 15px;
}

.mega-menu,
.mini-menu {
  position: fixed;
  top: 64px;
  left: 0;
  z-index: 90;
  width: 100vw;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-12px);
  transition: 180ms ease;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 16px 38px rgba(15, 20, 25, 0.08);
}

.mega-menu.open,
.mini-menu.open,
.site-header:has([data-ref-trigger]:hover) .mini-menu,
.site-header:has([data-ref-trigger]:focus-visible) .mini-menu,
.site-header:has(.mini-menu:hover) .mini-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.site-header:has([data-ref-trigger]:hover) [data-ref-trigger],
.site-header:has([data-ref-trigger]:focus-visible) [data-ref-trigger],
.site-header:has(.mini-menu:hover) [data-ref-trigger] {
  color: var(--blue);
}

.mega-inner {
  max-width: var(--max);
  margin: 0 auto;
  min-height: 320px;
  padding: 34px 22px 38px;
  display: grid;
  grid-template-columns: 1fr 1fr 1.4fr 1fr;
  gap: 30px;
}

.mega-inner a,
.mini-menu a {
  display: block;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  padding: 7px 0;
}

.mega-inner a:hover,
.mini-menu a:hover {
  color: var(--blue);
}

.menu-label {
  color: var(--text);
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 850;
}

.mega-feature {
  padding: 0 !important;
}

.mega-feature img {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius);
  object-fit: cover;
  margin-bottom: 12px;
}

.mini-menu {
  left: auto;
  right: max(22px, calc((100vw - var(--max)) / 2));
  width: 320px;
  border: 1px solid var(--line);
  border-radius: 0 0 12px 12px;
  padding: 14px 18px;
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  background: var(--text);
}

.mobile-panel {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 80;
  width: min(360px, 88vw);
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 26px;
  background: #fff;
  box-shadow: -22px 0 50px rgba(15, 20, 25, 0.16);
  transform: translateX(105%);
  transition: transform 220ms ease;
}

.mobile-panel.open {
  transform: translateX(0);
}

.mobile-panel a {
  font-size: 22px;
  font-weight: 800;
}

.panel-close {
  align-self: flex-end;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: end;
  overflow: hidden;
  padding: 132px max(22px, calc((100vw - var(--max)) / 2)) 52px;
  color: #fff;
}

.hero-media,
.hero-media img,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95) contrast(1.06);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(24, 12, 4, 0.86), rgba(94, 37, 8, 0.44) 46%, rgba(24, 12, 4, 0.16)),
    linear-gradient(0deg, rgba(24, 12, 4, 0.72), rgba(24, 12, 4, 0.08) 55%);
}

.hero-content {
  position: relative;
  max-width: 840px;
}

.hero h1,
.section-heading h2,
.quote-main h1,
.split-copy h2,
.area-copy h2,
.lead-form h2,
.lead-form h3,
.cta-band h2 {
  margin: 0;
  font-weight: 850;
  line-height: 0.95;
  letter-spacing: -0.02em;
}

.hero h1 {
  font-size: clamp(3rem, 6.2vw, 5.9rem);
  max-width: 920px;
}

.hero p {
  max-width: 680px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1.05rem, 1.8vw, 1.35rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 32px;
}

.trust-strip span {
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(6px);
  font-size: 13px;
  font-weight: 700;
}

.section {
  padding: 96px max(22px, calc((100vw - var(--max)) / 2));
}

.services-section,
.testimonials,
.lead-section {
  background: var(--surface);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 42px;
}

.section-heading.center {
  margin-inline: auto;
  text-align: center;
}

.section-kicker {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-heading h2,
.quote-main h1,
.split-copy h2,
.area-copy h2,
.lead-form h2,
.lead-form h3,
.cta-band h2 {
  font-size: clamp(2.3rem, 4.8vw, 4.7rem);
}

.section-heading > p:not(.section-kicker),
.split-copy > p,
.area-copy p {
  max-width: 700px;
  color: var(--muted);
  font-size: 18px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.service-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 30px rgba(15, 20, 25, 0.05);
}

.service-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 650ms ease;
}

.service-card:hover img {
  transform: scale(1.045);
}

.service-card div {
  padding: 20px;
}

.service-card h3,
.value-list h3,
.testimonial h3,
.referral-card h3 {
  margin: 0 0 8px;
  font-size: 23px;
  letter-spacing: -0.01em;
}

.service-card p,
.value-list p,
.testimonial p,
.referral-card p {
  color: var(--muted);
  margin: 0 0 14px;
}

.service-card a {
  color: var(--blue);
  font-weight: 850;
}

.service-card.featured {
  grid-column: span 2;
  background: var(--blue-dark);
  color: #fff;
}

.service-card.featured p,
.service-card.featured a {
  color: rgba(255, 255, 255, 0.88);
}

.split-section {
  display: grid;
  grid-template-columns: 1fr 0.86fr;
  gap: 72px;
  align-items: center;
}

.value-list {
  display: grid;
  gap: 18px;
  margin-top: 34px;
}

.value-list > div {
  display: grid;
  grid-template-columns: 54px 1fr;
  column-gap: 18px;
  align-items: start;
}

.value-list h3,
.value-list p {
  grid-column: 2;
}

.icon-badge {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--blue);
  font-weight: 850;
}

.image-stack {
  position: relative;
}

.stack-main {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  object-fit: cover;
  box-shadow: var(--shadow);
}

.stat-card {
  position: absolute;
  left: -34px;
  bottom: 28px;
  width: 190px;
  padding: 22px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.stat-card strong {
  display: block;
  color: var(--blue);
  font-size: 46px;
  line-height: 1;
}

.stat-card span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.quote-preview {
  padding: 96px max(22px, calc((100vw - var(--max)) / 2));
  background:
    radial-gradient(circle at 15% 0%, rgba(224, 120, 48, 0.26), transparent 32%),
    linear-gradient(135deg, #2a1207, #8a3a10 60%, #4a1d06);
  color: #fff;
}

.quote-main {
  min-height: 100vh;
  padding-top: 128px;
}

.quote-gate {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.58fr);
  gap: 24px;
  align-items: stretch;
}

.lead-form.compact {
  max-width: none;
  margin: 0;
}

.lead-form.compact h3 {
  margin: 0;
}

.lead-form.dark {
  color: var(--text);
  background: rgba(255, 255, 255, 0.96);
}

.quote-gate-card {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.2);
}

.quote-gate-card img {
  width: 100%;
  height: 55%;
  min-height: 260px;
  object-fit: cover;
}

.quote-gate-card div {
  padding: 28px;
}

.quote-gate-card strong {
  display: block;
  color: #fff;
  font-size: 26px;
  line-height: 1.1;
}

.quote-gate-card p {
  color: rgba(255, 255, 255, 0.76);
  margin-bottom: 0;
}

.section-heading.light .section-kicker,
.section-heading.light > p {
  color: rgba(255, 255, 255, 0.76);
}

.calculator-shell {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(12px);
}

.calculator-tabs {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.calculator-tabs button,
.segmented button {
  border: 0;
  border-radius: 8px;
  padding: 11px 16px;
  color: inherit;
  background: rgba(255, 255, 255, 0.12);
  font-size: 14px;
  font-weight: 850;
}

.calculator-tabs button.active,
.segmented button.active {
  background: #fff;
  color: var(--blue);
}

.calculator-grid {
  display: none;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.7fr);
  gap: 24px;
  padding: 24px;
}

.calculator-grid.active {
  display: grid;
}

.calc-form,
.lead-form {
  display: grid;
  gap: 18px;
}

.calc-form label,
.lead-form label {
  display: grid;
  gap: 7px;
  font-size: 14px;
  font-weight: 850;
}

.calc-form input,
.calc-form select,
.lead-form input,
.lead-form select,
.lead-form textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(229, 234, 240, 0.92);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: var(--text);
  outline: none;
}

.calc-form input:focus,
.calc-form select:focus,
.lead-form input:focus,
.lead-form select:focus,
.lead-form textarea:focus {
  border-color: var(--blue-light);
  box-shadow: 0 0 0 4px rgba(47, 125, 219, 0.16);
}

.dev-banner {
  border-radius: 8px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-weight: 800;
}

.input-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.field-label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 850;
}

.field-help {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.74);
  font-size: 13px;
}

.segmented,
.radio-row,
.check-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.radio-row label,
.check-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  width: auto;
  min-height: 42px;
  padding: 9px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 750;
}

.lead-form .radio-row label,
.lead-form .check-grid label,
.lead-form .consent {
  background: var(--surface);
  color: var(--text);
}

.estimate-panel {
  position: sticky;
  top: 88px;
  align-self: start;
  min-height: 100%;
  padding: 22px;
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
}

.diagram {
  width: 100%;
  height: 150px;
  margin-bottom: 18px;
  border-radius: var(--radius);
  background: var(--surface);
}

.diagram path {
  fill: rgba(47, 125, 219, 0.15);
  stroke: var(--blue);
  stroke-width: 4;
  stroke-linejoin: round;
}

.diagram.fence path {
  fill: none;
}

.diagram text {
  fill: var(--blue);
  font-weight: 850;
  text-anchor: middle;
}

.estimate-label {
  color: var(--muted);
  margin: 0;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.estimate-panel > strong {
  display: block;
  margin-top: 4px;
  font-size: clamp(2.2rem, 4vw, 3.7rem);
  line-height: 1;
  color: var(--blue);
}

.estimate-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 18px 0;
}

.estimate-stats span {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  color: var(--muted);
}

details {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

summary {
  font-weight: 850;
}

.gallery {
  columns: 3 260px;
  column-gap: 18px;
}

.gallery button {
  display: block;
  width: 100%;
  break-inside: avoid;
  margin: 0 0 18px;
  border: 0;
  border-radius: var(--radius);
  padding: 0;
  background: transparent;
  overflow: hidden;
}

.gallery img {
  width: 100%;
  border-radius: var(--radius);
  transition: transform 700ms ease;
}

.gallery button:hover img {
  transform: scale(1.035);
}

.testimonial-grid,
.referral-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.review-shots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 24px;
}

.review-shots img {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 28px rgba(15, 20, 25, 0.05);
}

.testimonial,
.referral-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  background: #fff;
  box-shadow: 0 14px 28px rgba(15, 20, 25, 0.05);
}

.testimonial strong,
.testimonial span {
  display: block;
}

.testimonial span {
  color: var(--muted);
}

.review-proof-heading {
  max-width: 640px;
  margin-top: 38px;
}

.review-proof-heading h3 {
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.areas {
  display: grid;
  grid-template-columns: 0.86fr 1fr;
  gap: 60px;
  align-items: center;
}

.map-card {
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(182, 74, 18, 0.08), rgba(224, 120, 48, 0.18)),
    var(--surface);
  min-height: 360px;
  display: grid;
  place-items: center;
}

.map-card svg {
  width: min(86%, 460px);
}

.map-card path {
  fill: rgba(10, 77, 162, 0.1);
  stroke: var(--blue);
  stroke-width: 7;
  stroke-linejoin: round;
}

.map-card circle {
  fill: var(--blue);
  stroke: #fff;
  stroke-width: 5;
}

.referral-grid {
  grid-template-columns: repeat(2, 1fr);
}

.referral-card ol {
  margin: 18px 0 0;
  padding-left: 18px;
  color: var(--muted);
  font-weight: 650;
}

.referral-card .btn {
  margin-top: 20px;
}

.referral-page {
  background: var(--base);
}

.referral-hero {
  min-height: 78vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.46fr);
  gap: 52px;
  align-items: end;
  padding: 136px max(22px, calc((100vw - var(--max)) / 2)) 72px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(6, 28, 59, 0.94), rgba(10, 77, 162, 0.76)),
    url("assets/projects/hero-fence-yard.jpeg") center / cover;
}

.referral-hero.sales {
  background:
    linear-gradient(90deg, rgba(6, 28, 59, 0.94), rgba(10, 77, 162, 0.72)),
    url("assets/original-site/long-driveway.jpg") center / cover;
}

.referral-hero h1 {
  max-width: 850px;
  margin: 0;
  font-size: clamp(3rem, 6vw, 6rem);
  font-weight: 850;
  line-height: 0.95;
  letter-spacing: -0.02em;
}

.referral-hero p {
  max-width: 690px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

.referral-hero-card {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(12px);
}

.referral-hero-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.referral-hero-card strong,
.referral-hero-card span {
  display: block;
  padding-inline: 24px;
}

.referral-hero-card strong {
  padding-top: 22px;
  color: #fff;
  font-size: clamp(2.4rem, 5vw, 4.8rem);
  line-height: 1;
}

.referral-hero-card span {
  padding-top: 8px;
  padding-bottom: 24px;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 750;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.referral-switch {
  margin-top: 0;
}

.lead-form {
  max-width: 920px;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: clamp(24px, 4vw, 44px);
  background: #fff;
  box-shadow: var(--shadow);
}

.consent {
  display: flex !important;
  grid-template-columns: auto 1fr;
  flex-direction: row;
  align-items: flex-start;
  gap: 10px !important;
  color: var(--muted);
  font-size: 13px !important;
}

.consent input {
  width: auto;
  min-height: auto;
  margin-top: 4px;
}

.cta-band {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  align-items: center;
  padding: 78px max(22px, calc((100vw - var(--max)) / 2));
  color: #fff;
  background: var(--blue);
}

.cta-band p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.footer {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 34px;
  padding: 54px max(22px, calc((100vw - var(--max)) / 2));
  background: #08111d;
  color: #fff;
}

.footer img {
  width: 220px;
  margin-bottom: 14px;
  filter: drop-shadow(0 0 0 #fff);
}

.footer p,
.footer a {
  display: block;
  color: rgba(255, 255, 255, 0.74);
  margin: 0 0 9px;
}

.footer h3 {
  margin: 0 0 14px;
}

.lightbox {
  width: min(1100px, 92vw);
  border: 0;
  border-radius: 16px;
  padding: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.72);
}

.lightbox img {
  width: 100%;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 10px;
}

.lightbox button {
  float: right;
  margin-bottom: 8px;
  border: 0;
  background: transparent;
  color: var(--blue);
  font-weight: 850;
}

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 620ms ease,
    transform 620ms ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 1060px) {
  .desktop-nav,
  .phone-link,
  .header-actions > .btn {
    display: none;
  }

  .site-header {
    justify-content: space-between;
  }

  .menu-button {
    display: block;
  }

  .mega-menu,
  .mini-menu {
    display: none;
  }

  .service-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .calculator-grid,
  .referral-hero,
  .split-section,
  .areas {
    grid-template-columns: 1fr;
  }

  .estimate-panel {
    position: static;
  }
}

@media (max-width: 720px) {
  .brand {
    width: 152px;
  }

  .hero {
    min-height: 86vh;
    padding-top: 110px;
  }

  .hero h1 {
    font-size: clamp(2.65rem, 14vw, 4.3rem);
  }

  .section,
  .quote-preview {
    padding-top: 64px;
    padding-bottom: 64px;
  }

  .service-grid,
  .testimonial-grid,
  .review-shots,
  .process-grid,
  .referral-grid,
  .input-row,
  .footer {
    grid-template-columns: 1fr;
  }

  .service-card.featured {
    grid-column: auto;
  }

  .calculator-tabs,
  .segmented {
    flex-direction: column;
  }

  .calculator-grid {
    padding: 16px;
  }

  .radio-row label,
  .check-grid label {
    width: 100%;
  }

  .stat-card {
    left: 14px;
    bottom: 14px;
  }

  .cta-band {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* ── Roofing regeneration additions ── */

.brand-word {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
  white-space: nowrap;
}
.brand-word strong {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.brand-word span {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--blue);
  text-transform: uppercase;
}

.badge-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 28px;
  padding: 18px max(22px, calc((100vw - var(--max)) / 2));
  background: var(--blue-dark);
  color: #f7ede4;
  font-size: 13.5px;
  font-weight: 700;
}
.badge-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.badge-strip svg {
  width: 15px;
  height: 15px;
  fill: var(--blue-light);
}

.star-row {
  color: #e8a33d;
  font-size: 15px;
  letter-spacing: 2px;
}
.review-aggregate {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 0 0 30px;
  font-weight: 800;
  font-size: 17px;
}
.review-aggregate small {
  color: var(--muted);
  font-weight: 600;
}

.page-hero {
  position: relative;
  padding: 150px max(22px, calc((100vw - var(--max)) / 2)) 70px;
  color: #fff;
  overflow: hidden;
}
.page-hero img.page-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20, 12, 6, 0.72), rgba(20, 12, 6, 0.55));
}
.page-hero > div {
  position: relative;
  z-index: 1;
  max-width: 760px;
}
.page-hero h1 {
  font-size: clamp(30px, 4.4vw, 50px);
  line-height: 1.06;
  margin: 10px 0 14px;
}
.page-hero p {
  font-size: 17px;
  line-height: 1.6;
  color: rgba(255, 244, 235, 0.92);
}
.breadcrumbs {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 235, 220, 0.85);
}
.breadcrumbs a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.included-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 14px;
}
.included-grid div {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  font-size: 14.5px;
  line-height: 1.55;
}
.included-grid svg {
  flex: none;
  width: 17px;
  height: 17px;
  margin-top: 2px;
  fill: var(--blue);
}

.faq-mini details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 0 18px;
}
.faq-mini details + details {
  margin-top: 10px;
}
.faq-mini summary {
  cursor: pointer;
  font-weight: 800;
  padding: 15px 0;
  list-style: none;
}
.faq-mini summary::-webkit-details-marker {
  display: none;
}
.faq-mini p {
  margin: 0 0 15px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.65;
}

.loc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.loc-grid a {
  display: block;
  text-align: center;
  padding: 13px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-weight: 700;
  font-size: 14px;
  transition: border-color 0.15s, transform 0.15s;
}
.loc-grid a:hover {
  border-color: var(--blue);
  transform: translateY(-2px);
}

.estimate-lock {
  position: relative;
}
.estimate-lock .locked-value {
  filter: blur(10px);
  user-select: none;
  pointer-events: none;
}
.estimate-lock.unlocked .locked-value {
  filter: none;
  user-select: auto;
}
.unlock-card {
  margin-top: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.5);
  border-radius: var(--radius);
  padding: 16px;
  display: grid;
  gap: 10px;
}
.unlock-card input {
  width: 100%;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.94);
  padding: 10px 12px;
  color: var(--text);
}
.estimate-lock.unlocked .unlock-card {
  display: none;
}

.demo-note {
  margin: 26px auto 0;
  max-width: 860px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--blue);
  border-radius: 10px;
  background: #fff;
  padding: 14px 18px;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.6;
}
.demo-note b {
  color: var(--text);
}

.demo-ribbon {
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 90;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #14100c;
  color: #f5ede3;
  font-size: 12.5px;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: 999px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.demo-ribbon:hover {
  background: #241a12;
}
.demo-ribbon .dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--blue-light);
}

.footer-disclaimer {
  grid-column: 1 / -1;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  margin-top: 26px;
  padding-top: 18px;
  font-size: 12px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.55);
}
.footer-disclaimer a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.form-success {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 34px 26px;
  text-align: center;
  display: grid;
  gap: 8px;
  justify-items: center;
}
.form-success .check-dot {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(28, 130, 66, 0.12);
  color: #1c8242;
  font-size: 22px;
  font-weight: 900;
}
.form-success strong {
  font-size: 18px;
}
.form-success p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

/* The hidden attribute must beat class display rules (.input-row grid, etc). */
[hidden] {
  display: none !important;
}

/* Radios and checkboxes inside the calculator and lead forms must not
   inherit the full-width text-input treatment (same exemption the consent
   checkbox already had). */
.calc-form .radio-row input,
.calc-form .check-grid input,
.lead-form .radio-row input,
.lead-form .check-grid input {
  width: 16px;
  height: 16px;
  min-height: 0;
  padding: 0;
  margin: 0;
  flex: none;
  accent-color: var(--blue);
}
