/* ------------------------------------------------------------
   SLAB LEAK REPAIR NORTH HUNTINGDON — style.css
   Design DNA: technical, editorial, grounded, local.
   Palette: deep slate + warm amber accent + off-white.
------------------------------------------------------------ */

/* ---------- TOKENS ---------- */
:root {
  --c-bg: #f8fafc;
  --c-surface: #ffffff;
  --c-dark: #0b1b2b;
  --c-dark-soft: #1e2e3f;
  --c-accent: #eab308;
  --c-accent-soft: #fef9c3;
  --c-text: #0f172a;
  --c-text-muted: #475569;
  --c-border: #e2e8f0;

  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Space Grotesk', 'Inter', sans-serif;

  --step--1: clamp(0.875rem, 0.8rem + 0.25vw, 1rem);
  --step-0: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --step-1: clamp(1.25rem, 1.15rem + 0.5vw, 1.5rem);
  --step-2: clamp(1.5rem, 1.3rem + 1vw, 2rem);
  --step-3: clamp(2rem, 1.75rem + 1.5vw, 2.75rem);
  --step-4: clamp(2.5rem, 2rem + 2.5vw, 4rem);

  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1.25rem;
  --space-lg: 2rem;
  --space-xl: 3.5rem;
  --space-2xl: 5rem;

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 28px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.06);

  --max-width: 1200px;
  --header-height: 72px;

  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ---------- RESET ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--c-text);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(64px + var(--safe-bottom)); /* space for sticky call */
}
@media (min-width: 768px) { body { padding-bottom: 0; } }

img { max-width: 100%; display: block; height: auto; }
a { color: inherit; }
button { font: inherit; }

/* ---------- ACCESSIBILITY ---------- */
.skip-link {
  position: absolute; top: -100%; left: var(--space-md);
  background: var(--c-dark); color: #fff; padding: 0.75rem 1rem;
  border-radius: var(--radius-sm); z-index: 9999; font-weight: 500;
}
.skip-link:focus { top: var(--space-md); }
:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- LAYOUT ---------- */
.section { padding: var(--space-xl) var(--space-md); }
.section__inner { max-width: var(--max-width); margin: 0 auto; }
.section__eyebrow {
  font-size: var(--step--1); text-transform: uppercase; letter-spacing: 0.08em;
  font-weight: 600; color: var(--c-accent); margin: 0 0 var(--space-xs);
}
.section__title {
  font-family: var(--font-display); font-size: var(--step-3); line-height: 1.1;
  letter-spacing: -0.02em; margin: 0 0 var(--space-md); font-weight: 600;
}
.section__text { color: var(--c-text-muted); max-width: 60ch; margin: 0 0 var(--space-sm); }
.section__cta { display: flex; flex-wrap: wrap; gap: var(--space-md); align-items: center; margin-top: var(--space-lg); }

@media (min-width: 768px) { .section { padding: var(--space-2xl) var(--space-lg); } }

