/* ==========================================================================
   Southern Facility Management — Design System
   Charcoal + Slate + Light Blue accent + Deep Teal CTA
   ========================================================================== */

/* Self-hosted fonts (SIL Open Font License, see /fonts). Hosting them here means
   visiting the site sends no visitor data to Google. */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
  src: url("../fonts/playfair-display-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --charcoal: #3A3A3A;
  --slate: #5B6770;
  --light-blue: #AAE4F4;
  --light-blue-tint: rgba(170, 228, 244, 0.18);
  --teal: #0F6C7B;
  --teal-dark: #0B535F;
  --white: #FFFFFF;
  --off-white: #F8FAFC;
  --border: #E5E7EB;

  --font-serif: "Playfair Display", Georgia, serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-sm: 5px;
  --radius-md: 7px;

  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 32px;
  --space-lg: 64px;
  --space-xl: 104px;

  --shadow-soft: 0 4px 12px rgba(58, 58, 58, 0.08);
  --shadow-lift: 0 12px 28px rgba(58, 58, 58, 0.14);

  --max-width: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--charcoal);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.15;
  color: var(--charcoal);
}

h1 { font-size: clamp(2.6rem, 5.6vw, 4.2rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); letter-spacing: -0.005em; }
h3 { font-size: clamp(1.3rem, 2.2vw, 1.6rem); }

p { color: var(--slate); }
.measure { max-width: 620px; }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
  display: inline-block;
  margin-bottom: var(--space-sm);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 36px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
  white-space: nowrap;
}
.btn .icon-arrow { width: 16px; height: 16px; transition: transform 200ms ease; flex-shrink: 0; }
.btn:hover .icon-arrow { transform: translateX(4px); }

.btn-primary {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 2px 10px rgba(15, 108, 123, 0.22);
}
.btn-primary:hover { background: var(--teal-dark); transform: translateY(-2px); box-shadow: 0 10px 22px rgba(15, 108, 123, 0.3); }

.btn-secondary {
  background: transparent;
  border-color: var(--charcoal);
  color: var(--charcoal);
}
.btn-secondary:hover { background: var(--charcoal); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow-soft); }

.btn-secondary.on-dark {
  border-color: var(--white);
  color: var(--white);
}
.btn-secondary.on-dark:hover { background: var(--white); color: var(--charcoal); }

.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 20px 0;
  transition: background-color 200ms ease, box-shadow 200ms ease, padding 200ms ease;
}
.site-header.is-solid {
  background: var(--white);
  box-shadow: 0 1px 0 var(--border);
  padding: 14px 0;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}
.logo-link {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.logo-icon {
  width: 36px;
  height: 36px;
  color: var(--white);
  flex-shrink: 0;
  transition: color 200ms ease;
}
.site-header.is-solid .logo-icon { color: var(--charcoal); }
.logo-text-group {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.logo-text-primary {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: var(--white);
  white-space: nowrap;
  transition: color 200ms ease;
}
.logo-text-secondary {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--light-blue);
  white-space: nowrap;
  transition: color 200ms ease;
}
.site-header.is-solid .logo-text-primary { color: var(--charcoal); }
.site-header.is-solid .logo-text-secondary { color: var(--teal); }

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  flex-wrap: nowrap;
}
.nav-links a {
  font-size: 0.92rem;
  font-weight: 500;
  color: rgba(255,255,255,0.9);
  transition: color 200ms ease;
}
.site-header.is-solid .nav-links a { color: var(--charcoal); }
.nav-links a:hover { color: var(--light-blue); }
.site-header.is-solid .nav-links a:hover { color: var(--teal); }

.nav-cta { display: flex; align-items: center; gap: var(--space-sm); }

.nav-toggle { display: none; }

