/* ==========================================================================
   NexamDC — Design System v2
   Institutional healthcare · clinical neutrals, single cobalt accent,
   tight radii, tabular numerals, thin rules. No display serif, no italic.
   Reference discipline: academic medical centre + public health system.

   BRAND LAYER — single source of truth
   ------------------------------------------------------------------------
   Every brand-derived value on this site resolves from the tokens below.
   To re-skin to the official NexamDC palette, change ONLY this block:
     --brand-900/800/600/500   darker / lighter steps of the primary
     --brand                   primary (logo block, buttons, links, rules)
     --brand-100/50            tinted fills for selected + soft states
     --brand-ink               text colour on top of --brand (usually #fff)
     --mark-bg / --mark-fg     logo block background / monogram colour
   Nothing else in the stylesheet hard-codes a brand hex.

   ⚠ PENDING: the values below are the provisional teal. Replace with the
   official NexamDC hex values once the brand sheet is supplied.

   ICON LANGUAGE — one system, no exceptions
   ------------------------------------------------------------------------
   24×24 grid · 1.5px stroke · round caps and joins · no fills · currentColor
   Enforced globally at §1b so hand-written inline SVG cannot drift.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  /* Surfaces — cool, clinical, not warm */
  --bg: #f6f8fa;
  --surface: #ffffff;
  --surface-2: #f0f3f6;
  --surface-3: #e7ecf1;

  /* Ink */
  --ink: #0b1f2a;
  --ink-2: #34495a;
  --ink-3: #5d7181;
  --ink-4: #8b9aa7;

  /* Rules — the primary structural device */
  --rule: #d3dce4;
  --rule-soft: #e6ebf0;
  --rule-strong: #b6c3ce;

  /* Brand — one deep cobalt/teal, used sparingly */
  --brand-900: #0a3444;
  --brand-800: #10485c;
  --brand: #14556b;
  --brand-600: #1c6b85;
  --brand-500: #2a809c;
  --brand-100: #dce9ef;
  --brand-50: #eef4f7;

  /* Logo lockup */
  --mark-bg: var(--brand);
  --mark-fg: #ffffff;

  /* Semantic — clinical only, no decorative accent hue */
  --positive: #1c6b4f;
  --positive-bg: #e9f3ee;
  --caution: #8a5a06;
  --caution-bg: #fbf3e2;
  --critical: #9c2a2a;
  --critical-bg: #fbeceb;

  /* Type — one family, no display serif */
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* Space — 4pt base */
  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 24px;
  --s6: 32px;
  --s7: 48px;
  --s8: 64px;
  --s9: 88px;
  --s10: 112px;

  /* Radii — restrained. Institutional means near-square. */
  --r-xs: 2px;
  --r-sm: 4px;
  --r-md: 6px;
  --r-lg: 8px;

  /* Elevation — shadow is a last resort; rules do the work */
  --shadow-sm: 0 1px 2px rgba(11, 31, 42, 0.06);
  --shadow-md: 0 4px 16px -8px rgba(11, 31, 42, 0.18);

  /* Motion — minimal, functional */
  --ease: cubic-bezier(0.2, 0, 0.2, 1);
  --fast: 120ms var(--ease);
  --base: 200ms var(--ease);

  --max: 1200px;
  --header-h: 64px;
}

/* ---------- 1b. Icon language ----------
   Presentation attributes rank below any author rule, so these two lines
   normalise every hand-written inline glyph on the site to the brand
   weight: 1.5px on a 24 grid. The logo lockup is exempt (.mark-svg) —
   a logotype carries more weight than a UI icon on purpose. */
svg[stroke-width]:not(.mark-svg),
svg [stroke-width] {
  stroke-width: 1.5;
}

/* Round joins everywhere — the brand's icons have no corners. */
svg[stroke-linecap] {
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- 2. Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  font-feature-settings: "kern" 1, "cv05" 1, "ss01" 1;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
h4,
p,
figure,
ul,
ol,
table {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  border: 0;
  background: none;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--brand-600);
  outline-offset: 2px;
  border-radius: 1px;
}

::selection {
  background: var(--brand-100);
  color: var(--brand-900);
}

/* Tabular numerals everywhere numbers are compared */
.num,
.stat__n,
.score-num,
.rank-n,
.metric__v,
td,
.eta {
  font-variant-numeric: tabular-nums;
}

/* ---------- 3. Type scale ---------- */
h1,
h2,
h3 {
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-wrap: balance;
}

.display-xl {
  font-size: clamp(2.1rem, 3.6vw, 3.1rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.028em;
}

.display-lg {
  font-size: clamp(1.6rem, 2.4vw, 2.05rem);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.022em;
}

.display-md {
  font-size: clamp(1.2rem, 1.7vw, 1.45rem);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

/* No decorative eyebrow rule — a small caps label is enough */
.eyebrow {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* The brand name inside a section label keeps its own weight so the
   lockup still reads as a name, not as a label fragment. */
.eyebrow__brand {
  color: var(--brand);
  font-weight: 700;
}

.lead {
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink-2);
  max-width: 62ch;
}

.muted {
  color: var(--ink-3);
}

.tiny {
  font-size: 0.75rem;
  line-height: 1.5;
}

.zh {
  font-size: 0.88em;
  color: var(--ink-3);
  letter-spacing: 0.01em;
}

.mono-label {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  text-transform: uppercase;
}

/* ---------- 4. Layout ---------- */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--s5);
}

.wrap--narrow {
  max-width: 780px;
}

.section {
  padding-block: clamp(48px, 6vw, 80px);
}

.section--rule {
  border-top: 1px solid var(--rule);
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: var(--s5) var(--s6);
  margin-bottom: var(--s6);
  padding-bottom: var(--s4);
  border-bottom: 1px solid var(--rule);
}

.section-head__text {
  max-width: 660px;
}

.section-head h2 {
  margin-top: var(--s2);
}

.section-head p {
  margin-top: var(--s3);
}

/* ---------- 5. Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}

.site-header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--s6);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
}

.logo__mark {
  width: 28px;
  height: 28px;
  border-radius: var(--r-sm);
  background: var(--mark-bg);
  display: grid;
  place-items: center;
  color: var(--mark-fg);
  flex-shrink: 0;
}

.logo__type {
  font-size: 1.0625rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--ink);
}

/* "DC" — the qualifier carries the brand colour, and since it is set in
   caps inside a mixed-case wordmark it needs its own tracking. */
.logo__type span {
  color: var(--brand);
  letter-spacing: -0.005em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
}

.nav__link {
  position: relative;
  padding: 8px 11px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-2);
  border-radius: var(--r-sm);
  transition: color var(--fast), background var(--fast);
}

/* drawer-only extras: booking CTA + phone (hidden on desktop row) */
.nav__cta,
.nav__tel {
  display: none;
}

.nav__link:hover {
  color: var(--ink);
  background: var(--surface-2);
}

.nav__link[aria-current="page"] {
  color: var(--brand);
  font-weight: 600;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--s2);
  margin-left: var(--s3);
}

/* Language switcher — a two-state segment, not a dropdown. The active
   language reads as filled; the other stays available in one click. */
.lang {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  padding: 2px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface-2);
  flex-shrink: 0;
}

.lang__globe {
  display: grid;
  place-items: center;
  padding: 0 5px 0 4px;
  color: var(--ink-4);
}

.lang__btn {
  appearance: none;
  font-family: inherit;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  line-height: 1.5;
  padding: 3px 7px;
  border: 0;
  border-radius: 2px;
  background: transparent;
  color: var(--ink-3);
  cursor: pointer;
  transition: background var(--fast), color var(--fast);
}

.lang__btn:hover {
  color: var(--ink);
  background: var(--surface-3);
}

.lang__btn.is-active,
.lang__btn[aria-pressed="true"] {
  background: var(--brand);
  color: var(--mark-fg);
}

.lang__btn:focus-visible {
  outline: 2px solid var(--brand-500);
  outline-offset: 1px;
}

/* Buttons — rectangular, no pill */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 16px;
  border-radius: var(--r-sm);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.005em;
  white-space: nowrap;
  transition: background var(--fast), color var(--fast), border-color var(--fast);
  border: 1px solid transparent;
}

.btn:active {
  transform: translateY(0.5px);
}

.btn--primary {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

.btn--primary:hover {
  background: var(--brand-800);
  border-color: var(--brand-800);
}

.btn--clay,
.btn--accent {
  background: var(--brand-800);
  color: #fff;
  border-color: var(--brand-800);
}

.btn--clay:hover,
.btn--accent:hover {
  background: var(--brand-900);
  border-color: var(--brand-900);
}

.btn--ghost {
  border-color: var(--rule);
  background: var(--surface);
  color: var(--ink);
}

.btn--ghost:hover {
  border-color: var(--rule-strong);
  background: var(--surface-2);
}

.btn--quiet {
  background: transparent;
  color: var(--brand);
  border-color: transparent;
  padding-inline: 8px;
}

.btn--quiet:hover {
  background: var(--brand-50);
}

.btn--sm {
  min-height: 32px;
  padding: 0 11px;
  font-size: 0.75rem;
}

.btn--onDark {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
}

.btn--onDark:hover {
  background: rgba(255, 255, 255, 0.16);
}

.btn--full {
  width: 100%;
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--surface);
  place-items: center;
}

/* ---------- 6. Hero ---------- */
.hero {
  background: var(--surface);
  border-bottom: 1px solid var(--rule);
  padding-top: clamp(32px, 4.5vw, 56px);
  padding-bottom: clamp(36px, 5vw, 64px);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
}

.hero__title {
  margin-top: var(--s3);
}

