/* ==========================================================================
   Veriphex — marketing site
   Palette: Meridian — navy #102A43 + teal #12A594
   ========================================================================== */

:root {
  /* Brand */
  --navy:          #102A43;
  --navy-deep:     #0A1D2E;
  --navy-mid:      #1B3D5F;
  --teal:          #12A594;
  --teal-lift:     #1FBFA9;   /* accent on dark grounds */
  --teal-deep:     #0E7C72;   /* accent where text contrast is required */

  /* Neutrals */
  --ink:           #102A43;
  --body:          #3D5266;
  --muted:         #5B7183;
  --rule:          #E1E8EF;
  --input-rule:    #D5DFE8;
  --danger:        #B42318;
  --surface:       #FFFFFF;
  --surface-alt:   #F5F8FA;

  /* On dark */
  --on-dark:       #EAF1F7;
  --on-dark-body:  #B8CBDA;
  --on-dark-muted: #8AA4BA;
  --on-dark-rule:  rgba(234, 241, 247, 0.14);

  /* Type */
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto,
          "Helvetica Neue", Arial, sans-serif;

  /* Layout */
  --wrap: 1140px;
  --gutter: 24px;
  --radius: 10px;
  --header-h: 76px;
}

/* --------------------------------------------------------------- reset -- */

*, *::before, *::after { box-sizing: border-box; }

/* An author `display` rule beats the UA stylesheet's [hidden] { display: none },
   so hidden elements that set their own display (.pilot-success) need this. */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--body);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

h1, h2, h3 {
  color: var(--ink);
  font-weight: 650;
  letter-spacing: -0.021em;
  line-height: 1.14;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; }

a { color: var(--teal-deep); }

/* ------------------------------------------------------------ a11y ------ */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--navy);
  color: #fff;
  padding: 12px 20px;
  border-radius: 0 0 var(--radius) 0;
  text-decoration: none;
  font-weight: 600;
}
.skip-link:focus { left: 0; }

:where(a, button):focus-visible {
  outline: 3px solid var(--teal-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

.section-dark :where(a, button):focus-visible,
.cta-band :where(a, button):focus-visible,
.site-footer :where(a, button):focus-visible {
  outline-color: var(--teal-lift);
}

/* ----------------------------------------------------------- layout ----- */

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding: clamp(72px, 9vw, 124px) 0; }

.section + .section { border-top: 1px solid var(--rule); }
.section-dark + .section,
.section + .section-dark,
.section + .cta-band { border-top: 0; }

.section-lede {
  font-size: clamp(1.0625rem, 0.98rem + 0.4vw, 1.25rem);
  color: var(--muted);
  max-width: 62ch;
  margin-top: 22px;
}

.section h2 {
  font-size: clamp(1.75rem, 1.28rem + 2.1vw, 2.75rem);
  max-width: 22ch;
}

.eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--teal-deep);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 3px;
  background: var(--teal);
  border-radius: 2px;
  flex: none;
}

.grid { display: grid; gap: 28px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; gap: 24px; }
}

/* ---------------------------------------------------------- buttons ----- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 15px 26px;
  border-radius: 7px;
  border: 1px solid transparent;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary {
  background: var(--navy);
  color: #FFFFFF;
  box-shadow: 0 1px 2px rgba(16, 42, 67, 0.16);
}
.btn-primary:hover { background: var(--navy-mid); }
.btn-primary:active { transform: translateY(1px); }

.btn-accent {
  background: var(--teal);
  color: var(--navy-deep);
}
.btn-accent:hover { background: var(--teal-lift); }
.btn-accent:active { transform: translateY(1px); }

.btn-sm { padding: 11px 20px; font-size: 0.9375rem; }
.btn-lg { padding: 18px 36px; font-size: 1.0625rem; }

.link-quiet {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9375rem;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2px;
}
.link-quiet:hover { color: var(--ink); border-bottom-color: var(--teal); }

.cta-row {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
  margin-top: 38px;
}
.cta-row-center { justify-content: center; }

/* ----------------------------------------------------------- header ----- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo { display: inline-flex; align-items: center; }
/* Negative margin cancels the lockup's baked-in clear space (see .footer-lockup)
   so the mark lines up with the page content edge below it. */
.logo img { height: 40px; width: auto; margin-left: -6px; }

