/* ===================================================================
   Interstate Roofing - getfreeroofquote.com
   Mobile-first, accessible, fast-loading stylesheet
   =================================================================== */

:root {
  --navy: #1F3864;
  --navy-dark: #142647;
  --gold: #FFC857;
  --gold-dark: #E6B048;
  --orange: #E97132;
  --green: #2E7D32;
  --red: #C00000;
  --text: #1F1F1F;
  --text-muted: #555555;
  --text-light: #777777;
  --bg: #FFFFFF;
  --bg-soft: #F5F7FA;
  --bg-card: #FFFFFF;
  --border: #E0E4EA;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.10);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.12);
  --radius: 8px;
  --radius-lg: 12px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--navy); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--navy-dark); }

/* Skip link for keyboard users */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--navy);
  color: #FFF;
  padding: 12px 20px;
  z-index: 1000;
  text-decoration: none;
  font-weight: 700;
}
.skip-link:focus { top: 0; }

/* Focus visibility */
:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ----------- Layout ----------- */

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
}

section { padding: 56px 0; }

/* ----------- Header / Nav ----------- */

.site-header {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  max-width: 1180px;
  margin: 0 auto;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  font-size: 20px;
  font-weight: 800;
  color: var(--navy);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px;
}
.brand-mark {
  width: 32px;
  height: 32px;
  display: inline-block;
}

.header-cta-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.phone-link {
  font-weight: 700;
  color: var(--navy);
  text-decoration: none;
  font-size: 16px;
  padding: 12px 14px;
  border-radius: var(--radius);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
}
.phone-link:hover { background: var(--bg-soft); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  min-height: 48px;
  transition: transform 0.1s, box-shadow 0.15s, background 0.15s;
  text-align: center;
  line-height: 1.2;
}
.btn-primary {
  background: var(--gold);
  color: #1A1A1A;
  border-color: var(--gold);
}
.btn-primary:hover {
  background: var(--gold-dark);
  border-color: var(--gold-dark);
  box-shadow: var(--shadow-md);
  color: #1A1A1A;
}
.btn-secondary {
  background: var(--navy);
  color: #FFF;
  border-color: var(--navy);
}
.btn-secondary:hover {
  background: var(--navy-dark);
  border-color: var(--navy-dark);
  color: #FFF;
}
.btn-large {
  font-size: 18px;
  padding: 18px 30px;
  min-height: 56px;
}

/* ----------- Hero ----------- */

.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-dark) 100%);
  color: #FFF;
  padding: 70px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.alert-banner {
  display: inline-block;
  background: var(--red);
  color: #FFF;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 8px 18px;
  border-radius: 100px;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(32px, 6vw, 56px);
  line-height: 1.05;
  font-weight: 800;
  margin: 0 0 20px;
  letter-spacing: -0.5px;
}
.hero h1 .accent { color: var(--gold); display: block; }

.hero p.lede {
  font-size: clamp(16px, 2.2vw, 20px);
  max-width: 720px;
  margin: 0 auto 28px;
  color: #E6EEF7;
  line-height: 1.5;
}

.hero .cta-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.markets-list {
  font-size: 15px;
  color: #B8C7D9;
  font-weight: 500;
}

/* ----------- Stats ----------- */

.stats {
  background: var(--bg-soft);
  padding: 36px 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 24px;
  text-align: center;
}
.stat-num {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 800;
  color: var(--navy);
  line-height: 1.1;
}
.stat-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ----------- Section headings ----------- */

.section-eyebrow {
  text-transform: uppercase;
  color: var(--orange);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-align: center;
  margin: 0 0 8px;
}
h2.section-title {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 800;
  text-align: center;
  margin: 0 0 14px;
  color: var(--navy);
  line-height: 1.15;
}
.section-sub {
  text-align: center;
  color: var(--text-muted);
  font-size: 17px;
  max-width: 640px;
  margin: 0 auto 40px;
}

/* ----------- City Cards ----------- */

.city-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}
.city-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
  min-height: 200px;
}
.city-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--navy);
  color: var(--text);
}
.city-state {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 1px;
}
.city-name {
  font-size: 24px;
  font-weight: 800;
  color: var(--navy);
  margin: 4px 0 12px;
}
.city-zips {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 16px;
}
.activity-pill {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  margin-bottom: 6px;
}
.activity-high { background: #FEE2E2; color: #B91C1C; }
.activity-moderate { background: #FEF3C7; color: #92400E; }
.city-county {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 18px;
}
.city-card-cta {
  margin-top: auto;
  font-weight: 700;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ----------- Why Us ----------- */

.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.why-card {
  padding: 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.why-card h3 {
  font-size: 20px;
  margin: 0 0 10px;
  color: var(--navy);
  font-weight: 700;
}
.why-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.6;
}
.why-icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--navy);
  color: var(--gold);
  border-radius: 50%;
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 14px;
}

/* ----------- Process ----------- */

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  counter-reset: step;
}
.process-step {
  text-align: center;
  padding: 0 16px;
  position: relative;
}
.process-step .step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--navy);
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 14px;
}
.process-step h3 {
  font-size: 18px;
  margin: 0 0 8px;
  color: var(--navy);
  font-weight: 700;
}
.process-step p {
  margin: 0;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.55;
}