.hero__lede {
  margin-top: var(--s4);
  font-size: 1.0625rem;
  line-height: 1.62;
  color: var(--ink-2);
  max-width: 46ch;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s2) var(--s4);
  margin-top: var(--s5);
  padding-top: var(--s4);
  border-top: 1px solid var(--rule-soft);
  font-size: 0.8125rem;
  color: var(--ink-2);
}

.hero__meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--positive);
  flex-shrink: 0;
}

/* Care console — a form, not a product mockup */
.console {
  background: var(--surface);
  border: 1px solid var(--rule-strong);
  border-radius: var(--r-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.console__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s3);
  padding: 9px 14px;
  border-bottom: 1px solid var(--rule);
  background: var(--surface-2);
}

.console__label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--positive);
  flex-shrink: 0;
}

.console__body {
  padding: 16px;
}

.field {
  display: block;
}

.field + .field {
  margin-top: var(--s4);
  padding-top: var(--s4);
  border-top: 1px solid var(--rule-soft);
}

.field__label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s2);
  margin-bottom: 7px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink);
}

.location-row {
  display: flex;
  align-items: center;
  gap: var(--s3);
  padding: 9px 9px 9px 11px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.location-row__text {
  min-width: 0;
  flex: 1;
}

.location-row__city {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.location-row__sub {
  display: block;
  font-size: 0.72rem;
  color: var(--ink-3);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 30px;
  padding: 0 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--surface);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--brand);
  transition: background var(--fast), border-color var(--fast);
  flex-shrink: 0;
}

.icon-btn:hover {
  background: var(--brand-50);
  border-color: var(--brand-100);
}

.icon-btn[disabled] {
  opacity: 0.55;
  cursor: progress;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 10px 11px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  transition: border-color var(--fast), box-shadow var(--fast);
}

.input-wrap:focus-within {
  border-color: var(--brand-600);
  box-shadow: 0 0 0 3px rgba(28, 107, 133, 0.1);
}

.input-wrap svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--ink-4);
}

.input-wrap textarea {
  border: 0;
  background: none;
  resize: none;
  width: 100%;
  min-height: 46px;
  font-size: 0.9rem;
  line-height: 1.5;
  outline: none;
  color: var(--ink);
}

.input-wrap textarea::placeholder {
  color: var(--ink-4);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 9px;
}

.chip {
  padding: 4px 9px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--surface);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: all var(--fast);
  min-height: 28px;
}

.chip:hover {
  border-color: var(--rule-strong);
  background: var(--surface-2);
  color: var(--ink);
}

.chip[aria-pressed="true"],
.chip.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.console__foot {
  display: flex;
  align-items: center;
  gap: var(--s3);
  margin-top: var(--s4);
}

.console__foot .tiny {
  color: var(--ink-3);
  line-height: 1.45;
  max-width: 26ch;
}

/* Result panel */
.result {
  margin-top: var(--s4);
  border-top: 1px solid var(--rule);
  padding-top: var(--s4);
}

.result__empty {
  display: grid;
  gap: 5px;
}

.result__empty p:last-child {
  font-size: 0.8125rem;
  color: var(--ink-3);
  line-height: 1.55;
}

.result__card {
  border: 1px solid var(--rule);
  border-left: 2px solid var(--brand);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  background: var(--surface);
  padding: 14px;
  animation: fade 240ms var(--ease) both;
}

@keyframes fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.result__tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 7px;
  border-radius: var(--r-xs);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  color: var(--brand-800);
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.result__name {
  margin-top: 9px;
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: -0.012em;
}

.result__zh {
  font-size: 0.78rem;
  color: var(--ink-3);
  margin-top: 1px;
}

.result__metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: var(--s3);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
}

.metric__k {
  font-size: 0.6875rem;
  color: var(--ink-3);
  margin-bottom: 1px;
}

.metric__v {
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.3;
}

.result__why {
  margin-top: var(--s3);
  padding: 9px 11px;
  border-radius: var(--r-sm);
  background: var(--surface-2);
  font-size: 0.78rem;
  line-height: 1.55;
  color: var(--ink-2);
}

.result__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: var(--s3);
}

/* ---------- 7. Stat strip ---------- */
.strip {
  background: var(--surface-2);
  border-bottom: 1px solid var(--rule);
}

.strip__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.stat {
  padding: var(--s5) var(--s5);
  border-left: 1px solid var(--rule);
}

.stat:first-child {
  border-left: 0;
  padding-left: 0;
}

.stat__n {
  font-size: clamp(1.5rem, 2.2vw, 1.9rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.stat__n small {
  font-size: 0.55em;
  font-weight: 500;
  color: var(--ink-3);
  margin-left: 1px;
}

.stat__l {
  margin-top: 6px;
  font-size: 0.7813rem;
  color: var(--ink-3);
  line-height: 1.4;
}

/* ---------- 8. Rankings ---------- */
.rank-toolbar {
  display: flex;
  align-items: center;
  gap: var(--s3);
  flex-wrap: wrap;
  margin-bottom: var(--s4);
  padding-bottom: var(--s3);
  border-bottom: 1px solid var(--rule-soft);
}

/* Segmented control — rectangular, bordered */
.tabs {
  display: inline-flex;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--surface);
}

.tab {
  padding: 7px 14px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: background var(--fast), color var(--fast);
  min-height: 32px;
  border-right: 1px solid var(--rule);
}

.tab:last-child {
  border-right: 0;
}

.tab:hover {
  background: var(--surface-2);
}

.tab[aria-selected="true"] {
  background: var(--brand);
  color: #fff;
  font-weight: 600;
}

.select {
  height: 34px;
  padding: 0 30px 0 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--surface)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%235d7181' stroke-width='2.6'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 10px center;
  appearance: none;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
}

.dept-row {
  display: none;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: var(--s4);
}

.dept-row.is-open {
  display: flex;
}

.dept-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--surface);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: all var(--fast);
  min-height: 30px;
}

.dept-chip:hover {
  border-color: var(--rule-strong);
  background: var(--surface-2);
}

.dept-chip.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

/* Table */
.rank-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--rule);
}

.rank-table thead th {
  padding: 9px 12px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: var(--surface-2);
  border-bottom: 1px solid var(--rule);
  white-space: nowrap;
}

.rank-table tbody tr {
  border-bottom: 1px solid var(--rule-soft);
  transition: background var(--fast);
}

.rank-table tbody tr:last-child {
  border-bottom: 0;
}

.rank-table tbody tr:hover {
  background: var(--brand-50);
}

.rank-table td {
  padding: 12px;
  vertical-align: middle;
  font-size: 0.8125rem;
}

.col-rank {
  width: 46px;
}

.rank-n {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-4);
  font-family: var(--mono);
}

.rank-n.top {
  color: var(--brand);
}

.h-name {
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--ink);
}

.h-zh {
  font-size: 0.75rem;
  color: var(--ink-3);
  margin-top: 1px;
}

.h-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 5px;
}

.tag {
  padding: 1px 6px;
  border-radius: var(--r-xs);
  background: var(--surface-2);
  border: 1px solid var(--rule-soft);
  font-size: 0.6875rem;
  color: var(--ink-3);
  line-height: 1.5;
  white-space: nowrap;
}

.tag--intl {
  background: var(--positive-bg);
  border-color: #cfe4d9;
  color: var(--positive);
  font-weight: 500;
}

.col-city {
  width: 110px;
  font-size: 0.7813rem;
  color: var(--ink-2);
}

.col-score {
  width: 132px;
}

.score-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.score-num {
  font-size: 0.8125rem;
  font-weight: 600;
  min-width: 22px;
  color: var(--ink);
}

.score-bar {
  flex: 1;
  height: 3px;
  border-radius: 1px;
  background: var(--surface-3);
  overflow: hidden;
}

.score-bar i {
  display: block;
  height: 100%;
  background: var(--brand-600);
  width: 0;
  transition: width 500ms var(--ease);
}

.score-bar.is-top i {
  background: var(--brand);
}

.col-act {
  width: 76px;
  text-align: right;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7813rem;
  font-weight: 600;
  color: var(--brand);
  padding: 5px 0;
  white-space: nowrap;
}

.link-arrow:hover {
  color: var(--brand-900);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.link-arrow svg {
  transition: transform var(--fast);
}

.link-arrow:hover svg {
  transform: translateX(2px);
}

.rank-foot {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s4);
  flex-wrap: wrap;
  margin-top: var(--s4);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
}

/* ---------- 9. Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--rule);
  background: var(--surface);
}

.step {
  padding: var(--s5);
  border-left: 1px solid var(--rule);
}

.step:first-child {
  border-left: 0;
}

.step__n {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--brand);
  padding-bottom: 6px;
  border-bottom: 1px solid var(--brand-100);
  margin-bottom: var(--s3);
}

.step h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.35;
}

.step p {
  margin-top: 6px;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--ink-3);
}


/* collapsed long ranking: rows beyond 15 hidden behind a toggle row */
#rankBody.is-collapsed tr.is-extra { display: none; }

.rank-more td {
  padding: 0;
  border-top: 1px solid var(--rule);
}

.rank-more__btn {
  display: block;
  width: 100%;
  padding: 13px;
  border: 0;
  background: var(--surface-2);
  font-family: var(--sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--brand-800);
  cursor: pointer;
  transition: background var(--fast), color var(--fast);
}

.rank-more__btn:hover {
  background: var(--brand-50);
  color: var(--brand-900);
}

.rank-more__btn:focus-visible {
  outline: 2px solid var(--brand-500);
  outline-offset: -2px;
}
/* ---------- 10. Services ---------- */
.services {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.svc {
  padding: var(--s5);
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
  transition: background var(--fast);
}

.svc:hover {
  background: var(--brand-50);
}

.svc__icon {
  width: 30px;
  height: 30px;
  border-radius: var(--r-sm);
  display: grid;
  place-items: center;
  background: var(--brand-50);
  color: var(--brand);
  margin-bottom: var(--s3);
  border: 1px solid var(--brand-100);
}

.svc h3 {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
}

.svc p {
  margin-top: 5px;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--ink-3);
}