/* ---------- Nav dropdowns ---------- */
.nav-item { position: relative; }
.nav-item > a { display: inline-flex; align-items: center; gap: 4px; }
.nav-caret {
  display: inline-block;
  width: 6px; height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.75;
  transition: transform 180ms ease, margin-top 180ms ease;
  margin-top: -3px;
}
.nav-item:hover .nav-caret { transform: rotate(225deg); margin-top: 3px; }
.dropdown {
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lift);
  padding: 10px;
  min-width: 240px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms;
  z-index: 50;
}
.nav-item:hover .dropdown,
.nav-item:focus-within .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}
.dropdown a {
  display: block;
  padding: 10px 12px;
  border-radius: 4px;
  color: var(--charcoal) !important;
  font-size: 0.88rem;
  font-weight: 500;
}
.dropdown a:hover { background: var(--off-white); color: var(--teal) !important; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  color: var(--white);
  overflow: hidden;
  background: linear-gradient(180deg, rgba(20,26,33,0.78), rgba(20,26,33,0.55)),
              linear-gradient(120deg, #22303a, #3A3A3A 60%);
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: -1;
  animation: kenburns 60s ease-in-out infinite alternate;
}
@keyframes kenburns {
  0% { transform: scale(1); }
  100% { transform: scale(1.08); }
}
.hero-content {
  max-width: 760px;
  padding-top: 60px;
}
.hero h1 {
  color: var(--white);
  margin-bottom: var(--space-sm);
}
.hero .subhead {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.88);
  max-width: 620px;
  margin-bottom: var(--space-md);
}
.hero-ctas {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
  margin-bottom: var(--space-lg);
}
.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, auto);
  gap: var(--space-lg);
}
.hero-stat .stat-number {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--light-blue);
  display: block;
}
.hero-stat .stat-label {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.75);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.placeholder-flag {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.5);
  font-style: italic;
}

/* ---------- Sections ---------- */
.section {
  padding: var(--space-xl) 0;
}
.section-alt { background: var(--off-white); }
.section-dark {
  background: var(--charcoal);
  color: var(--white);
}
.section-dark h2, .section-dark h3 { color: var(--white); }
.section-dark p { color: rgba(255,255,255,0.78); }

.section-header {
  max-width: 680px;
  margin-bottom: var(--space-lg);
}
.section-header.centered { margin-left: auto; margin-right: auto; text-align: center; }
.section-header p { margin-top: var(--space-sm); font-size: 1.05rem; }

/* ---------- Trust bar ---------- */
.trust-bar {
  padding: var(--space-md) 0;
  background: var(--off-white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-bar p {
  text-align: center;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--slate);
}

/* ---------- Grids & Cards ---------- */
.grid {
  display: grid;
  gap: var(--space-md);
}
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card {
  display: block;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  box-shadow: var(--shadow-soft);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.service-card { display: flex; flex-direction: column; }
.service-card .btn { margin-top: 24px; align-self: flex-start; }

.icon-chip {
  width: 52px; height: 52px;
  border-radius: var(--radius-md);
  background: var(--light-blue-tint);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: var(--space-sm);
  color: var(--teal);
}
.icon-chip svg { width: 26px; height: 26px; }

.tile {
  text-align: center;
  padding: var(--space-md) var(--space-sm);
  border-radius: var(--radius-md);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-soft); }
.tile .icon-chip { margin: 0 auto var(--space-sm); }

/* ---------- Differentiator rows (Why Choose Us) ---------- */
.diff-row {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: var(--space-sm);
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--border);
}
.diff-row:last-child { border-bottom: none; }

/* ---------- Timeline (Process page) ---------- */
.timeline {
  display: flex;
  justify-content: space-between;
  position: relative;
  padding-top: var(--space-md);
}
.timeline::before {
  content: "";
  position: absolute;
  top: 44px; left: 0; right: 0;
  height: 2px;
  background: var(--border);
}
.timeline-progress {
  position: absolute;
  top: 44px; left: 0;
  height: 2px;
  background: var(--teal);
  width: 0%;
  transition: width 1200ms ease;
}
.timeline-step {
  flex: 1;
  text-align: center;
  padding: 0 var(--space-xs);
  position: relative;
}
.timeline-node {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--white);
  border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto var(--space-sm);
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--slate);
  transition: background-color 400ms ease, border-color 400ms ease, color 400ms ease;
  position: relative;
  z-index: 2;
}
.timeline-step.active .timeline-node {
  background: var(--teal);
  border-color: var(--teal);
  color: var(--white);
}
.timeline-step h3 { font-size: 1rem; margin-bottom: 4px; }
.timeline-step p { font-size: 0.88rem; }

