/* ============================================================
   iHart Services — Shared stylesheet
   Sodexo-inspired clean corporate aesthetic
   ============================================================ */

:root {
  /* Brand — iHart red */
  --blue:        #E11C24;          /* primary brand red */
  --blue-deep:   #B5141B;          /* darker red — hover */
  --blue-light:  #FDE8E9;          /* light red tint — backgrounds */
  --blue-tint:   #FBF6F6;          /* subtle warm tint */

  /* Surfaces */
  --bg:          #FFFFFF;
  --bg-soft:     #F6F7F9;
  --bg-tint:     #FBF6F6;
  --bg-dark:     #0F1419;          /* near-black, neutral */

  /* Ink */
  --ink:         #0E1116;
  --ink-soft:    #4A5260;
  --ink-mute:    #7C8497;
  --ink-rev:     #FFFFFF;

  /* Lines */
  --line:        #E5E7EC;
  --line-soft:   #EFF1F4;

  /* Type — ONE family */
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;

  /* Layout */
  --max:        1320px;
  --gutter:     32px;
  --nav-h:      80px;

  --ease: cubic-bezier(.2,.7,.2,1);
}

/* Brand accents */
:root[data-accent="red"]     { --blue: #E11C24; --blue-deep: #B5141B; }
:root[data-accent="crimson"] { --blue: #B82127; --blue-deep: #8B181D; }
:root[data-accent="black"]   { --blue: #1A1A1A; --blue-deep: #000000; }
:root[data-accent="navy"]    { --blue: #14264A; --blue-deep: #0A1B36; }

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }
::selection { background: var(--blue); color: #fff; }
image-slot { display: block; width: 100%; height: 100%; }

/* ---------- Type ---------- */
h1, h2, h3, h4, h5 { margin: 0; font-family: var(--font); font-weight: 600; color: var(--ink); letter-spacing: -0.018em; }
h1 { font-size: clamp(40px, 5.5vw, 68px); line-height: 1.05; font-weight: 600; }
h2 { font-size: clamp(32px, 3.6vw, 48px); line-height: 1.1; font-weight: 600; }
h3 { font-size: clamp(22px, 2vw, 28px); line-height: 1.2; font-weight: 600; letter-spacing: -0.012em; }
h4 { font-size: 16px; line-height: 1.3; font-weight: 600; letter-spacing: -0.005em; }
p  { margin: 0 0 1em; }

.eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--blue);
  text-transform: none;
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--blue);
}

.lead { font-size: 18px; line-height: 1.55; color: var(--ink-soft); max-width: 60ch; }

.rule { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---------- Layout ---------- */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.wrap-wide { max-width: 1440px; margin: 0 auto; padding: 0 var(--gutter); }

section { padding: clamp(64px, 8vw, 120px) 0; }
section.tight { padding: clamp(48px, 5vw, 72px) 0; }

/* ---------- Top nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  height: var(--nav-h);
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 32px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--ink);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.015em;
}
.brand-logo {
  height: 44px;
  width: auto;
  max-width: none;
  flex-shrink: 0;
  display: block;
}
.brand-mark {
  width: 36px; height: 36px;
  background: var(--blue);
  display: grid; place-items: center;
  color: #fff;
  font-weight: 700; font-size: 16px;
  letter-spacing: -0.02em;
  border-radius: 4px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text small {
  font-size: 11px; font-weight: 500; color: var(--ink-mute); letter-spacing: 0;
  margin-top: 2px;
}
/* Footer wordmark — white text with red i */
.f-wordmark {
  font-size: 28px; font-weight: 800; letter-spacing: -0.025em; color: #fff;
  line-height: 1;
}
.f-wordmark .i { color: var(--blue); }
.f-wordmark small {
  display: block;
  font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
  color: rgba(255,255,255,0.7);
  margin-top: 6px;
  text-transform: uppercase;
}

.nav-links {
  display: flex; gap: 4px; justify-self: center;
  font-size: 14.5px;
  font-weight: 500;
}
.nav-links a {
  padding: 10px 14px; border-radius: 4px;
  color: var(--ink-soft);
  transition: color .15s var(--ease), background .15s var(--ease);
  white-space: nowrap;
}
.nav-links a:hover { color: var(--blue); }
.nav-links a.active { color: var(--blue); font-weight: 600; }

.nav-cta {
  font-size: 14px;
  font-weight: 600;
  padding: 11px 22px;
  border-radius: 4px;
  background: var(--blue);
  color: #fff;
  transition: background .15s var(--ease);
  white-space: nowrap;
}
.nav-cta:hover { background: var(--blue-deep); }
.nav-cta.active { background: var(--blue-deep); }

.nav-toggle { display: none; }
.mobile-nav { display: none; }
.mobile-nav a {
  display: block; padding: 14px 8px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 16px;
  font-weight: 500;
}

@media (max-width: 1020px) {
  .nav-links { display: none; }
  .nav-toggle {
    display: grid; place-items: center;
    width: 40px; height: 40px;
    background: transparent; border: 1px solid var(--line);
    border-radius: 4px;
  }
  .nav-toggle svg { width: 20px; height: 20px; }
  .nav-inner { grid-template-columns: auto 1fr auto auto; }
  .mobile-nav {
    border-top: 1px solid var(--line);
    padding: 16px var(--gutter) 24px;
    background: var(--bg);
  }
  .mobile-nav.open { display: block; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 24px;
  border-radius: 4px;
  font-size: 14.5px; font-weight: 600;
  background: var(--blue); color: #fff;
  border: 1px solid var(--blue);
  transition: background .15s var(--ease), border-color .15s var(--ease);
}
.btn:hover { background: var(--blue-deep); border-color: var(--blue-deep); }
.btn .arrow { font-size: 16px; line-height: 1; margin-top: -1px; }

.btn.ghost {
  background: transparent; color: var(--blue); border-color: var(--blue);
}
.btn.ghost:hover { background: var(--blue); color: #fff; }
.btn.ghost.on-dark {
  color: #fff; border-color: rgba(255,255,255,0.4);
}
.btn.ghost.on-dark:hover { background: #fff; color: var(--blue); border-color: #fff; }
.btn.big { padding: 16px 28px; font-size: 15px; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 15px; font-weight: 600; color: var(--blue);
  transition: gap .2s var(--ease);
}
.link-arrow:hover { gap: 12px; }
.link-arrow .arrow { font-size: 18px; }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative;
  min-height: clamp(520px, 70vh, 720px);
  background: var(--bg-dark);
  color: #fff;
  overflow: hidden;
  display: flex; align-items: flex-end;
}
.hero-bg {
  position: absolute; inset: 0;
  background:
    linear-gradient(135deg, var(--bg-dark) 0%, #15315f 100%);
  z-index: 0;
}
.hero-bg image-slot {
  width: 100%; height: 100%;
  opacity: 0.5;
}
.hero-bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,30,71,0.4) 0%, rgba(10,30,71,0.6) 60%, rgba(10,30,71,0.85) 100%);
  pointer-events: none;
}
.hero .wrap-wide {
  position: relative; z-index: 2;
  width: 100%;
  padding-top: clamp(48px, 8vw, 96px);
  padding-bottom: clamp(48px, 8vw, 96px);
}
.hero h1 {
  font-size: clamp(40px, 6vw, 76px);
  color: #fff;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
  max-width: 18ch;
  margin-bottom: 24px;
}
.hero p.lead {
  color: rgba(255,255,255,0.85);
  max-width: 56ch;
  font-size: 19px;
  margin-bottom: 36px;
}
.hero .cta-row { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Section title block ---------- */
.section-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: end;
  margin-bottom: clamp(40px, 5vw, 64px);
}
.section-head h2 { max-width: 18ch; }
.section-head .lead { margin: 0; }
@media (max-width: 760px) {
  .section-head { grid-template-columns: 1fr; }
}

/* ---------- News carousel ---------- */
.news {
  background: var(--bg-soft);
}
.news-track-wrap {
  position: relative;
}
.news-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: clamp(280px, 30vw, 380px);
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 16px;
  scrollbar-width: thin;
}
.news-track::-webkit-scrollbar { height: 6px; }
.news-track::-webkit-scrollbar-track { background: var(--line-soft); }
.news-track::-webkit-scrollbar-thumb { background: var(--ink-mute); border-radius: 3px; }

.news-card {
  scroll-snap-align: start;
  background: var(--bg);
  border-radius: 8px;
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
  border: 1px solid var(--line);
}
.news-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 48px rgba(14,26,43,0.08);
  border-color: var(--blue);
}
.news-card .nc-img {
  aspect-ratio: 4/3;
  background: var(--blue);
  position: relative;
  overflow: hidden;
}
.news-card .nc-img::before {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(135deg, var(--blue) 0%, var(--blue-deep) 100%);
}
.news-card .nc-img::after {
  content: "";
  position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,0.12) 0, transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(0,0,0,0.2) 0, transparent 50%);
}
.news-card .nc-img .nc-cat {
  position: absolute; left: 16px; top: 16px;
  background: rgba(255,255,255,0.95);
  color: var(--blue);
  font-size: 11px; font-weight: 700; letter-spacing: 0.04em;
  padding: 5px 10px; border-radius: 3px;
  text-transform: uppercase;
  z-index: 2;
}
.news-card .nc-body {
  padding: 24px;
  display: flex; flex-direction: column;
  gap: 12px;
  flex: 1;
}
.news-card .nc-meta {
  font-size: 12px; font-weight: 500;
  color: var(--ink-mute);
}
.news-card h3 {
  font-size: 19px; line-height: 1.3;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.news-card p {
  font-size: 14.5px; color: var(--ink-soft); line-height: 1.5;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-card .nc-link {
  font-size: 14px; font-weight: 600; color: var(--blue);
  margin-top: auto;
}

.news-controls {
  display: flex; justify-content: flex-end; gap: 8px;
  margin-bottom: 32px;
}
.news-controls button {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg);
  display: grid; place-items: center;
  color: var(--ink);
  transition: background .15s var(--ease), border-color .15s var(--ease);
}
.news-controls button:hover {
  background: var(--blue); color: #fff; border-color: var(--blue);
}
.news-controls button svg { width: 18px; height: 18px; }

/* ---------- Industries grid ---------- */
.industries {
  background: var(--bg);
}
.industry-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.industry-card {
  position: relative;
  aspect-ratio: 4/5;
  background: var(--blue-deep);
  color: #fff;
  border-radius: 8px;
  overflow: hidden;
  display: flex; align-items: flex-end;
  padding: 32px;
  transition: transform .35s var(--ease);
}
.industry-card .ic-bg {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep) 100%);
  transition: transform .5s var(--ease);
}
.industry-card .ic-bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,0.5) 100%);
}
.industry-card .ic-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s var(--ease);
}
.industry-card:has(.ic-photo) .ic-bg { display: none; }
.industry-card:has(.ic-photo)::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0,0,0,0.7) 100%);
  z-index: 1;
}
.industry-card:hover .ic-photo { transform: scale(1.05); }
.industry-card image-slot { position: absolute; inset: 0; }
.industry-card:hover { transform: translateY(-4px); }
.industry-card:hover .ic-bg { transform: scale(1.06); }
.industry-card .ic-content {
  position: relative; z-index: 2;
  display: flex; flex-direction: column;
  gap: 12px;
}
.industry-card h3 {
  color: #fff;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.industry-card p {
  color: rgba(255,255,255,0.85);
  font-size: 14.5px; line-height: 1.5;
  margin: 0;
  max-width: 30ch;
}
.industry-card .ic-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 600;
  margin-top: 8px;
  color: #fff;
}
@media (max-width: 980px) { .industry-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .industry-grid { grid-template-columns: 1fr; } }

