/* =========================================================
   Echovasc Imaging Diagnostics — shared stylesheet
   Design tokens
   ========================================================= */

:root {
  --ink: #0A2036;
  --ink-soft: #13314F;
  --paper: #F5F7F8;
  --white: #FFFFFF;
  --teal: #0E93A0;
  --teal-dark: #0B7580;
  --teal-text: #0A5D66;   /* AA-safe on white for links/small text */
  --teal-tint: #E4F4F5;   /* light fill for chips/badges */
  --slate: #4C5F70;
  --slate-light: #7C90A0;
  --hairline: #DCE3E8;
  --hairline-on-ink: rgba(255,255,255,0.16);
  --focus: #0E7C86;

  --font-sans: 'IBM Plex Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

  --maxw: 1180px;
  --gutter: 24px;
  --radius-s: 3px;
  --radius-m: 4px;
}

/* Arrow / directional micro-interaction — used consistently on action links */
.go {
  display: inline-block;
  margin-left: 3px;
  transition: transform 0.15s ease;
}
a:hover .go, .btn:hover .go { transform: translateX(4px); }
.dl { display: inline-block; margin-left: 3px; transition: transform 0.15s ease; }
a:hover .dl, .btn:hover .dl { transform: translateY(3px); }

/* Emphasis accent — deliberate, brand-specific use of italics + color */
em.accent {
  font-style: italic;
  color: var(--teal-text);
  font-weight: inherit;
}

/* =========================================================
   Reset
   ========================================================= */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

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

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
svg { display: block; }
a { color: var(--teal-text); text-decoration-thickness: 1.5px; text-underline-offset: 2px; }
a:hover { color: var(--teal-dark); }
ul, ol { padding-left: 1.2em; }
button { font-family: inherit; }

h1, h2, h3, h4 {
  font-family: var(--font-sans);
  color: var(--ink);
  font-weight: 600;
  line-height: 1.18;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.1rem, 4.2vw, 3.1rem); font-weight: 650; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.05rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; max-width: 62ch; color: var(--ink); }
.lede { font-size: 1.15rem; color: var(--slate); max-width: 52ch; }

/* Visible, deliberate keyboard focus */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2.5px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  background: var(--ink);
  color: var(--white);
  padding: 12px 18px;
  border-radius: var(--radius-m);
  z-index: 1000;
  font-weight: 600;
  transition: top 0.15s ease;
}
.skip-link:focus { top: 12px; }

/* Screen-reader only */
.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;
}

/* =========================================================
   Layout helpers
   ========================================================= */

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section { padding: 88px 0; border-bottom: 1px solid var(--hairline); }
.section:last-of-type { border-bottom: none; }
.section--tight { padding: 64px 0; }
.section--ink {
  background:
    linear-gradient(rgba(10,32,54,0.94), rgba(10,32,54,0.97)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 120' preserveAspectRatio='none'%3E%3Cpath d='M0 60H80L96 20L114 100L128 60H160L172 40L184 80L196 60H400' stroke='%230E93A0' stroke-width='1.4' fill='none' opacity='0.35'/%3E%3C/svg%3E");
  background-repeat: no-repeat, repeat-x;
  background-position: center, bottom;
  background-size: cover, 400px 120px;
  border-bottom-color: var(--hairline-on-ink); color: var(--white);
}
.section--ink h1, .section--ink h2, .section--ink h3 { color: var(--white); }
.section--ink p { color: rgba(255,255,255,0.78); }
.section--panel { background: var(--white); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--teal-text);
  margin: 0 0 14px;
}
.section--ink .eyebrow { color: #6FD3D8; }
.eyebrow::before {
  content: "";
  width: 18px; height: 2px;
  background: currentColor;
  display: inline-block;
}

.grid-2 { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; gap: 40px; }
  .grid-3 { grid-template-columns: 1fr; gap: 28px; }
}

/* =========================================================
   Header / nav
   ========================================================= */

