/* Warrix Health website — design v4 "Athletic" (team pick, 6 Oct 2026).
   Hinge Health's structure (the brief's main visual reference: real people,
   big type, one primary action) in Warrix's sports-brand personality: dark
   ground, electric blue, italic display type, sharp corners, the Warrix mark
   as a supergraphic. Single dark theme on purpose, every colour painted.
   Contrast: --brand (#0E68D6) carries white button text at AA (5.2:1); the brighter
   --electric is only used on large surfaces; text links use --brand-ink. */

:root {
  --ink: #F4F7FB;
  --ink-2: #C3CDDB;
  --muted: #8B97AA;
  --line: #222A38;
  --page: #0D1119;
  --paper: #07090E;
  --night: #07090E;
  --brand: #0E68D6;
  --brand-ink: #4FA5FF;
  --electric: #1E8BFF;
  --tint: #12223A;
  --tint-2: #0F1724;
  --navy: #07090E;
  --navy-2: #121A28;
  --sky: #6FB6FF;
  --line-green: #06C755;
  --warn-bg: #2A1D0B;
  --warn-ink: #FFCF8A;
  --warn-bar: #E08A1E;

  --display: "Kanit", "Noto Sans Thai", system-ui, sans-serif;
  --body: "IBM Plex Sans Thai", "Noto Sans Thai", system-ui, sans-serif;

  --r-photo: 4px;
  --wrap: 1200px;
  --gut: clamp(20px, 4vw, 40px);
  --sec: clamp(64px, 9vw, 120px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0; background: var(--paper); color: var(--ink-2);
  font-family: var(--body); font-size: 1.0625rem; line-height: 1.75;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--brand-ink); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #fff; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }

h1, h2, h3, h4 { font-family: var(--display); color: var(--ink); font-weight: 600; margin: 0; text-wrap: balance; letter-spacing: -0.005em; }
h1, h2 { font-style: italic; font-weight: 700; letter-spacing: -0.015em; }
h1 { font-size: clamp(2.35rem, 5.4vw, 4.25rem); line-height: 1.16; }
h2 { font-size: clamp(1.85rem, 3.6vw, 2.85rem); line-height: 1.22; }
h3 { font-size: clamp(1.2rem, 1.8vw, 1.45rem); line-height: 1.35; }
h4 { font-size: 1.08rem; line-height: 1.4; }
.lead { font-size: clamp(1.1rem, 1.5vw, 1.28rem); line-height: 1.7; color: var(--ink-2); max-width: 38em; }
.eyebrow { display: block; font-family: var(--body); font-weight: 600; font-size: .86rem; letter-spacing: .03em; color: var(--brand-ink); margin-bottom: 14px; }
.muted { color: var(--muted); font-size: .94rem; }
.num { font-variant-numeric: tabular-nums; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.sec { padding: var(--sec) 0; }
.sec-tight { padding: calc(var(--sec) * .6) 0; }
.bg-page { background: var(--page); }
.bg-tint { background: var(--tint-2); }
.sec-head { display: grid; gap: 16px; margin-bottom: clamp(32px, 4.5vw, 56px); max-width: 46rem; }
.sec-head p { margin: 0; color: var(--muted); font-size: 1.08rem; }
.sec-head-row { display: flex; gap: 24px; justify-content: space-between; align-items: end; flex-wrap: wrap; max-width: none; }

/* ---- buttons: pills with an arrow ---- */
.pill {
  display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 26px;
  border-radius: 6px; border: 1.5px solid transparent; cursor: pointer;
  font-family: var(--display); font-weight: 500; font-size: 1.05rem; line-height: 1; text-decoration: none;
  transition: background .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}
.pill:hover { transform: translateY(-1px); text-decoration: none; }
.pill svg { width: 18px; height: 18px; flex: none; }
.pill-primary { background: var(--brand); color: #fff; }
.pill-primary:hover { background: var(--brand-ink); color: #fff; }
.pill-ghost { background: transparent; color: var(--ink); border-color: rgba(255,255,255,.45); }
.pill-ghost:hover { background: #fff; color: var(--night); border-color: #fff; }
.pill-light { background: #fff; color: var(--night); }
.pill-light:hover { background: var(--tint); color: var(--ink); }
.pill-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.pill-outline-light:hover { background: #fff; color: var(--night); }
.pill-line { background: var(--line-green); color: var(--night); }
.pill-line:hover { background: #2BD872; color: var(--night); }
.pill-sm { min-height: 42px; padding: 0 18px; font-size: .96rem; }
.pills { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.textlink { font-family: var(--display); font-weight: 500; color: var(--brand-ink); text-decoration: none; display: inline-flex; gap: 8px; align-items: center; }
.textlink svg { width: 16px; height: 16px; transition: transform .15s ease; }
.textlink:hover svg { transform: translateX(3px); }

/* ---- header ---- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(7,9,14,.9); backdrop-filter: saturate(140%) blur(8px); border-bottom: 1px solid var(--line); }
.hd { display: flex; align-items: center; gap: 28px; height: 74px; }
.logo { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; flex: none; }
.logo:hover { color: var(--ink); }
.logo-mark { width: 40px; height: auto; color: var(--electric); }
.logo-word { font-family: var(--display); font-weight: 600; font-size: 1.12rem; letter-spacing: .06em; line-height: 1; white-space: nowrap; }
.logo-word span { color: var(--electric); }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a { color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: .97rem; padding: 8px 12px; border-radius: 8px; white-space: nowrap; }
.nav a:hover { color: #fff; background: var(--tint-2); }
.nav a[aria-current="page"] { color: var(--brand-ink); }
.hd .pill { flex: none; }
.menu { display: none; margin-left: auto; position: relative; }
.menu summary { list-style: none; cursor: pointer; width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; border: 1.5px solid var(--line); color: var(--ink); }
.menu summary::-webkit-details-marker { display: none; }
.menu summary svg { width: 22px; height: 22px; }
.menu-panel { position: fixed; inset: 74px 0 auto 0; background: var(--page); border-bottom: 1px solid var(--line); padding: 12px var(--gut) 24px; box-shadow: 0 18px 40px rgba(0,0,0,.5); max-height: calc(100vh - 74px); overflow-y: auto; }
.menu-panel a { display: block; padding: 14px 4px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; font-family: var(--display); font-size: 1.15rem; }
.menu-panel .pill { margin-top: 18px; width: 100%; justify-content: center; }

/* ---- hero: split ---- */
.hero { padding: clamp(40px, 6vw, 80px) 0 clamp(56px, 7vw, 96px); }
.hero-grid { display: grid; grid-template-columns: 1.08fr .92fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero h1 { margin-bottom: 22px; }
/* Thai has no spaces between words, so the browser's dictionary may split a
   compound (บาด|เจ็บ). Key headlines wrap phrases in .nw and break only
   between them. */
.nw { white-space: nowrap; }
@media (min-width: 921px) { .hero-grid:has(.hero-stack) { grid-template-columns: 1fr 1fr; } }
.hero .lead { margin-bottom: 30px; }
.hero-note { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: .95rem; color: var(--muted); }
.hero-note b { color: var(--ink); font-weight: 600; }
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: 18px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--brand-ink); }
.crumbs span { margin: 0 6px; }

.photo { border-radius: var(--r-photo); overflow: hidden; background: var(--tint); }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo-port { aspect-ratio: 4 / 5; }
.photo-land { aspect-ratio: 3 / 2; }
.hero-stack { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.hero-stack .photo:nth-child(2) { margin-top: 72px; }
.hero-photo { position: relative; }
.hero-photo .photo { aspect-ratio: 4 / 5; max-height: 640px; }
.hero-photo.is-land .photo { aspect-ratio: 4 / 3; }

/* ---- stage track: where a page sits on the care path ---- */
.track { display: flex; flex-wrap: wrap; gap: 6px 0; margin: 0 0 18px; padding: 0; list-style: none; font-size: .88rem; font-weight: 600; }
.track li { display: inline-flex; align-items: center; color: var(--muted); }
.track li + li::before { content: ""; width: 22px; height: 1.5px; background: var(--line); margin: 0 8px; }
.track li.on { color: var(--brand-ink); }
.track li.on b { background: var(--brand); color: #fff; }
.track b { font-family: var(--display); font-weight: 500; width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center; font-size: .78rem; margin-right: 7px; background: var(--tint); color: var(--brand-ink); }

/* ---- symptom entry ---- */
.symptoms { display: flex; flex-wrap: wrap; gap: 12px; }
.symptom {
  display: inline-flex; align-items: center; gap: 14px; padding: 16px 22px 16px 26px; border-radius: 6px;
  background: var(--page); border: 1.5px solid var(--line); color: var(--ink); text-decoration: none;
  font-family: var(--display); font-size: clamp(1.15rem, 2vw, 1.5rem); font-weight: 500; line-height: 1.2;
  transition: border-color .15s ease, background .15s ease;
}
.symptom small { font-family: var(--body); font-size: .86rem; font-weight: 400; color: var(--muted); }
.symptom svg { width: 20px; height: 20px; color: var(--brand-ink); transition: transform .15s ease; }
.symptom:hover { border-color: var(--electric); color: #fff; background: var(--tint); }
.symptom:hover svg { transform: translateX(3px); }
.symptom.alt { background: var(--brand); border-color: var(--brand); color: #fff; }
.symptom.alt small, .symptom.alt svg { color: #fff; }
.symptom.alt:hover { background: var(--electric); border-color: var(--electric); color: #fff; }

/* ---- the care path ---- */
.path { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(18px, 2.4vw, 32px); list-style: none; padding: 0; counter-reset: stage; }
.path > li { display: flex; flex-direction: column; gap: 14px; }
.path .photo { aspect-ratio: 4 / 5; }
.stage-no { font-family: var(--display); font-style: italic; font-weight: 600; font-size: 1.5rem; color: var(--brand-ink); letter-spacing: .06em; display: flex; align-items: center; gap: 10px; }
.stage-no::after { content: ""; flex: 1; height: 1.5px; background: var(--line); }
.path h3 { font-size: clamp(1.35rem, 2.2vw, 1.75rem); }
.path p { margin: 0; color: var(--muted); font-size: .98rem; }
.path .links { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .95rem; }
.path .links a { text-decoration: none; font-weight: 500; }

/* text-only path on condition pages */
.path-text .stage-no { font-size: 1rem; }
.path-text p { color: var(--ink-2); font-size: 1rem; }
.h-small { font-size: 1.4rem; margin-bottom: 18px; }
.band-links.on-light { margin-top: 0; }
.band-links.on-light a { color: var(--ink); border-color: var(--line); background: var(--paper); }
.band-links.on-light a:hover { border-color: var(--brand); color: var(--brand-ink); background: var(--paper); }

/* ---- editorial feature rows ---- */
.features { display: grid; gap: clamp(56px, 8vw, 104px); }
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.feature:nth-of-type(even) .feature-media { order: 2; }
.feature .photo { aspect-ratio: 5 / 4; }
.feature h3 { font-size: clamp(1.6rem, 3vw, 2.3rem); margin-bottom: 14px; }
.feature p { color: var(--ink-2); }
.facts-line { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 4px 0 22px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: .95rem; }
.facts-line span { color: var(--muted); }
.facts-line b { color: var(--ink); font-weight: 600; margin-left: 4px; }

/* ---- index list (typographic, no boxes) ---- */
.index { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(28px, 5vw, 64px); }
.index li { border-top: 1px solid var(--line); }
.index a { display: grid; grid-template-columns: 1fr auto; gap: 4px 18px; padding: 22px 0; text-decoration: none; color: var(--ink); }
.index a:hover h3 { color: var(--brand-ink); }
.index h3 { font-size: 1.3rem; transition: color .15s ease; }
.index p { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: .95rem; }
.index .price { font-family: var(--display); font-weight: 500; color: var(--brand-ink); white-space: nowrap; font-size: 1.05rem; }

/* ---- full-bleed photo band ---- */
.band-photo { position: relative; color: #fff; overflow: hidden; background: var(--navy); }
.band-photo > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.band-photo::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7,9,14,.95) 0%, rgba(7,9,14,.7) 45%, rgba(7,9,14,.1) 100%); z-index: 1; }
.band-photo .wrap { position: relative; z-index: 2; padding-top: clamp(80px, 11vw, 150px); padding-bottom: clamp(80px, 11vw, 150px); }
.band-photo h2 { color: #fff; max-width: 15em; margin-bottom: 18px; }
.band-photo p { color: rgba(255,255,255,.86); max-width: 34em; font-size: 1.12rem; }
.band-photo .eyebrow { color: var(--sky); }
.band-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.band-links a { display: inline-flex; align-items: center; gap: 10px; padding: 12px 20px; border-radius: 6px; border: 1.5px solid rgba(255,255,255,.55); color: #fff; text-decoration: none; font-family: var(--display); font-weight: 500; }
.band-links a:hover { background: #fff; color: var(--night); border-color: #fff; }
.band-links svg { width: 16px; height: 16px; }

/* ---- navy facts band ---- */
.band-navy { background: var(--electric); color: #fff; }
.band-navy .eyebrow { color: var(--night); }
.band-navy h2 { color: #fff; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; list-style: none; padding: 0; }
.stats li { border-top: 1.5px solid rgba(255,255,255,.45); padding-top: 22px; }
.stats b { display: block; font-family: var(--display); font-style: italic; font-weight: 700; font-size: clamp(2.4rem, 4.6vw, 3.6rem); line-height: 1.05; color: #fff; }
.stats b small { font-size: .45em; font-weight: 600; color: var(--night); margin-left: 6px; }
.stats span { display: block; margin-top: 10px; color: var(--night); font-size: .98rem; line-height: 1.55; }

/* ---- spec sheet: the brief's who / by whom / how long / how much ---- */
.spec { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; margin: 0; border-top: 1.5px solid var(--ink); }
.spec div { padding: 20px 20px 22px 0; }
.spec div + div { padding-left: 20px; border-left: 1px solid var(--line); }
.spec dt { font-size: .86rem; color: var(--muted); font-weight: 500; margin-bottom: 6px; }
.spec dd { margin: 0; font-family: var(--display); font-weight: 500; font-size: 1.15rem; line-height: 1.4; color: var(--ink); }
.spec dd small { display: block; font-family: var(--body); font-weight: 400; font-size: .86rem; color: var(--muted); margin-top: 2px; }

/* ---- two-column prose sections ---- */
.cols { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(28px, 5vw, 80px); align-items: start; }
.cols h2 { position: sticky; top: 110px; }
/* Grid children default to min-width:auto, so a wide table would stretch the
   column past the phone screen instead of scrolling inside .table-wrap. */
.cols > *, .hero-grid > *, .feature > *, .form-shell > *, .branches > *, .cta-final .wrap > * { min-width: 0; }
.ticks { list-style: none; padding: 0; display: grid; gap: 14px; }
.ticks li { position: relative; padding-left: 34px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .55em; width: 18px; height: 10px; border-left: 2.5px solid var(--brand); border-bottom: 2.5px solid var(--brand); transform: rotate(-45deg); }

/* ---- numbered steps (a real sequence) ---- */
.steps { list-style: none; padding: 0; display: grid; gap: 0; counter-reset: step; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 64px 1fr; gap: 18px; padding: 22px 0; border-top: 1px solid var(--line); }
.steps li::before { content: counter(step, decimal-leading-zero); font-family: var(--display); font-weight: 500; font-size: 1.5rem; color: var(--brand-ink); line-height: 1.2; }
.steps h4 { margin-bottom: 4px; }
.steps p { margin: 0; color: var(--muted); }

/* ---- tables ---- */
.table-wrap { position: relative; overflow-x: auto; margin: 8px 0 18px; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 1rem; min-width: 440px; }
th { text-align: left; font-weight: 600; font-size: .86rem; color: var(--muted); padding: 12px 16px 12px 0; border-bottom: 1.5px solid var(--ink); white-space: nowrap; }
td { padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); vertical-align: top; font-variant-numeric: tabular-nums; }
td:first-child { font-weight: 600; color: var(--ink); }
.scroll-hint { display: none; font-size: .85rem; color: var(--muted); margin-top: -8px; }

/* ---- callouts ---- */
.note { border-left: 3px solid var(--brand); background: var(--tint-2); padding: 16px 20px; border-radius: 0 12px 12px 0; margin: 18px 0; font-size: .98rem; }
.note-warn { border-left-color: var(--warn-bar); background: var(--warn-bg); color: var(--warn-ink); }
.note-warn strong { color: var(--warn-ink); }
.note p:last-child { margin: 0; }

/* coming-soon state for booking features (BOOKING_LIVE off) */
.soon-badge { display: inline-block; font-family: var(--display); font-weight: 500; font-size: .9rem; color: #7A4300; background: #FFE9C7; border-radius: 999px; padding: 4px 14px; margin-bottom: 12px; }
.note-soon { border-left-color: var(--warn-bar); background: var(--warn-bg); color: var(--warn-ink); margin: 0 0 26px; }
.note-soon strong { color: var(--warn-ink); }
.note-soon .pills { margin-top: 12px; }
button.pill:disabled, .btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

/* ---- FAQ ---- */
.faq { border-top: 1.5px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 20px; padding: 22px 0; font-family: var(--display); font-weight: 500; font-size: 1.15rem; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--body); font-weight: 400; font-size: 1.6rem; line-height: 1; color: var(--brand-ink); flex: none; }
.faq details[open] summary::after { content: "–"; }
.faq .a { padding: 0 0 22px; color: var(--ink-2); max-width: 46rem; }
.faq .a p:last-child { margin: 0; }

/* ---- galleries ---- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.gallery .photo { aspect-ratio: 3 / 2; border-radius: 16px; }
.gallery figure { margin: 0; }
.gallery figcaption { font-size: .86rem; color: var(--muted); margin-top: 8px; }

/* port galleries (ACL) keep people whole */
.gallery-port { grid-template-columns: repeat(4, 1fr); }
.gallery-port .photo { aspect-ratio: 4 / 5; }

/* ---- equipment ---- */
.equip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; list-style: none; padding: 0; }
.equip .photo { aspect-ratio: 1; border-radius: 16px; margin-bottom: 12px; }
.equip h4 { font-size: 1rem; margin-bottom: 4px; }
.equip p { font-size: .9rem; color: var(--muted); margin: 0; }

/* ---- people / roles ---- */
.roles { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(18px, 3vw, 36px); list-style: none; padding: 0; }
.roles h3 { margin: 14px 0 6px; font-size: 1.25rem; }
.roles p { margin: 0; color: var(--muted); font-size: .96rem; }
.roles .photo { aspect-ratio: 4 / 5; }
.doctors { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(28px, 5vw, 64px); }
.doctors li { border-top: 1px solid var(--line); padding: 22px 0; }
.doctors h3 { font-size: 1.22rem; margin-bottom: 4px; }
.doctors p { margin: 0; color: var(--muted); font-size: .95rem; }
.doctors .area { display: inline-block; font-size: .82rem; font-weight: 600; color: var(--brand-ink); margin-bottom: 8px; }

/* ---- branches ---- */
.branches { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(20px, 3vw, 36px); }
.branch { display: grid; gap: 16px; }
.branch .photo { aspect-ratio: 3 / 2; }
.branch h3 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); }
.branch p { margin: 0; color: var(--muted); }
.branch .pills { margin-top: 6px; }
.info { margin: 0; display: grid; gap: 0; border-top: 1.5px solid var(--ink); }
.info div { display: grid; grid-template-columns: 9rem 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.info dt { color: var(--muted); font-size: .92rem; font-weight: 500; }
.info dd { margin: 0; color: var(--ink); }
.avail { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.avail li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: .98rem; }
.avail li span:last-child { color: var(--muted); }
.avail a { color: var(--ink); text-decoration: none; font-weight: 500; }
.avail a:hover { color: var(--brand-ink); }

/* ---- final CTA ---- */
.cta-final { background: var(--tint); }
.cta-final .wrap { display: grid; grid-template-columns: 1.2fr .8fr; gap: 32px; align-items: end; padding-top: clamp(64px, 8vw, 104px); padding-bottom: clamp(64px, 8vw, 104px); }
.cta-final h2 { margin-bottom: 14px; }
.cta-final p { margin: 0; color: var(--ink-2); }
.cta-final .pills { justify-content: flex-end; }
.cta-contacts { margin-top: 22px; font-size: .95rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 20px; }
.cta-contacts a { color: var(--ink); font-weight: 500; text-decoration: none; }

/* ---- forms (assessment request + booking) ---- */
.form-shell { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
.form-card { background: var(--page); border: 1px solid var(--line); border-radius: 8px; padding: clamp(22px, 3.4vw, 40px); box-shadow: 0 20px 50px rgba(0,0,0,.35); }
.q { border: 0; margin: 0 0 30px; padding: 0; }
.q legend, .q > label > span { display: block; font-family: var(--display); font-weight: 500; font-size: 1.15rem; color: var(--ink); margin-bottom: 4px; padding: 0; }
.q .hint { display: block; font-size: .9rem; color: var(--muted); margin-bottom: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-family: var(--body); font-size: .98rem; font-weight: 500; color: var(--ink);
  background: var(--paper); border: 1.5px solid var(--line); border-radius: 6px;
  padding: 10px 16px; cursor: pointer; line-height: 1.3; text-align: left;
}
.chip small { display: block; font-size: .8rem; font-weight: 400; color: var(--muted); }
.chip:hover { border-color: var(--electric); }
.chip[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.chip[aria-pressed="true"] small { color: rgba(255,255,255,.82); }
.chips-date .chip { min-width: 86px; text-align: center; }
.field { display: block; width: 100%; font-family: var(--body); font-size: 1.02rem; color: var(--ink); padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 6px; background: var(--paper); }
.field::placeholder { color: #5F6B7E; }
.field:focus { outline: none; border-color: var(--electric); box-shadow: 0 0 0 4px rgba(30,139,255,.25); }
textarea.field { min-height: 92px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row label > span { display: block; font-weight: 600; font-size: .95rem; color: var(--ink); margin-bottom: 6px; }
.form-error { color: #FF9B91; font-weight: 600; min-height: 1.3em; margin: 12px 0 0; }
.form-foot { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-top: 8px; }
.form-foot .pill { min-height: 56px; }
.done { text-align: left; }
.done .ref { font-family: var(--display); font-weight: 600; font-size: 2rem; color: var(--brand-ink); letter-spacing: .02em; }
.aside h3 { margin-bottom: 14px; }
.aside .steps li { grid-template-columns: 48px 1fr; padding: 16px 0; }
.aside .steps li::before { font-size: 1.15rem; }

/* ---- booking wizard (exact slot, secondary) — kept class names ---- */
.bk-step { background: var(--page); border: 1px solid var(--line); border-radius: 8px; padding: clamp(20px, 3vw, 32px); margin-bottom: 16px; }
.bk-step h2 { font-size: 1.35rem; margin-bottom: 14px; }
.bk-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.bk-pill { font-family: var(--body); font-size: .98rem; font-weight: 600; color: var(--ink); background: var(--paper); border: 1.5px solid var(--line); border-radius: 14px; padding: 12px 16px; cursor: pointer; text-align: left; min-width: 140px; line-height: 1.35; }
.bk-pill span { display: block; font-weight: 400; font-size: .82rem; color: var(--muted); margin-top: 2px; }
.bk-pill:hover { border-color: var(--electric); }
.bk-pill.active, .bk-pill[aria-pressed="true"] { border-color: var(--brand); background: var(--tint); }
.bk-pill:disabled { opacity: .4; cursor: not-allowed; }
.bk-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; }
.bk-slot { font-family: var(--display); font-weight: 500; font-size: 1.02rem; color: var(--ink); background: var(--paper); border: 1.5px solid var(--line); border-radius: 12px; padding: 11px 4px; cursor: pointer; }
.bk-slot:hover { border-color: var(--electric); }
.bk-slot.active, .bk-slot[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
#bk-form label { display: block; font-weight: 600; margin-bottom: 14px; color: var(--ink); }
#bk-form input[type=text], #bk-form input[type=tel] { width: 100%; max-width: 440px; margin-top: 6px; font-family: var(--body); font-size: 1rem; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 6px; background: var(--paper); color: var(--ink); }
#bk-form input:focus { outline: none; border-color: var(--electric); box-shadow: 0 0 0 4px rgba(30,139,255,.25); }
#bk-error { color: #FF9B91; font-weight: 600; min-height: 1.2em; }
/* compat classes still used by the booking page's own markup */
.callout { border-left: 3px solid var(--brand); background: var(--tint-2); padding: 14px 18px; border-radius: 0 12px 12px 0; margin: 14px 0; font-size: .98rem; }
.callout-green { border-left-color: #16A34A; background: #0E2418; }
.callout-blue { border-left-color: var(--brand); background: var(--tint-2); }
.callout-warn { border-left-color: var(--warn-bar); background: var(--warn-bg); color: var(--warn-ink); }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 6px; border: 1.5px solid transparent; font-family: var(--display); font-weight: 500; font-size: 1rem; text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-ink); color: #fff; }
.btn-navy { background: var(--tint); color: #fff; }
.btn-line { background: var(--line-green); color: var(--night); }
.btn-ghost { background: transparent; color: var(--ink); border-color: rgba(255,255,255,.45); }
.btn:disabled { opacity: .55; cursor: wait; }
.card { background: var(--page); border: 1px solid var(--line); border-radius: 8px; padding: 24px; }
.page-hero { padding: clamp(36px, 5vw, 64px) 0 12px; }
.page-hero h1 { margin-bottom: 14px; }
.page-hero p { max-width: 40em; color: var(--ink-2); }
.breadcrumb { font-size: .9rem; color: var(--muted); margin-bottom: 14px; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.block { padding: 24px 0; }
.container { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }

/* ---- footer ---- */
.site-footer { background: #040609; border-top: 1px solid var(--line); color: rgba(255,255,255,.74); font-size: .95rem; }
.ft { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 36px; padding: 72px 0 48px; }
.site-footer h3 { color: #fff; font-size: 1rem; font-family: var(--display); font-weight: 500; margin-bottom: 14px; }
.site-footer a { color: rgba(255,255,255,.9); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer ul { list-style: none; display: grid; gap: 8px; }
.site-footer .logo { color: #fff; margin-bottom: 16px; }
.site-footer .logo-mark { color: var(--electric); }
.site-footer .logo-word span { color: var(--sky); }
.ft-base { border-top: 1px solid rgba(255,255,255,.14); padding: 20px 0 28px; font-size: .86rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; }

/* ---- sticky mobile action bar ---- */
.mbar { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--page); border-top: 1px solid var(--line); padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); gap: 10px; }
.mbar .pill { flex: 1; justify-content: center; min-height: 50px; padding: 0 14px; }
.mbar .pill-line { flex: 0 0 auto; }

/* ---- responsive ---- */
@media (max-width: 1080px) {
  .nav a { padding: 8px 8px; font-size: .93rem; }
  .equip { grid-template-columns: repeat(3, 1fr); }
  .spec { grid-template-columns: repeat(3, 1fr); }
  .spec div:nth-child(4) { padding-left: 0; border-left: 0; }
  .spec div:nth-child(n+4) { border-top: 1px solid var(--line); }
  .ft { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 920px) {
  .nav, .hd > .pill { display: none; }
  .menu { display: block; }
  .hero-grid, .feature, .cols, .form-shell, .cta-final .wrap { grid-template-columns: 1fr; }
  .feature:nth-of-type(even) .feature-media { order: 0; }
  .cols h2 { position: static; }
  .path { grid-template-columns: 1fr 1fr; row-gap: 40px; }
  .stats { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .roles { grid-template-columns: 1fr 1fr; }
  .cta-final .pills { justify-content: flex-start; }
  .hero-photo .photo { max-height: 520px; }
  .scroll-hint { display: block; }
  .mbar { display: flex; }
  body { padding-bottom: 76px; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .index, .doctors, .branches, .avail, .form-row { grid-template-columns: 1fr; }
  .gallery, .gallery-port { grid-template-columns: 1fr 1fr; }
  .equip { grid-template-columns: 1fr 1fr; }
  .spec { grid-template-columns: 1fr 1fr; }
  .spec div, .spec div + div { padding: 16px 14px 16px 0; border-left: 0; border-top: 1px solid var(--line); }
  .spec div:nth-child(even) { padding-left: 14px; border-left: 1px solid var(--line); }
  .info div { grid-template-columns: 1fr; gap: 2px; }
  .hero-stack .photo:nth-child(2) { margin-top: 40px; }
  .symptom { padding: 13px 18px 13px 20px; }
  .ft { grid-template-columns: 1fr; padding-top: 56px; }
  .logo-word { font-size: 1rem; }
  .steps li { grid-template-columns: 48px 1fr; }
}

/* =========================================================
   Home page (design v4) — hero, ticker, credibility strip, measurement
   ========================================================= */
.hx { position: relative; overflow: hidden; background: var(--night); }
.hx h1 { margin-bottom: 22px; font-size: clamp(2.6rem, 6.2vw, 5.4rem); line-height: 1.04; }
.hx .lead { margin-bottom: 30px; color: var(--ink-2); }
.hx-grid { display: grid; grid-template-columns: 1fr 1fr; min-height: min(86vh, 820px); }
.hx-text { position: relative; z-index: 2; align-self: center; padding: 64px clamp(20px, 4vw, 56px) 64px max(var(--gut), calc((100vw - var(--wrap)) / 2 + var(--gut))); }
.hx-text .eyebrow { letter-spacing: .08em; }
.hx-meta { margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: .92rem; color: var(--muted); }
.hx-media { position: relative; }
.hx-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 35%; }
.hx-media::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, var(--night) 0%, rgba(7,9,14,.35) 22%, rgba(7,9,14,0) 45%); }
.hx-mark { position: absolute; z-index: 1; left: -6%; top: 6%; width: min(70vw, 980px); fill: none; stroke: rgba(30,139,255,.22); stroke-width: .35; pointer-events: none; }

.ticker { overflow: hidden; white-space: nowrap; background: var(--electric); color: #fff; padding: 16px 0; }
.ticker > div { display: inline-flex; align-items: center; animation: tick 40s linear infinite; }
.ticker span { font-family: var(--display); font-style: italic; font-weight: 700; font-size: clamp(1.3rem, 2.4vw, 2rem); padding: 0 28px; }
.ticker i { width: 10px; height: 10px; background: var(--night); transform: rotate(45deg); display: inline-block; }
@keyframes tick { to { transform: translateX(-33.333%); } }
@media (prefers-reduced-motion: reduce) { .ticker > div { animation: none; } }

.trust { border-bottom: 1px solid var(--line); }
.trust .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px; padding-top: 22px; padding-bottom: 22px; }
.trust-label { margin: 0; font-size: .86rem; font-weight: 600; color: var(--muted); }
.trust-list { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 26px; }
.trust-list li { font-family: var(--display); font-weight: 500; font-size: 1.02rem; color: var(--ink); }

/* measurement cards (brief: Samitivej SMAP — what each test measures, how it helps) */
.measure { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 2.4vw, 32px); }
.measure li { display: flex; flex-direction: column; gap: 12px; }
.measure .photo { aspect-ratio: 4 / 3.6; }
.measure h3 { font-size: 1.3rem; }
.measure dl { margin: 0; display: grid; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; }
.measure dt { font-size: .82rem; font-weight: 600; color: var(--brand-ink); }
.measure dd { margin: 2px 0 0; color: var(--ink-2); }
.measure-fact { margin: 0; font-family: var(--display); font-weight: 500; color: var(--ink); }

@media (max-width: 920px) {
  .hx-grid { grid-template-columns: 1fr; min-height: 0; }
  .hx-media { order: -1; height: 56vh; min-height: 340px; }
  .hx-media::before { background: linear-gradient(0deg, var(--night) 0%, rgba(7,9,14,0) 45%); }
  .hx-text { padding: 8px var(--gut) 48px; }
  .hx-mark { top: 40vh; width: 140vw; left: -30vw; }
  .measure { grid-template-columns: 1fr; }
}
