/* Knoxville Mold Pros — shared stylesheet
   Design language: professional restoration-industry. Navy (trust) + safety-orange (CTA).
   System fonts, 4-pt spacing grid, max content width 1080px. Mobile-first. */

:root {
  --navy: #0f2748;
  --navy-deep: #0a1c35;
  --blue: #1d4ed8;
  --orange: #ea580c;
  --orange-dark: #c2410c;
  --orange-darker: #9a3412;
  --bg: #ffffff;
  --surface: #f4f7fb;
  --border: #d8e0ea;
  --text: #1a2332;
  --muted: #55637a;
  --success: #15803d;
  --radius: 8px;
  --shadow: 0 2px 8px rgba(15, 39, 72, 0.08);
  --shadow-lg: 0 8px 24px rgba(15, 39, 72, 0.14);
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --max-width: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  /* room for the sticky mobile call bar */
  padding-bottom: 64px;
}

h1, h2, h3, h4 { line-height: 1.25; color: var(--navy); margin: 0 0 var(--space-4); }
h1 { font-size: 2rem; letter-spacing: -0.02em; }
h2 { font-size: 1.5rem; letter-spacing: -0.01em; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 var(--space-4); }
a { color: var(--blue); }
img, svg { max-width: 100%; }

/* ---------- Header ---------- */
.site-header {
  background: var(--navy);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: var(--shadow);
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--space-3) var(--space-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}
.logo {
  font-weight: 800;
  font-size: 1.15rem;
  color: #fff;
  text-decoration: none;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.logo svg { flex: none; }
.logo .logo-sub { color: #9fb3cd; font-weight: 500; font-size: 0.85rem; display: block; }

.header-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--orange-dark); /* 5.2:1 on white text — AA */
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius);
  white-space: nowrap;
  transition: background 150ms ease;
}
.header-cta:hover, .header-cta:focus-visible { background: var(--orange-darker); }

.site-nav { gap: var(--space-1); }
.site-nav a {
  color: #d7e2f0;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  transition: background 150ms ease, color 150ms ease;
}
.site-nav a:hover, .site-nav a:focus-visible,
.site-nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.12); color: #fff; }

/* Mobile nav: collapsed behind the hamburger toggle */
.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 44px;
  height: 44px;
  padding: 11px 10px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: var(--radius);
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: #fff;
  border-radius: 1px;
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0.4; }