/* ---------- 11. Quotes ---------- */
.quotes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s4);
}

.quote {
  display: flex;
  flex-direction: column;
  padding: var(--s5);
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
}

.quote__mark {
  display: none;
}

.quote blockquote {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--ink-2);
  flex: 1;
}

.quote__by {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: var(--s4);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
}

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--brand-900);
  background: var(--brand-100);
  flex-shrink: 0;
}

.quote__name {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.3;
}

.quote__meta {
  display: block;
  font-size: 0.7188rem;
  color: var(--ink-3);
}

.stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: var(--brand-600);
}

/* ---------- 12. Blog / posts ---------- */
.posts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s5);
}

.post {
  display: flex;
  flex-direction: column;
  padding-top: var(--s4);
  border-top: 2px solid var(--ink);
  transition: border-color var(--fast);
}

.post:hover {
  border-top-color: var(--brand-500);
}

/* Art becomes a numbered plate, not a gradient hero */
.post__art {
  aspect-ratio: 16 / 9;
  border-radius: var(--r-sm);
  margin-bottom: var(--s3);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: var(--surface-2) !important;
  border: 1px solid var(--rule);
}

.post__art::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--rule-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule-soft) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.9;
}

.post__art span {
  position: relative;
  z-index: 1;
  font-family: var(--mono);
  font-size: 1.6rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--ink-4);
  background: var(--surface);
  padding: 4px 12px;
  border: 1px solid var(--rule);
  border-radius: var(--r-xs);
}

.art-a,
.art-b,
.art-c,
.art-d {
  background: var(--surface-2);
}

.post__cat {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--brand);
}

.post h3 {
  margin-top: 6px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.012em;
}

.post h3 a:hover {
  color: var(--brand);
}

.post p {
  margin-top: 6px;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--ink-3);
  flex: 1;
}

.post__meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: var(--s3);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
  font-size: 0.7188rem;
  color: var(--ink-3);
}

/* ---------- 13. CTA — a register, not a banner ---------- */
.cta {
  position: relative;
  background: var(--brand-900);
  color: #fff;
  border-radius: var(--r-md);
  overflow: hidden;
  padding: clamp(24px, 3.4vw, 40px);
}

.cta__grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr);
  gap: clamp(24px, 3.5vw, 48px);
  align-items: start;
}

.cta h2 {
  font-size: clamp(1.35rem, 2.1vw, 1.75rem);
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: -0.022em;
  color: #fff;
}

.cta p {
  margin-top: var(--s3);
  color: rgba(255, 255, 255, 0.74);
  font-size: 0.875rem;
  line-height: 1.65;
  max-width: 44ch;
}

.cta .eyebrow {
  color: rgba(255, 255, 255, 0.56);
}

.cta-form {
  display: grid;
  gap: 8px;
  padding: var(--s4);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--r-sm);
}

.cta-form input,
.cta-form textarea {
  width: 100%;
  padding: 9px 11px;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  background: #fff;
  color: var(--ink);
  font-size: 0.8125rem;
  outline: none;
  min-height: 38px;
}

.cta-form input::placeholder,
.cta-form textarea::placeholder {
  color: var(--ink-4);
}

.cta-form input:focus,
.cta-form textarea:focus {
  box-shadow: 0 0 0 2px #fff;
}

.cta-form textarea {
  resize: vertical;
  min-height: 68px;
}

.form-note {
  font-size: 0.6875rem;
  color: rgba(255, 255, 255, 0.56);
  line-height: 1.5;
  text-align: center;
}

.form-success {
  padding: var(--s5);
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.18);
  text-align: center;
}

.form-success strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 4px;
}

/* ---------- 14. Footer ---------- */
.site-footer {
  margin-top: clamp(40px, 6vw, 72px);
  border-top: 1px solid var(--rule);
  background: var(--surface);
  padding-top: var(--s6);
  padding-bottom: var(--s4);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.15fr;
  gap: var(--s6);
}

.footer__brand p {
  margin-top: var(--s3);
  font-size: 0.7813rem;
  line-height: 1.6;
  color: var(--ink-3);
  max-width: 32ch;
}

/* Domain line — the one place the brand is written as an address. */
.footer__brand .footer__domain {
  margin-top: var(--s2);
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.04em;
  color: var(--brand);
}

.footer__h {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: var(--s3);
}

.footer__list li + li {
  margin-top: 7px;
}

.footer__list a {
  font-size: 0.7813rem;
  color: var(--ink-2);
  transition: color var(--fast);
}

.footer__list a:hover {
  color: var(--brand);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer__list li {
  font-size: 0.7813rem;
  color: var(--ink-2);
  line-height: 1.5;
}

.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  flex-wrap: wrap;
  margin-top: var(--s6);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
  font-size: 0.7188rem;
  color: var(--ink-3);
}

.disclaimer {
  margin-top: var(--s4);
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  font-size: 0.7188rem;
  line-height: 1.6;
  color: var(--ink-3);
  background: var(--surface-2);
}

/* ---------- 15. Sub-page hero ---------- */
.page-hero {
  background: var(--surface);
  padding-top: clamp(28px, 3.6vw, 44px);
  padding-bottom: clamp(24px, 3vw, 36px);
  border-bottom: 1px solid var(--rule);
}

.page-hero__inner {
  max-width: 780px;
}

.page-hero h1 {
  margin-top: var(--s2);
}

.page-hero p {
  margin-top: var(--s3);
}

/* About */
.split {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
}

.prose p + p {
  margin-top: var(--s4);
}

.prose p {
  font-size: 0.9375rem;
  line-height: 1.72;
  color: var(--ink-2);
}

.prose h3 {
  font-size: 0.9375rem;
  font-weight: 650;
  margin-top: var(--s5);
  margin-bottom: var(--s2);
  padding-top: var(--s4);
  border-top: 1px solid var(--rule-soft);
}

.pull {
  margin-top: var(--s5);
  padding: var(--s4) var(--s5);
  border-left: 2px solid var(--brand);
  background: var(--brand-50);
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--brand-900);
}

.values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.value {
  padding: var(--s5);
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}

.value__n {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--ink-4);
  letter-spacing: 0.05em;
}

.value h3 {
  margin-top: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
}

.value p {
  margin-top: 6px;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--ink-3);
}

.team {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s4);
}

.member__photo {
  aspect-ratio: 1;
  border-radius: var(--r-sm);
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  color: var(--brand-800);
  background: var(--surface-2) !important;
  border: 1px solid var(--rule);
  margin-bottom: var(--s3);
}

.member h3 {
  font-size: 0.875rem;
  font-weight: 600;
}

.member p {
  font-size: 0.75rem;
  color: var(--ink-3);
  line-height: 1.5;
  margin-top: 2px;
}

/* FAQ */
.faq {
  border-top: 1px solid var(--rule);
  background: var(--surface);
  border-bottom: 1px solid var(--rule);
}

.faq details {
  border-bottom: 1px solid var(--rule-soft);
}

.faq details:last-child {
  border-bottom: 0;
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  padding: 14px 0;
  font-size: 0.9rem;
  font-weight: 550;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "";
  width: 9px;
  height: 9px;
  border-right: 1.5px solid var(--ink-3);
  border-bottom: 1.5px solid var(--ink-3);
  transform: rotate(45deg) translateY(-2px);
  transition: transform var(--fast);
  flex-shrink: 0;
  margin-right: 4px;
}

.faq details[open] summary::after {
  transform: rotate(225deg) translateY(-2px);
}

.faq summary:hover {
  color: var(--brand);
}

.faq p {
  padding-bottom: 16px;
  font-size: 0.8375rem;
  line-height: 1.7;
  color: var(--ink-3);
  max-width: 78ch;
}

/* ---------- 16. Blog index ---------- */
.blog-feature {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(20px, 3vw, 40px);
  align-items: center;
  padding-bottom: clamp(24px, 3vw, 40px);
  border-bottom: 1px solid var(--rule);
  margin-bottom: var(--s6);
}

.blog-feature__art {
  aspect-ratio: 4 / 3;
  border-radius: var(--r-sm);
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  background: var(--surface-2) !important;
  border: 1px solid var(--rule);
}

.blog-feature__art::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--rule-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule-soft) 1px, transparent 1px);
  background-size: 28px 28px;
}

.blog-feature__art span {
  font-family: var(--mono);
  font-size: 2rem;
  color: var(--ink-4);
  letter-spacing: 0.02em;
  position: relative;
  z-index: 1;
  background: var(--surface);
  padding: 6px 18px;
  border: 1px solid var(--rule);
  border-radius: var(--r-xs);
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s6) var(--s5);
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: var(--s6);
}

/* ---------- 17. Article ---------- */
.article-head {
  max-width: 780px;
  margin-inline: auto;
  padding-top: clamp(28px, 4vw, 48px);
}

.article-head h1 {
  margin-top: var(--s2);
}

.article-body {
  max-width: 700px;
  margin-inline: auto;
  padding-block: clamp(24px, 3vw, 40px);
}

.article-body p {
  font-size: 0.9688rem;
  line-height: 1.75;
  color: var(--ink-2);
}

.article-body p + p {
  margin-top: var(--s4);
}

.article-body h2 {
  font-size: 1.1875rem;
  font-weight: 650;
  line-height: 1.3;
  letter-spacing: -0.015em;
  margin-top: var(--s6);
  margin-bottom: var(--s3);
  padding-top: var(--s4);
  border-top: 1px solid var(--rule);
}

.article-body h3 {
  font-size: 0.9375rem;
  font-weight: 650;
  margin-top: var(--s5);
  margin-bottom: var(--s2);
}

