/* GutterGuardHub Design System — LIGHT THEME
   Palette: deep teal-blue (water/protection, trustworthy) + leaf-green accent (the literal
   function of a gutter guard: keeping leaves out). White/near-white surfaces throughout —
   no dark header/hero. Typography: system font stack for performance (no webfont blocking). */

:root {
  --gg-primary: #0f6e7a;
  --gg-primary-light: #128795;
  --gg-primary-dark: #0a4d56;
  --gg-accent: #2f7d3c;
  --gg-accent-light: #3f9a4e;
  --gg-accent-dark: #215c2b;
  --gg-bg: #ffffff;
  --gg-surface: #f6f9f8;
  --gg-surface-alt: #eef4f2;
  --gg-ink: #132022;
  --gg-ink-muted: #54666a;
  --gg-border: #dde6e5;
  --gg-success: #1f7a3d;
  --gg-danger: #b3261e;
  --gg-radius: 10px;
  --gg-shadow: 0 1px 3px rgba(15, 110, 122, 0.08), 0 1px 2px rgba(15, 110, 122, 0.06);
  --gg-shadow-lg: 0 10px 25px rgba(15, 110, 122, 0.12);
  --gg-max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

/* ---------- Accessibility: keyboard focus states (WCAG 2.4.7) ----------
   :focus-visible shows the ring only for keyboard/assistive-tech navigation,
   not on mouse/touch clicks, so pointer users don't see visual noise while
   keyboard users always get a clear, high-contrast indicator. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--gg-accent-light);
  outline-offset: 2px;
  border-radius: 4px;
}
.btn:focus-visible,
.card:focus-visible,
.header-cta:focus-visible {
  outline: 3px solid var(--gg-accent-light);
  outline-offset: 3px;
}
/* Colored-background contexts (primary-bg header CTA, sticky call bar) need a
   white ring for contrast against the teal/green background. */
.header-cta:focus-visible,
.sticky-call-bar a:focus-visible {
  outline-color: #fff;
}
/* Skip-to-content link: visually hidden until focused */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--gg-primary);
  color: #fff;
  padding: 12px 20px;
  border-radius: 0 0 8px 0;
  font-weight: 700;
}
.skip-link:focus {
  left: 0;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--gg-ink);
  background: var(--gg-bg);
  line-height: 1.55;
}
img { max-width: 100%; display: block; }
a { color: var(--gg-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; font-weight: 700; margin: 0 0 0.5em; color: var(--gg-primary-dark); }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.3em; }

.container { max-width: var(--gg-max); margin: 0 auto; padding: 0 20px; }

/* ---------- Header (light) ---------- */
.site-header {
  background: #ffffff;
  color: var(--gg-ink);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--gg-border);
  box-shadow: 0 1px 4px rgba(15, 110, 122, 0.05);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand-logo { display: flex; align-items: center; gap: 10px; color: var(--gg-primary-dark); font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.brand-logo:hover { text-decoration: none; opacity: 0.85; }
.brand-logo svg { flex-shrink: 0; }
.main-nav { display: flex; gap: 4px; align-items: center; }
.main-nav a {
  color: var(--gg-ink);
  padding: 8px 14px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.94rem;
}
.main-nav a:hover { background: var(--gg-surface-alt); text-decoration: none; color: var(--gg-primary-dark); }
.header-cta {
  background: var(--gg-accent);
  color: #fff !important;
  padding: 9px 18px !important;
  border-radius: 8px;
  font-weight: 700 !important;
}
.header-cta:hover { background: var(--gg-accent-dark); }
.header-phone {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--gg-primary-dark) !important;
  font-weight: 800 !important;
  font-size: 1.02rem;
  padding: 8px 10px !important;
  white-space: nowrap;
}
.header-phone:hover { color: var(--gg-accent-dark) !important; text-decoration: none; }
.mobile-call-btn {
  display: none;
  color: #fff;
  font-size: 1.3rem;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--gg-accent);
  margin-right: 6px;
}
.mobile-nav-toggle { display: none; background: none; border: none; color: var(--gg-primary-dark); font-size: 1.5rem; cursor: pointer; }

@media (max-width: 860px) {
  .main-nav { display: none; }
  .mobile-nav-toggle { display: block; }
  .mobile-call-btn { display: inline-flex; align-items: center; }
  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 68px; left: 0; right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--gg-border);
    box-shadow: var(--gg-shadow);
    padding: 10px 20px 20px;
    gap: 2px;
  }
}