/* ----------- Gallery ----------- */

.gallery {
  background: var(--bg-soft);
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.gallery-item {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background: #FFF;
  transition: transform 0.15s, box-shadow 0.15s;
}
.gallery-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.gallery-item img {
  width: 100%;
  height: auto;
  aspect-ratio: 650 / 436;
  object-fit: cover;
}
.gallery-caption {
  padding: 14px 16px;
  font-size: 14px;
  color: var(--text-muted);
}
.gallery-caption strong { color: var(--navy); display: block; margin-bottom: 2px; font-size: 15px; }

/* ----------- Testimonials ----------- */

.testimonials {
  background: #FFF;
}
.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.testimonial {
  padding: 28px;
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--gold);
}
.testimonial-stars {
  color: #F59E0B;
  font-size: 18px;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.testimonial-quote {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  margin: 0 0 16px;
  font-style: italic;
}
.testimonial-author {
  font-size: 14px;
  color: var(--text-muted);
}
.testimonial-author strong { color: var(--navy); }

/* ----------- FAQ ----------- */

.faq-list {
  max-width: 760px;
  margin: 0 auto;
}
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
  background: #FFF;
}
.faq-item summary {
  cursor: pointer;
  padding: 18px 24px;
  font-weight: 700;
  font-size: 16px;
  color: var(--navy);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 24px;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 12px;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item[open] summary { border-bottom: 1px solid var(--border); }
.faq-answer { padding: 18px 24px; color: var(--text-muted); line-height: 1.6; }
.faq-answer p:first-child { margin-top: 0; }
.faq-answer p:last-child { margin-bottom: 0; }

/* ----------- Quote Form ----------- */

.quote-section { background: var(--bg-soft); }
.quote-form-wrap {
  max-width: 720px;
  margin: 0 auto;
  background: #FFF;
  padding: 36px 32px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-field { display: flex; flex-direction: column; }
.form-field.span-2 { grid-column: 1 / -1; }
.form-field label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.form-field label .req { color: var(--red); }
.form-field input, .form-field select, .form-field textarea {
  font: inherit;
  font-size: 16px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #FFF;
  color: var(--text);
  min-height: 48px;
  width: 100%;
}
.form-field textarea { min-height: 110px; resize: vertical; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(31,56,100,0.15);
}
.form-submit {
  margin-top: 24px;
  width: 100%;
}
.form-disclaimer {
  font-size: 13px;
  color: var(--text-light);
  text-align: center;
  margin-top: 14px;
  line-height: 1.5;
}

/* ----------- Trust badges ----------- */

.trust-badges {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 30px;
  align-items: center;
}
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: #FFF;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
}
.trust-badge strong { color: var(--navy); }

/* ----------- Footer ----------- */

.site-footer {
  background: var(--navy-dark);
  color: #C8D3E2;
  padding: 56px 0 24px;
  font-size: 15px;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 36px;
  margin-bottom: 32px;
}
.footer-col h3 {
  color: #FFF;
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.footer-col p, .footer-col ul { margin: 0 0 10px; }
.footer-col ul { list-style: none; padding: 0; }
.footer-col li { margin-bottom: 8px; }
.footer-col a {
  color: #C8D3E2;
  text-decoration: none;
  padding: 4px 0;
  display: inline-block;
  min-height: 32px;
  line-height: 1.4;
}
.footer-col a:hover { color: var(--gold); text-decoration: underline; }
.footer-bottom {
  border-top: 1px solid #2D4467;
  padding-top: 20px;
  text-align: center;
  font-size: 13px;
  color: #8FA0B8;
  line-height: 1.6;
}
.footer-bottom .disclaimer {
  max-width: 880px;
  margin: 8px auto 0;
  font-size: 12px;
}

/* ----------- Honeypot (anti-spam) ----------- */
.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ----------- Responsive ----------- */

@media (max-width: 720px) {
  section { padding: 44px 0; }
  .hero { padding: 50px 0 44px; }
  .header-inner { padding: 12px 16px; }
  .container { padding: 0 16px; }
  .form-grid { grid-template-columns: 1fr; }
  .quote-form-wrap { padding: 26px 20px; }
  .hero .cta-row { flex-direction: column; align-items: stretch; }
  .hero .cta-row .btn { width: 100%; }
}

@media (max-width: 480px) {
  .header-cta-group { width: 100%; justify-content: space-between; }
  .brand { font-size: 18px; }
}

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

/* ----------- Print ----------- */
@media print {
  .site-header, .site-footer, .hero .cta-row, .quote-section { display: none; }
}
