/* ============================================================
   HALO Precision Diagnostics — site stylesheet
   Design language: editorial, warm, premium (functionhealth.com-inspired)
   Official HALO brand palette (from HALO brand guidelines):
     PMS 4189 C        #1B4A53  dark teal (primary)
     Pantone 142 C     #FFB548  gold (accent)
     Pantone 4182 C    #6B7566  sage
     Pantone 425 C     #555960  dark grey
     Pantone Cool Grey 7 C #989AA5  grey
     Pantone 663 C     #E5E1F6  pale lavender
     Pantone Black 6 C #000000  black
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,wght@0,400;0,600;0,700;1,500&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --navy: #1b4a53;          /* PMS 4189 C dark teal — primary */
  --navy-dark: #113239;     /* darker shade of PMS 4189 C */
  --teal: #1b4a53;
  --teal-dark: #113239;
  --gold: #ffb548;          /* Pantone 142 C */
  --sage: #6b7566;          /* Pantone 4182 C */
  --ink: #22262b;           /* body text (near Pantone Black 6 C) */
  --muted: #555960;         /* Pantone 425 C */
  --grey: #989aa5;          /* Pantone Cool Grey 7 C */
  --lavender: #e5e1f6;      /* Pantone 663 C */
  --cream: #f7f4ee;         /* warm editorial background */
  --bg: var(--cream);
  --bg-soft: #ffffff;       /* alternating sections = white */
  --bg-tint: #e9efee;       /* light tint of PMS 4189 C */
  --line: #e3ded4;
  --radius: 22px;
  --shadow: 0 10px 34px rgba(17, 50, 57, 0.10);
  --font-head: "Source Serif 4", Georgia, serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  font-size: 17px;
  line-height: 1.7;
}

h1, h2, h3, h4 { font-family: var(--font-head); color: var(--navy); line-height: 1.08; font-weight: 600; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: 1.35rem; line-height: 1.3; }
a { color: var(--navy); }
img { max-width: 100%; height: auto; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 28px; }
.section { padding: 92px 0; }
.section.soft { background: var(--bg-soft); }
.section.navy { background: var(--navy); }
.section.navy h2, .section.navy h3, .section.navy p { color: #fff; }
.section.navy h2 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); }
.center { text-align: center; }