/* ---------- Phone CTA (buttons/links using PhoneLink component) ---------- */
.phone-cta { white-space: nowrap; }
.phone-icon { margin-right: 2px; }
.footer-phone {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #fff !important;
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 14px;
}
.footer-phone:hover { color: var(--gg-accent-light) !important; text-decoration: none; }
.sticky-call-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 60;
  background: var(--gg-accent);
  box-shadow: 0 -2px 10px rgba(0,0,0,0.15);
}
.sticky-call-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  padding: 14px 0;
}
.sticky-call-bar a:hover { text-decoration: none; }
@media (max-width: 640px) {
  .sticky-call-bar { display: block; }
  body { padding-bottom: 52px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-primary { background: var(--gg-accent); color: #fff; }
.btn-primary:hover { background: var(--gg-accent-dark); text-decoration: none; }
.btn-outline { background: transparent; border-color: var(--gg-primary); color: var(--gg-primary-dark); }
.btn-outline:hover { background: var(--gg-surface-alt); text-decoration: none; }
.btn-secondary { background: var(--gg-primary); color: #fff; }
.btn-secondary:hover { background: var(--gg-primary-dark); text-decoration: none; }
.btn-sm { padding: 8px 16px; font-size: 0.9rem; }
.btn-block { width: 100%; }

/* ---------- Hero (light, with full-bleed background image option) ---------- */
.hero {
  background: linear-gradient(180deg, var(--gg-surface-alt) 0%, #ffffff 100%);
  color: var(--gg-ink);
  padding: 64px 0 56px;
  position: relative;
}
.hero h1 { color: var(--gg-primary-dark); font-size: clamp(1.9rem, 4vw, 2.9rem); max-width: 780px; }
.hero p.lead { font-size: 1.15rem; color: var(--gg-ink-muted); max-width: 620px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.trust-badges { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 34px; }
.trust-badge { display: flex; align-items: center; gap: 8px; color: var(--gg-ink-muted); font-size: 0.9rem; font-weight: 600; }

/* Homepage hero: full-bleed background photo with a light overlay so text stays readable
   while the photo itself sets the scene (a real gutter guard on a real roofline). */
.hero-bg-photo {
  position: relative;
  padding: 0;
  overflow: hidden;
  background: var(--gg-primary-dark);
}
.hero-bg-photo picture,
.hero-bg-photo > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero-bg-photo::after {
  /* Light-theme scrim: keeps the photo visible while guaranteeing WCAG-AA text contrast
     for the white heading/body text placed on top of it. */
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(10,77,86,0.88) 0%, rgba(10,77,86,0.72) 45%, rgba(10,77,86,0.40) 100%);
  z-index: 1;
}
.hero-bg-photo .container {
  position: relative;
  z-index: 2;
  padding: 76px 20px 64px;
}
.hero-bg-photo h1,
.hero-bg-photo p.lead { color: #ffffff; }
.hero-bg-photo p.lead { color: rgba(255,255,255,0.92); }
.hero-bg-photo .trust-badge { color: rgba(255,255,255,0.92); }
.hero-bg-photo .btn-outline { border-color: #fff; color: #fff; }
.hero-bg-photo .btn-outline:hover { background: rgba(255,255,255,0.15); }
@media (max-width: 700px) {
  .hero-bg-photo .container { padding: 56px 20px 48px; }
}

/* Hero with side image (guard-type pillar pages) */
.hero-split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}
.hero-split-media { position: relative; }
.hero-split-media picture,
.hero-split-media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--gg-radius);
  box-shadow: var(--gg-shadow-lg);
}
@media (max-width: 900px) {
  .hero-split { grid-template-columns: 1fr; }
  .hero-split-media { order: -1; margin-bottom: 8px; }
}

/* Service-page photo banner */
.service-photo {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  border-radius: var(--gg-radius);
  box-shadow: var(--gg-shadow-lg);
}
.service-photo picture,
.service-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---------- ZIP lookup ---------- */
.zip-lookup {
  background: var(--gg-bg);
  border: 1px solid var(--gg-border);
  border-radius: var(--gg-radius);
  padding: 20px;
  box-shadow: var(--gg-shadow-lg);
  margin-top: 30px;
  max-width: 420px;
}
.zip-lookup form { display: flex; gap: 8px; }
.zip-lookup input {
  flex: 1;
  padding: 12px 14px;
  border-radius: 6px;
  border: 1px solid var(--gg-border);
  font-size: 1rem;
}
.zip-lookup label { color: var(--gg-ink); font-weight: 700; display: block; margin-bottom: 8px; }
.hero-bg-photo .zip-lookup label { color: var(--gg-ink); }

/* ---------- Sections / cards ---------- */
.section { padding: 56px 0; }
.section-tight { padding: 32px 0; }
.section-title { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 10px; }
.section-sub { color: var(--gg-ink-muted); font-size: 1.05rem; max-width: 700px; margin-bottom: 32px; }
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  background: var(--gg-bg);
  border: 1px solid var(--gg-border);
  border-radius: var(--gg-radius);
  padding: 24px;
  box-shadow: var(--gg-shadow);
}
.card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.card p { color: var(--gg-ink-muted); font-size: 0.95rem; margin-bottom: 12px; }
.card-icon {
  width: 44px; height: 44px;
  border-radius: 10px;
  background: rgba(47,125,60,0.12);
  color: var(--gg-accent-dark);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
  font-size: 1.3rem;
}

.badge {
  display: inline-block;
  background: rgba(47,125,60,0.12);
  color: var(--gg-accent-dark);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

/* ---------- Pros/Cons list (guard-type pages) ---------- */
.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 700px) { .pros-cons { grid-template-columns: 1fr; } }
.pros-cons .pros, .pros-cons .cons {
  border-radius: var(--gg-radius);
  padding: 20px;
  border: 1px solid var(--gg-border);
}
.pros-cons .pros { background: rgba(47,125,60,0.06); }
.pros-cons .cons { background: rgba(179,38,30,0.05); }
.pros-cons h4 { margin-top: 0; font-size: 1rem; }
.pros-cons .pros h4 { color: var(--gg-accent-dark); }
.pros-cons .cons h4 { color: var(--gg-danger); }
.pros-cons ul { margin-bottom: 0; padding-left: 1.2em; }
.pros-cons li { margin-bottom: 6px; font-size: 0.94rem; }

.cost-callout {
  background: var(--gg-surface-alt);
  border: 1px solid var(--gg-border);
  border-left: 4px solid var(--gg-primary);
  border-radius: 8px;
  padding: 16px 20px;
  margin: 20px 0;
}
.cost-callout strong { color: var(--gg-primary-dark); }

/* ---------- Breadcrumbs ---------- */
.breadcrumbs { font-size: 0.88rem; color: var(--gg-ink-muted); padding: 14px 0; }
.breadcrumbs a { color: var(--gg-ink-muted); }
.breadcrumbs .sep { margin: 0 6px; color: var(--gg-border); }
.breadcrumbs .current { color: var(--gg-ink); font-weight: 600; }

/* ---------- Alt bg section ---------- */
.section-alt { background: var(--gg-surface); border-top: 1px solid var(--gg-border); border-bottom: 1px solid var(--gg-border); }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid var(--gg-border); padding: 18px 0; }
.faq-item h3 { font-size: 1.05rem; margin-bottom: 8px; }
.faq-item p { color: var(--gg-ink-muted); margin: 0; }

/* ---------- Lists / directories ---------- */
.link-list { columns: 3; column-gap: 24px; }
.link-list li { break-inside: avoid; margin-bottom: 6px; }
@media (max-width: 900px) { .link-list { columns: 2; } }
@media (max-width: 600px) { .link-list { columns: 1; } }

.state-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.state-grid a {
  display: block;
  padding: 12px 16px;
  background: var(--gg-bg);
  border: 1px solid var(--gg-border);
  border-radius: 8px;
  font-weight: 600;
}
.state-grid a:hover { border-color: var(--gg-accent); text-decoration: none; }
.state-grid .zc { color: var(--gg-ink-muted); font-weight: 400; font-size: 0.85rem; }

.tier3-note {
  background: #fdf6e3;
  border: 1px solid #f0dcb8;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 0.9rem;
  color: #7a5210;
  margin: 20px 0;
}

/* ---------- Forms ---------- */
.lead-form { background: var(--gg-surface); border-radius: var(--gg-radius); padding: 28px; box-shadow: var(--gg-shadow); border: 1px solid var(--gg-border); }
.lead-form .field { margin-bottom: 14px; }
.lead-form label { display: block; font-weight: 700; font-size: 0.88rem; margin-bottom: 6px; }
.lead-form input, .lead-form select, .lead-form textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--gg-border);
  border-radius: 6px;
  font-size: 0.98rem;
  font-family: inherit;
  background: #fff;
}
.lead-form .disclosure { font-size: 0.78rem; color: var(--gg-ink-muted); margin-top: 12px; }
.lead-form input[aria-invalid="true"] { border-color: var(--gg-danger); background: rgba(179,38,30,0.04); }
.lead-form-or {
  text-align: center;
  color: var(--gg-ink-muted);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 14px 0;
  position: relative;
}
.lead-form-or::before, .lead-form-or::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: var(--gg-border);
}
.lead-form-or::before { left: 0; }
.lead-form-or::after { right: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--gg-primary-dark); color: rgba(255,255,255,0.82); padding: 48px 0 24px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.footer-grid h4 { color: #fff; font-size: 0.95rem; margin-bottom: 14px; }
.footer-grid a { color: rgba(255,255,255,0.75); font-size: 0.9rem; display: block; margin-bottom: 8px; }
.footer-grid a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.15); margin-top: 32px; padding-top: 20px; font-size: 0.82rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.flex { display: flex; }
.gap-2 { gap: 8px; }
.items-center { align-items: center; }