@media (max-width: 480px) {
  :root { --header-h: 64px; }
  .logo img { height: 32px; margin-left: -5px; }
}

/* ------------------------------------------------------------- hero ----- */

.hero {
  position: relative;
  padding: clamp(76px, 11vw, 148px) 0 clamp(72px, 9vw, 120px);
  background:
    radial-gradient(78ch 62ch at 12% -14%, rgba(18, 165, 148, 0.10), transparent 62%),
    radial-gradient(70ch 56ch at 92% 4%,  rgba(16, 42, 67, 0.07), transparent 60%),
    var(--surface-alt);
  border-bottom: 1px solid var(--rule);
  overflow: hidden;
}

.hero-inner { max-width: 900px; }

/* Eyebrow + build-status pill share one row, and wrap to two on narrow screens. */
.hero-topline {
  display: flex;
  align-items: center;
  gap: 8px 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.hero-topline .eyebrow { margin-bottom: 0; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--navy);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--rule);
  border-radius: 100px;
  padding: 6px 15px 6px 12px;
}

.status-dot {
  width: 7px;
  height: 7px;
  flex: none;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 3px rgba(18, 165, 148, 0.18);
}

.hero h1 {
  font-size: clamp(2.125rem, 1.32rem + 3.6vw, 3.875rem);
  letter-spacing: -0.028em;
  line-height: 1.06;
  max-width: 17ch;
}

.hero .lede {
  font-size: clamp(1.0625rem, 0.96rem + 0.55vw, 1.375rem);
  color: var(--body);
  max-width: 58ch;
  margin-top: 26px;
  line-height: 1.55;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 56px 0 0;
  padding: 0;
}
.hero-badges li {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid var(--rule);
  border-radius: 100px;
  padding: 7px 16px;
}

/* ------------------------------------------------------------ cards ----- */

.problem-grid, .solution-grid, .sector-grid { margin-top: 56px; }

.card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 34px 30px 32px;
  position: relative;
}
.card::before {
  content: "";
  position: absolute;
  inset: -1px auto auto -1px;
  width: 56px;
  height: 3px;
  background: var(--teal);
  border-radius: var(--radius) 0 var(--radius) 0;
}

.card h3 {
  font-size: 1.1875rem;
  line-height: 1.3;
  margin-bottom: 14px;
  max-width: 24ch;
}
.card p { font-size: 0.9688rem; line-height: 1.68; }

.card-index {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--teal-deep);
  margin-bottom: 16px;
}

/* --------------------------------------------------- dark section ------- */

.section-dark {
  background: var(--navy);
  color: var(--on-dark-body);
}
.section-dark h2, .section-dark h3 { color: var(--on-dark); }
.section-dark .section-lede { color: var(--on-dark-muted); }
.section-dark .eyebrow { color: var(--teal-lift); }
.section-dark .eyebrow::before { background: var(--teal-lift); }

.card-dark {
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--on-dark-rule);
}
.card-dark::before { background: var(--teal-lift); }
.card-dark p { color: var(--on-dark-body); }

/* ------------------------------------------------------------- flow ----- */

.flow {
  display: grid;
  grid-template-columns: 1fr auto 1.15fr auto 1fr;
  align-items: stretch;
  gap: 0;
  margin-top: 56px;
  border: 1px solid var(--on-dark-rule);
  border-radius: var(--radius);
  overflow: hidden;
}

.flow-node {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 28px 26px;
  text-align: center;
  background: rgba(255, 255, 255, 0.025);
}

.flow-node-core {
  background: rgba(18, 165, 148, 0.14);
  box-shadow: inset 0 -3px 0 var(--teal-lift);
}

.flow-label {
  font-weight: 650;
  font-size: 1rem;
  color: var(--on-dark);
  letter-spacing: -0.01em;
}
.flow-node-core .flow-label { color: #FFFFFF; }

.flow-sub {
  font-size: 0.8125rem;
  color: var(--on-dark-muted);
  letter-spacing: 0.01em;
}

.flow-arrow {
  width: 56px;
  position: relative;
  background: rgba(255, 255, 255, 0.025);
}
.flow-arrow::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 12px;
  right: 18px;
  height: 1px;
  background: var(--teal-lift);
  opacity: 0.55;
}
.flow-arrow::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 14px;
  width: 7px;
  height: 7px;
  border-top: 1px solid var(--teal-lift);
  border-right: 1px solid var(--teal-lift);
  transform: translateY(-50%) rotate(45deg);
  opacity: 0.85;
}