/* ---------- Stats strip (generic) ---------- */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-md);
  text-align: center;
}
.stats-strip .stat-number {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  color: var(--teal);
}

/* ---------- Forms ---------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
}
.form-grid .full { grid-column: 1 / -1; }
label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--charcoal);
}
.section-dark label { color: rgba(255,255,255,0.9); }
input, select, textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  background: var(--white);
  color: var(--charcoal);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(15, 108, 123, 0.18);
}
textarea { resize: vertical; min-height: 96px; }
.field { margin-bottom: var(--space-sm); }

/* ---------- Emergency callout ---------- */
.emergency-banner {
  background: var(--teal);
  color: var(--white);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  flex-wrap: wrap;
}
.emergency-banner a.phone {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--white);
}

/* ---------- FAQ ---------- */
.faq-item {
  border-bottom: 1px solid var(--border);
  padding: var(--space-sm) 0;
}
.faq-item h3 { font-size: 1.05rem; margin-bottom: 6px; }

/* ---------- Footer ---------- */
.site-footer {
  background: #24292E;
  color: rgba(255,255,255,0.7);
  padding: var(--space-lg) 0 var(--space-md);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr 1fr;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}
.footer-grid a.footer-emergency {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--light-blue) !important;
  font-weight: 700;
}
.footer-social {
  display: flex;
  gap: 12px;
  margin-top: var(--space-sm);
}
.footer-grid .footer-social a {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 0;
  transition: background-color 180ms ease;
}
.footer-social a:hover { background: var(--teal); }
.footer-social .icon { width: 16px; height: 16px; color: var(--white); }
.footer-grid h4 {
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}
.footer-grid a, .footer-grid p { font-size: 0.88rem; color: rgba(255,255,255,0.65); display: block; margin-bottom: 8px; }
.footer-grid a:hover { color: var(--light-blue); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: var(--space-sm);
  font-size: 0.8rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 600ms ease, transform 600ms ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Breadcrumb / page hero (interior pages) ---------- */
.page-hero {
  background: var(--charcoal);
  color: var(--white);
  padding: 160px 0 var(--space-lg);
}
.page-hero .eyebrow { color: var(--light-blue); }
.page-hero h1 { color: var(--white); }
.page-hero p { color: rgba(255,255,255,0.8); max-width: 640px; margin-top: var(--space-sm); }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-lg { margin-top: var(--space-lg); }
.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal);
  background: var(--light-blue-tint);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: var(--space-xs);
}

/* ---------- Icons ---------- */
.icon { width: 20px; height: 20px; display: block; }
.icon-chip svg.icon { width: 26px; height: 26px; }

/* ---------- Dense icon grid (Who We Serve / What We Manage) ---------- */
.grid-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* ---------- Glassmorphism diagram ---------- */
.diagram-wrap {
  position: relative;
  background: linear-gradient(135deg, rgba(170,228,244,0.28), rgba(15,108,123,0.06));
  border-radius: 24px;
  padding: var(--space-lg) var(--space-md);
}
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
.glass-chip {
  position: absolute;
  background: rgba(255,255,255,0.68);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.75);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--charcoal);
  box-shadow: 0 8px 20px rgba(58,58,58,0.1);
  animation: floaty 5s ease-in-out infinite;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.glass-chip .icon { width: 14px; height: 14px; color: var(--teal); }
.glass-core {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.8);
  box-shadow: 0 12px 30px rgba(15,108,123,0.18);
}

/* ---------- Coverage map ---------- */
.coverage-map-wrap {
  background: var(--charcoal);
  border-radius: 20px;
  padding: var(--space-md);
  position: relative;
}
@keyframes mapPulse {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.5); }
}
.map-pulse { transform-origin: center; transform-box: fill-box; animation: mapPulse 2.4s ease-in-out infinite; }
.map-legend { display: flex; flex-wrap: wrap; gap: var(--space-md); margin-top: var(--space-sm); }
.map-legend span { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; color: rgba(255,255,255,0.75); }
.map-legend .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--light-blue); flex-shrink: 0; }

