:root {
  --primary-color: hsla(79, 65%, 48%, 1);
  --secondary-color: hsla(88, 82%, 9%, 1);
  --accent-color: hsla(180, 60%, 40%, 1);
  --background-color: #000000;
  --hero-text-color: #FFFFFF;
  --body-text-color: #E0E0E0;
  --font-base: 'IBM Plex Sans', sans-serif;
  --font-heading: 'Source Sans 3', sans-serif;
  --brand-padding: 16px;
  --focus-color: rgba(0, 200, 180, 0.9);
  --max-content-width: 900px;
  --topbar-height: 74px;
  --topbar-bg: #000;
}

/* Reset */
*,
*::before,
*::after { box-sizing: border-box; }
html, body { height: 100%; }

body {
  font-family: var(--font-base);
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background: var(--background-color);
  color: var(--body-text-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Hero */
header.hero {
  position: relative;
  background-color: var(--primary-color);
  color: var(--hero-text-color);
  padding: calc(var(--brand-padding) + 0px) 16px 40px;
  text-align: center;
  overflow: visible;
}

.brand {
  position: absolute;
  top: var(--brand-padding);
  left: var(--brand-padding);
  display: inline-block;
  line-height: 0;
  z-index: 5;
}
.brand:focus {
  outline: 3px solid var(--focus-color);
  outline-offset: 4px;
  border-radius: 6px;
}

.brand-logo {
  height: auto;
  width: auto;
  max-width: 96px;
  display: block;
  filter: drop-shadow(0 6px 10px rgba(0, 80, 70, 0.15));
  transition: filter 160ms ease, transform 160ms ease;
}
@media (max-width: 399px) { .brand-logo { max-width: 96px; } }
@media (min-width: 400px) and (max-width: 767px) { .brand-logo { max-width: 140px; } }
@media (min-width: 768px) and (max-width: 999px) { .brand-logo { max-width: 200px; } }
@media (min-width: 1000px) { .brand-logo { max-width: 260px; } }

.brand-logo:hover {
  transform: translateY(-2px);
  filter: drop-shadow(0 8px 12px rgba(0, 80, 70, 0.18));
}
@media (prefers-reduced-motion: reduce) {
  .brand-logo, .btn { transition: none; transform: none; }
}

.hero .hero-content {
  position: relative;
  z-index: 1;
  background: transparent;
  color: var(--hero-text-color, #fff);
  text-align: center;
  padding: 24px 16px 32px;
  padding-top: calc(var(--topbar-height) + 4px);
}

/* Topbar */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: var(--topbar-height);
  background: var(--topbar-bg);
  display: flex;
  justify-content: space-between; 
  align-items: center;
  padding: 0.5rem 1rem;           
  z-index: 1000;                  
  box-shadow: 0 1px 6px rgba(0,0,0,0.25);
}

/* Headline */
header.hero h1 {
  font-size: 1.25rem;
  margin: 48px 0 12px;
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.15;
  color: var(--hero-text-color);
  max-width: var(--max-content-width);
  margin-left: auto;
  margin-right: auto;
}
header.hero p {
  font-size: 1rem;
  max-width: calc(var(--max-content-width) - 40px);
  margin: 0 auto 30px;
  color: var(--hero-text-color);
}
header.hero p.highlighted-intro { color: var(--secondary-color); }

/* CTAs */
.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}
.btn {
  background: var(--accent-color);
  color: var(--hero-text-color);
  padding: 10px 18px;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 700;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  cursor: pointer;
}
.btn.secondary {
  background: var(--hero-text-color);
  color: var(--accent-color);
  border: 2px solid var(--accent-color);
}
a:focus, .btn:focus {
  outline: 3px solid var(--focus-color);
  outline-offset: 2px;
  border-radius: 6px;
}

/* Sections */
section {
  padding: 32px 16px;
  max-width: var(--max-content-width);
  margin: 0 auto;
}
section h2 {
  font-size: 1.125rem;
  margin-bottom: 16px;
  font-family: var(--font-heading);
  color: var(--hero-text-color);
}
section ul {
  list-style: disc;
  padding-left: 20px;
  color: var(--body-text-color);
}

/* Footer & Feature */
footer, .feature {
  background: var(--secondary-color);
  color: var(--hero-text-color);
  text-align: center;
  padding: 20px;
}

.feature-left { text-align: left; }

/* Utilities */
.hidden-visually {
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden; clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}
.hidden { display: none; }
.sr-hidden {
  position: absolute; left: -9999px;
  width: 1px; height: 1px;
  overflow: hidden;
}

/* Contact Form */
.vn-form__error { color: var(--color-error, #c32); font-size: 0.95em; margin-top: 0.25rem; }
.vn-form__status.success { color: var(--color-success, #080); }
.vn-form__status.error { color: var(--color-error, #c32); }

.contact { max-width: 600px; margin: 2rem auto; padding: 1rem; }
.contact h2 { font-size: 1.5rem; margin-bottom: 1rem; text-align: center; }
.form-group { margin-bottom: 1rem; }
label { display: block; font-weight: 600; margin-bottom: 0.5rem; }
input, textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font: inherit;
}
textarea { resize: vertical; }
button {
  background: #000;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
}
button:hover, button:focus { background: #333; }

/* Nav */
/* Mobile overlay nav (default) */
.main-nav {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 70%;
  background: #000;
  transform: translateX(100%);
  transition: transform 0.3s ease-in-out;
  z-index: 999;
}
.main-nav.open { transform: translateX(0); }

.main-nav ul {
  list-style: none;
  margin: 4rem 0 0 0;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.main-nav a {
  text-decoration: none;
  color: #fff;
  font-weight: 600;
  font-size: 1.2rem;
}
.main-nav .cta {
  background: #fff;
  color: #000;
  padding: 0.5rem 1rem;
  border-radius: 4px;
}

/* Backdrop for mobile */
.nav-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease-in-out;
  z-index: 998;
}
.nav-backdrop.open {
  opacity: 1;
  visibility: visible;
}

/* Nav toggle */
.nav-toggle {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

/* Desktop inline nav */
@media (min-width: 768px) {
  .topbar {
    justify-content: center; /* center contents horizontally */
  }

  .brand {
    position: absolute;
    left: var(--brand-padding);
    top: var(--brand-padding);
  }

  .main-nav {
    position: static;
    transform: none;
    height: auto;
    width: auto;
    background: transparent;
  }

  .main-nav ul {
    flex-direction: row;
    gap: 2rem;
    margin: 0;
    padding: 0;
    justify-content: center; /* center nav items */
  }

  .nav-backdrop { display: none; }
  .nav-toggle { display: none; }
}
.content-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
}
.vn-form__status.info {
  background-color: #e6f0ff;   /* soft blue background */
  border: 1px solid #99c2ff;   /* blue border */
  color: #003366;              /* dark blue text */
  padding: 0.75em;
  margin-top: 1em;
  border-radius: 4px;
  font-size: 0.95em;
}

/* Shared fade-in animation */
@keyframes fadeInStatus {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.vn-form__status {
  margin-top: 1rem;
  font-size: 1rem;
  padding: 0.75em;
  border-radius: 4px;
  opacity: 0; /* start hidden */
  animation: fadeInStatus 0.4s ease forwards;
}

/* Informational message (scorecard result) */
.vn-form__status.info {
  background-color: #e6f0ff;
  border: 1px solid #99c2ff;
  color: #003366;
}

/* Success message (form sent) */
.vn-form__status.success {
  background-color: #e6ffe6;
  border: 1px solid #66cc66;
  color: #004d00;
}

/* Error message (validation/network issues) */
.vn-form__status.error {
  background-color: #ffe6e6;
  border: 1px solid #cc6666;
  color: #660000;
}
#scorecard-form {
  display: grid;
  grid-template-columns: 80px 1fr;  /* left: input, right: long label text */
  gap: 0.75rem 1rem;
  max-width: 800px;                 /* allow long labels room */
  margin: 0 auto;
  align-items: start;
}

#scorecard-form label {
  display: contents;                 /* children become grid items */
  font-weight: 600;
}

#scorecard-form input[type="number"] {
  grid-column: 1;                    /* left column */
  width: 60px;                       /* 60–80px as desired */
  text-align: center;
  align-self: center;                 /* vertically align with text */
}

#scorecard-form .label-text {
  grid-column: 2;                    /* right column (takes remaining space) */
  line-height: 1.4;
}
#scorecard-form button.btn {
  grid-column: 2;          /* place under label column */
  justify-self: center;    /* centre horizontally */
  margin-top: 1rem;
}

/* Hover & focus effects for all .btn */
.btn:hover,
.btn:focus {
  background: var(--accent-color);
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.25));
  transform: translateY(-2px);
  transition: all 0.2s ease;
}

/* Accessibility: remove motion for reduced-motion users */
@media (prefers-reduced-motion: reduce) {
  .btn:hover,
  .btn:focus {
    transform: none;
    filter: none;
    transition: none;
  }
}

/* Active nav link */
.main-nav a.active {
  color: var(--primary-color);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}
@media (max-width: 767px) {
  .main-nav a.active { color: var(--primary-color); }
}

/* Service article icon layout */
.services article {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.25rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.services article:last-child { border-bottom: none; }
.service-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  color: var(--primary-color);
}
.services article > div { flex: 1; }
.services article h3 { margin-top: 0.25rem; }

/* Hero — large 3D logo watermark */
.hero-logo-3d {
  position: absolute;
  right: -6%;
  top: 50%;
  width: 52%;
  max-width: 520px;
  transform: translateY(-50%) perspective(700px) rotateY(-22deg) rotateX(6deg);
  pointer-events: none;
  z-index: 0;
  opacity: 0.22;
}
.hero-logo-3d svg { width: 100%; height: auto; display: block; }

@media (max-width: 767px) {
  .hero-logo-3d {
    width: 85%;
    right: -25%;
    opacity: 0.14;
  }
}

/* ── Homepage credibility section ───────────────────────────────────────── */

.section-label {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  color: var(--accent-color);
  margin: 0 0 0.4rem;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--hero-text-color);
  font-family: var(--font-heading);
  line-height: 1.15;
  margin: 0 0 2.25rem;
}