@media (max-width: 860px) {
  .flow { grid-template-columns: 1fr; }
  .flow-node { padding: 22px 20px; }
  .flow-arrow {
    width: auto;
    height: 34px;
  }
  .flow-arrow::before {
    top: 8px;
    bottom: 12px;
    left: 50%;
    right: auto;
    width: 1px;
    height: auto;
  }
  .flow-arrow::after {
    top: auto;
    bottom: 11px;
    right: auto;
    left: 50%;
    transform: translateX(-50%) rotate(135deg);
  }
}

/* ---------------------------------------------------------- sectors ----- */

.sector {
  padding: 32px 0 0;
  border-top: 3px solid var(--navy);
}
.sector:nth-child(2) { border-top-color: var(--teal); }
.sector:nth-child(3) { border-top-color: var(--navy-mid); }

.sector-reg {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--teal-deep);
  margin-bottom: 12px;
}

.sector h3 { font-size: 1.25rem; margin-bottom: 12px; }
.sector p { font-size: 0.9688rem; line-height: 1.68; }

.sector-note {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 1.0625rem;
}

/* --------------------------------------------------------- CTA band ----- */

.cta-band {
  background:
    radial-gradient(60ch 40ch at 50% 0%, rgba(18, 165, 148, 0.20), transparent 66%),
    var(--navy-deep);
  color: var(--on-dark-body);
  text-align: center;
}

.cta-inner { max-width: 760px; }
.cta-band .eyebrow { color: var(--teal-lift); justify-content: center; }
.cta-band .eyebrow::before { background: var(--teal-lift); }
.cta-band h2 {
  color: var(--on-dark);
  max-width: 20ch;
  margin-inline: auto;
}
/* Centred heading over a left-aligned, readable-width column of body copy.
   The column itself is centred in the band; the button and email stay centred. */
.cta-copy-block {
  max-width: 54ch;
  margin: 22px auto 0;
  text-align: left;
}
.cta-copy {
  color: var(--on-dark-body);
  font-size: clamp(1.0625rem, 0.98rem + 0.4vw, 1.1875rem);
}
.cta-copy + .cta-copy { margin-top: 16px; }
.cta-fallback {
  margin-top: 26px;
  font-size: 0.9375rem;
  color: var(--on-dark-muted);
}
.cta-fallback a { color: var(--teal-lift); text-decoration-thickness: 1px; text-underline-offset: 3px; }

/* ------------------------------------------------- request a pilot ------ */

.cta-band + .section { border-top: 0; }

.pilot {
  background:
    radial-gradient(64ch 44ch at 50% -10%, rgba(18, 165, 148, 0.09), transparent 64%),
    var(--surface-alt);
  text-align: center;
}

.pilot-inner { max-width: 720px; }
.pilot .eyebrow { justify-content: center; }
.pilot h2 { margin-inline: auto; }

.pilot-lede {
  font-size: clamp(1rem, 0.95rem + 0.28vw, 1.0938rem);
  color: var(--muted);
  max-width: 56ch;
  margin: 20px auto 0;
  line-height: 1.62;
}

.pilot-card {
  max-width: 560px;
  margin: 44px auto 0;
  padding: 40px;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 16px;
  box-shadow:
    0 1px 2px rgba(16, 42, 67, 0.04),
    0 12px 32px -12px rgba(16, 42, 67, 0.14);
}

/* Fields ------------------------------------------------------------------ */

.field + .field { margin-top: 20px; }

.field label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.005em;
  margin-bottom: 7px;
}

.field-optional {
  font-weight: 500;
  color: #8497A8;
  letter-spacing: 0.02em;
}

.pilot-form input[type="text"],
.pilot-form input[type="email"],
.pilot-form textarea {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--input-rule);
  border-radius: 9px;
  padding: 12px 14px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
  -webkit-appearance: none;
  appearance: none;
}

.pilot-form input[type="text"],
.pilot-form input[type="email"] { height: 46px; }

.pilot-form textarea {
  min-height: 108px;
  line-height: 1.55;
  resize: vertical;
}