.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(245,247,248,0.92);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--hairline);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 76px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--ink);
  font-weight: 650; font-size: 1.05rem; letter-spacing: -0.01em;
}
.brand:hover { color: var(--ink); }
.brand-mark { width: 34px; height: 34px; flex: none; }
.brand-name-sub { display: block; font-weight: 450; font-size: 0.72rem; color: var(--slate); letter-spacing: 0; }

.nav-primary { display: flex; align-items: center; gap: 30px; }
.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  color: var(--ink); text-decoration: none; font-size: 0.96rem; font-weight: 500;
  padding: 6px 2px; border-bottom: 2px solid transparent;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { border-bottom-color: var(--teal); color: var(--ink); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 600; font-size: 0.95rem;
  padding: 12px 22px;
  border-radius: var(--radius-m);
  border: 1.5px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  min-height: 46px;
}
.btn-primary { background: var(--teal); color: var(--white); box-shadow: 0 3px 0 var(--teal-dark); }
.btn-primary:hover { background: var(--teal-dark); color: var(--white); box-shadow: 0 2px 0 #063e44; transform: translateY(1px); }
.btn-outline { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--white); }
.btn-outline-light { background: transparent; border-color: rgba(255,255,255,0.5); color: var(--white); }
.btn-outline-light:hover { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn-block { width: 100%; }

.nav-toggle {
  display: none;
  background: transparent; border: 1.5px solid var(--ink); border-radius: var(--radius-m);
  width: 46px; height: 46px; align-items: center; justify-content: center;
}
.nav-toggle svg { width: 20px; height: 20px; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-toggle { display: inline-flex; }
  .site-header.nav-open .nav-links {
    display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
    position: absolute; top: 76px; left: 0; right: 0;
    background: var(--paper); border-bottom: 1px solid var(--hairline);
    padding: 10px var(--gutter) 20px;
  }
  .site-header.nav-open .nav-links a { padding: 12px 4px; width: 100%; border-bottom: 1px solid var(--hairline); }
  .site-header.nav-open .nav-cta { display: flex; margin: 10px var(--gutter) 20px; }
}

/* =========================================================
   Hero
   ========================================================= */

.hero { padding: 72px 0 56px; }
.hero-copy .btn-row { display: flex; flex-wrap: wrap; gap: 14px; margin: 30px 0 22px; }
.hero-note {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.92rem; color: var(--slate);
}
.hero-note .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); flex: none; }