/* ---------- BUTTONS & LINKS ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 1.5rem; border-radius: var(--radius-pill);
  font-weight: 600; text-decoration: none; border: none; cursor: pointer;
  transition: background 0.2s, color 0.2s, transform 0.1s;
  min-height: 44px; font-size: var(--step--1);
}
.btn--primary { background: var(--c-accent); color: var(--c-dark); }
.btn--primary:hover { background: #facc15; }
.btn--outline { background: transparent; border: 1.5px solid var(--c-border); color: var(--c-text); }
.btn--outline:hover { border-color: var(--c-dark); }
.btn--large { padding: 1.125rem 2rem; font-size: var(--step-0); }
.link-arrow {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-weight: 500; color: var(--c-text); text-decoration: none;
  border-bottom: 1.5px solid var(--c-accent); padding-bottom: 2px;
  transition: color 0.2s;
}
.link-arrow:hover { color: var(--c-accent); }

/* ---------- HEADER ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(248,250,252,0.92); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--c-border);
  padding: 0 var(--space-md);
}
.site-header__inner {
  max-width: var(--max-width); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-height);
}
.site-header__logo { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; }
.logo-mark { width: 32px; height: 32px; background: var(--c-dark); border-radius: 8px; position: relative; }
.logo-mark::after {
  content: ''; position: absolute; inset: 6px; background: var(--c-accent);
  border-radius: 4px; clip-path: polygon(0 60%, 40% 60%, 40% 100%, 60% 100%, 60% 40%, 100% 40%, 100% 0, 60% 0, 60% 40%, 40% 40%, 40% 0, 0 0);
}
.logo-text { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; line-height: 1; }
.logo-text small { display: block; font-size: 0.65rem; font-weight: 400; color: var(--c-text-muted); letter-spacing: 0.04em; }

.menu-toggle {
  display: flex; flex-direction: column; gap: 5px;
  background: transparent; border: none; cursor: pointer;
  padding: 10px; min-width: 44px; min-height: 44px;
  align-items: center; justify-content: center;
}
.menu-toggle__bar { width: 22px; height: 2px; background: var(--c-text); transition: transform 0.2s, opacity 0.2s; }

.site-nav { display: none; }
.site-nav.is-open {
  display: flex; flex-direction: column;
  position: absolute; top: var(--header-height); left: 0; right: 0;
  background: var(--c-surface); padding: var(--space-md);
  border-bottom: 1px solid var(--c-border); box-shadow: var(--shadow-md);
  max-height: calc(100dvh - var(--header-height)); overflow-y: auto;
}
.site-nav__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--space-xs); }
.site-nav__list a {
  display: block; padding: 0.75rem 0.5rem; text-decoration: none;
  font-weight: 500; border-radius: var(--radius-sm); min-height: 44px;
}
.site-nav__list a:hover, .site-nav__list a[aria-current="page"] { background: var(--c-accent-soft); }
.site-nav__phone {
  display: flex; align-items: center; gap: 0.5rem; margin-top: var(--space-md);
  padding: 0.75rem 1rem; background: var(--c-dark); color: #fff;
  border-radius: var(--radius-pill); text-decoration: none; font-weight: 600;
  justify-content: center; min-height: 48px;
}

@media (min-width: 900px) {
  .menu-toggle { display: none; }
  .site-nav { display: flex !important; position: static; background: none; padding: 0; box-shadow: none; flex-direction: row; align-items: center; gap: var(--space-md); max-height: none; }
  .site-nav__list { flex-direction: row; gap: var(--space-xs); }
  .site-nav__list a { padding: 0.5rem 0.75rem; }
  .site-nav__phone { margin-top: 0; padding: 0.6rem 1.25rem; }
}

/* ---------- HERO ---------- */
.hero {
  background: var(--c-dark); color: #f8fafc;
  padding: var(--space-lg) var(--space-md) var(--space-xl);
}
.hero__content { max-width: var(--max-width); margin: 0 auto; }
.hero__eyebrow {
  font-size: var(--step--1); text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--c-accent); font-weight: 600; margin: 0 0 var(--space-sm);
}
.hero__title {
  font-family: var(--font-display); font-size: clamp(2.4rem, 8vw, 4.8rem);
  line-height: 1.05; letter-spacing: -0.02em; font-weight: 600; margin: 0 0 var(--space-md);
}
.hero__sub { font-size: var(--step-0); color: #cbd5e1; max-width: 600px; margin-bottom: var(--space-lg); }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); align-items: center; }
.hero__cta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--c-accent); color: var(--c-dark);
  padding: 1rem 1.75rem; border-radius: var(--radius-pill);
  font-weight: 600; text-decoration: none; min-height: 52px;
  transition: background 0.2s;
}
.hero__cta:hover { background: #facc15; }
.hero__secondary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  color: #e2e8f0; text-decoration: none; font-weight: 500;
  border-bottom: 1.5px solid var(--c-accent); padding-bottom: 2px;
  min-height: 44px;
}
.hero__meta {
  display: flex; flex-wrap: wrap; gap: var(--space-md);
  margin-top: var(--space-lg); font-size: var(--step--1); color: #94a3b8;
}
.hero__visual { max-width: var(--max-width); margin: var(--space-lg) auto 0; position: relative; }
.hero__image { border-radius: var(--radius-lg); width: 100%; object-fit: cover; aspect-ratio: 16/9; }
.hero__visual-caption {
  font-size: 0.75rem; color: #94a3b8; margin-top: 0.5rem;
  font-style: italic;
}

@media (min-width: 768px) {
  .hero { padding: var(--space-2xl) var(--space-lg) var(--space-2xl); }
  .hero__content { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-xl); align-items: center; }
  .hero__visual { margin: 0; }
}

/* ---------- INTRO GRID ---------- */
.intro-grid { display: grid; gap: var(--space-xl); }
.intro-grid__content .section__title { margin-top: 0; }
.intro-grid__meta { display: grid; gap: var(--space-md); }
.stat-block {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-md); padding: var(--space-md);
}
.stat-block__number { font-family: var(--font-display); font-size: 2rem; font-weight: 600; color: var(--c-accent); line-height: 1; }
.stat-block__label { display: block; font-weight: 600; margin: 0.25rem 0; }
.stat-block p { margin: 0; color: var(--c-text-muted); font-size: var(--step--1); }

@media (min-width: 768px) {
  .intro-grid { grid-template-columns: 1.4fr 1fr; align-items: start; }
}

/* ---------- SIGNS GRID ---------- */
.signs-grid {
  display: grid; gap: var(--space-md); margin-top: var(--space-lg);
}
@media (min-width: 600px) { .signs-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .signs-grid { grid-template-columns: repeat(3, 1fr); } }
.sign-card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-md); padding: var(--space-md);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.sign-card:hover { border-color: var(--c-accent); box-shadow: var(--shadow-sm); }
.sign-card__icon { font-size: 1.5rem; display: block; margin-bottom: var(--space-xs); }
.sign-card h3 { font-family: var(--font-display); font-size: var(--step-1); margin: 0 0 var(--space-xs); }
.sign-card p { margin: 0; color: var(--c-text-muted); font-size: var(--step--1); }