.article-body ul,
.article-body ol {
  margin-top: var(--s3);
  display: grid;
  gap: 8px;
}

.article-body li {
  position: relative;
  padding-left: 18px;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--ink-2);
}

.article-body ul li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.7em;
  width: 4px;
  height: 4px;
  background: var(--brand-500);
}

.article-body ol {
  counter-reset: step;
}

.article-body ol li {
  counter-increment: step;
  padding-left: 26px;
}

.article-body ol li::before {
  content: counter(step) ".";
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--brand);
  line-height: 1.75;
}

.callout {
  margin-top: var(--s4);
  padding: var(--s3) var(--s4);
  border-radius: var(--r-sm);
  background: var(--surface-2);
  border: 1px solid var(--rule);
  border-left: 2px solid var(--caution);
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--ink-2);
}

.callout strong {
  display: block;
  margin-bottom: 3px;
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--caution);
  font-family: var(--mono);
  font-weight: 600;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: var(--s3);
  margin-top: var(--s4);
  padding-top: var(--s3);
  border-top: 1px solid var(--rule-soft);
  font-size: 0.75rem;
  color: var(--ink-3);
}

/* ---------- 18. Reveal — subtle, no lift ---------- */
[data-reveal] {
  opacity: 0;
  transition: opacity 400ms var(--ease);
}

[data-reveal].is-in {
  opacity: 1;
}

/* ---------- 19. Responsive ---------- */
@media (max-width: 1024px) {
  .hero__grid {
    grid-template-columns: 1fr;
    gap: var(--s6);
  }

  .services,
  .posts,
  .quotes,
  .post-grid,
  .values {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .step:nth-child(3) {
    border-left: 0;
  }

  .step:nth-child(n + 3) {
    border-top: 1px solid var(--rule);
  }

  .team {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .cta__grid {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--s5);
  }

  .strip__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat {
    border-left: 0;
    padding-left: 0;
  }

  .stat:nth-child(n + 3) {
    border-top: 1px solid var(--rule);
  }

  .section-head {
    grid-template-columns: 1fr;
    align-items: start;
  }
}

@media (max-width: 860px) {
  .nav {
    display: none;
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--s2);
    background: var(--surface);
    border-bottom: 1px solid var(--rule);
    box-shadow: var(--shadow-md);
  }

  .nav.is-open {
    display: flex;
  }

  .nav.is-open .nav__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
    padding: 12px 16px;
    background: var(--brand);
    color: var(--brand-ink, #fff);
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: var(--r-sm);
    text-decoration: none;
  }

  .nav.is-open .nav__tel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 11px 12px;
    font-family: var(--mono);
    font-size: 0.8rem;
    letter-spacing: 0.02em;
    color: var(--brand-800);
    text-decoration: none;
  }

  .nav__link {
    padding: 11px 12px;
    border-radius: var(--r-sm);
  }

  .nav-toggle {
    display: grid;
  }

  .header-actions {
    margin-left: auto;
  }

  .header-actions .btn--primary {
    display: none;
  }

  /* phone CTA no longer fits beside the switcher + hamburger */
  .header-actions .btn--quiet {
    display: none;
  }

  .split,
  .blog-feature {
    grid-template-columns: 1fr;
  }

  .values,
  .team {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .wrap {
    padding-inline: var(--s4);
  }

  .services,
  .posts,
  .quotes,
  .post-grid,
  .values,
  .steps {
    grid-template-columns: 1fr;
  }

  .steps .step {
    border-left: 0;
  }

  .steps .step + .step {
    border-top: 1px solid var(--rule);
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }

  .rank-table th:nth-child(3),
  .rank-table th:nth-child(4),
  .rank-table td:nth-child(3),
  .rank-table td:nth-child(4) {
    display: none;
  }

  .rank-table {
    border-left: 0;
    border-right: 0;
  }

  .rank-table td {
    padding: 10px 8px;
  }

  .col-score {
    width: 80px;
  }

  .hero__meta {
    font-size: 0.75rem;
    gap: var(--s2);
  }

  .console__foot {
    flex-direction: column;
    align-items: stretch;
  }

  .console__foot .tiny {
    max-width: none;
  }

  .result__metrics {
    grid-template-columns: 1fr 1fr;
  }
}

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

  [data-reveal] {
    opacity: 1;
  }
}

/* ==========================================================================
   Guide page components (v3 — freemium funnel)
   ========================================================================== */

/* Key facts strip */
.facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--rule);
  background: var(--surface);
}

.fact {
  padding: var(--s4);
  border-left: 1px solid var(--rule);
}

.fact:first-child {
  border-left: 0;
}

.fact__k {
  font-family: var(--mono);
  font-size: 0.6563rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 4px;
}

.fact__v {
  font-size: 0.8438rem;
  font-weight: 550;
  line-height: 1.45;
}

/* Photo plates — placeholders pending licensed photography */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s4);
}

.photo-plate {
  position: relative;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--rule);
  background: var(--surface-2);
  overflow: hidden;
  display: grid;
  place-items: center;
}

.photo-plate::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--rule-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule-soft) 1px, transparent 1px);
  background-size: 20px 20px;
}

.photo-plate svg {
  position: relative;
  z-index: 1;
  color: var(--ink-4);
}

.photo-plate figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.92);
  border-top: 1px solid var(--rule);
  font-size: 0.7188rem;
  font-weight: 550;
  color: var(--ink-2);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.photo-plate figcaption .mono-label {
  font-size: 0.625rem;
  flex-shrink: 0;
  padding-top: 1px;
}

/* Free badge */
.badge-free {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--r-xs);
  background: var(--positive-bg);
  border: 1px solid #cfe4d9;
  color: var(--positive);
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* Pending-verification banner */
.notice {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--rule);
  border-left: 2px solid var(--caution);
  background: var(--caution-bg);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--ink-2);
}

/* Step rows with floor tags */
.gsteps {
  border-top: 1px solid var(--rule);
}

.gstep {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: var(--s5);
  padding: var(--s4) 0;
  border-bottom: 1px solid var(--rule-soft);
}

.gstep__floor {
  font-family: var(--mono);
  font-size: 0.7188rem;
  color: var(--brand);
  line-height: 1.5;
  padding-top: 2px;
}

.gstep__floor span {
  display: block;
  color: var(--ink-4);
  font-size: 0.6563rem;
  margin-top: 2px;
}

.gstep h3 {
  font-size: 0.9rem;
  font-weight: 600;
}

.gstep p {
  margin-top: 4px;
  font-size: 0.8438rem;
  line-height: 1.62;
  color: var(--ink-2);
}

.gstep .tip {
  margin-top: 8px;
  padding: 8px 10px;
  background: var(--brand-50);
  border-left: 2px solid var(--brand-100);
  font-size: 0.7813rem;
  color: var(--ink-2);
  line-height: 1.55;
}

/* Service tier cards (conversion module) */
.tiers {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--rule);
  background: var(--surface);
}

.tier {
  padding: var(--s5);
  border-left: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
}

.tier:first-child {
  border-left: 0;
}

.tier--featured {
  background: var(--brand-50);
}

.tier__name {
  font-size: 0.9rem;
  font-weight: 600;
}

.tier__price {
  margin-top: 4px;
  font-size: 1.3rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.tier__price small {
  font-size: 0.7188rem;
  font-weight: 500;
  color: var(--ink-3);
}

.tier ul {
  margin-top: var(--s3);
  display: grid;
  gap: 6px;
  flex: 1;
}

.tier li {
  position: relative;
  padding-left: 16px;
  font-size: 0.7813rem;
  line-height: 1.5;
  color: var(--ink-2);
}

.tier li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.6em;
  width: 4px;
  height: 4px;
  background: var(--brand-500);
}

/* Add-on table */
.addons {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--rule);
}

.addons th,
.addons td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 0.8125rem;
  text-align: left;
  vertical-align: top;
}

.addons th {
  background: var(--surface-2);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-3);
  border-bottom: 1px solid var(--rule);
}

.addons td:last-child {
  font-variant-numeric: tabular-nums;
  font-weight: 550;
  white-space: nowrap;
}

@media (max-width: 860px) {
  .facts {
    grid-template-columns: 1fr 1fr;
  }
  .fact:nth-child(n + 3) {
    border-top: 1px solid var(--rule);
  }
  .fact:nth-child(3) {
    border-left: 0;
  }
  .photo-grid,
  .tiers {
    grid-template-columns: 1fr;
  }
  .tier {
    border-left: 0;
    border-top: 1px solid var(--rule);
  }
  .tier:first-child {
    border-top: 0;
  }
  .gstep {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

/* ==========================================================================
   Photography — real hospital campus images + graceful fallback tiles
   ========================================================================== */

/* ranking table: thumbnail before the hospital name */
.h-cell {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
}

.h-photo {
  width: 46px;
  height: 46px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  object-fit: cover;
  flex-shrink: 0;
  background: var(--surface-2);
}

.h-photo--mono {
  display: grid;
  place-items: center;
  background: var(--brand-50);
  color: var(--brand);
  font-weight: 650;
  font-size: 1rem;
  line-height: 1;
}

/* triage result card: campus banner under the hospital name */
.result__photo {
  margin: 12px 0 2px;
}

.result__photo img {
  display: block;
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
}

/* guide page: plates holding real photography */
.photo-plate.has-photo::before {
  display: none; /* drop the grid pattern behind real images */
}

.photo-plate.has-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 680px) {
  .h-photo {
    width: 38px;
    height: 38px;
  }

  .result__photo img {
    height: 120px;
  }
}

/* --------------------------------------------------------------------------
   Guide page — embedded map & transport block
   -------------------------------------------------------------------------- */
.map-embed {
  position: relative;
  min-height: 260px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--surface-2);
}