.hero-panel {
  background: var(--ink);
  border-radius: var(--radius-m);
  padding: 30px;
  color: var(--white);
}
.hero-panel-label { font-family: var(--font-mono); font-size: 0.76rem; letter-spacing: 0.04em; color: #8FE3E8; margin-bottom: 14px; }
.hero-trace { width: 100%; height: auto; }
.hero-trace path { stroke-dasharray: 900; stroke-dashoffset: 900; animation: draw 2.1s ease-out forwards 0.2s; }
@media (prefers-reduced-motion: reduce) { .hero-trace path { stroke-dashoffset: 0; animation: none; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.hero-tags { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.hero-tag {
  font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.04em; font-weight: 600;
  border-radius: 3px;
  padding: 6px 10px; color: var(--ink);
  background: #8FE3E8;
}
.hero-tag:nth-child(2) { background: #6FD3D8; }
.hero-tag:nth-child(3) { background: #4EC2C8; }

/* Stat strip */
.stat-strip {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline);
}
.stat {
  padding: 26px var(--gutter);
  border-left: 1px solid var(--hairline);
}
.stat:first-child { border-left: none; }
.stat-num { font-family: var(--font-mono); font-size: 1.6rem; font-weight: 600; color: var(--teal-dark); display: block; }
.stat-label { font-size: 0.88rem; color: var(--slate); }
@media (max-width: 720px) {
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: none; }
}

/* =========================================================
   Section heading block
   ========================================================= */
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head p { margin-top: 12px; }

/* =========================================================
   Service rows (diagnostic-list style, not cards)
   ========================================================= */
.service-row {
  display: grid; grid-template-columns: 130px 1fr; gap: 32px;
  padding: 34px 0; border-top: 1px solid var(--hairline);
}
.service-row:last-child { border-bottom: 1px solid var(--hairline); }
.service-tag {
  font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.03em;
  color: var(--ink); font-weight: 700;
  align-self: start;
  background: var(--teal-tint);
  border: 1px solid var(--teal);
  border-radius: 3px;
  padding: 5px 10px;
  display: inline-block;
  width: fit-content;
}
.service-row h3 { margin-bottom: 8px; }
.service-row .lede-line { color: var(--ink); font-weight: 550; margin-bottom: 6px; }
.service-row ul { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 8px; }
.service-row ul li { position: relative; padding-left: 20px; color: var(--slate); font-size: 0.96rem; }
.service-row ul li::before {
  content: ""; position: absolute; left: 0; top: 0.55em;
  width: 8px; height: 1.5px; background: var(--teal);
}
@media (max-width: 700px) {
  .service-row { grid-template-columns: 1fr; gap: 10px; }
}

/* =========================================================
   Partner columns
   ========================================================= */
.partner-col { border-top: 2px solid var(--ink); padding-top: 22px; }
.partner-kicker { font-family: var(--font-mono); font-size: 0.8rem; color: var(--slate); margin-bottom: 10px; display: block; }
.partner-col ul { list-style: none; padding: 0; margin: 16px 0 20px; display: grid; gap: 9px; }
.partner-col ul li { position: relative; padding-left: 20px; color: var(--slate); font-size: 0.95rem; }
.partner-col ul li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 8px; height: 1.5px; background: var(--teal); }

/* =========================================================
   Timeline / how it works (genuine sequences)
   ========================================================= */
.timeline { display: flex; gap: 0; list-style: none; margin: 0; padding: 0; }
.timeline li {
  flex: 1; position: relative; padding: 0 18px 0 0;
}
.timeline .step-num {
  font-family: var(--font-mono); font-size: 0.78rem; font-weight: 600;
  color: var(--teal-text); display: block; margin-bottom: 10px; letter-spacing: 0.03em;
}
.timeline .node {
  display: flex; align-items: center; gap: 12px; margin-bottom: 16px;
}
.timeline .node-num {
  font-size: 1.15rem; font-weight: 600; line-height: 1;
  width: 42px; height: 42px; border-radius: 50%;
  color: var(--white);
  background: var(--teal);
  box-shadow: 0 3px 0 var(--teal-dark);
  display: flex; align-items: center; justify-content: center; flex: none;
}
.timeline .rule { height: 1.5px; background: var(--hairline); flex: 1; }
.timeline h3 { font-size: 1.02rem; margin-bottom: 6px; }
.timeline p { font-size: 0.94rem; color: var(--slate); }
@media (max-width: 860px) {
  .timeline { flex-direction: column; gap: 26px; }
  .timeline .rule { display: none; }
}

.story-timeline { display: flex; gap: 0; list-style: none; margin: 40px 0 0; padding: 0; }
.story-timeline li { flex: 1; border-top: 2px solid var(--teal); padding-top: 16px; }
.story-timeline .era { font-family: var(--font-mono); font-size: 0.78rem; color: var(--teal-text); display: block; margin-bottom: 6px; }
.story-timeline h3 { font-size: 1.05rem; margin-bottom: 6px; }
.story-timeline p { font-size: 0.94rem; color: var(--slate); }
@media (max-width: 860px) { .story-timeline { flex-direction: column; gap: 22px; } }

/* =========================================================
   Leadership
   ========================================================= */
.leader { display: grid; grid-template-columns: 74px 1fr; gap: 22px; padding: 28px 0; border-top: 1px solid var(--hairline); }
.leader:last-child { border-bottom: 1px solid var(--hairline); }
.leader-avatar {
  width: 74px; height: 74px; border-radius: 50%;
  background: var(--ink); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-weight: 600; font-size: 1.05rem;
}
.leader-role { font-size: 0.86rem; color: var(--teal-text); font-weight: 600; margin-bottom: 4px; }
.leader-credentials { font-family: var(--font-mono); font-size: 0.82rem; color: var(--slate); margin: 4px 0 12px; }
@media (max-width: 560px) { .leader { grid-template-columns: 1fr; } }

/* =========================================================
   Notice / callout box
   ========================================================= */
.notice {
  border: 1px solid var(--hairline);
  border-left: 3px solid var(--teal);
  background: var(--white);
  border-radius: var(--radius-m);
  padding: 22px 26px;
}
.notice h3 { margin-bottom: 8px; }
.notice p:last-child { margin-bottom: 0; }

/* =========================================================
   FAQ
   ========================================================= */
.faq-item { border-top: 1px solid var(--hairline); padding: 22px 0; }
.faq-item:last-child { border-bottom: 1px solid var(--hairline); }
.faq-item summary {
  cursor: pointer; font-weight: 600; font-size: 1.02rem; color: var(--ink);
  list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; font-family: var(--font-mono); font-size: 1.2rem; color: var(--teal-text); flex: none;
  transition: transform 0.15s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { margin-top: 12px; color: var(--slate); }

/* =========================================================
   Forms
   ========================================================= */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 20px; }
.field-full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: 0.92rem; color: var(--ink); }
.field .hint { font-size: 0.82rem; color: var(--slate-light); font-weight: 400; }
.field input,
.field select,
.field textarea {
  font: inherit; font-size: 1rem;
  padding: 12px 14px;
  border: 1.5px solid var(--hairline);
  border-radius: var(--radius-m);
  background: var(--white); color: var(--ink);
  min-height: 48px;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--teal); }
.honeypot-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: 0.92rem; margin-top: 6px; min-height: 1.4em; }
.form-status[data-state="error"] { color: #B3261E; }
.form-status[data-state="ok"] { color: var(--teal-dark); }
@media (max-width: 700px) { .form-grid { grid-template-columns: 1fr; } }

/* =========================================================
   CTA band
   ========================================================= */
.cta-band { text-align: left; }
.cta-band .btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 26px; }