/* ---------- CTA MID ---------- */
.section--cta-mid { background: var(--c-dark); color: #f8fafc; }
.cta-mid { text-align: center; max-width: 600px; margin: 0 auto; }
.cta-mid__title { font-family: var(--font-display); font-size: var(--step-2); margin: 0 0 var(--space-sm); }
.cta-mid__text { color: #cbd5e1; margin: 0 0 var(--space-lg); }
.section--cta-alt { background: var(--c-dark-soft); }

/* ---------- DETECTION ---------- */
.detection-grid { display: grid; gap: var(--space-xl); }
.detection-list { list-style: none; padding: 0; margin: var(--space-md) 0 0; display: flex; flex-direction: column; gap: var(--space-md); }
.detection-list li { display: flex; gap: var(--space-sm); }
.detection-list__num {
  font-family: var(--font-display); font-weight: 600; color: var(--c-accent);
  font-size: 1.25rem; line-height: 1; min-width: 1.5rem;
}
.detection-list strong { display: block; font-weight: 600; }
.detection-list p { margin: 0.15rem 0 0; color: var(--c-text-muted); font-size: var(--step--1); }
.detection-grid__image img { border-radius: var(--radius-lg); }

@media (min-width: 768px) {
  .detection-grid { grid-template-columns: 1fr 1fr; align-items: center; }
}

/* ---------- FAQ PREVIEW ---------- */
.faq-preview { margin-top: var(--space-lg); display: flex; flex-direction: column; gap: var(--space-sm); }
.faq-item {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: var(--radius-md); padding: var(--space-sm) var(--space-md);
}
.faq-item summary {
  cursor: pointer; font-weight: 600; list-style: none; display: flex;
  justify-content: space-between; align-items: center; min-height: 44px;
  gap: var(--space-sm);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-size: 1.25rem; color: var(--c-accent); font-weight: 400; }
.faq-item[open] summary::after { content: '–'; }
.faq-item p { margin: 0.5rem 0 0; color: var(--c-text-muted); }

/* ---------- FINAL CTA ---------- */
.section--final-cta { background: var(--c-dark); color: #f8fafc; }
.final-cta { display: grid; gap: var(--space-lg); }
.final-cta__title { font-family: var(--font-display); font-size: var(--step-3); margin: 0 0 var(--space-sm); }
.final-cta__text { color: #cbd5e1; margin: 0 0 var(--space-lg); }
.final-cta__actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); }
.final-cta__address {
  font-style: normal; display: flex; flex-direction: column; gap: 0.25rem;
  color: #94a3b8; font-size: var(--step--1); border-left: 2px solid var(--c-accent);
  padding-left: var(--space-md);
}

@media (min-width: 768px) {
  .final-cta { grid-template-columns: 1.5fr 1fr; align-items: center; }
}

/* ---------- STICKY CALL ---------- */
.sticky-call {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--c-dark); padding: 0.65rem var(--space-md);
  padding-bottom: calc(0.65rem + var(--safe-bottom));
  z-index: 90; display: flex; justify-content: center;
  border-top: 1px solid var(--c-dark-soft);
}
.sticky-call__btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--c-accent); color: var(--c-dark);
  padding: 0.75rem 2rem; border-radius: var(--radius-pill);
  font-weight: 600; text-decoration: none; width: 100%;
  justify-content: center; max-width: 400px; min-height: 48px;
}
@media (min-width: 768px) { .sticky-call { display: none; } }

/* ---------- FOOTER ---------- */
.site-footer {
  background: var(--c-dark); color: #94a3b8;
  padding: var(--space-xl) var(--space-md) var(--space-lg);
  font-size: var(--step--1);
}
.site-footer__inner { max-width: var(--max-width); margin: 0 auto; display: grid; gap: var(--space-lg); }
.site-footer__brand { display: flex; align-items: center; gap: 0.6rem; color: #e2e8f0; font-weight: 500; }
.site-footer__nav { display: flex; flex-wrap: wrap; gap: var(--space-md); }
.site-footer__nav a { color: #94a3b8; text-decoration: none; }
.site-footer__nav a:hover { color: var(--c-accent); }
.site-footer__legal { border-top: 1px solid #1e2e3f; padding-top: var(--space-md); }
.site-footer__disclaimer { font-size: 0.75rem; margin-top: 0.5rem; color: #64748b; }

@media (min-width: 768px) {
  .site-footer__inner { grid-template-columns: 1fr 1fr; }
  .site-footer__legal { grid-column: 1 / -1; }
}

/* ---------- REDUCED MOTION ---------- */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}

/* ---------- SAFE AREA ---------- */
@supports (padding: max(0px)) {
  .site-header { padding-top: max(0px, env(safe-area-inset-top)); }
  .sticky-call { padding-bottom: max(0.65rem, env(safe-area-inset-bottom)); }
}