.map-embed iframe {
  display: block;
  width: 100%;
  height: 260px;
  border: 0;
  filter: saturate(0.82) contrast(0.98);
}

.loc-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

#transportList .fact__v {
  font-size: 0.84rem;
}

@media (max-width: 680px) {
  .map-embed {
    min-height: 200px;
  }

  .map-embed iframe {
    height: 200px;
  }
}

/* map embed: fallback layer behind the iframe */
.map-embed iframe {
  position: relative;
  z-index: 1;
}

.map-fallback {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-align: center;
  padding: 20px;
  color: var(--brand);
  background:
    linear-gradient(var(--surface-2), var(--surface-2)) padding-box,
    repeating-linear-gradient(0deg, transparent, transparent 23px, var(--rule) 23px, var(--rule) 24px),
    repeating-linear-gradient(90deg, transparent, transparent 23px, var(--rule) 23px, var(--rule) 24px),
    var(--bg);
  background-size: 100% 100%, 24px 24px, 24px 24px, auto;
}

.map-fallback strong {
  font-size: 0.95rem;
  color: var(--ink);
}

.map-fallback .tiny {
  max-width: 34ch;
  color: var(--ink-3);
}

.map-embed iframe.is-failed {
  display: none;
}

/* --------------------------------------------------------------------------
   Guide page — illustrated layer: hero photo, dept tiles, visit-route sketch
   -------------------------------------------------------------------------- */
.guide-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: clamp(20px, 3vw, 40px);
  align-items: center;
}

.guide-hero > div {
  min-width: 0;
}

.hero-photo {
  margin: 0;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-sm, 0 1px 2px rgba(11, 31, 42, 0.06));
}

.hero-photo img {
  display: block;
  width: 100%;
  height: 210px;
  object-fit: cover;
}

.hero-photo figcaption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-top: 1px solid var(--rule);
  font-size: 0.75rem;
  color: var(--ink-3);
}

@media (max-width: 860px) {
  .guide-hero {
    grid-template-columns: 1fr;
  }

  .hero-photo img {
    height: 170px;
  }
}

/* department strength tiles */
.dept-strip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

@media (max-width: 860px) {
  .dept-strip {
    grid-template-columns: repeat(2, 1fr);
  }
}

.dept-tile {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
}

.dept-tile__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: var(--r-sm);
  background: var(--brand-50);
  color: var(--brand);
  border: 1px solid var(--brand-100);
}

.dept-tile__icon svg {
  width: 28px;
  height: 28px;
}

.dept-tile__name {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
}

.dept-tile__score {
  width: 100%;
  height: 3px;
  border-radius: 2px;
  background: var(--rule);
  overflow: hidden;
}

.dept-tile__score i {
  display: block;
  height: 100%;
  background: var(--brand);
}

/* visit route sketch */
.journey {
  margin: 6px 0 clamp(18px, 2.5vw, 26px);
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 10px 14px 2px;
}

.journey svg {
  display: block;
  width: 100%;
  height: auto;
}

/* dept chips carry icons now */
.dept-chip svg {
  flex-shrink: 0;
}

/* hand-drawn campus plan (schematic) */
.campus-map {
  margin: clamp(22px, 3vw, 32px) 0 0;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm, 12px);
  background: #fbfaf6;
  overflow: hidden;
}

.campus-map__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 18px 0;
}

.campus-map__title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.campus-map__title svg {
  color: var(--brand);
  flex-shrink: 0;
}

.campus-map__note {
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}

.campus-map__canvas {
  padding: 6px 10px 0;
}

.campus-map__canvas svg.cmap {
  display: block;
  width: 100%;
  height: auto;
}

.campus-map__legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 22px;
  margin: 4px 14px 0;
  padding: 11px 4px 15px;
  border-top: 1px dashed var(--rule);
  font-size: 0.78rem;
  color: var(--ink-2);
}

.campus-map__legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.campus-map__legend i {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  border: 1.4px solid var(--rule-strong);
  background: var(--surface-2);
  flex-shrink: 0;
}

.campus-map__legend .lg-op i { background: var(--brand-100); border-color: var(--brand); }
.campus-map__legend .lg-intl i { background: #e0efec; border-color: #2a7a6f; }
.campus-map__legend .lg-er i { background: #f6ece2; border-color: #b3813f; }

.campus-map__legend .lg-gate svg {
  color: var(--brand);
}

.campus-map__legend .lg-metro i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 0;
  background: var(--brand);
  color: #fff;
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 600;
}

/* svg element classes */
.cmap .cm-b { fill: var(--surface-2); stroke: var(--rule-strong); stroke-width: 1.4; }
.cmap .cm-b--op { fill: var(--brand-100); stroke: var(--brand); }
.cmap .cm-b--intl { fill: #e0efec; stroke: #2a7a6f; }
.cmap .cm-b--er { fill: #f6ece2; stroke: #b3813f; }
.cmap .cm-road { fill: var(--surface-3); }
.cmap .cm-dash { stroke: #fff; stroke-width: 2; stroke-dasharray: 9 9; fill: none; }
.cmap .cm-path { stroke: var(--brand-500); stroke-width: 1.6; stroke-dasharray: 4 4; fill: none; }
.cmap .cm-arrow { stroke: var(--brand-500); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.cmap .cm-tree { fill: #dfe9dd; stroke: #9db89d; stroke-width: 1; }
.cmap .cm-metro { fill: var(--brand); }
.cmap .cm-metro-t { font-family: var(--mono); font-size: 11px; font-weight: 600; fill: #fff; }
.cmap text { font-family: var(--sans); fill: var(--ink-2); }
.cmap .cm-lbl { font-size: 12.5px; font-weight: 600; fill: var(--ink); }
.cmap .cm-sub { font-family: var(--mono); font-size: 10px; fill: var(--ink-3); }
.cmap .cm-street { font-size: 11px; letter-spacing: 0.22em; fill: var(--ink-3); }
.cmap .cm-poi { font-size: 11px; font-weight: 500; fill: var(--ink-2); }
.cmap .cm-note { font-size: 10.5px; font-style: italic; fill: var(--ink-3); }

@media (max-width: 640px) {
  .campus-map__head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .campus-map__legend { gap: 8px 16px; }
}

/* ==========================================================================
   TRUST LAYER — supplier network, live tracking, feedback
   ========================================================================== */

.strip--tight { border-top: 0; padding: 0; }
.strip--tight .strip__grid { border-top: 1px solid var(--rule); }

/* ---------- supplier filters ---------- */
.sup-toolbar {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  flex-wrap: wrap;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 22px;
}

.sup-toolbar > p { flex: 0 0 auto; padding-top: 12px; }

.sup-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin-left: auto;
  align-items: flex-start;
}

.sup-filter { display: flex; flex-direction: column; gap: 6px; }

.sup-filter__label {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.sup-filter__opts { display: flex; flex-wrap: wrap; gap: 6px; }

.fchip {
  padding: 4px 10px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-2);
  font-size: 0.73rem;
  line-height: 1.5;
  cursor: pointer;
  transition: all var(--fast);
}
.fchip:hover { border-color: var(--rule-strong); background: var(--surface-2); }
.fchip.is-active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.sup-filter--end .select { height: 30px; font-size: 0.75rem; min-width: 150px; }

/* ---------- supplier cards ---------- */
.sup-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

@media (max-width: 900px) {
  .sup-list { grid-template-columns: 1fr; }
  .sup-filters { margin-left: 0; }
}

.sup-card {
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 18px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  transition: border-color var(--fast), box-shadow var(--fast);
}
.sup-card:hover { border-color: var(--rule-strong); }

.sup-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }

.sup-card__id { display: flex; gap: 11px; align-items: flex-start; }

.sup-card__mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 8px;
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  color: var(--brand-800);
  font-size: 0.95rem;
  font-weight: 600;
}

.sup-card__name { font-size: 1rem; font-weight: 600; color: var(--ink); line-height: 1.3; }
.sup-card__sub {
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--ink-3);
  line-height: 1.5;
}

.sup-card__score {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: 5px 9px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--rule);
}
.sup-card__score-n {
  font-family: var(--mono);
  font-size: 1.24rem;
  font-weight: 500;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.sup-card__score-l {
  font-size: 0.6rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.sup-card__score.is-top { background: var(--brand-50); border-color: var(--brand-100); }
.sup-card__score.is-top .sup-card__score-n { color: var(--brand-800); }

.sup-card__metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px 16px;
}

.sup-metric { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; align-items: baseline; }
.sup-metric__k { font-size: 0.72rem; color: var(--ink-3); }
.sup-metric__v {
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.sup-metric__bar {
  grid-column: 1 / -1;
  height: 2px;
  background: var(--rule);
  border-radius: 2px;
  overflow: hidden;
}
.sup-metric__bar i { display: block; height: 100%; background: var(--brand-500); }

.sup-card__badges { display: flex; flex-wrap: wrap; gap: 5px; }

.vbadge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--surface-2);
  border: 1px solid var(--rule);
  font-size: 0.66rem;
  color: var(--ink-2);
}
.vbadge svg { color: var(--brand-500); flex-shrink: 0; }

.sup-card__note {
  font-size: 0.79rem;
  color: var(--ink-2);
  line-height: 1.6;
  padding-left: 10px;
  border-left: 2px solid var(--brand-100);
}

.sup-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 0.7rem;
  color: var(--ink-3);
}
.sup-card__meta span { display: inline-flex; align-items: center; gap: 4px; }

.sup-card__foot {
  margin-top: auto;
  padding-top: 13px;
  border-top: 1px dashed var(--rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sup-card__price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.sup-card__price b { font-family: var(--mono); font-size: 0.95rem; color: var(--ink); }
.sup-card__price span { font-size: 0.7rem; color: var(--ink-3); }
.sup-card__slots { color: var(--brand-800) !important; }

.sup-card__actions { display: flex; gap: 8px; flex-wrap: wrap; }

.sup-breakdown {
  border-top: 1px dashed var(--rule);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.sup-weight {
  display: grid;
  grid-template-columns: 1fr 90px 42px;
  align-items: center;
  gap: 10px;
  font-size: 0.71rem;
  color: var(--ink-2);
}
.sup-weight__bar { height: 4px; background: var(--rule); border-radius: 2px; overflow: hidden; }
.sup-weight__bar i { display: block; height: 100%; background: var(--brand); }
.sup-weight__v {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.sup-breakdown__hosp { font-size: 0.7rem; color: var(--ink-3); margin-top: 4px; }

.sup-empty {
  grid-column: 1 / -1;
  padding: 34px 0;
  text-align: center;
  color: var(--ink-3);
  font-size: 0.86rem;
}

/* ---------- scoring model ---------- */
.sup-model { max-width: 780px; }
.sup-model__rows { display: flex; flex-direction: column; gap: 12px; }
.sup-model__row {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 16px;
  align-items: center;
  font-size: 0.84rem;
  color: var(--ink-2);
}
.sup-model__bar { height: 6px; background: var(--rule); border-radius: 3px; overflow: hidden; }
.sup-model__bar i { display: block; height: 100%; background: var(--brand); }

@media (max-width: 620px) {
  .sup-model__row { grid-template-columns: 1fr; gap: 6px; }
}

/* ---------- tracking ---------- */
.trk-head__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 34px;
  flex-wrap: wrap;
}

.trk-head__copy { max-width: 620px; }

.trk-head__status {
  flex-shrink: 0;
  min-width: 210px;
  padding: 15px 18px;
  border: 1px solid var(--brand-100);
  border-radius: var(--r-sm);
  background: var(--brand-50);
}

.trk-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.63rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-800);
}
.trk-live i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-500);
  animation: trkPulse 1.8s ease-out infinite;
}
@keyframes trkPulse {
  0% { box-shadow: 0 0 0 0 rgba(42, 128, 156, 0.45); }
  70% { box-shadow: 0 0 0 7px rgba(42, 128, 156, 0); }
  100% { box-shadow: 0 0 0 0 rgba(42, 128, 156, 0); }
}