/* Three-column BAG pillar grid */
.pillar-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin-bottom: 2rem;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  overflow: hidden;
}

.pillar {
  padding: 1.75rem 1.5rem;
  border-right: 1px solid rgba(255,255,255,0.08);
  transition: background 0.2s ease;
}
.pillar:last-child { border-right: none; }
.pillar:hover { background: rgba(255,255,255,0.03); }

.pillar-word {
  display: block;
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--primary-color);
  font-family: var(--font-heading);
  letter-spacing: -0.01em;
  margin-bottom: 0.2rem;
}

.pillar-tagline {
  display: block;
  font-size: 0.72rem;
  color: var(--accent-color);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.9rem;
  opacity: 0.85;
}

.pillar p {
  font-size: 0.92rem;
  color: rgba(224,224,224,0.72);
  line-height: 1.65;
  margin: 0;
}

/* Trust chips */
.trust-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.chip {
  display: inline-block;
  padding: 0.3rem 0.9rem;
  border: 1px solid rgba(152,203,43,0.3);
  border-radius: 100px;
  font-size: 0.78rem;
  color: var(--primary-color);
  letter-spacing: 0.04em;
  opacity: 0.8;
}

/* CTA repeat heading — give it real weight */
.cta-repeat h2 {
  font-size: 1.6rem;
  line-height: 1.2;
  font-weight: 700;
  font-family: var(--font-heading);
}

