:root {
  --blue: #01417a;
  --blue-dark: #062b4e;
  --orange: #d37b25;
  --orange-dark: #a95d16;
  --ink: #222;
  --muted: #666;
  --paper: #fff;
  --soft: #f2f4f6;
  --line: #dfe3e7;
  --max: 1170px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Work Sans", Arial, Helvetica, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
}

a {
  color: inherit;
}

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

.topbar {
  background: var(--blue);
  color: #fff;
  font-size: 14px;
}

.topbar-inner,
.nav-inner,
.section-inner {
  width: min(var(--max), calc(100% - 30px));
  margin: 0 auto;
}

.topbar-inner {
  min-height: 35px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 26px;
}

.topbar a {
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.06);
}

.nav-inner {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo img {
  width: 245px;
  height: auto;
}

.menu {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.menu a {
  text-decoration: none;
  color: #333;
}

.menu a:hover {
  color: var(--orange);
}

.button,
button,
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 0;
  padding: 14px 25px;
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.button:hover,
button:hover,
input[type="submit"]:hover {
  background: var(--orange-dark);
  transform: translateY(-1px);
}

.button.secondary {
  background: #fff;
  color: var(--blue);
  border: 2px solid #fff;
}

.button.ghost {
  background: transparent;
  color: var(--blue);
  border: 2px solid var(--blue);
}

.hero {
  min-height: 620px;
  display: flex;
  align-items: center;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(0, 28, 55, 0.82), rgba(0, 28, 55, 0.38)),
    url("/assets/images/home-hero-family-roofing.jpg") center / cover no-repeat;
}

.hero-copy {
  max-width: 575px;
  padding: 70px 0;
}

.hero h1 {
  margin: 0;
  font-size: 52px;
  line-height: 1.08;
  font-weight: 700;
}

.rule {
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.65);
  margin: 25px 0;
}

.hero h2 {
  margin: 0;
  font-size: 22px;
  color: #fff;
  font-weight: 500;
}

.hero p {
  margin: 0 0 30px;
  color: #e6edf5;
  font-size: 20px;
}

.estimate-band {
  background: #f2f2f2;
  padding: 48px 0 42px;
}

.estimate-card {
  background: #fff;
  max-width: 920px;
  margin: 0 auto;
  padding: 34px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.estimate-card h2 {
  text-align: center;
  color: var(--blue);
  margin: 0 0 24px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

label {
  display: block;
  font-weight: 600;
  color: #333;
  margin-bottom: 6px;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid #d4d8dd;
  border-radius: 0;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.span-2 {
  grid-column: span 2;
}

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

.form-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
  margin-top: 18px;
}

.form-note {
  color: var(--muted);
  margin: 0;
}

section {
  padding: 88px 0;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 54px;
  align-items: center;
}

.split h2,
.service-grid h2,
.page-title h1,
.agent-panel h2 {
  color: var(--blue);
  line-height: 1.18;
}

.split h2 {
  font-size: 34px;
  margin: 0 0 20px;
}

.lead {
  font-size: 19px;
  color: #333;
}

.blue-section {
  background: var(--blue);
  color: #fff;
}

.blue-section h2 {
  color: #fff;
}

.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 28px;
}

.fact {
  border-top: 1px solid rgba(255, 255, 255, 0.35);
  padding-top: 18px;
}

.fact strong {
  display: block;
  font-size: 28px;
}

.service-grid {
  background: #f5f6f7;
}

.service-grid h2 {
  text-align: center;
  font-size: 34px;
  margin: 0 0 18px;
}

.center-copy {
  max-width: 930px;
  margin: 0 auto 36px;
  text-align: center;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.card {
  background: #fff;
  border: 1px solid var(--line);
}

.card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.card-content {
  padding: 22px;
}

.card h3 {
  color: var(--blue);
  margin: 0 0 10px;
}

.media-section {
  background: #fff;
}

.soft-section {
  background: var(--soft);
}

.media-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 34px;
  align-items: end;
  margin-bottom: 34px;
}

.media-heading h2 {
  color: var(--blue);
  font-size: 34px;
  line-height: 1.18;
  margin: 0;
}

.media-heading p {
  margin: 0;
  color: var(--muted);
}

.album-title {
  background:
    linear-gradient(90deg, rgba(1, 65, 122, 0.92), rgba(1, 65, 122, 0.35)),
    url("/assets/images/gallery/gutters/custom-home-gutter-elevation.jpg") center / cover no-repeat;
  color: #fff;
}

.album-title h1,
.album-title p {
  max-width: 760px;
  color: #fff;
}

.eyebrow {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
}

.album-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.album-nav a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.78);
  padding: 10px 16px;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
}

.album-nav a:hover {
  background: #fff;
  color: var(--blue);
}

