:root {
  --accent: #4bb9d7;
  --accent-dark: #248acc;
  --ink: #11151a;
  --ink-soft: #27303a;
  --bg: #f6f8fb;
  --card: #ffffff;
  --line: #dbe3ea;
  --dark: #0f1217;
  --dark-soft: #141a22;
  --max: 1180px;
  --radius: 12px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Montserrat", sans-serif;
  color: var(--ink);
  background: #fff;
  line-height: 1.65;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

.container {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
}

.top-strip {
  background: #f2f6fb;
  color: #1d2a38;
  text-align: center;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.65rem 1rem;
  border-bottom: 1px solid #dde7f0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #ffffff;
  border-bottom: 1px solid #e2e9f0;
}

.nav-wrap {
  min-height: 78px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  color: #0d1218;
  flex: 0 0 auto;
}

.brand-logo {
  display: block;
  width: auto;
  height: 40px;
  max-width: 210px;
}

.brand-fallback {
  display: none;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 0.85rem 1.1rem;
  min-width: 0;
}

.main-nav a {
  color: #1f2a36;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.main-nav a:hover {
  color: var(--accent-dark);
}

.hero {
  background-image: linear-gradient(125deg, rgba(0, 0, 0, 0.72), rgba(15, 26, 38, 0.66)), url("https://www.ellisbuildersllc.com/wp-content/uploads/2026/02/best-roofing-materials-connecticut-weather-featured.webp");
  background-size: cover;
  background-position: center 35%;
  color: #fff;
  padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.hero h1 {
  margin: 0;
  font-size: clamp(1.85rem, 4vw, 3rem);
  line-height: 1.16;
  max-width: 18ch;
}

.hero p {
  margin: 1rem 0 0;
  max-width: 72ch;
  color: #edf4fc;
}

.eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.84rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  color: #b5e8f4;
}

.breadcrumb {
  margin: 0 0 0.8rem;
  font-size: 0.88rem;
  color: #dbe6f2;
}

.breadcrumb a {
  color: #c7ebf5;
}

.hero-actions {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.65rem 1.1rem;
  border-radius: 999px;
  border: 1px solid transparent;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 0.81rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  background: #5ac4e2;
  color: #fff;
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.6);
  color: #fff;
}

.btn-outline:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.btn-call {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-call:hover {
  background: #3db4d2;
  color: #fff;
}

.section {
  padding: clamp(2.6rem, 6vw, 4.5rem) 0;
}

.section-light {
  background: var(--bg);
}

.section-dark {
  background: linear-gradient(165deg, var(--dark) 0%, #151d27 100%);
  color: #fff;
}

.content-block {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 2.5vw, 2rem);
  margin-bottom: 1.15rem;
  box-shadow: 0 16px 30px rgba(5, 17, 32, 0.05);
}

.content-block h2,
.content-block h3 {
  margin-top: 0;
  color: #10161f;
}

.content-block p {
  margin: 0.8rem 0;
  color: #202b37;
}

.premium-block {
  border-color: #b5dff0;
  background: linear-gradient(180deg, #ffffff 0%, #f7fcff 100%);
}

.premium-block h2 {
  color: #0f3650;
}

.toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 1rem;
}

.toc a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.2rem 0.95rem;
  font-size: 0.8rem;
  font-weight: 600;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 0.9rem;
}

.card {
  grid-column: span 12;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  padding: 1rem 1rem 1.05rem;
}

.card h3 {
  margin: 0;
  font-size: 1.02rem;
}

.card p {
  margin: 0.65rem 0;
  color: var(--ink-soft);
}

.county-card {
  background: #fefefe;
}

.text-link {
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.checklist,
.steps,
.link-list,
.town-grid {
  padding-left: 1.15rem;
}

.checklist li,
.steps li,
.link-list li,
.town-grid li {
  margin: 0.38rem 0;
}

.steps li strong {
  color: #0f1620;
}

.faq-grid {
  display: grid;
  gap: 0.8rem;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.95rem;
  background: #fff;
}

.faq-item h3 {
  margin: 0;
  font-size: 0.98rem;
}

.faq-item p {
  margin: 0.55rem 0 0;
}

.search-wrap {
  margin-bottom: 1.2rem;
}

.search-wrap label {
  display: block;
  font-size: 0.82rem;
  margin-bottom: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: #1f2d3a;
}

.search-wrap input {
  width: min(100%, 560px);
  min-height: 46px;
  border: 1px solid #c8d3de;
  border-radius: 10px;
  padding: 0.55rem 0.78rem;
  font: inherit;
}

.search-count {
  margin-top: 0.65rem;
  font-size: 0.9rem;
}

.town-grid {
  columns: 1;
}

.town-grid li[hidden] {
  display: none;
}

.cta-panel {
  text-align: left;
}

.cta-panel h2 {
  margin-top: 0;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}

.map-section {
  width: 100%;
  line-height: 0;
}

.map-section iframe {
  display: block;
  width: 100%;
}

.site-footer {
  background: #070a0f;
  color: #d8e3ef;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.1rem;
  padding: 2rem 0 1.2rem;
}

.site-footer h3,
.site-footer h4 {
  margin: 0 0 0.35rem;
  color: #fff;
}

.site-footer p {
  margin: 0.35rem 0;
}

.site-footer a {
  color: #b8e8f5;
}

.copyright {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
  font-size: 0.82rem;
  padding: 0.9rem 1rem 1.1rem;
}

@media (min-width: 680px) {
  .card {
    grid-column: span 6;
  }

  .town-grid {
    columns: 2;
  }

  .footer-grid {
    grid-template-columns: 1.15fr 1fr 1fr;
  }
}

@media (min-width: 980px) {
  .card {
    grid-column: span 4;
  }

  .county-grid .card {
    grid-column: span 3;
  }

  .town-grid {
    columns: 3;
  }
}

@media (max-width: 980px) {
  .main-nav {
    display: none;
  }

  .nav-wrap {
    min-height: 70px;
    grid-template-columns: auto auto;
    justify-content: space-between;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 1.3rem, var(--max));
  }

  .btn-call {
    display: none;
  }
}