/* Responsive */
@media (max-width: 767px) {
  .pillar-grid { grid-template-columns: 1fr; }
  .pillar {
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
  .pillar:last-child { border-bottom: none; }
  .section-title { font-size: 1.5rem; }
  .cta-repeat h2 { font-size: 1.25rem; }
}

/* ── Section intro paragraph ─────────────────────────────────────────────── */
.section-intro {
  font-size: 1rem;
  color: rgba(224,224,224,0.65);
  max-width: 580px;
  margin: 0 0 2rem;
  line-height: 1.65;
}

/* ── Services — article cards ────────────────────────────────────────────── */
section.services article {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 1.5rem;
  border-bottom: none;
  margin-bottom: 1rem;
  background: rgba(255,255,255,0.02);
  transition: background 0.2s ease;
}
section.services article:hover { background: rgba(255,255,255,0.04); }
section.services article:last-child { margin-bottom: 0; }

section.services article h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--hero-text-color);
  margin: 0 0 0.6rem;
}

/* Deliverable — always last <li> in each service */
section.services article ul li:last-child {
  list-style: none;
  margin-top: 0.75rem;
  margin-left: -1.25rem;
  padding: 0.45rem 0.75rem;
  background: rgba(152,203,43,0.07);
  border-left: 2px solid rgba(152,203,43,0.35);
  border-radius: 0 4px 4px 0;
  font-size: 0.87rem;
  color: rgba(224,224,224,0.7);
}