/* ---------- Timeline preview (condensed, homepage) ---------- */
.timeline-preview {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  flex-wrap: wrap;
  justify-content: center;
}
.timeline-preview .step {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--charcoal);
  background: var(--off-white);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 10px 18px;
}
.timeline-preview .step .icon { width: 16px; height: 16px; color: var(--teal); }
.timeline-preview .arrow { color: var(--slate); opacity: 0.5; width: 18px; height: 18px; }

/* ---------- Case study preview ---------- */
.case-study-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-soft);
}
.case-study-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-sm);
  margin: var(--space-md) 0;
}
.case-study-grid div {
  text-align: center;
  padding: var(--space-sm);
  background: var(--off-white);
  border-radius: var(--radius-sm);
}
.case-study-grid .value { font-family: var(--font-serif); font-size: 1.5rem; color: var(--teal); display: block; }
.case-study-grid .label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--slate); margin-top: 4px; }

/* ---------- Standards / certifications list ---------- */
.standards-list { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-sm); }
.standards-list li {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 16px;
  background: var(--off-white);
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.92rem;
}
.standards-list .icon { color: var(--teal); flex-shrink: 0; }

/* ---------- Real photography ---------- */
.photo-cover {
  width: 100%;
  display: block;
  object-fit: cover;
  border-radius: var(--radius-md);
}
.service-card .photo-cover {
  height: 130px;
  margin-bottom: var(--space-sm);
}
.industry-photo {
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-top: var(--space-lg);
  display: block;
}
@media (max-width: 720px) {
  .industry-photo { height: 220px; margin-top: var(--space-md); }
}

/* ---------- Photo placeholder (generic) ---------- */
.photo-placeholder {
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(58,58,58,0.92), rgba(15,108,123,0.7));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: rgba(255,255,255,0.6);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  padding: var(--space-sm);
}
.photo-placeholder .placeholder-icon {
  width: 42px;
  height: 42px;
  color: rgba(255,255,255,0.85);
}
.service-card .photo-placeholder {
  height: 130px;
  font-size: 0.7rem;
  margin-bottom: var(--space-sm);
}
.service-card .learn-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: var(--space-sm);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--teal);
}
.service-card .learn-more .icon { width: 14px; height: 14px; transition: transform 200ms ease; }
.service-card:hover .learn-more .icon { transform: translateX(4px); }

/* ==========================================================================
   Accessibility, forms, and legal pages
   ========================================================================== */

/* Visually hidden but still read aloud by screen readers */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link: first Tab stop on every page */
.skip-link {
  position: absolute;
  left: 16px; top: -80px;
  z-index: 300;
  background: var(--charcoal);
  color: var(--white);
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
}
.skip-link:focus { top: 16px; }
main:focus { outline: none; }

/* Visible keyboard focus everywhere (light ring on dark areas, teal on light) */
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }
.hero :focus-visible,
.page-hero :focus-visible,
.section-dark :focus-visible,
.site-footer :focus-visible,
.site-header:not(.is-solid) :focus-visible,
.skip-link:focus-visible { outline-color: var(--light-blue); }
.card :focus-visible,
.site-header .dropdown :focus-visible,
.nav-links.nav-open :focus-visible { outline-color: var(--teal); }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--teal); outline-offset: 1px; }

/* Long words and email addresses wrap instead of pushing the page wider */
p, li, a, h1, h2, h3, h4 { overflow-wrap: break-word; }