@media (max-width: 959px) {
  .site-nav {
    display: none;
    order: 4;
    flex-basis: 100%;
    flex-direction: column;
    padding-top: var(--space-2);
  }
  .site-nav.is-open { display: flex; }
  .header-cta { margin-left: auto; }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Skip-to-content: hidden until focused */
.skip-link {
  position: absolute;
  left: var(--space-4);
  top: var(--space-2);
  z-index: 100;
  background: var(--navy-deep);
  color: #fff;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 700;
  transform: translateY(-200%);
  transition: transform 150ms ease;
}
.skip-link:focus-visible { transform: translateY(0); }

/* Keep anchored targets clear of the sticky header */
[id] { scroll-margin-top: 76px; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-deep) 100%);
  color: #fff;
  padding: var(--space-8) 0;
}
.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-4);
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
}
.hero h1 { color: #fff; font-size: 2.2rem; }
.hero p.lead { color: #c4d3e6; font-size: 1.1rem; max-width: 34rem; }
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin: 0 0 var(--space-5);
  padding: 0;
  list-style: none;
}
.hero-badges li {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #e6eef8;
  font-size: 0.88rem;
  font-weight: 600;
  padding: var(--space-1) var(--space-3);
  border-radius: 999px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  transition: background 150ms ease, color 150ms ease;
}
.btn-primary { background: var(--orange-dark); color: #fff; }
.btn-primary:hover, .btn-primary:focus-visible { background: var(--orange-darker); }
.btn-secondary { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.btn-secondary:hover, .btn-secondary:focus-visible { background: rgba(255, 255, 255, 0.12); }
.btn-call { background: var(--orange-dark); color: #fff; }
.btn-call:hover, .btn-call:focus-visible { background: var(--orange-darker); }
.btn-call::before { content: "📞 "; }

/* ---------- Page hero (interior pages) ---------- */
.page-hero {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: var(--space-7) 0;
}
.page-hero h1 { margin-bottom: var(--space-2); }
.page-hero .breadcrumb {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 var(--space-3);
}
.page-hero .breadcrumb a { color: var(--muted); }

/* ---------- Sections ---------- */
.section { padding: var(--space-8) 0; }
.section-alt { background: var(--surface); }
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 var(--space-4); }
.section-intro { max-width: 46rem; color: var(--muted); }

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  box-shadow: var(--shadow);
}
.card h3 { margin-bottom: var(--space-2); }
.card p { color: var(--muted); margin-bottom: var(--space-3); }
.card .card-link { font-weight: 700; text-decoration: none; }
.card .card-link:hover { text-decoration: underline; }
.card-icon { color: var(--blue); margin-bottom: var(--space-3); }

/* ---------- Steps ---------- */
.steps { counter-reset: step; padding: 0; list-style: none; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 var(--space-5) 56px;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.steps h3 { margin-bottom: var(--space-1); }
.steps p { color: var(--muted); margin: 0; }

/* ---------- FAQ ---------- */
.faq { max-width: 46rem; }
.faq details {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-4) var(--space-5);
  margin-bottom: var(--space-3);
}
.faq summary {
  font-weight: 700;
  cursor: pointer;
  color: var(--navy);
}
.faq details[open] summary { margin-bottom: var(--space-2); }
.faq p { margin-bottom: 0; color: var(--muted); }

/* ---------- Form ---------- */
.form-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: var(--space-5);
}
.form-card h2 { font-size: 1.3rem; }
.form-note { font-size: 0.88rem; color: var(--muted); margin-bottom: var(--space-4); }
.form-row { display: grid; grid-template-columns: 1fr; gap: var(--space-4); }
label { display: block; font-weight: 600; font-size: 0.92rem; margin-bottom: var(--space-1); color: var(--navy); }
input[type="text"], input[type="tel"], input[type="email"], select, textarea {
  width: 100%;
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font: inherit;
  color: var(--text);
  background: #fff;
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 1px;
}
textarea { min-height: 110px; resize: vertical; }
.consent { display: flex; gap: var(--space-2); align-items: flex-start; }
.consent input { margin-top: 4px; }
.consent label { font-weight: 400; font-size: 0.85rem; color: var(--muted); margin: 0; }
.hidden { position: absolute; left: -9999px; }

/* ---------- Areas list ---------- */
.areas-grid { display: grid; grid-template-columns: 1fr; gap: var(--space-2); padding: 0; list-style: none; }
.areas-grid li {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-deep);
  color: #b6c5da;
  padding: var(--space-7) 0 var(--space-6);
  font-size: 0.92rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}
.site-footer h3 { color: #fff; font-size: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: var(--space-2); }
.site-footer a { color: #b6c5da; text-decoration: none; }
.site-footer a:hover, .site-footer a:focus-visible { color: #fff; text-decoration: underline; }
.footer-phone { color: #fff; font-weight: 700; font-size: 1.2rem; text-decoration: none; }
.footer-legal {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  color: #8fa3bd;
  font-size: 0.85rem;
}

/* ---------- Sticky mobile call bar ---------- */
.mobile-call-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 60;
  background: var(--orange-dark);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  display: flex;
}
.mobile-call-bar a {
  flex: 1;
  text-align: center;
  color: #fff;
  font-weight: 800;
  text-decoration: none;
  padding: var(--space-4);
  font-size: 1rem;
}
.mobile-call-bar a + a { border-left: 1px solid rgba(255, 255, 255, 0.25); }

/* ---------- 404 ---------- */
.not-found { text-align: center; padding: var(--space-8) 0; }

/* ---------- Tablet+ ---------- */
@media (min-width: 640px) {
  h1 { font-size: 2.5rem; }
  .hero h1 { font-size: 2.6rem; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .form-row { grid-template-columns: 1fr 1fr; }
  .areas-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .hero-inner { grid-template-columns: 1.1fr 0.9fr; }
  .card-grid--3 { grid-template-columns: repeat(3, 1fr); }
  .areas-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 2fr 1fr 1fr; }
  .nav-toggle { display: none; }
  .site-nav { display: flex; flex-direction: row; order: 0; flex-basis: auto; }
}

/* Large screens: the mobile call bar is redundant with the header CTA */
@media (min-width: 960px) {
  body { padding-bottom: 0; }
  .mobile-call-bar { display: none; }
}

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