/* =========================================================
   Footer
   ========================================================= */
.site-footer { background: var(--ink); color: rgba(255,255,255,0.82); padding: 64px 0 28px; }
.site-footer a { color: rgba(255,255,255,0.82); }
.site-footer a:hover { color: var(--white); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid var(--hairline-on-ink); }
.footer-brand .brand { color: var(--white); }
.footer-brand p { color: rgba(255,255,255,0.68); margin-top: 14px; font-size: 0.95rem; }
.footer-col h4 { color: var(--white); font-size: 0.92rem; margin-bottom: 14px; }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: 0.95rem; }
.footer-patient-note {
  margin-top: 18px; font-size: 0.86rem; color: rgba(255,255,255,0.62);
  border-left: 2px solid var(--teal); padding-left: 12px;
}
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  padding-top: 24px; font-size: 0.86rem; color: rgba(255,255,255,0.6);
}
.footer-bottom ul { list-style: none; display: flex; gap: 18px; padding: 0; margin: 0; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; gap: 30px; } }

/* =========================================================
   Page header (interior pages)
   ========================================================= */
.page-header { padding: 60px 0 50px; }
.page-header .eyebrow { margin-bottom: 16px; }
.page-header p.lede { margin-top: 16px; }

/* Breadcrumb-free simple back link used on 404 */
.center-block { text-align: center; padding: 120px 0; }
.center-block .code { font-family: var(--font-mono); font-size: 0.95rem; color: var(--teal-text); margin-bottom: 14px; display: block; }