/* ── Playbook — numbered chapter cards ───────────────────────────────────── */
.vestibular-playbook-toc > ol {
  list-style: none;
  padding: 0;
  counter-reset: toc;
}
.vestibular-playbook-toc > ol > li {
  counter-increment: toc;
  position: relative;
  padding: 1.25rem 1.5rem 1.25rem 4.25rem;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  background: rgba(255,255,255,0.02);
  transition: background 0.2s;
}
.vestibular-playbook-toc > ol > li:hover { background: rgba(255,255,255,0.04); }
.vestibular-playbook-toc > ol > li::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 1.1rem;
  top: 1.25rem;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--primary-color);
  font-family: var(--font-heading);
  opacity: 0.5;
  line-height: 1;
}
.vestibular-playbook-toc > ol > li h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--hero-text-color);
  margin: 0 0 0.5rem;
}
.vestibular-playbook-toc > ol > li ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.vestibular-playbook-toc > ol > li ul li {
  padding: 0.15rem 0;
  font-size: 0.84rem;
  color: rgba(224,224,224,0.55);
}
.vestibular-playbook-toc > ol > li ul li::before {
  content: "→ ";
  color: var(--accent-color);
  opacity: 0.7;
}

/* ── Diagnostic — numbered how-to steps ──────────────────────────────────── */
.feature ol {
  list-style: none;
  padding: 0;
  counter-reset: steps;
  margin: 0 0 1rem;
}
.feature ol li {
  counter-increment: steps;
  position: relative;
  padding: 0.65rem 0 0.65rem 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-size: 0.92rem;
  color: rgba(224,224,224,0.75);
}
.feature ol li:last-child { border-bottom: none; }
.feature ol li::before {
  content: counter(steps);
  position: absolute;
  left: 0;
  top: 0.6rem;
  width: 1.6rem;
  height: 1.6rem;
  background: var(--primary-color);
  color: var(--secondary-color);
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.78rem;
  text-align: center;
  line-height: 1.6rem;
}

/* ── Diagnostic — solution cards ─────────────────────────────────────────── */
.solution ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.solution ul li {
  padding: 0.9rem 1rem 0.9rem 1.25rem;
  border-left: 2px solid var(--primary-color);
  border-radius: 0 6px 6px 0;
  background: rgba(255,255,255,0.02);
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: rgba(224,224,224,0.72);
  transition: background 0.2s;
}
.solution ul li:hover { background: rgba(255,255,255,0.04); }
.solution ul li strong {
  color: var(--primary-color);
  display: block;
  margin-bottom: 0.2rem;
  font-size: 0.95rem;
}

/* ── Diagnostic — maturity stage cards ───────────────────────────────────── */
article.stage {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1rem;
  background: rgba(255,255,255,0.02);
  max-width: var(--max-content-width);
  margin-left: auto;
  margin-right: auto;
  transition: background 0.2s;
}
article.stage:hover { background: rgba(255,255,255,0.04); }
article.stage h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary-color);
  margin: 0 0 0.75rem;
}
article.stage ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
article.stage ul li {
  padding: 0.35rem 0;
  font-size: 0.88rem;
  color: rgba(224,224,224,0.68);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
article.stage ul li:last-child { border-bottom: none; }
article.stage ul li strong { color: rgba(152,203,43,0.8); }

/* ── Contact — form section spacing ──────────────────────────────────────── */
.contact { margin-top: 1.5rem; }