.trk-head__now { margin-top: 6px; font-size: 1.06rem; font-weight: 600; color: var(--ink); }
.trk-head__next { margin-top: 4px; font-size: 0.74rem; color: var(--ink-2); }

.trk-meta {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin-top: 28px;
  padding: 15px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.trk-meta__item { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.trk-meta__v {
  font-size: 0.79rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 860px) {
  .trk-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
  .trk-head__status { width: 100%; }
}

.trk-stages-wrap { margin-top: 24px; }

.trk-progress { height: 3px; background: var(--rule); border-radius: 2px; overflow: hidden; }
.trk-progress i { display: block; height: 100%; background: var(--brand); transition: width 600ms ease; }

.trk-stages {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-top: 12px;
  padding: 0;
  list-style: none;
}

.trk-stage { display: flex; align-items: center; gap: 7px; font-size: 0.74rem; color: var(--ink-3); }

.trk-stage__dot {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1.5px solid var(--rule-strong);
  background: var(--surface);
  color: #fff;
}
.trk-stage.is-done .trk-stage__dot { background: var(--brand); border-color: var(--brand); }
.trk-stage.is-done .trk-stage__label { color: var(--ink); }
.trk-stage.is-active .trk-stage__dot {
  border-color: var(--brand);
  background: var(--surface);
  box-shadow: 0 0 0 3px var(--brand-50);
}
.trk-stage.is-active .trk-stage__label { color: var(--brand-800); font-weight: 600; }

@media (max-width: 640px) {
  .trk-stages { grid-template-columns: repeat(3, 1fr); row-gap: 10px; }
}

.trk-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.95fr);
  gap: 20px;
  align-items: start;
}

@media (max-width: 980px) {
  .trk-grid { grid-template-columns: 1fr; }
}

.trk-col-side { display: flex; flex-direction: column; gap: 16px; }

.trk-panel {
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 20px;
}

.trk-panel__title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 14px;
}

/* escort card */
.escort { display: flex; gap: 12px; align-items: flex-start; }
.escort__avatar {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-family: var(--mono);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.escort__body { min-width: 0; }
.escort__name { font-size: 0.98rem; font-weight: 600; color: var(--ink); }
.escort__meta { margin-top: 3px; font-size: 0.73rem; color: var(--ink-2); }
.escort__langs { margin-top: 5px; font-family: var(--mono); font-size: 0.7rem; color: var(--ink-3); }
.escort__badges { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.escort__actions { display: flex; flex-direction: column; gap: 8px; margin-top: 15px; }

/* node timeline */
.trk-nodes {
  list-style: none;
  margin: 6px 0 0;
  padding: 0 0 0 4px;
  position: relative;
}
.trk-nodes::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 12px;
  bottom: 18px;
  width: 1px;
  background: var(--rule);
}

.trk-node { position: relative; padding: 0 0 20px 32px; }
.trk-node:last-child { padding-bottom: 0; }

.trk-node__head { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

.trk-node__dot {
  position: absolute;
  left: 0;
  top: 1px;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid var(--rule-strong);
  background: var(--surface);
  color: #fff;
  z-index: 1;
}

.trk-node__time {
  font-family: var(--mono);
  font-size: 0.73rem;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.trk-node__title { font-size: 0.88rem; font-weight: 600; color: var(--ink-2); }

.trk-node__state {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.61rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 2px 6px;
  border-radius: 3px;
  border: 1px solid var(--rule);
}

.trk-node__body { margin-top: 6px; }
.trk-node__note { font-size: 0.79rem; color: var(--ink-2); line-height: 1.65; }

.trk-node__facts { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 7px; }
.trk-fact {
  font-family: var(--mono);
  font-size: 0.63rem;
  color: var(--ink-3);
  padding: 2px 7px;
  border-radius: 3px;
  background: var(--surface-2);
}

.trk-node.is-done .trk-node__dot { background: var(--brand); border-color: var(--brand); }
.trk-node.is-done .trk-node__title { color: var(--ink); }
.trk-node.is-done .trk-node__state { color: var(--brand-800); border-color: var(--brand-100); background: var(--brand-50); }

.trk-node.is-active .trk-node__dot {
  border-color: var(--brand);
  border-width: 5px;
  box-shadow: 0 0 0 4px var(--brand-50);
}
.trk-node.is-active .trk-node__title { color: var(--brand-800); }
.trk-node.is-active .trk-node__state { color: #fff; background: var(--brand); border-color: var(--brand); }
.trk-node.is-active .trk-node__note { color: var(--ink); }

.trk-node.is-pending .trk-node__note { color: var(--ink-3); }

.trk-node.is-late .trk-node__dot { background: var(--critical); border-color: var(--critical); }
.trk-node.is-late .trk-node__state { color: var(--critical); border-color: #e6c3c1; background: var(--critical-bg); }

/* promises + fees */
.trk-promises { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.trk-promises li { display: flex; gap: 8px; font-size: 0.79rem; color: var(--ink-2); line-height: 1.65; }
.trk-promises svg { flex-shrink: 0; margin-top: 4px; color: var(--brand-500); }

.trk-fees { width: 100%; border-collapse: collapse; font-size: 0.79rem; }
.trk-fees th {
  text-align: left;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
  padding: 12px 0 5px;
}
.trk-fees th:first-child { padding-top: 0; }
.trk-fees td { padding: 4px 0; color: var(--ink-2); }
.trk-fees .num { text-align: right; font-family: var(--mono); color: var(--ink); font-variant-numeric: tabular-nums; }
.trk-fees .is-total td {
  padding-top: 11px;
  border-top: 1px solid var(--rule);
  font-weight: 600;
  color: var(--ink);
}

/* report strip */
.trk-report {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
  padding: 26px 28px;
  border: 1px solid var(--brand-100);
  border-radius: var(--r-sm);
  background: var(--brand-50);
}
.trk-report__actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- feedback ---------- */
.fb-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.9fr);
  gap: 22px;
  align-items: start;
}
@media (max-width: 980px) {
  .fb-grid { grid-template-columns: 1fr; }
}

.fb-form {
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 24px;
}

.fb-field { border: 0; padding: 0; margin: 0 0 20px; }
.fb-field--row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
@media (max-width: 620px) {
  .fb-field--row { grid-template-columns: 1fr; }
}

.fb-legend {
  display: block;
  font-size: 0.79rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 9px;
  padding: 0;
}

.fb-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 620px) {
  .fb-types { grid-template-columns: 1fr; }
}

.fb-type {
  position: relative;
  text-align: left;
  padding: 10px 12px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-size: 0.79rem;
  color: var(--ink-2);
  cursor: pointer;
  transition: all var(--fast);
}
.fb-type:hover { border-color: var(--rule-strong); background: var(--surface-2); }
.fb-type.is-active {
  border-color: var(--brand);
  background: var(--brand-50);
  color: var(--brand-800);
  font-weight: 600;
}

.fb-type__flag {
  display: inline-block;
  margin-right: 7px;
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--critical-bg);
  color: var(--critical);
  font-family: var(--mono);
  font-size: 0.58rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  vertical-align: 1px;
}

.fb-textarea,
.fb-input {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-family: inherit;
  font-size: 0.82rem;
  color: var(--ink);
  resize: vertical;
}
.fb-textarea:focus,
.fb-input:focus { outline: 2px solid var(--brand-500); outline-offset: 1px; border-color: var(--brand-500); }

.fb-attach {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border: 1px dashed var(--rule-strong);
  border-radius: var(--r-sm);
  font-size: 0.73rem;
  color: var(--ink-3);
  cursor: pointer;
}
.fb-attach:hover { border-color: var(--brand-500); color: var(--ink-2); }
.fb-attach__icon {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: 1rem;
  line-height: 1;
}

.fb-error {
  margin: 0 0 12px;
  padding: 9px 12px;
  border-left: 2px solid var(--critical);
  background: var(--critical-bg);
  color: var(--critical);
  font-size: 0.78rem;
}

.fb-panel {
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 20px;
  margin-bottom: 16px;
}

.fb-sla { width: 100%; border-collapse: collapse; font-size: 0.76rem; }
.fb-sla th {
  text-align: left;
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
}
.fb-sla td { padding: 9px 0; border-bottom: 1px solid var(--rule); color: var(--ink-2); }
.fb-sla tr:last-child td { border-bottom: 0; }
.fb-sla .num { text-align: right; font-family: var(--mono); color: var(--ink); white-space: nowrap; }

.fb-flow { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.fb-flow__item { display: flex; gap: 11px; font-size: 0.78rem; color: var(--ink-2); line-height: 1.6; }
.fb-flow__n {
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid var(--brand-100);
  background: var(--brand-50);
  color: var(--brand-800);
  font-family: var(--mono);
  font-size: 0.63rem;
}

.fb-ok {
  display: flex;
  gap: 14px;
  padding: 22px;
  border: 1px solid var(--brand-100);
  border-radius: var(--r-sm);
  background: var(--brand-50);
  margin-top: 18px;
}
.fb-ok__icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
}
.fb-ok__title { font-size: 1rem; font-weight: 600; color: var(--ink); }
.fb-ok__body { margin-top: 6px; font-size: 0.82rem; color: var(--ink-2); line-height: 1.65; }
.fb-ok__urgent {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--brand-800);
}
.fb-ok button { margin-top: 14px; }

/* hidden guards: author display rules above must not defeat the hidden attribute */
[hidden] { display: none !important; }

/* ---------- sample-record notice (tracking page) ---------- */
.trk-sample {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin: 0 0 clamp(24px, 3.4vw, 36px);
  padding: 16px 20px;
  background: #fbf7ee;
  border: 1px solid #e9dcc0;
  border-left: 3px solid #b3813f;
  border-radius: var(--r-sm);
}

.trk-sample__tag {
  flex-shrink: 0;
  margin-top: 1px;
  padding: 3px 8px;
  border: 1px solid #e0d0a8;
  border-radius: 3px;
  background: #fff;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #7d5a24;
  white-space: nowrap;
}

.trk-sample__copy { min-width: 0; }

.trk-sample__title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.5;
}

