:root {
  --navy: #0b1f4a;
  --navy-2: #12306e;
  --blue: #1d4ed8;
  --ink: #0f172a;
  --muted: #475569;
  --line: #e2e8f0;
  --paper: #f6f8fc;
  --white: #fff;
  --ok: #0f766e;
  --radius: 14px;
  --shadow: 0 16px 40px rgba(11, 31, 74, 0.08);
  --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); }
.wrap { width: min(var(--max), calc(100% - 40px)); margin: 0 auto; }

/* Header */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: flex-start;
  min-height: 80px; gap: 16px;
}
.brand { display: flex; align-items: center; flex-wrap: nowrap; flex-shrink: 0; gap: 12px; min-width: 0; margin-right: 0; text-decoration: none; color: var(--navy); }
.header-ids {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0;
  white-space: nowrap;
  text-align: center;
}
.header-ids a { text-decoration: none; }
.header-ids a:hover { text-decoration: underline; }
.brand-mark {
  --mark: 56px;
  width: calc(var(--mark) * 289 / 401);
  height: var(--mark);
  overflow: hidden;
  flex: 0 0 auto;
  display: block;
}
.brand-logo {
  height: calc(var(--mark) * 1264 / 401);
  width: calc(var(--mark) * 1568 / 401);
  max-width: none;
  max-height: none;
  object-fit: contain;
  object-position: left top;
  margin-top: calc(var(--mark) * -318 / 401);
  margin-left: calc(var(--mark) * -639 / 401);
  display: block;
}
.brand-words { display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.brand-words strong { display: block; font-size: 17px; font-weight: 800; letter-spacing: .06em; line-height: 1.1; color: var(--navy); }
.brand-words small { display: block; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; line-height: 1.2; color: var(--muted); }
nav { display: flex; gap: 18px; align-items: center; flex-shrink: 0; }
nav a { text-decoration: none; color: var(--ink); font-weight: 600; font-size: 15px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 11px 16px; border-radius: 10px; font-weight: 700;
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-ghost { background: #fff; color: var(--navy); border-color: var(--line); }
.btn-dark { background: var(--navy); color: #fff; }
.menu-btn { display: none; margin-left: auto; background: none; border: 0; font-size: 22px; }

/* Hero */
.hero { padding: 56px 0 28px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.kicker { color: var(--blue); font-weight: 700; letter-spacing: .04em; }
h1, h2, h3 { font-family: "Source Serif 4", Georgia, serif; line-height: 1.12; margin: 8px 0 16px; }
h1 { font-size: clamp(36px, 5vw, 58px); }
h1 em { font-style: italic; color: var(--blue); }
.lead { font-size: 18px; color: var(--muted); max-width: 540px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 22px 0 10px; }
.hero-logo { height: 120px; width: auto; max-width: none; object-fit: contain; margin: 8px 0 4px; }
.phone-line { color: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); }
.stat b { display: block; font-size: 28px; }
.stat span { color: var(--muted); font-size: 14px; }
.hero-art {
  background: linear-gradient(180deg, #eef3fb, #fff);
  border: 1px solid var(--line); border-radius: 24px;
  min-height: 340px; display: grid; place-items: center; padding: 24px;
  box-shadow: var(--shadow);
}
.hero-rotator {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 280px;
  border-radius: 16px;
  overflow: hidden;
  align-self: stretch;
}
.hero-photo {
  width: 100%; height: 100%; min-height: 280px;
  object-fit: cover; border-radius: 16px; display: block;
}
.hero-rotator .hero-photo {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .55s ease;
}
.hero-rotator .hero-photo.is-active { opacity: 1; }
.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}
.hero-dots button {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.55);
  cursor: pointer;
}
.hero-dots button.is-active { background: #fff; }

@media (min-width: 861px) {
  .header-ids { display: flex; }
}

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 0.45fr 0.55fr;
    align-items: center;
    gap: 36px;
  }
  .hero-art {
    min-height: 490px;
    height: 490px;
    padding: 20px;
  }
  .hero-rotator {
    min-height: 0;
    height: 100%;
  }
  .hero-photo,
  .hero-rotator .hero-photo {
    min-height: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

/* Bands + cards */
.band { padding: 64px 0; }
.band-navy { background: var(--navy); color: #fff; }
.band-paper { background: var(--paper); }
.grid-4, .grid-2, .grid-3 { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.feature-row { display: grid; gap: 16px; grid-template-columns: repeat(5, 1fr); }
.samsara-link { display: inline-block; background: #fff; border-radius: 6px; padding: 6px 8px; line-height: 0; margin: 0 0 8px; }
.samsara-logo { height: 30px; width: auto; max-width: 100%; object-fit: contain; display: block; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: 1fr 1fr; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: 0 1px 0 rgba(15,23,42,.03);
}
.card h3 { margin-top: 8px; font-size: 22px; }
.svc-icon {
  width: 40px; height: auto; display: block; margin: 0 auto 14px;
}
.tag { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--blue); background: #eff4ff; padding: 4px 8px; border-radius: 999px; }
.feature { display: grid; grid-template-columns: 64px 1fr; gap: 16px; align-items: start; }
.num { font-size: 28px; font-weight: 800; color: var(--blue); }

.map-box {
  background: #070b16; color: #dbeafe; border-radius: 18px; padding: 28px;
  display: grid; grid-template-columns: .9fr 1.1fr; gap: 24px;
}
.map-box ul { columns: 2; padding-left: 18px; }
.map-visual { margin: 0; }
.map-visual img { width: 100%; height: auto; border-radius: 12px; display: block; }
.map-visual figcaption { margin-top: 12px; font-size: 14px; line-height: 1.45; color: #cbd5e1; }

form { display: grid; gap: 12px; }
label { font-weight: 600; font-size: 14px; }
input, select, textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px;
  font: inherit;
}
input[type="checkbox"], input[type="radio"] { width: auto; flex: none; }
textarea { min-height: 110px; resize: vertical; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.contact-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 20px; align-items: start; }
.contact-grid.contact-grid-home {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "quote office"
    "intro office";
  align-items: start;
  align-content: start;
  gap: 20px;
}
.contact-grid-home .contact-quote { grid-area: quote; }
.contact-grid-home .contact-intro { grid-area: intro; }
.contact-grid-home .contact-office { grid-area: office; }
.contact-grid-home .contact-intro h2 { margin-top: 8px; }
.office-map { margin: 12px 0 16px; width: 100%; overflow: visible; }
.office-map iframe { display: block; width: 100%; height: 320px; border: 0; border-radius: 14px; }
.office-map-caption { margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.fine { font-size: 13px; color: var(--muted); }
.pay-intro {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px 40px;
  align-items: center;
}
.pay-intro .lead { margin-bottom: 0; }
.pay-qr {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-self: center;
  gap: 8px;
  width: fit-content;
  text-align: center;
  color: var(--ink);
  text-decoration: none;
}
.pay-qr img {
  width: 160px;
  height: auto;
  display: block;
}
.pay-qr span {
  font-size: 14px;
  color: var(--muted);
}
.pay-card { text-align: center; }
.pay-card .fine { text-align: center; margin-top: 12px; }
.pay-card-btn { margin: 14px 0 0; display: flex; justify-content: center; }

footer { background: var(--ink); color: #cbd5e1; padding: 36px 0 24px; }
.footer-brand { display: flex; align-items: center; gap: 12px; margin: 0 0 12px; }
footer .brand-mark,
footer .brand-logo { background: none; padding: 0; box-shadow: none; }
footer .brand-logo { filter: url(#knock-white); }
.footer-brand .brand-words strong { color: #fff; }
.footer-brand .brand-words small { color: #cbd5e1; }
.foot-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 24px; }
footer a { color: #fff; }
.legal { margin-top: 24px; border-top: 1px solid #334155; padding-top: 14px; font-size: 13px; }

.call-fab {
  display: none; position: fixed; right: 16px; bottom: 16px; z-index: 30;
  background: var(--blue); color: #fff; text-decoration: none;
  padding: 12px 16px; border-radius: 999px; font-weight: 700;
  box-shadow: var(--shadow);
}

.btn-lg { padding: 14px 22px; font-size: 17px; }
.checks { display: grid; grid-template-columns: 1fr; gap: 8px; }
.checks label,
label.checks {
  font-weight: 500;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  white-space: normal;
}
.checks input { margin: 0; }
.quote-result { display: none; }
.quote-result.show { display: block; }
.total {
  font-size: 42px; font-weight: 800; color: var(--navy); margin: 0;
}
.breakdown { list-style: none; padding: 0; margin: 16px 0; }
.breakdown li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--line); }
.warn { background: #fff7ed; border: 1px solid #fdba74; color: #9a3412; padding: 12px 14px; border-radius: 10px; }
.okbox { background: #ecfdf5; border: 1px solid #6ee7b7; color: #065f46; padding: 12px 14px; border-radius: 10px; }
.err { color: #b91c1c; font-weight: 600; }
.section-label { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 700; margin: 18px 0 8px; }
.admin-bar { background: #111827; color: #e5e7eb; padding: 10px 0; font-size: 13px; }
.range-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; }

@media (max-width: 860px) {
  nav { display: none; }
  nav.open { display: flex; flex-direction: column; position: absolute; left: 0; right: 0; top: 100%; background: #fff; padding: 16px 20px 20px; border-bottom: 1px solid var(--line); }
  .menu-btn { display: block; }
  .hero-grid, .grid-4, .grid-3, .grid-2, .feature-row, .contact-grid, .contact-grid.contact-grid-home, .map-box, .foot-grid, .row-2 { grid-template-columns: 1fr; }
  .contact-grid.contact-grid-home {
    grid-template-rows: none;
    grid-template-areas:
      "quote"
      "intro"
      "office";
  }
  .pay-intro { grid-template-columns: 1fr; justify-items: center; text-align: left; }
  .pay-intro > div { width: 100%; }
  .pay-qr { margin: 8px auto 0; }
  .stats { grid-template-columns: 1fr 1fr; }
  .call-fab { display: inline-flex; }
  .brand { flex-wrap: nowrap; }
  .brand-mark { --mark: 48px; }
}