.eyebrow {
  text-transform: uppercase; letter-spacing: .16em; font-size: .78rem;
  color: var(--muted); font-weight: 700; font-family: var(--font-body);
}
.eyebrow::before {
  content: ""; display: block; width: 36px; height: 5px;
  background: var(--gold); border-radius: 3px; margin-bottom: 12px;
}
.center .eyebrow::before { margin-left: auto; margin-right: auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(247, 244, 238, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 16px 28px; max-width: 1280px; margin: 0 auto; }
.logo img { height: 44px; display: block; }
.main-nav ul { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; align-items: center; }
.main-nav a {
  text-decoration: none; color: var(--navy); font-family: var(--font-body);
  font-weight: 600; font-size: .92rem; padding: 10px 13px; border-radius: 999px; display: block;
}
.main-nav a:hover { background: var(--bg-tint); }
.main-nav .btn-nav { background: var(--navy); color: #fff; border-radius: 999px; padding: 11px 22px; }
.main-nav .btn-nav:hover { background: var(--navy-dark); color: #fff; }
/* Secondary (outline) nav CTA so the FastTrack button stands out as primary */
.main-nav .btn-nav.ghost-nav { background: transparent; color: var(--navy); border: 1.5px solid var(--navy); }
.main-nav .btn-nav.ghost-nav:hover { background: var(--bg-tint); color: var(--navy); }
/* FastTrack Assessment image button (the logo art already has its own card look) */
.main-nav .ft-trigger {
  display: inline-flex; align-items: center; padding: 0; border-radius: 12px;
  overflow: hidden; box-shadow: 0 2px 8px rgba(17,50,57,.10);
  transition: box-shadow .15s ease, transform .15s ease;
}
.main-nav .ft-trigger:hover { box-shadow: 0 5px 16px rgba(17,50,57,.18); transform: translateY(-1px); }
.main-nav .ft-trigger img { height: 46px; width: auto; display: block; }

/* FastTrack Assessment hover panel */
.fasttrack .ft-panel {
  min-width: 380px; padding: 22px 24px; right: 0; left: auto;
}
.ft-panel h4 { font-family: var(--font-head); font-weight: 600; font-size: 1.25rem; color: var(--navy); text-transform: none; letter-spacing: 0; margin: 0 0 10px; }
.ft-panel p { font-size: .95rem; color: var(--muted); margin: 0; line-height: 1.55; }
.ft-panel hr { border: none; border-top: 1px solid var(--line); margin: 16px 0; }
.ft-panel-actions { display: flex; align-items: center; gap: 16px; }
.ft-panel-actions .btn { margin: 0; padding: 12px 24px; }
.ft-tag { font-family: var(--font-body); font-weight: 700; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--teal-dark); }
.has-sub { position: relative; }
.has-sub > .sub { display: none; position: absolute; top: 100%; left: 0; background: #fff; min-width: 270px; box-shadow: var(--shadow); border-radius: 18px; padding: 10px; }
.has-sub:hover > .sub { display: block; }
.sub li { width: 100%; }
.sub a { border-radius: 12px; }
.nav-toggle { display: none; background: none; border: none; font-size: 1.7rem; color: var(--navy); cursor: pointer; }

@media (max-width: 920px) {
  .nav-toggle { display: block; }
  .main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--cream); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; align-items: stretch; padding: 14px; }
  .has-sub > .sub { display: block; position: static; box-shadow: none; padding-left: 18px; background: transparent; }
  .fasttrack .ft-panel { min-width: 0; width: auto; padding-left: 18px; }
  .main-nav .btn-nav, .main-nav .btn-nav.ft-trigger, .main-nav .btn-nav.ghost-nav { display: inline-block; }
}

/* ---------- Hero (light, editorial) ---------- */
.hero { background: var(--cream); color: var(--ink); padding: 104px 0 84px; }
.hero h1 { color: var(--navy); margin: 0 0 20px; max-width: 900px; }
.hero .lede { font-size: 1.22rem; color: var(--muted); max-width: 680px; line-height: 1.6; }
.hero.small { padding: 68px 0 56px; }
.hero.small h1 { font-size: clamp(2.1rem, 4.5vw, 3.3rem); }

.video-frame {
  position: relative; padding-top: 56.25%; border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); background: var(--navy-dark);
  margin-top: 44px;
}
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---------- Full-screen video hero ---------- */
.hero-video {
  position: relative; min-height: 94vh; display: flex; align-items: flex-end;
  overflow: hidden; background: var(--navy-dark);
}
.hero-video .bg-video {
  position: absolute; top: 50%; left: 50%;
  width: 100vw; height: 56.25vw;           /* 16:9 cover */
  min-height: 100%; min-width: 177.78vh;
  transform: translate(-50%, -50%);
  pointer-events: none;
  /* video thumbnail shows instantly while the player loads */
  background: var(--navy-dark) url("https://vumbnail.com/1162652795.jpg") center / cover no-repeat;
}
.hero-video .bg-video iframe { width: 100%; height: 100%; border: 0; }
.hero-video .overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(17,50,57,.88) 0%, rgba(17,50,57,.35) 45%, rgba(17,50,57,.15) 100%);
}
.hero-video .container { position: relative; z-index: 2; padding-top: 120px; padding-bottom: 72px; transition: opacity 1.2s ease; }
.hero-video .overlay { transition: opacity 1.2s ease; }
.hero-video.text-hidden .container { opacity: 0; pointer-events: none; }
.hero-video.text-hidden .overlay { opacity: .25; }
.hero-video h1 { color: #fff; margin: 0 0 18px; max-width: 900px; }
.hero-video .lede { font-size: 1.22rem; color: #dbe7ea; max-width: 660px; line-height: 1.6; }
.hero-video .eyebrow { color: #dbe7ea; }
.hero-video .btn.ghost { border-color: #fff; color: #fff; }
.hero-video .btn.ghost:hover { background: rgba(255,255,255,.14); }
.hero-video .refs, .hero-video .refs a { color: #b9cdd2; }

/* Mobile: stacked layout — 16:9 video on top, text below on cream.
   A cover-cropped 16:9 video shows only a sliver on portrait screens,
   so we stop cropping and let the full frame play. */
@media (max-width: 760px) {
  .hero-video { min-height: 0; display: block; background: var(--cream); }
  .hero-video .bg-video {
    position: relative; top: auto; left: auto; transform: none;
    width: 100%; height: auto; aspect-ratio: 16 / 9;
    min-width: 0; min-height: 0;
  }
  .hero-video .overlay { display: none; }
  .hero-video .container {
    padding-top: 36px; padding-bottom: 48px;
    opacity: 1 !important; pointer-events: auto !important; /* no text fade on mobile */
  }
  .hero-video h1 { color: var(--navy); }
  .hero-video .lede { color: var(--muted); }
  .hero-video .eyebrow { color: var(--muted); }
  .hero-video .btn.ghost { border-color: var(--navy); color: var(--navy); }
  .hero-video .btn.ghost:hover { background: var(--bg-tint); }
  .hero-video .refs, .hero-video .refs a { color: var(--muted); }
}

.hero-stats { display: flex; gap: 56px; flex-wrap: wrap; margin-top: 48px; padding-top: 34px; border-top: 1px solid var(--line); }
.hero-stats > div { min-width: 150px; }
.hero-stats strong { display: block; font-family: var(--font-head); font-size: 2.1rem; color: var(--navy); font-weight: 600; }
.hero-stats span { color: var(--muted); font-size: .92rem; }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; background: var(--navy); padding: 20px 0; white-space: nowrap; }
.marquee-track { display: inline-block; animation: marquee 42s linear infinite; }
.marquee span { color: #fff; font-family: var(--font-head); font-size: 1.15rem; margin: 0 14px; opacity: .92; }
.marquee span::after { content: "·"; color: var(--gold); margin-left: 28px; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Numbered steps ---------- */
.step-num {
  font-family: var(--font-body); font-weight: 700; font-size: .85rem;
  color: var(--navy); background: var(--gold);
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; margin-bottom: 18px;
}

/* ---------- Buttons (pills) ---------- */
.btn {
  display: inline-block; text-decoration: none; font-family: var(--font-body); font-weight: 600;
  padding: 15px 32px; border-radius: 999px; font-size: 1rem; margin: 6px 10px 6px 0;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.btn.primary { background: var(--navy); color: #fff; }
.btn.primary:hover { background: var(--navy-dark); }
.btn.ghost { border: 1.5px solid var(--navy); color: var(--navy); }
.btn.ghost:hover { background: var(--bg-tint); }
.section.navy .btn.ghost, .hero.dark .btn.ghost { border-color: #fff; color: #fff; }
.section.navy .btn.ghost:hover { background: rgba(255,255,255,.12); }
.btn.gold { background: var(--gold); color: #000; }
.btn.gold:hover { background: #f0a635; }

/* ---------- Cards & grids ---------- */
.grid { display: grid; gap: 26px; }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 920px) { .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; } }

.card {
  background: #fff; border: none; border-radius: var(--radius);
  padding: 32px; box-shadow: 0 3px 16px rgba(17, 50, 57, .06);
}
.section.soft .card { background: var(--cream); box-shadow: none; }
.card h3 { margin-top: 0; }
.card.stat { text-align: center; }
.card.stat img { height: 64px; margin-bottom: 14px; }
.card.stat .big { font-family: var(--font-head); font-size: 1.7rem; font-weight: 600; color: var(--navy); }

.split { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
.split.rev { grid-template-columns: .9fr 1.1fr; }
@media (max-width: 860px) { .split, .split.rev { grid-template-columns: 1fr; } }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }

/* ---------- Team ---------- */
.person { text-align: left; background: #fff; border-radius: var(--radius); padding: 22px; box-shadow: 0 3px 16px rgba(17,50,57,.06); }
.section.soft .person { background: var(--cream); box-shadow: none; }
.person img { width: 50%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 50%; box-shadow: none; }
.person .li { font-size: .82rem; font-weight: 600; }
.person h3 { margin: 16px 0 2px; }
.person .role { color: var(--sage); font-weight: 600; font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; font-family: var(--font-body); }
.person p { font-size: .95rem; color: var(--muted); }

/* ---------- Tables ---------- */
table.data { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 3px 16px rgba(17,50,57,.06); }
table.data th { background: var(--navy); color: #fff; text-align: left; padding: 14px 18px; font-family: var(--font-body); font-weight: 600; font-size: .88rem; }
table.data td { padding: 14px 18px; border-bottom: 1px solid #eee9df; vertical-align: top; }
table.data tr:nth-child(even) td { background: var(--cream); }

/* ---------- Locations / map ---------- */
.map-frame {
  position: relative; padding: 14px; background: #fff;
  border-radius: calc(var(--radius) + 10px);
  box-shadow: 0 34px 70px -24px rgba(17,50,57,.30), 0 8px 24px rgba(17,50,57,.08);
}
.map-frame::after {
  content: ""; position: absolute; inset: 14px; border-radius: var(--radius);
  box-shadow: inset 0 0 0 1px rgba(27,74,83,.14); pointer-events: none; z-index: 350;
}
#map { height: 560px; border-radius: var(--radius); z-index: 1; }
#map .leaflet-tile-pane { filter: sepia(14%) saturate(135%) hue-rotate(-6deg) brightness(1.02); }
#map .leaflet-control-zoom { border: none !important; border-radius: 12px !important; overflow: hidden; box-shadow: 0 8px 22px rgba(17,50,57,.18) !important; }
#map .leaflet-control-zoom a { background: #fff !important; color: var(--navy) !important; border: none !important; font-family: var(--font-body); }
#map .leaflet-control-zoom a:hover { background: var(--bg-tint) !important; }
#map .leaflet-control-attribution { background: rgba(255,255,255,.85) !important; border-radius: 8px 0 0 0; font-family: var(--font-body); font-size: .7rem; }
.halo-pin svg { transition: transform .15s ease, filter .15s ease; transform-origin: 50% 100%; filter: drop-shadow(0 6px 10px rgba(17,50,57,.35)); }
.halo-pin:hover svg { transform: scale(1.12); filter: drop-shadow(0 10px 16px rgba(17,50,57,.45)); }
.map-filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 26px; align-items: center; }
.map-filters .chip {
  border: 1.5px solid var(--navy); background: transparent; color: var(--navy);
  border-radius: 999px; padding: 10px 22px; font-family: var(--font-body); font-weight: 600; font-size: .88rem; cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.map-filters .chip:hover { background: var(--bg-tint); }
.map-filters .chip.active { background: var(--navy); color: #fff; }
.map-filters input[type="search"] {
  flex: 1; min-width: 220px; padding: 12px 20px; border: 1.5px solid var(--line);
  border-radius: 999px; font-size: .95rem; background: #fff; font-family: var(--font-body);
}
.map-filters input[type="search"]:focus { outline: none; border-color: var(--navy); }
.loc-card { border-left: none; }
.loc-card .badges { margin: 6px 0 10px; }
.badge {
  display: inline-block; font-size: .7rem; font-weight: 700; font-family: var(--font-body);
  padding: 4px 12px; border-radius: 999px; margin-right: 6px; text-transform: uppercase; letter-spacing: .06em;
}
.badge.genetic { background: var(--bg-tint); color: var(--navy); }
.badge.focal { background: #fdebcb; color: #7a5a1e; }
.badge.research { background: #ecedf0; color: #565a63; }
.badge.imaging { background: #e9ece8; color: var(--sage); }
.loc-card .addr { color: var(--muted); font-size: .95rem; margin: 4px 0; }
.loc-card .services { font-size: .88rem; color: var(--muted); }
.leaflet-popup-content-wrapper { border-radius: 14px; box-shadow: 0 20px 44px rgba(17,50,57,.22); }
.leaflet-popup-content { font-family: var(--font-body); }
.leaflet-popup-content h3 { margin: 0 0 4px; font-size: 1rem; color: var(--navy); }
.leaflet-popup-tip { box-shadow: 0 6px 14px rgba(17,50,57,.12); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: #c3d2d5; padding: 72px 0 28px; margin-top: 0; }
.site-footer h4 { color: #fff; font-size: .82rem; text-transform: uppercase; letter-spacing: .12em; font-family: var(--font-body); font-weight: 700; }
.site-footer a { color: #c3d2d5; text-decoration: none; display: block; padding: 4px 0; font-size: .95rem; }
.site-footer a:hover { color: var(--gold); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 36px; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.14); margin-top: 44px; padding-top: 22px; font-size: .82rem; color: var(--grey); }

/* ---------- Forms ---------- */
.form-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 36px; max-width: 820px; margin: 0 auto; }
.section.soft .form-card { background: #fff; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 22px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-family: var(--font-body); font-weight: 600; font-size: .9rem; color: var(--navy); }
.field .req { color: #b23; }
.field input, .field select, .field textarea {
  font-family: var(--font-body); font-size: 1rem; color: var(--ink);
  padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; width: 100%;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--navy); }
.form-fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; margin: 26px 0 0; }
.form-fieldset legend { font-family: var(--font-head); font-weight: 600; color: var(--navy); padding: 0 10px; font-size: 1.1rem; }
.choice-row { display: flex; flex-wrap: wrap; gap: 18px; }
.choice { display: inline-flex; align-items: center; gap: 8px; font-size: .95rem; font-weight: 500; }
.choice input { width: auto; }
.form-note { font-size: .82rem; color: var(--muted); }
.form-success {
  display: none; background: var(--bg-tint); border-left: 5px solid var(--gold);
  padding: 22px 26px; border-radius: 0 var(--radius) var(--radius) 0; font-size: 1.05rem;
}
.form-success.show { display: block; }
.form-error {
  display: none; background: #fdf1f1; border-left: 5px solid #b23;
  padding: 16px 20px; border-radius: 0 var(--radius) var(--radius) 0; font-size: .95rem;
}
.form-error.show { display: block; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Assessment form: single-column, boxed radio options */
.form-lead { max-width: 640px; margin: 0 auto 8px; text-align: center; }
.form-lead .no-cost { font-family: var(--font-body); font-weight: 700; color: var(--navy); margin: 6px 0 0; }
.checklist { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 26px; margin: 18px 0 0; padding: 0; list-style: none; }
.checklist li { font-size: .92rem; color: var(--muted); font-weight: 600; }
.checklist li::before { content: "\2713"; color: #3a9b6e; font-weight: 800; margin-right: 8px; }
.field .help { font-size: .82rem; color: var(--muted); font-weight: 400; }
.field .opt-label-note { color: var(--muted); font-weight: 400; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.opt-group { display: grid; gap: 12px; margin-top: 2px; }
.opt-group.two { grid-template-columns: 1fr 1fr; }
.opt-group.three { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 560px) { .opt-group.two, .opt-group.three { grid-template-columns: 1fr; } }
.opt {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  border: 1.5px solid var(--line); border-radius: 12px; padding: 14px 16px;
  font-size: .98rem; font-weight: 500; transition: border-color .12s ease, background .12s ease;
}
.opt:hover { border-color: var(--navy); }
.opt input { width: auto; margin: 0; accent-color: var(--navy); }
.opt:has(input:checked) { border-color: var(--navy); background: var(--bg-tint); }
.consent { display: flex; align-items: flex-start; gap: 10px; font-size: .92rem; line-height: 1.5; color: var(--muted); cursor: pointer; }
.consent input { width: 18px; height: 18px; margin: 2px 0 0; flex: 0 0 auto; accent-color: var(--navy); }

/* ---------- Misc ---------- */
.notice { background: var(--bg-tint); border-left: 5px solid var(--gold); padding: 20px 26px; border-radius: 0 var(--radius) var(--radius) 0; }
.refs { font-size: .8rem; color: var(--grey); }
.breadcrumbs { font-size: .85rem; color: var(--muted); margin-bottom: 12px; font-family: var(--font-body); }
.breadcrumbs a { color: var(--muted); }
.cta-band { text-align: center; }
.cta-band h2 { margin-bottom: 10px; }