.pilot-form ::placeholder { color: #93A6B5; }

.pilot-form input:hover,
.pilot-form textarea:hover { border-color: #C3D0DB; }

.pilot-form input:focus,
.pilot-form textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(18, 165, 148, 0.16);
}

.pilot-form input.is-invalid,
.pilot-form textarea.is-invalid { border-color: var(--danger); }

.pilot-form input.is-invalid:focus,
.pilot-form textarea.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.14);
}

.field-error {
  margin-top: 6px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--danger);
}

/* Honeypot — off-screen, never shown, not announced. */
.pilot-gotcha {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Submit ------------------------------------------------------------------ */

.pilot-submit {
  display: block;
  width: 100%;
  margin-top: 28px;
  font: inherit;
  /* 19px/700 clears the WCAG large-text threshold, so white on brand teal
     meets AA at 3.07:1. Do not reduce the size or weight. */
  font-size: 1.1875rem;
  font-weight: 700;
  line-height: 1;
  color: #FFFFFF;
  background: var(--teal);
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 15px 24px;
  cursor: pointer;
  transition: background-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}
.pilot-submit:hover {
  background: #0F9587;
  box-shadow: 0 6px 18px -8px rgba(18, 165, 148, 0.7);
}
.pilot-submit:active { transform: translateY(1px); }
.pilot-submit:disabled {
  background: #7FC9C0;
  cursor: default;
  box-shadow: none;
  transform: none;
}

/* Alert + success --------------------------------------------------------- */

.form-alert {
  margin-top: 24px;
  padding: 13px 16px;
  font-size: 0.9375rem;
  color: var(--danger);
  background: #FDF3F2;
  border: 1px solid #F3D4D1;
  border-radius: 9px;
}

.pilot-success {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 4px 0;
}

.pilot-check {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #FFFFFF;
  background: var(--teal-deep);
}
.pilot-check svg { width: 18px; height: 18px; }

.pilot-success-msg {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.5;
  padding-top: 4px;
}

@media (max-width: 560px) {
  .pilot-card { padding: 28px 22px; border-radius: 14px; margin-top: 34px; }
  .field + .field { margin-top: 18px; }
}

/* ----------------------------------------------------------- footer ----- */

.site-footer {
  background: var(--navy);
  color: var(--on-dark-muted);
  padding: 52px 0;
  border-top: 1px solid var(--on-dark-rule);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

/* Vertical stack: full lockup as the footer anchor, tagline directly beneath. */
.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}

/* The lockup viewBox carries 24 units of brand clear space on every side, which
   at render height H insets the ink by H * 0.141 from the box edge. Pull it back
   so the mark's left edge lines up optically with the tagline beneath it. */
.footer-lockup {
  height: 50px;
  width: auto;
  max-width: 100%;
  margin-left: -7px;
}

.footer-tagline {
  font-size: 0.9063rem;
  font-weight: 600;
  color: var(--on-dark-body);
}

.footer-meta { text-align: right; font-size: 0.9063rem; }
.footer-meta a { color: var(--teal-lift); text-decoration: none; }
.footer-meta a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-copy { margin-top: 6px; color: var(--on-dark-muted); }

@media (max-width: 640px) {
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 26px; }
  .footer-meta { text-align: left; }
  .footer-brand { gap: 0; }
  .footer-lockup { height: 44px; margin-left: -6px; }

  /* Full-width CTAs in the body — never the compact header button, which would
     blow out the header flex row and push the page wider than the viewport. */
  .cta-row { gap: 20px; }
  .cta-row .btn { width: 100%; }
  .cta-row .link-quiet { width: auto; }
}

/* The status pill carries a long string, so step the type down to keep it on one
   line as the viewport narrows. Breakpoints are set from the measured intrinsic
   pill widths (396px / 353px / 321px) against the available content width
   (viewport - 48px of gutter), with headroom for font variation across
   platforms. Below ~368px nothing fits, so it wraps as a rounded tag rather
   than a two-line stadium, with the dot held to the first line. */
@media (max-width: 460px) {
  .status-pill { font-size: 0.6875rem; letter-spacing: 0.06em; padding: 6px 13px 6px 11px; }
}
@media (max-width: 410px) {
  .status-pill { font-size: 0.625rem; letter-spacing: 0.05em; padding: 6px 12px 6px 10px; }
}
@media (max-width: 368px) {
  .status-pill { align-items: flex-start; border-radius: 12px; }
  .status-dot { margin-top: 3px; }
  .footer-lockup { height: 38px; margin-left: -5px; }
}