/* Links inside running text are underlined so they never rely on color alone */
p a:not(.btn), li a:not(.btn) {
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

/* Respect the visitor's reduced-motion setting */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* Forms */
.req { color: #B3261E; font-weight: 700; }
.field-optional { font-weight: 400; color: var(--slate); font-size: 0.8rem; }
.form-note { font-size: 0.82rem; color: var(--slate); margin-bottom: var(--space-sm); }
.form-consent { display: flex; align-items: flex-start; gap: 10px; margin: 4px 0 var(--space-sm); }
.form-consent input[type="checkbox"] {
  flex: 0 0 22px;
  width: 22px; height: 22px;
  padding: 0;
  margin-top: 2px;
  accent-color: var(--teal);
}
.form-consent label { font-size: 0.85rem; font-weight: 400; line-height: 1.5; margin: 0; color: var(--slate); }
.form-consent label a { color: var(--teal); text-decoration: underline; }
.form-status { font-size: 0.88rem; margin-bottom: 12px; }
.form-status:empty { margin: 0; }
.lead-form .form-fine { font-size: 0.78rem; color: var(--slate); margin-top: 12px; text-align: center; }

/* Forms placed on the dark call-to-action band sit on a white card, so keep dark text */
.section-dark .card label,
.section-dark .card h2,
.section-dark .card h3 { color: var(--charcoal); }
.section-dark .card p,
.section-dark .card .form-note,
.section-dark .card .form-fine { color: var(--slate); }
.section-dark .card a { color: var(--teal); }
.section-dark .card .btn-primary { color: var(--white); }

/* Compact mobile header: logo, call-to-action, and menu button must all fit on a 320px screen */
@media (max-width: 720px) {
  .site-header .container { padding: 0 var(--space-sm); gap: var(--space-xs); }
  .nav-cta .btn { padding: 10px 14px; font-size: 0.8rem; }
  .nav-toggle { min-width: 44px; min-height: 44px; padding: 0; }
}

/* Spam trap: real visitors never see or reach this field (hidden, not focusable, ignored by screen readers) */
.hp-field { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Click-to-call bar, shown on phones only */
.call-bar { display: none; }
@media (max-width: 720px) {
  .call-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
    display: flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 52px; padding: 12px 16px;
    background: var(--teal); color: var(--white);
    font-weight: 700; font-size: 1rem;
    box-shadow: 0 -4px 14px rgba(0, 0, 0, 0.18);
  }
  .call-bar .icon { width: 18px; height: 18px; }
  .call-bar:focus-visible { outline-color: var(--white); outline-offset: -5px; }
  /* keep the footer and focused elements from sitting behind the bar */
  body { padding-bottom: 52px; }
  html { scroll-padding-bottom: 64px; }
}

/* Footer legal links */
.footer-legal a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.footer-legal a:hover { color: var(--light-blue); }

/* Legal pages (privacy, terms, cookies, accessibility) */
.legal-content { max-width: 760px; margin: 0 auto; }
.legal-content h2 { font-size: 1.55rem; margin: var(--space-md) 0 var(--space-xs); }
.legal-content h2:first-of-type { margin-top: 0; }
.legal-content h3 { font-size: 1.15rem; margin: var(--space-sm) 0 6px; }
.legal-content p { color: var(--charcoal); margin-bottom: 14px; line-height: 1.7; }
.legal-content ul { margin: 0 0 16px 0; padding-left: 22px; }
.legal-content li { color: var(--charcoal); margin-bottom: 8px; line-height: 1.65; }
.legal-content a { color: var(--teal); text-decoration: underline; text-underline-offset: 2px; }
.legal-summary {
  background: var(--off-white);
  border: 1px solid var(--border);
  border-left: 4px solid var(--teal);
  border-radius: var(--radius-sm);
  padding: 18px 22px;
  margin-bottom: var(--space-md);
}
.legal-summary p:last-child { margin-bottom: 0; }
.legal-table-wrap { overflow-x: auto; margin: 0 0 20px; }
.legal-table { width: 100%; border-collapse: collapse; min-width: 520px; }
.legal-table th, .legal-table td {
  border: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
  font-size: 0.92rem;
  color: var(--charcoal);
}
.legal-table th { background: var(--off-white); font-weight: 600; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 960px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero-stats { grid-template-columns: repeat(2, auto); row-gap: var(--space-sm); }
  .standards-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-study-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav-links { gap: var(--space-sm); }
  .section { padding: 72px 0; }
}

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; background: none; border: none; color: var(--white); font-size: 1.6rem; cursor: pointer; }
  .site-header.is-solid .nav-toggle { color: var(--charcoal); }
  .logo-text-primary { font-size: 0.88rem; }
  .logo-text-secondary { font-size: 0.56rem; }
  .hero { min-height: 82vh; }
  .hero-bg { animation: none; }
  .hero-content { padding-top: 90px; }
  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { width: 100%; }
  .grid-3, .grid-4, .grid-2, .grid-6 { grid-template-columns: minmax(0, 1fr); }
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .stats-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .timeline { flex-direction: column; gap: var(--space-md); }
  .timeline::before, .timeline-progress { display: none; }
  .page-hero { padding: 110px 0 var(--space-md); }
  .emergency-banner { flex-direction: column; align-items: flex-start; }
  .btn { white-space: normal; text-align: center; padding-left: 20px; padding-right: 20px; }
  .nav-cta .btn { white-space: nowrap; }
  .standards-list, .case-study-grid { grid-template-columns: minmax(0, 1fr); }
  .timeline-preview { flex-direction: column; align-items: stretch; }
  .timeline-preview .arrow { display: none; }
  .nav-item { position: static; }
  .dropdown {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    background: transparent;
    padding: 4px 0 4px 16px;
    min-width: 0;
  }
  .dropdown a { color: var(--slate) !important; font-size: 0.85rem; }
  /* The open mobile menu panel is always white, so its links must be dark whether or not the header has turned solid */
  .site-header .nav-links.nav-open a { color: var(--charcoal); }
  .site-header .nav-links.nav-open a:hover { color: var(--teal); }
  .site-header .nav-links.nav-open { align-items: stretch; gap: 14px !important; }
  .site-header .nav-links.nav-open .dropdown a { padding: 6px 12px; }
  .nav-caret { display: none; }
  /* Tighter vertical rhythm on phones (desktop spacing is far too airy at this size) */
  .section { padding: 44px 0; }
  .section-header { margin-bottom: var(--space-md); }
  .mt-lg { margin-top: var(--space-md); }
  .hero-ctas { margin-bottom: var(--space-md); }
  .footer-grid { margin-bottom: var(--space-md); }
  .site-footer { padding-top: 44px; }

  /* Icon tile lists (What We Manage, Who We Serve, Industries, small badges): 2 or 3 per row instead of one long stack.
     Cards that carry paragraph text stay one per row so they remain readable. */
  .grid:has(> .tile:not(.card)), .grid:has(> .badge) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.grid-6, .grid.grid-6:has(> .tile:not(.card)) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-6, .grid:has(> .tile:not(.card)), .grid:has(> .badge) { gap: var(--space-xs); }
  .grid-6 > .tile, .grid:has(> .tile:not(.card)) > .tile { padding: 14px 6px; }
  .grid-6 > .tile .icon-chip, .grid:has(> .tile:not(.card)) > .tile .icon-chip { margin-bottom: 10px; }
}

@media (max-width: 400px) {
  .logo-text-group { display: none; }
}


/* Cookie choices banner (only shown when analytics is turned on) */
.consent-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1200; display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; padding: 16px 24px; background: var(--charcoal); color: #fff; box-shadow: 0 -4px 18px rgba(0,0,0,0.18); }
.consent-banner p { margin: 0; font-size: 0.92rem; line-height: 1.5; max-width: 760px; color: #fff; }
.consent-banner a { color: var(--light-blue); text-decoration: underline; }
.consent-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.consent-btn { min-height: 44px; padding: 10px 22px; border-radius: 6px; font: inherit; font-weight: 600; cursor: pointer; border: 2px solid #fff; background: transparent; color: #fff; }
.consent-btn.consent-accept { background: #fff; color: var(--charcoal); }
.consent-btn:focus-visible { outline: 3px solid var(--light-blue); outline-offset: 2px; }
.footer-link-btn { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; cursor: pointer; }
.footer-link-btn:focus-visible { outline: 3px solid var(--light-blue); outline-offset: 2px; }
@media (max-width: 640px) { .consent-banner { flex-direction: column; align-items: stretch; padding: 14px 16px; } .consent-actions .consent-btn { flex: 1; } }