/* ---------- Feature band (split image/text) ---------- */
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  align-items: stretch;
  min-height: 520px;
}
.feature.reverse { direction: rtl; }
.feature.reverse > * { direction: ltr; }
.feature .f-img {
  background: var(--blue);
  position: relative;
  overflow: hidden;
  min-height: 360px;
}
.feature .f-img image-slot { position: absolute; inset: 0; }
.feature .f-img::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep) 100%);
  z-index: 0;
}
.feature .f-img.has-image::after { display: none; }
.feature .f-img::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,0.1) 0, transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(0,0,0,0.2) 0, transparent 50%);
  z-index: 1;
}
.feature .f-body {
  display: flex; flex-direction: column; justify-content: center;
  padding: clamp(40px, 6vw, 80px);
  background: var(--bg);
}
.feature .f-body.dark {
  background: var(--bg-dark);
  color: #fff;
}
.feature .f-body.dark h2 { color: #fff; }
.feature .f-body.dark .lead { color: rgba(255,255,255,0.8); }
.feature .f-body.tint { background: var(--bg-tint); }
@media (max-width: 880px) {
  .feature { grid-template-columns: 1fr; }
  .feature.reverse { direction: ltr; }
  .feature .f-img { min-height: 320px; }
}

/* ---------- Stats strip ---------- */
.stats {
  background: var(--blue);
  color: #fff;
  padding: clamp(48px, 6vw, 80px) 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.stat {
  border-left: 2px solid rgba(255,255,255,0.3);
  padding-left: 20px;
}
.stat .stat-n {
  font-size: clamp(40px, 4.5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1;
  color: #fff;
  margin-bottom: 12px;
}
.stat .stat-l {
  font-size: 14px;
  color: rgba(255,255,255,0.85);
  line-height: 1.5;
  max-width: 26ch;
}
@media (max-width: 760px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- Footer ---------- */
footer.site {
  background: var(--bg-dark);
  color: #fff;
  padding: 80px 0 28px;
}
footer.site .f-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
footer.site h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.55);
  margin-bottom: 16px;
}
footer.site .f-col a {
  display: block; padding: 6px 0;
  color: rgba(255,255,255,0.85); font-size: 14.5px;
  font-weight: 500;
}
footer.site .f-col a:hover { color: #fff; }
footer.site .f-mark {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 20px; letter-spacing: -0.015em;
  margin-bottom: 16px;
}
footer.site .f-mark .brand-mark {
  background: #fff; color: var(--blue);
}
footer.site .f-tag {
  font-size: 16px; color: rgba(255,255,255,0.8); line-height: 1.55;
  max-width: 34ch; margin: 0 0 20px;
}
footer.site .f-bot {
  display: flex; justify-content: space-between;
  padding-top: 40px;
  margin-top: 24px;
  font-size: 14px;
  color: rgba(255,255,255,0.65);
  flex-wrap: nowrap; gap: 32px;
  white-space: nowrap;
}
footer.site .f-naics { display: flex; gap: 24px; flex-wrap: nowrap; white-space: nowrap; }
@media (max-width: 880px) {
  footer.site .f-bot { flex-wrap: wrap; white-space: normal; }
  footer.site .f-naics { flex-wrap: wrap; white-space: normal; }
}
@media (max-width: 880px) { footer.site .f-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { footer.site .f-grid { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Cert chips ---------- */
.cert-row { display: flex; flex-wrap: wrap; gap: 8px; }
.cert {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px;
  background: var(--blue-light);
  color: var(--blue-deep);
  border-radius: 999px;
  font-size: 12.5px; font-weight: 600;
}
.cert.on-dark {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

/* ---------- Form ---------- */
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 22px; }
.field label {
  font-size: 14px; font-weight: 600; color: var(--ink);
}
.field label .req { color: #C04545; }
.field input, .field select, .field textarea {
  font: inherit; font-size: 15px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 12px 14px;
  color: var(--ink);
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
  width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-light);
}
.field textarea { min-height: 120px; resize: vertical; }
.field .hint { font-size: 13px; color: var(--ink-mute); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }

.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.checks label {
  display: flex; align-items: center; gap: 10px;
  font-size: 14.5px; font-weight: 500;
  color: var(--ink);
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 4px;
  cursor: pointer; background: var(--bg);
  transition: all .15s var(--ease);
}
.checks label:has(input:checked) {
  border-color: var(--blue); background: var(--blue-light);
}
.checks input[type=checkbox] { accent-color: var(--blue); width: 16px; height: 16px; }
@media (max-width: 600px) { .checks { grid-template-columns: 1fr; } }

/* ---------- Page header (sub pages) ---------- */
.ph {
  background: var(--bg-tint);
  padding: clamp(56px, 7vw, 96px) 0 clamp(48px, 6vw, 72px);
  border-bottom: 1px solid var(--line);
}
.ph-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: end;
}
.ph h1 { font-size: clamp(40px, 5vw, 64px); }
.ph .lead { font-size: 19px; }
@media (max-width: 760px) { .ph-grid { grid-template-columns: 1fr; } }

/* ---------- Two-col text ---------- */
.two-col {
  display: grid; grid-template-columns: 1fr 1.4fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; } }

/* ---------- Service detail rows (services page) ---------- */
.detail {
  display: grid; grid-template-columns: 64px 1fr 1fr;
  gap: clamp(24px, 4vw, 48px);
  padding: clamp(40px, 5vw, 64px) 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.detail .d-num {
  font-size: 56px; font-weight: 700; line-height: 1;
  color: var(--blue);
  letter-spacing: -0.03em;
}
.detail h3 { font-size: clamp(24px, 2.5vw, 32px); margin-bottom: 14px; }
.detail .d-list {
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: 10px;
}
.detail .d-list li {
  padding: 12px 16px;
  background: var(--bg-soft);
  border-radius: 4px;
  font-size: 14.5px; color: var(--ink-soft);
  display: flex; align-items: center; gap: 12px;
}
.detail .d-list li::before {
  content: "";
  width: 6px; height: 6px; background: var(--blue); border-radius: 50%;
}
@media (max-width: 880px) { .detail { grid-template-columns: 1fr; } .detail .d-num { font-size: 40px; } }

/* ---------- Services index strip ---------- */
.svc-index {
  display: flex; flex-wrap: wrap;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
}
.svc-index a {
  flex: 1; min-width: 160px;
  padding: 18px 16px;
  font-size: 13.5px; font-weight: 600;
  color: var(--ink-soft);
  border-right: 1px solid var(--line);
  transition: background .15s var(--ease), color .15s var(--ease);
}
.svc-index a:last-child { border-right: 0; }
.svc-index a:hover { background: var(--bg); color: var(--blue); }
.svc-index a span { color: var(--blue); margin-right: 8px; font-weight: 700; }

/* ---------- Coverage map ---------- */
.map-card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 36px;
  overflow: hidden;
}
.us-map { width: 100%; aspect-ratio: 16/9; }
.us-map path { fill: var(--blue-light); stroke: var(--bg); stroke-width: 0.5; transition: fill .3s var(--ease); }
.us-map path.hl { fill: var(--blue); }
.us-map path.hq { fill: var(--blue-deep); }
.us-map text { font-size: 9px; letter-spacing: 0.06em; fill: var(--ink-soft); font-weight: 600; }

/* ---------- Tweaks panel ---------- */
.tweaks {
  position: fixed; right: 20px; bottom: 20px; z-index: 100;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 18px 16px;
  width: 260px;
  box-shadow: 0 14px 40px rgba(0,0,0,0.1);
  display: none;
}
.tweaks.open { display: block; }
.tweaks h5 {
  margin: 0 0 14px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--ink-soft);
  display: flex; justify-content: space-between; align-items: center;
}
.tweaks h5 button {
  background: transparent; border: 0; padding: 2px 6px;
  font-size: 11px; color: var(--ink-mute); cursor: pointer;
}
.tweaks .tw-row { margin-bottom: 14px; }
.tweaks .tw-row > span {
  display: block; font-size: 11px; font-weight: 600; color: var(--ink-soft); margin-bottom: 8px;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.tw-swatches { display: flex; gap: 8px; }
.tw-swatch {
  width: 28px; height: 28px; border-radius: 50%;
  border: 2px solid var(--line); background: var(--c);
  cursor: pointer; transition: transform .15s var(--ease), border-color .15s var(--ease);
}
.tw-swatch:hover { transform: scale(1.08); }
.tw-swatch.active { border-color: var(--ink); }

@media (max-width: 980px) {
  .cap-badge-row { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 640px) {
  .cap-badge-row { grid-template-columns: 1fr 1fr !important; }
}

/* Footer badge row — official cert images */
.f-badges {
  display: flex !important; flex-wrap: nowrap !important; gap: 8px !important; align-items: center !important;
}
.f-badges .f-badge {
  background: #fff !important;
  border-radius: 4px !important;
  padding: 6px 10px !important;
  display: inline-flex !important; align-items: center !important; justify-content: center !important;
  height: 88px !important;
  width: auto !important;
  flex: 0 0 auto !important;
  line-height: 1 !important;
}
.f-badges .f-badge img {
  height: 100% !important; width: auto !important;
  max-height: 100% !important; max-width: none !important;
  object-fit: contain !important;
  display: block !important;
}
.f-badges .f-badge.text {
  background: rgba(255,255,255,0.08) !important;
  color: #fff !important;
  font-size: 12px !important; font-weight: 700 !important; letter-spacing: 0.04em !important;
  padding: 0 14px !important;
  white-space: nowrap !important;
}
.muted { color: var(--ink-soft); }
.center { text-align: center; }
.mb-0 { margin-bottom: 0; }
.mt-32 { margin-top: 32px; }
.mt-48 { margin-top: 48px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.dark-band { background: var(--bg-dark); color: #fff; }
.dark-band h2 { color: #fff; }
.dark-band .lead { color: rgba(255,255,255,0.8); }


/* ============================================================
   MOBILE RESPONSIVENESS — comprehensive pass
   Stack vertically · readable text · full-width CTAs · hamburger
   ============================================================ */

/* ---- Hamburger nav: hide nav-cta until mobile menu opens; toggle CTA into hamburger ---- */
@media (max-width: 1020px) {
  .nav-cta { display: none; }
  .mobile-nav .nav-cta-mobile {
    display: block;
    margin-top: 16px;
    padding: 14px 22px;
    background: var(--blue);
    color: #fff !important;
    border-radius: 4px;
    text-align: center;
    font-weight: 600;
    border-bottom: none;
  }
  .nav-inner { grid-template-columns: auto 1fr auto; }
}
.mobile-nav .nav-cta-mobile { display: none; }

/* ============================================================
   < 880px — tablet portrait
   ============================================================ */
@media (max-width: 880px) {
  :root {
    --gutter: 24px;
    --nav-h: 64px;
  }

  /* Section padding */
  section { padding: 56px 0 !important; }
  section.tight { padding: 40px 0 !important; }

  /* Type */
  h1 { font-size: clamp(32px, 8vw, 48px) !important; }
  h2 { font-size: clamp(26px, 6vw, 36px) !important; }
  h3 { font-size: 20px !important; }
  .lead { font-size: 16.5px !important; }

  /* All multi-col grids → single col */
  .section-head,
  .ph-grid,
  .two-col,
  .industry-grid,
  .feature,
  .stats-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  .feature.reverse { direction: ltr !important; }
  .feature .f-img { min-height: 280px; aspect-ratio: 4/3 !important; }
  .feature .f-body { padding: 36px 24px !important; }

  /* Hero */
  .hero { min-height: 0; padding: 64px 0 !important; }
  .hero h1 { max-width: 100% !important; }

  /* Stats */
  .stats-grid { grid-template-columns: 1fr 1fr !important; gap: 28px !important; }
  .stat { border-left: none; border-top: 2px solid rgba(255,255,255,0.3); padding-left: 0; padding-top: 16px; }
  .stat .stat-n { font-size: 38px !important; }

  /* News carousel */
  .news-track { grid-auto-columns: 84% !important; }
  .news-controls { display: none !important; }

  /* Industries */
  .industry-card { aspect-ratio: 4/3 !important; padding: 24px !important; }
  .industry-card h3 { font-size: 22px !important; color: #fff !important; }

  /* Page header */
  .ph { padding: 48px 0 36px !important; }

  /* Services detail rows */
  .detail { grid-template-columns: 1fr !important; gap: 16px !important; padding: 32px 0 !important; }
  .detail .d-num { font-size: 32px !important; }

  /* Services index strip */
  .svc-index { flex-direction: column; }
  .svc-index a { border-right: 0; border-bottom: 1px solid var(--line); padding: 14px 20px; }
  .svc-index a:last-child { border-bottom: 0; }

  /* Forms */
  .field-row { grid-template-columns: 1fr !important; gap: 0 !important; }
  .checks { grid-template-columns: 1fr !important; }

  /* CTA rows → stack & full-width buttons */
  .cta-row {
    flex-direction: column !important;
    align-items: stretch !important;
    width: 100%;
  }
  .cta-row .btn { width: 100%; justify-content: center; }
  .btn.big { padding: 14px 22px; font-size: 14.5px; }

  /* Footer */
  footer.site { padding: 56px 0 24px; }
  footer.site .f-grid { grid-template-columns: 1fr !important; gap: 32px !important; padding-bottom: 36px; }
  footer.site .f-tag { max-width: 100%; }
  footer.site .f-bot { flex-direction: column; gap: 12px; padding-top: 24px; white-space: normal; }
  footer.site .f-naics { flex-direction: column; gap: 6px; white-space: normal; }
  .f-badges { flex-wrap: wrap !important; }
  .f-badges .f-badge { height: 72px !important; }

  /* Capabilities badge row */
  .cap-badge-row { grid-template-columns: 1fr 1fr !important; gap: 32px !important; }

  /* Generic 4-col / 3-col grids on subpages — use selectors that catch the most patterns */
  /* Tweaks panel */
  .tweaks { left: 16px; right: 16px; bottom: 16px; width: auto; }

  /* GC Services pricing tiers → stack */
  #pricing > div > div[style*="grid-template-columns: repeat(3"],
  #pricing > div > div[style*="grid-template-columns: repeat(4"] {
    grid-template-columns: 1fr !important;
  }

  /* Add-ons list — single column */
  #pricing ul[style*="grid-template-columns: 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }

  /* Inline grids on subpages (capabilities, contact, subs, gc, etc.) */
  section [style*="grid-template-columns: repeat(3, 1fr)"],
  section [style*="grid-template-columns: repeat(4, 1fr)"],
  section [style*="grid-template-columns: 1fr 1fr"],
  section [style*="grid-template-columns: 1.05fr 0.95fr"],
  section [style*="grid-template-columns: 0.4fr 1.4fr 0.8fr 0.8fr"],
  section [style*="grid-template-columns: 0.45fr 1fr"],
  section [style*="grid-template-columns: 1fr 1.1fr"],
  section [style*="grid-template-columns: 1fr 1.4fr"],
  section [style*="grid-template-columns: 80px 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  /* Sticky asides → static on mobile */
  aside[style*="sticky"] {
    position: static !important;
  }

  /* Sub form step indicator — keep on mobile */
  .step { padding: 14px 0 !important; }

  /* Page header decorative aside dl — full width */
  .ph .meta-list,
  .ph dl { padding: 16px 0; }

  /* Inline image-slot hero (gc-services dmv map) */
  section [style*="aspect-ratio: 21/9"] {
    aspect-ratio: 16/10 !important;
    margin-top: -20px !important;
  }

  /* Disaster response hero meta dl */
  .dark-band [style*="grid-template-columns: 140px 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 4px !important;
  }

  /* Capabilities target contracts table → stacked */
  .dark-band [style*="grid-template-columns: 0.4fr 1.4fr 0.8fr 0.8fr"] > * {
    padding: 4px 0 !important;
  }

  /* Subcontractor step sidebar — collapse but readable */
  .step { grid-template-columns: 32px 1fr !important; }

  /* Big numbers on subcontractor benefit cards */
  section [style*="font-size: 28px; font-weight: 700; color: var(--blue)"],
  section [style*="font-size: 32px; font-weight: 700; color: var(--blue)"],
  section [style*="font-size: 44px; font-weight: 700"] {
    font-size: 28px !important;
  }

  /* Cap statement preview — full width */
  section [style*="aspect-ratio: 8.5/11"] { max-width: 480px; margin-left: auto; margin-right: auto; }

  /* GC Services engagement policy box */
  .dark-band, .partner-dark { padding: 56px 0 !important; }

  /* Pricing card top "Most Popular" pill positioning */
  div[style*="Most Popular"] { left: 20px !important; }

  /* GC Services pricing pricetag */
  section #pricing [style*="font-size: 44px; font-weight: 800"] {
    font-size: 36px !important;
  }
}

/* ============================================================
   < 560px — phone portrait
   ============================================================ */
@media (max-width: 560px) {
  :root { --gutter: 18px; }

  h1 { font-size: 30px !important; line-height: 1.1 !important; }
  h2 { font-size: 24px !important; line-height: 1.15 !important; }
  h3 { font-size: 19px !important; }
  .lead { font-size: 16px !important; }
  p { font-size: 15.5px; }

  /* Brand logo smaller */
  .brand-logo { height: 36px !important; }

  /* All sections — even tighter padding */
  section { padding: 44px 0 !important; }

  /* Hero */
  .hero { padding: 48px 0 !important; }
  .hero h1 { font-size: 30px !important; }
  .hero p.lead { font-size: 16px !important; }

  /* Cards / panels */
  section [style*="padding: 36px"],
  section [style*="padding: 40px"],
  section [style*="padding: clamp(40px, 5vw, 64px)"],
  form[style*="padding: 40px"] {
    padding: 22px !important;
  }
  /* Engagement policy panel */
  section [style*="padding: clamp(40px, 5vw, 64px)"] {
    padding: 28px 22px !important;
  }

  /* Stats — single col on tiny screens */
  .stats-grid { grid-template-columns: 1fr !important; gap: 20px !important; }

  /* Capabilities badge row */
  .cap-badge-row { grid-template-columns: 1fr !important; gap: 28px !important; max-width: 280px !important; margin: 0 auto !important; }

  /* Footer badges — smaller */
  .f-badges .f-badge { height: 56px !important; }

  /* Tighter h1 in hero on phones */
  .hero h1 { max-width: 100%; }

  /* Cap statement preview */
  section [style*="aspect-ratio: 8.5/11"] [style*="display: grid; grid-template-columns: 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }

  /* GC Services price tier border + Most Popular pill */
  div[style*="border: 2px solid var(--blue)"] { padding: 28px 22px !important; }

  /* About founder card sticky CTA inline */
  .feature .f-body { padding: 28px 22px !important; }

  /* Capabilities cert cards */
  .industry-grid { gap: 16px !important; }

  /* Map card */
  .map-card { padding: 18px !important; }
  .map-card svg { aspect-ratio: 4/3 !important; }

  /* Subcontractor side step nav — make compact */
  .step { padding: 12px 0 !important; }

  /* News card */
  .news-track { grid-auto-columns: 92% !important; gap: 12px !important; }
  .news-card .nc-body { padding: 18px !important; }

  /* Service detail bullet list */
  .detail .d-list li { padding: 10px 14px !important; font-size: 14px !important; }

  /* Tweaks panel — full-width strip */
  .tweaks { width: auto; }
}

/* Prevent horizontal scroll on any page */
html, body { overflow-x: hidden; }