.trk-sample__body {
  margin-top: 6px;
  font-size: 0.79rem;
  line-height: 1.72;
  color: var(--ink-2);
  max-width: 92ch;
}

/* static, non-pulsing progress flag — deliberately not a "live" indicator */
.trk-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #7d5a24;
}

.trk-flag::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 1px;
  background: #b3813f;
}

.trk-lock {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--rule);
  font-size: 0.72rem;
  line-height: 1.65;
  color: var(--ink-3);
}

/* ---------- "what you get" + sample-vs-real ---------- */
.trk-sec__head { margin-bottom: clamp(18px, 2.6vw, 26px); }

.trk-expect {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  overflow: hidden;
}

.trk-expect__item {
  background: var(--surface);
  padding: 20px 18px;
}

.trk-expect__n {
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  color: var(--brand-500);
}

.trk-expect__t {
  margin-top: 9px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
}

.trk-expect__b {
  margin-top: 7px;
  font-size: 0.78rem;
  line-height: 1.68;
  color: var(--ink-2);
}

@media (max-width: 900px) {
  .trk-expect { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .trk-expect { grid-template-columns: 1fr; }
}

.trk-cmp__scroll { overflow-x: auto; }

.trk-cmp {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  font-size: 0.79rem;
}

.trk-cmp thead th {
  padding: 0 14px 10px;
  text-align: left;
  font-family: var(--mono);
  font-size: 0.61rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ink-3);
  border-bottom: 1px solid var(--rule-strong);
  white-space: nowrap;
}

.trk-cmp thead th.is-real { color: var(--brand-800); }

.trk-cmp tbody th,
.trk-cmp tbody td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  line-height: 1.62;
  border-bottom: 1px solid var(--rule);
}

.trk-cmp tbody th {
  width: 17%;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

.trk-cmp tbody td { color: var(--ink-3); }
.trk-cmp tbody td.is-real {
  color: var(--ink);
  background: var(--brand-50);
}
.trk-cmp tbody tr:last-child th,
.trk-cmp tbody tr:last-child td { border-bottom: 0; }

@media (max-width: 640px) {
  .trk-sample { flex-direction: column; gap: 9px; }
}

/* ==========================================================================
   BOOKING SHEET — reached from every "book" affordance on the site
   ========================================================================== */

html.is-bk-open { overflow: hidden; }

.bk-sheet {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  justify-content: flex-end;
}

.bk-sheet__scrim {
  position: absolute;
  inset: 0;
  background: rgba(9, 24, 30, 0.46);
  animation: bkFade 180ms ease-out;
}

@keyframes bkFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.bk-sheet__panel {
  position: relative;
  width: min(540px, 100%);
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--surface);
  box-shadow: -24px 0 70px rgba(9, 24, 30, 0.28);
  animation: bkIn 260ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

@keyframes bkIn {
  from { transform: translateX(26px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@media (max-width: 620px) {
  .bk-sheet__panel { width: 100%; }
}

.bk-sheet__x {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--rule);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink-2);
  cursor: pointer;
  transition: all var(--fast);
}
.bk-sheet__x:hover { border-color: var(--rule-strong); color: var(--ink); background: var(--surface-2); }

.bk-sheet__body { padding: 30px 28px 34px; }

@media (max-width: 620px) {
  .bk-sheet__body { padding: 26px 20px 32px; }
}

.bk-kicker {
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand-500);
}

.bk-title {
  margin-top: 9px;
  font-size: 1.34rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  line-height: 1.32;
  max-width: 24ch;
}

.bk-lede {
  margin-top: 9px;
  font-size: 0.84rem;
  line-height: 1.68;
  color: var(--ink-2);
}

.bk-picked {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-top: 14px;
  padding: 7px 8px 7px 12px;
  border: 1px solid var(--brand-100);
  border-radius: 999px;
  background: var(--brand-50);
  font-size: 0.79rem;
}

.bk-picked__k {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand-800);
  opacity: 0.7;
}

.bk-picked__v { font-weight: 600; color: var(--brand-900); }

.bk-picked__x {
  border: 0;
  background: transparent;
  padding: 0 4px;
  font-size: 0.72rem;
  color: var(--brand-800);
  text-decoration: underline;
  cursor: pointer;
}

.bk-form { margin-top: 22px; display: flex; flex-direction: column; gap: 18px; }

.bk-field { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.bk-field--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.bk-field--3 { display: grid; grid-template-columns: 1.1fr 1fr 1fr; gap: 14px; }

@media (max-width: 620px) {
  .bk-field--2 { grid-template-columns: 1fr; }
  .bk-field--3 { grid-template-columns: 1fr 1fr; }
  .bk-field--3 > label:first-child { grid-column: 1 / -1; }
}

.bk-legend {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink);
  padding: 0;
}

.bk-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-2);
}

.bk-input {
  width: 100%;
  padding: 10px 11px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-family: inherit;
  font-size: 0.84rem;
  color: var(--ink);
}
.bk-input:focus {
  outline: 2px solid var(--brand-500);
  outline-offset: 1px;
  border-color: var(--brand-500);
}
.bk-textarea { resize: vertical; line-height: 1.6; }
.bk-hint { font-size: 0.68rem; color: var(--ink-3); font-weight: 400; }

/* tier chooser */
.bk-tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }

@media (max-width: 460px) {
  .bk-tiers { grid-template-columns: 1fr; }
}

.bk-tier {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 11px 12px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  text-align: left;
  cursor: pointer;
  transition: all var(--fast);
}
.bk-tier:hover { border-color: var(--rule-strong); background: var(--surface-2); }
.bk-tier.is-active {
  border-color: var(--brand);
  background: var(--brand-50);
  box-shadow: inset 0 0 0 1px var(--brand);
}

.bk-tier__name { font-size: 0.8rem; font-weight: 600; color: var(--ink); }
.bk-tier__price {
  font-family: var(--mono);
  font-size: 0.92rem;
  color: var(--brand-800);
  font-variant-numeric: tabular-nums;
}
.bk-tier__note { font-size: 0.67rem; line-height: 1.5; color: var(--ink-3); }

.bk-error {
  margin: 0;
  padding: 9px 12px;
  border-left: 2px solid var(--critical);
  background: var(--critical-bg);
  color: var(--critical);
  font-size: 0.78rem;
}

.bk-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  padding: 13px 18px;
  border: 1px solid var(--brand-900);
  border-radius: var(--r-sm);
  background: var(--brand-900);
  color: #fff;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--fast), transform var(--fast);
}
.bk-submit:hover { background: var(--brand); border-color: var(--brand); }
.bk-submit:active { transform: translateY(1px); }

.bk-privacy,
.bk-demo {
  margin: 0;
  font-size: 0.7rem;
  line-height: 1.6;
  color: var(--ink-3);
}

.bk-demo {
  padding-top: 10px;
  border-top: 1px dashed var(--rule);
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.01em;
}

/* success state */
.bk-ok { padding-top: 26px; }

.bk-ok__mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  margin-bottom: 16px;
}