.album-overview {
  padding: 44px 0;
  background: #fff;
}

.album-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.album-card {
  display: grid;
  min-height: 360px;
  position: relative;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  background: #111;
}

.album-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.82;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.album-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.74), rgba(0, 0, 0, 0.08));
}

.album-card span,
.album-card strong {
  position: relative;
  z-index: 1;
  align-self: end;
  margin: 0 22px;
}

.album-card span {
  margin-top: auto;
  font-size: 13px;
  text-transform: uppercase;
  font-weight: 700;
}

.album-card strong {
  display: block;
  margin-bottom: 24px;
  font-size: 22px;
  line-height: 1.2;
}

.album-card:hover img {
  opacity: 0.95;
  transform: scale(1.025);
}

.album-section {
  scroll-margin-top: 120px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.gallery-grid-wide {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.gallery-tile {
  position: relative;
  min-height: 260px;
  overflow: hidden;
  background: #111;
}

.gallery-tile img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.2s ease;
}

.gallery-tile:hover img {
  transform: scale(1.03);
}

.gallery-caption {
  position: absolute;
  inset: auto 0 0;
  padding: 42px 18px 18px;
  color: #fff;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0));
  font-weight: 700;
}

.gallery-caption strong,
.gallery-caption span {
  display: block;
}

.gallery-caption span {
  margin-top: 3px;
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.86);
}

.detail-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.detail-strip figure {
  margin: 0;
  background: #fff;
  border: 1px solid var(--line);
}

.detail-strip img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.detail-strip figcaption {
  padding: 14px 16px;
  font-weight: 700;
  color: var(--blue);
}

.album-cta {
  background: var(--blue);
  color: #fff;
  padding: 58px 0;
}

.album-cta .section-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: center;
}

.album-cta h2,
.album-cta p {
  color: #fff;
}

.album-cta h2 {
  margin: 0 0 10px;
  font-size: 32px;
  line-height: 1.2;
}

.album-cta p {
  margin: 0;
  max-width: 760px;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.video-card {
  border: 1px solid var(--line);
  background: #fff;
}

.video-thumb {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  background:
    linear-gradient(135deg, rgba(1, 65, 122, 0.92), rgba(211, 123, 37, 0.82)),
    #0f2538;
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
}

.video-card div:last-child {
  padding: 20px;
}

.video-card h3 {
  margin: 0 0 10px;
  color: var(--blue);
}

.agent-panel {
  background: var(--blue-dark);
  color: #fff;
}

.agent-panel h2 {
  color: #fff;
}

.agent-console {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 24px;
}

.agent-console pre {
  margin: 0;
  white-space: pre-wrap;
  color: #d8e7f8;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
}

.page-title {
  background: var(--blue);
  color: #fff;
  padding: 76px 0;
}

.page-title h1 {
  color: #fff;
  margin: 0 0 12px;
  font-size: 44px;
}

.page-title p {
  max-width: 760px;
  margin: 0;
  color: #e6edf5;
  font-size: 19px;
}

.content {
  max-width: 920px;
  margin: 0 auto;
}

.content h2,
.content h3 {
  color: var(--blue);
}

.content h2 {
  margin-top: 0;
  font-size: 32px;
}

.answer-capsule {
  background: #f3f7fb;
  border-left: 5px solid var(--orange);
  padding: 24px;
  margin-bottom: 34px;
}

.footer {
  background: #0f2538;
  color: #d7e1ea;
  padding: 64px 0 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 38px;
}

.footer h3 {
  color: #fff;
  margin-top: 0;
}

.footer a {
  color: #fff;
}

.legal {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  margin-top: 38px;
  padding-top: 22px;
  font-size: 13px;
}

.notice {
  padding: 12px 16px;
  margin-top: 18px;
  background: #eff9f1;
  border: 1px solid #b7dfbf;
  color: #245c2c;
  display: none;
}

@media (max-width: 900px) {
  .topbar-inner {
    justify-content: space-between;
    gap: 12px;
    font-size: 12px;
  }

  .nav-inner {
    min-height: 84px;
  }

  .menu {
    display: none;
  }

  .logo img {
    width: 265px;
  }

  .hero {
    min-height: 560px;
  }

  .hero h1 {
    font-size: 36px;
  }

  .hero p {
    font-size: 17px;
  }

  .form-grid,
  .split,
  .cards,
  .media-heading,
  .album-feature-grid,
  .detail-strip,
  .album-cta .section-inner,
  .gallery-grid,
  .video-grid,
  .facts,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .album-card {
    min-height: 300px;
  }

  .span-2,
  .span-3 {
    grid-column: auto;
  }

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

  .form-footer input[type="submit"],
  .form-footer button {
    width: 100%;
  }

  section {
    padding: 58px 0;
  }
}