.bk-next {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.bk-next li {
  position: relative;
  padding-left: 18px;
  font-size: 0.81rem;
  line-height: 1.62;
  color: var(--ink-2);
}

.bk-next li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1.5px solid var(--brand-500);
}

.bk-ok__actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 22px; }

/* ---------- six-phase process grid (homepage #how) ----------
   Independent bordered cards with a real gutter: the full-bleed preview
   strips need air between rows, so the old shared-rule grid is gone. */
.steps--phases {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px;
  border: 0;
  background: none;
}

.steps--phases .step {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 22px 22px 190px; /* bottom reserve = preview strip 172 + 18 gap */
  border: 1px solid var(--rule);
}

.step__when {
  margin-bottom: 11px;
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.steps--phases .step__n { margin-bottom: 12px; }
.steps--phases .step h3 { font-size: 0.98rem; line-height: 1.35; }
.steps--phases .step p { margin-top: 7px; font-size: 0.8rem; line-height: 1.62; color: var(--ink-2); }

.step__see {
  display: block;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px dashed var(--rule);
  font-family: var(--mono);
  font-size: 0.66rem;
  line-height: 1.55;
  color: var(--brand-800);
}

.steps--phases .step__see { margin-top: auto; }

/* ---- step preview: a legible thumbnail of the screen behind the step ----
   Every card carries one, so the six cells stay perfectly aligned. The
   panel is HTML/CSS (no image request), sized in em so the lightbox can
   scale the same markup up to a readable size with one font-size change. */
.step__media {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 172px;
  border-top: 1px solid var(--rule);
  background: var(--surface);
  overflow: hidden;
}

.pk-btn {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: zoom-in;
}

.step__media.has-act .pk-btn { height: calc(100% - 38px); }

.pk-btn:focus-visible {
  outline: 2px solid var(--brand-500);
  outline-offset: -2px;
}

.pk {
  display: flex;
  flex-direction: column;
  height: 100%;
  font-size: 12px;
  line-height: 1.4;
  color: var(--ink-2);
  background: var(--surface);
}

.pk__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8em;
  flex: none;
  padding: 0.55em 0.95em;
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
  font-family: var(--mono);
  font-size: 0.82em;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.pk__path { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

.pk__tag {
  flex: none;
  padding: 0.18em 0.5em;
  border: 1px solid var(--brand-100);
  border-radius: var(--r-xs);
  background: var(--brand-50);
  color: var(--brand-800);
  letter-spacing: 0.04em;
}

.pk__body {
  display: flex;
  flex-direction: column;
  gap: 0.42em;
  flex: 1;
  min-height: 0;
  padding: 0.8em 0.95em;
}

/* label / value rows */
.pk__row {
  display: grid;
  grid-template-columns: 4.9em minmax(0, 1fr);
  gap: 0.7em;
  align-items: baseline;
}

.pk__k {
  font-family: var(--mono);
  font-size: 0.78em;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-4);
}

.pk__v {
  font-size: 1.02em;
  color: var(--ink-2);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.pk__v--key { color: var(--brand-900); font-weight: 600; }
.pk__num { font-family: var(--mono); font-variant-numeric: tabular-nums; color: var(--ink); }

/* supplier rows with score + composition bar */
.pk__sup { display: block; }

.pk__sup-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6em;
}

.pk__nm {
  font-size: 1.02em;
  font-weight: 600;
  color: var(--ink);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.pk__sc {
  flex: none;
  padding: 0.1em 0.5em;
  border-radius: var(--r-xs);
  background: var(--brand);
  color: var(--brand-ink, #fff);
  font-family: var(--mono);
  font-size: 0.82em;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.pk__sc--ok { background: var(--positive-bg); color: var(--positive); border: 1px solid transparent; }

.pk__meter {
  display: flex;
  gap: 2px;
  height: 3px;
  margin-top: 0.25em;
  background: var(--surface-3);
  border-radius: 1px;
  overflow: hidden;
}

.pk__seg { display: block; height: 100%; }
.pk__seg--a { background: var(--brand-500); }
.pk__seg--b { background: var(--brand-100); }
.pk__seg--c { background: var(--rule-strong); }

.pk__legend {
  font-family: var(--mono);
  font-size: 0.74em;
  letter-spacing: 0.04em;
  color: var(--ink-4);
}

/* escort assignment */
.pk__who {
  display: flex;
  align-items: center;
  gap: 0.7em;
  padding-bottom: 0.6em;
  border-bottom: 1px solid var(--rule);
}

.pk__av {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.4em;
  height: 2.4em;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--brand-900);
  font-family: var(--mono);
  font-size: 0.82em;
  letter-spacing: 0.04em;
}

.pk__who-t { display: flex; flex-direction: column; min-width: 0; }
.pk__who-t b { font-size: 0.98em; font-weight: 600; color: var(--ink); }
.pk__who-t em { font-style: normal; font-size: 0.8em; color: var(--ink-3); }

/* node timeline */
.pk__tl { display: flex; flex-direction: column; gap: 0.32em; }

.pk__node {
  display: grid;
  grid-template-columns: 3.4em 0.9em minmax(0, 1fr);
  gap: 0.55em;
  align-items: center;
}

.pk__t {
  font-family: var(--mono);
  font-size: 0.8em;
  font-variant-numeric: tabular-nums;
  color: var(--ink-4);
  text-align: right;
}

.pk__dot {
  position: relative;
  width: 0.62em;
  height: 0.62em;
  margin-left: 0.14em;
  border: 1.5px solid var(--brand-500);
  border-radius: 50%;
  background: var(--surface);
}

.pk__node--done .pk__dot { background: var(--brand-500); }

.pk__node + .pk__node .pk__dot::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 1.5px);
  width: 1px;
  height: 1.15em;
  margin-left: -0.5px;
  background: var(--rule);
}

.pk__lbl {
  font-size: 1.02em;
  color: var(--ink-2);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* document rows */
.pk__files { display: flex; flex-direction: column; gap: 0.3em; }

.pk__file {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6em;
  padding-bottom: 0.2em;
  border-bottom: 1px dotted var(--rule);
}

.pk__fname {
  display: flex;
  align-items: center;
  gap: 0.4em;
  font-size: 1em;
  color: var(--ink-2);
  overflow: hidden;
  white-space: nowrap;
}

.pk__fname::before {
  content: "";
  flex: none;
  width: 0.62em;
  height: 0.78em;
  border: 1.5px solid var(--brand-500);
  border-radius: 1px;
}

.pk__pill {
  flex: none;
  font-family: var(--mono);
  font-size: 0.74em;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  text-transform: uppercase;
}

/* feedback chips */
.pk__chips { display: flex; flex-wrap: wrap; gap: 0.35em; }

.pk__chips i {
  padding: 0.2em 0.55em;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: var(--surface);
  font-style: normal;
  font-size: 0.82em;
  color: var(--ink-2);
}

.pk__chips i.is-on {
  border-color: var(--brand);
  background: var(--brand-50);
  color: var(--brand-900);
  font-weight: 600;
}

/* the action bar: a full-width strip locked to the bottom of the preview,
   visually attached to the thumbnail — no floating chip, nothing occluded */
.pk__go {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: 38px;
  padding: 0 14px;
  border: 0;
  border-top: 1px solid var(--brand-100);
  background: var(--brand-50);
  font-family: var(--sans);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
  color: var(--brand-900);
  text-decoration: none;
  cursor: pointer;
  text-align: left;
  transition: background var(--fast), color var(--fast);
}

.pk__go svg { flex: none; transition: transform var(--fast); }
.pk__go:hover { background: var(--brand); color: #fff; }
.pk__go:hover svg { transform: translateX(2px); }
.pk__go:focus-visible { outline: 2px solid var(--brand-500); outline-offset: -2px; }

/* ---- enlarged preview (lightbox) ---- */
.peek-modal {
  position: fixed;
  inset: 0;
  z-index: 220;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.peek-modal[hidden] { display: none; }

.peek-modal__scrim {
  position: absolute;
  inset: 0;
  border: 0;
  padding: 0;
  background: rgba(11, 31, 42, 0.6);
  cursor: default;
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}

.peek-modal__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(780px, 100%);
  max-height: 86vh;
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: 0 28px 70px rgba(11, 31, 42, 0.34);
  overflow: hidden;
}

.peek-modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px 13px;
  border-bottom: 1px solid var(--rule);
}

.peek-modal__eyebrow {
  display: block;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.peek-modal__title {
  margin: 5px 0 0;
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink);
}

.peek-modal__x {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color var(--fast), color var(--fast);
}

.peek-modal__x:hover { border-color: var(--brand); color: var(--brand-900); }
.peek-modal__x:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 2px; }

.peek-modal__body {
  padding: 18px;
  overflow: auto;
  background: var(--surface-2);
}

.peek-modal__body .pk {
  height: auto;
  min-height: 200px;
  font-size: 16px;
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  background: var(--surface);
  overflow: hidden;
}

.peek-modal__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 13px 18px;
  border-top: 1px solid var(--rule);
  background: var(--surface);
}

.peek-modal__note {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.64rem;
  line-height: 1.5;
  letter-spacing: 0.03em;
  color: var(--ink-3);
  max-width: 42ch;
}

html.is-peek-open,
html.is-peek-open body { overflow: hidden; }

@media (max-width: 600px) {
  .step__media { height: 176px; }
  .pk { font-size: 11.5px; }
  .peek-modal { padding: 10px; }
  .peek-modal__body .pk { font-size: 12px; }
}

@media (max-width: 900px) {
  .steps--phases { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
  .steps--phases { grid-template-columns: 1fr; }
}

.sup-card__sample {
  font-size: 0.7rem;
  color: var(--brand-800);
  text-decoration: underline;
  text-underline-offset: 2px;
  white-space: nowrap;
}
.sup-card__sample:hover { color: var(--brand-900); }
