/* ============================================================
   HEYJA AESTHETICS — Dr. M. Havasi
   Warm Clinical Minimal — warm white × bronze × warm ink
   (Revere Clinics / Clinique La Prairie direction)

   Craft pass:
   · type: strict 1.25 modular scale (12.5/14/16/20/25/31/39/49/61/76)
     — only the hero/preloader display + brand lockup are exempt
   · one label style site-wide: 12.5px / 0.18em / uppercase
   · 7 color tokens + white; every transparency via color-mix
   · bronze TEXT on light surfaces uses --color-accent-dk (AA 4.5:1);
     --color-accent is reserved for large type, dark grounds & decoration
   · spacing on the 8pt grid; section rhythm 128px desktop / 80px mobile
   · two durations only: --dur (350ms micro) / --dur-slow (900ms reveal)
   ============================================================ */

:root {
  /* ---- the 7 color tokens + white (Emerald & Gold — from the brand emblem) ---- */
  --color-bg:        #F4F1E7;  /* warm ivory — the emblem's cream field */
  --color-surface:   #FFFFFF;
  --color-border:    #E0DAC8;  /* warm sage hairline */
  --color-accent:    #B0934C;  /* gold — decoration, large type, on-dark */
  --color-accent-dk: #6F5D2D;  /* deep gold for small text on light (AA) */
  --color-accent-lt: #EFEAD8;  /* soft gold-cream highlight */
  --color-ink:       #223A1E;  /* deep botanical green (emblem forest) */
  --color-ink-2:     #495341;  /* green-grey secondary text */

  /* derived — no new hex values */
  --color-ink-3:  color-mix(in srgb, var(--color-ink) 62%, var(--color-bg)); /* muted, still AA */
  --color-on-dark: var(--color-bg);

  /* legacy aliases (referenced from js/blog-data.js + js/gallery-data.js) */
  --grey: var(--color-ink-3);

  /* ---- type ---- */
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;
  --font-script:  'Pinyon Script', cursive;
  --font-fa:      'Vazirmatn', Tahoma, sans-serif;
  /* legacy aliases kept so nothing silently falls back */
  --serif: var(--font-display);
  --sans: var(--font-body);
  --script: var(--font-script);
  --fa: var(--font-fa);

  /* modular scale — ratio 1.25 */
  --fs-12: 12.5px;
  --fs-14: 14px;
  --fs-16: 16px;
  --fs-20: 20px;
  --fs-25: 25px;
  --fs-31: 31px;
  --fs-39: 39px;
  --fs-49: 49px;
  --fs-61: 61px;
  --fs-76: 76px;

  /* the one label style */
  --track-label: 0.18em;

  /* ---- space + shape (8pt grid) ---- */
  --radius:    2px;
  --space-xs:  8px;
  --space-sm:  16px;
  --space-md:  24px;
  --space-lg:  32px;
  --space-xl:  64px;
  --space-2xl: 96px;
  --section-pad: 128px;

  --shadow-sm: 0 1px 3px color-mix(in srgb, var(--color-ink) 6%, transparent);
  --shadow-md: 0 4px 16px color-mix(in srgb, var(--color-ink) 8%, transparent);

  --gutter: clamp(24px, 4vw, 64px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 350ms;       /* micro-interactions */
  --dur-slow: 900ms;  /* reveals (mirrors the GSAP reveal timing) */
}

@media (max-width: 820px) {
  :root { --section-pad: 80px; }
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: var(--fs-16);
  background: var(--color-bg);
  color: var(--color-ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--color-accent-dk); color: var(--color-surface); }

/* slim palette-matched scrollbar */
html { scrollbar-width: thin; scrollbar-color: var(--color-border) var(--color-bg); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--color-bg); }
::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: 8px;
  border: 2px solid var(--color-bg);
}
::-webkit-scrollbar-thumb:hover { background: var(--color-accent); }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* one gentle grade so any admin-uploaded photo sits in the palette */
.portrait-frame__img,
.ba__img img,
.featured__media img,
.article__hero img {
  filter: saturate(0.92) contrast(1.02);
}

/* custom focus ring — never the UA default, never removed */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: var(--radius);
}

.container {
  width: min(1200px, 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* ---------- typography ---------- */

.kicker {
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-accent-dk);
  margin-bottom: var(--space-md);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}
.kicker::before {
  content: "";
  width: 40px;
  height: 1px;
  background: var(--color-accent);
}
.kicker--gold { color: var(--color-accent-dk); }

.h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-49);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--color-ink);
  max-width: 20ch;
}
.h2 em {
  font-style: italic;
  color: var(--color-accent);
  font-weight: 300;
}
.h2--light { color: var(--color-ink); } /* light theme: all headings are ink */

.lead {
  font-family: var(--font-display);
  font-size: var(--fs-20);
  font-style: italic;
  line-height: 1.55;
  margin: var(--space-md) 0 var(--space-sm);
  color: var(--color-ink-2);
}

.body-copy {
  max-width: 65ch;
  color: var(--color-ink-2);
  font-size: var(--fs-16);
}

.script {
  font-family: var(--font-script);
  font-weight: 400;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  font-family: var(--font-body);
  font-size: var(--fs-12);
  font-weight: 500;
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  padding: 16px 32px;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius);
  color: var(--color-accent-dk);
  background: transparent;
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
  will-change: transform;
}
.btn:hover { background: var(--color-accent-lt); border-color: var(--color-accent-dk); color: var(--color-accent-dk); }

.btn--gold { background: var(--color-accent-dk); border-color: var(--color-accent-dk); color: var(--color-surface); }
.btn--gold:hover { background: color-mix(in srgb, var(--color-accent-dk) 82%, var(--color-ink)); border-color: color-mix(in srgb, var(--color-accent-dk) 82%, var(--color-ink)); color: var(--color-surface); }
.btn--ghost { background: transparent; }
.btn--small { padding: 8px 24px; min-height: 44px; }
.btn--big { padding: 16px 48px; }

/* ---------- monogram ---------- */

.mono { width: 44px; height: 44px; color: var(--color-accent); }
.mono--lg { width: 84px; height: 84px; }
.mono--cta {
  width: clamp(110px, 14vw, 170px);
  height: auto;
  margin-inline: auto;
  color: var(--color-accent);
  opacity: 0.55;
}

/* ---------- preloader (dark splash → dark hero, no flash) ---------- */

.preloader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: var(--color-ink);
  display: grid;
  place-items: center;
}
.preloader__inner { text-align: center; }
.preloader__mark { display: flex; justify-content: center; margin-bottom: var(--space-md); }
.preloader__mark svg { opacity: 0; transform: scale(0.85) rotate(-8deg); }
.preloader__word {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: var(--fs-39);
  letter-spacing: 0.14em;  /* Latin brand lockup — exempt from label tracking */
  margin-left: 0.14em;     /* optically recenter the tracking */
  color: var(--color-on-dark);
  overflow: hidden;
  direction: ltr;          /* Latin brand stays LTR in RTL mode */
  white-space: nowrap;
}
/* brand emblem (assets/logo.png) — replaces the abstract monogram in the
   big lockups; scales cleanly and works on the dark grounds it sits on */
.brand-logo { width: 44px; height: auto; }
.brand-logo--lg { width: 96px; }
.footer__brand .brand-logo { width: 64px; }
.nav__logo { width: 40px; flex-shrink: 0; }
.preloader__word span {
  display: inline-block;
  transform: translateY(110%);
}
.preloader__bar {
  width: min(220px, 50vw);
  height: 1px;
  background: color-mix(in srgb, var(--color-on-dark) 16%, transparent);
  margin: var(--space-lg) auto 0;
}
.preloader__bar i {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--color-accent);
}

/* ---------- cursor (desktop only) ---------- */

.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor {
    display: block;
    position: fixed;
    top: 0; left: 0;
    z-index: 999;
    pointer-events: none;
  }
  .cursor__dot {
    position: fixed;
    width: 6px; height: 6px;
    margin: -3px 0 0 -3px;
    border-radius: 50%;
    background: var(--color-accent);
  }
  .cursor__ring {
    position: fixed;
    width: 38px; height: 38px;
    margin: -19px 0 0 -19px;
    border-radius: 50%;
    border: 1px solid color-mix(in srgb, var(--color-accent) 40%, transparent);
    display: grid;
    place-items: center;
    font-size: var(--fs-12);
    letter-spacing: var(--track-label);
    text-transform: uppercase;
    color: var(--color-surface);
    transition: width var(--dur) var(--ease), height var(--dur) var(--ease),
                margin var(--dur) var(--ease), background-color var(--dur) var(--ease);
  }
  .cursor--link .cursor__ring {
    width: 56px; height: 56px;
    margin: -28px 0 0 -28px;
    background: color-mix(in srgb, var(--color-accent) 12%, transparent);
  }
  .cursor--view .cursor__ring {
    width: 72px; height: 72px;
    margin: -36px 0 0 -36px;
    background: var(--color-accent);
  }
  .cursor--view .cursor__ring::after { content: "view"; }
}

/* ---------- language toggle ---------- */

.lang-toggle {
  font-family: var(--font-fa);
  font-size: var(--fs-14);
  font-weight: 400;
  width: 44px;  /* >=44px tap target */
  height: 44px;
  flex-shrink: 0; /* nav is flex; without this it squeezes to 42px at 375px */
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-ink-2);
  cursor: pointer;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease),
              background-color var(--dur) var(--ease);
}
.lang-toggle:hover { border-color: var(--color-accent); color: var(--color-accent-dk); background: var(--color-accent-lt); }

/* ---------- nav (clinical: solid white, hairline border, sticky) ---------- */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  padding: 16px var(--gutter);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  transition: padding var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.nav--solid { padding-block: 8px; box-shadow: var(--shadow-sm); } /* floats over content once scrolled */
.nav__brand { display: flex; align-items: center; gap: var(--space-sm); }
.nav__brand .mono { width: 40px; height: 40px; }
.nav__brand-text {
  /* Latin brand lockup — exempt from the modular scale */
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.12em;
  color: var(--color-ink);
  display: flex;
  flex-direction: column;
  line-height: 1.05;
  direction: ltr; /* Latin brand stays LTR in RTL mode */
}
.nav__brand-text small {
  font-family: var(--font-body);
  font-size: 0.5rem;
  letter-spacing: 0.32em;
  color: var(--color-accent-dk);
  margin-top: 5px;
  text-transform: uppercase;
}
.nav__links { display: flex; gap: var(--space-lg); }
.nav__links a {
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-ink-2);
  position: relative;
  padding-block: 6px;
  transition: color var(--dur) var(--ease);
}
/* signature detail: bronze hairline grows under links */
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--color-accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--dur) var(--ease);
}
.nav__links a:hover { color: var(--color-ink); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__links a[aria-current="page"] { color: var(--color-accent-dk); }
.nav__links a[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }

.nav__burger {
  display: none;
  width: 44px; height: 44px;
  flex-shrink: 0; /* nav is flex; without this it squeezes to 42px at 375px */
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  cursor: pointer;
  position: relative;
  z-index: 102;
}
.nav__burger span {
  position: absolute;
  left: 11px; right: 11px;
  height: 1px;
  background: var(--color-ink);
  transition: transform var(--dur) var(--ease), top var(--dur) var(--ease);
}
.nav__burger span:nth-child(1) { top: 17px; }
.nav__burger span:nth-child(2) { top: 25px; }
.nav__burger.is-open span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { top: 21px; transform: rotate(-45deg); }

/* ---------- mobile menu ---------- */

.menu {
  position: fixed;
  inset: 0;
  z-index: 101;
  background: var(--color-bg);
  display: grid;
  place-items: center;
  clip-path: inset(0 0 100% 0);
  visibility: hidden;
}
.menu--open { clip-path: inset(0 0 0 0); visibility: visible; } /* no-GSAP fallback */
.menu__inner { text-align: center; padding: var(--space-lg); }
.menu__link {
  display: block;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-39);
  line-height: 1.5;
  color: var(--color-ink);
}
.menu__link--gold { color: var(--color-accent-dk); font-style: italic; }
.menu__foot {
  margin-top: var(--space-xl);
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-ink-3);
}

/* ---------- hero (deliberate dark exception: hosts the WebGL bloom) ---------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: 128px var(--gutter) 80px;
  background: var(--color-ink);
}
.hero__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero__veil {
  position: absolute;
  inset: 0;
  /* tonal readability fade over the canvas — not a decorative color gradient */
  background: linear-gradient(to bottom,
    color-mix(in srgb, var(--color-ink) 40%, transparent),
    color-mix(in srgb, var(--color-ink) 0%, transparent) 32%,
    color-mix(in srgb, var(--color-ink) 0%, transparent) 62%,
    var(--color-ink) 98%);
  pointer-events: none;
}
.hero__content { position: relative; z-index: 2; max-width: 1200px; margin-inline: auto; width: 100%; }
.hero__eyebrow {
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-lg);
}
.hero__title {
  /* the one clamp'd display size on the site */
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(56px, 11vw, 136px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--color-on-dark);
  margin-bottom: var(--space-lg);
}
.hero__line { display: block; overflow: hidden; padding-bottom: 0.08em; }
.hero__line--italic { font-style: italic; color: var(--color-accent); }
.hero__line .char {
  display: inline-block;
  transform: translateY(115%) rotate(4deg);
  will-change: transform;
}
.hero__sub {
  max-width: 44ch;
  color: color-mix(in srgb, var(--color-on-dark) 78%, transparent);
  font-size: var(--fs-16);
  font-weight: 300;
  margin-bottom: 0;
}
/* CTAs detach from the copy block and sit on the baseline grid */
.hero__actions { display: flex; gap: var(--space-sm); flex-wrap: wrap; margin-top: var(--space-xl); }
/* on-dark button variants (hero + cta live on ink) */
.hero .btn--ghost, .cta .btn--ghost { color: var(--color-on-dark); border-color: color-mix(in srgb, var(--color-on-dark) 40%, transparent); }
.hero .btn--ghost:hover, .cta .btn--ghost:hover { border-color: var(--color-accent); color: var(--color-accent); background: transparent; }
.hero .btn--gold, .cta .btn--gold { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-ink); }
.hero .btn--gold:hover, .cta .btn--gold:hover { background: color-mix(in srgb, var(--color-accent) 88%, var(--color-on-dark)); border-color: color-mix(in srgb, var(--color-accent) 88%, var(--color-on-dark)); color: var(--color-ink); }

.hero__signature {
  position: absolute;
  right: clamp(24px, 5vw, 80px);
  bottom: 96px;
  z-index: 2;
  text-align: right;
}
.hero__signature .script {
  font-size: clamp(31px, 3.4vw, 46px);
  color: var(--color-accent);
}
.hero__sig-sub {
  display: block;
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: color-mix(in srgb, var(--color-on-dark) 60%, transparent);
  margin-top: 8px;
}
.hero__scroll {
  position: absolute;
  left: var(--gutter);
  bottom: 32px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: color-mix(in srgb, var(--color-on-dark) 60%, transparent);
}
.hero__scroll-line {
  width: 72px;
  height: 1px;
  background: color-mix(in srgb, var(--color-accent) 35%, transparent);
  position: relative;
  overflow: hidden;
}
.hero__scroll-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-accent);
  animation: scrollLine 2.2s var(--ease) infinite; /* ambient loop — exempt from the 2-duration rule */
}
@keyframes scrollLine {
  0% { transform: translateX(-100%); }
  55% { transform: translateX(0); }
  100% { transform: translateX(100%); }
}

/* ---------- marquee ---------- */

.marquee {
  background: var(--color-accent-lt);
  color: var(--color-ink-2);
  overflow: hidden;
  padding: 16px 0;
  border-block: 1px solid var(--color-border);
}
.marquee__track { display: flex; width: max-content; animation: marquee 26s linear infinite; } /* ambient loop */
.marquee__group {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  padding-right: var(--space-lg);
  white-space: nowrap;
}
.marquee__group span {
  font-family: var(--font-display);
  font-size: var(--fs-20);
  font-style: italic;
  letter-spacing: 0.06em;
}
.marquee__group i { font-style: normal; font-size: var(--fs-12); color: var(--color-accent-dk); }
@keyframes marquee { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; }
}

/* ---------- sections (light banding: bg ↔ surface) ---------- */

.section--cream { background: var(--color-bg); color: var(--color-ink); }
.section--ink {
  background: var(--color-surface);
  color: var(--color-ink);
  border-block: 1px solid var(--color-border);
}

/* ---------- about (5/7 asymmetric, offset column) ---------- */

.about { padding: var(--section-pad) 0; }
.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--space-2xl);
  align-items: start;
}
/* deliberate asymmetry: the text column starts lower than the portrait */
.about__body { margin-top: var(--space-xl); }
.portrait-frame {
  aspect-ratio: 3 / 4;
  background: var(--color-accent-lt);
  border: 1px solid var(--color-border);
  outline: 1px solid var(--color-border);
  outline-offset: 10px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.portrait-frame__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}
.portrait-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, color-mix(in srgb, var(--color-ink) 55%, transparent), transparent 30%);
  pointer-events: none;
}
.portrait-frame__caption {
  position: absolute;
  bottom: 24px;
  font-size: var(--fs-31);
  color: var(--color-surface);
  z-index: 1;
}
.about__points { margin-top: var(--space-lg); border-top: 1px solid var(--color-border); }
.about__points li {
  display: flex;
  align-items: baseline;
  gap: var(--space-md);
  padding: 16px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: var(--fs-16);
  color: var(--color-ink-2);
}
.about__points li span {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--color-accent-dk);
  font-size: var(--fs-16);
}

/* ---------- services (open cards: hairline top + ghost number) ---------- */

.services { padding: var(--section-pad) 0; }
.services__grid {
  margin-top: var(--space-xl);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 24px; /* card-grid pattern: 24px gutters (posts/related/locations follow) */
}
.card {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--color-border);
  border-radius: 0;
  padding: var(--space-md) 0 0;
  position: relative;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.card:hover { border-top-color: var(--color-accent); transform: translateY(-2px); }
/* oversized ghost numeral, sitting behind the content */
.card__num {
  position: absolute;
  top: 16px;
  inset-inline-end: 0;
  z-index: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: var(--fs-61);
  line-height: 1;
  color: var(--color-border);
  pointer-events: none;
}
.card h3 {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-25);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--color-ink);
  margin: var(--space-sm) 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}
.card h3 small {
  font-family: var(--font-body);
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-accent-dk);
}
.card p {
  position: relative;
  z-index: 1;
  font-size: var(--fs-14);
  color: var(--color-ink-2);
  max-width: 36ch;
}
.card__deco {
  position: absolute;
  inset-inline-end: 0;
  bottom: 16px;
  font-style: normal;
  font-size: var(--fs-12);
  color: var(--color-accent-dk);
  opacity: 0;
  transform: rotate(-90deg) scale(0.6);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.card:hover .card__deco { opacity: 0.9; transform: rotate(0deg) scale(1); }

/* ---------- stats (thin band between two hairlines) ---------- */

.stats {
  background: var(--color-bg);
  color: var(--color-ink);
  border-block: 1px solid var(--color-border);
  margin-top: -1px; /* hairlines never double up against .section--ink */
  padding: var(--space-xl) 0;
}
.stats__row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
  text-align: center;
}
.stat__num {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-49);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--color-accent);
  display: block;
}
.stat__label {
  display: block;
  margin-top: var(--space-xs);
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-ink-2);
}
.stat__suffix { font-style: normal; }

/* ---------- approach (horizontal timeline: connected hairline + nodes) ---------- */

.approach { padding: var(--section-pad) 0; }
.steps {
  margin-top: var(--space-xl);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0; /* border-tops meet edge-to-edge → one continuous line */
  counter-reset: step;
}
.step {
  position: relative;
  border-top: 1px solid var(--color-border);
  padding: var(--space-md) 40px 0 0;
}
/* bronze node pinned on the timeline */
.step::before {
  content: "";
  position: absolute;
  top: -4px;
  inset-inline-start: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-accent);
}
/* oversized ghost numeral behind the step heading */
.step__num {
  position: absolute;
  top: 8px;
  inset-inline-start: -4px;
  z-index: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: var(--fs-61);
  line-height: 1;
  color: var(--color-border);
  pointer-events: none;
}
.step h3 {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--fs-20);
  letter-spacing: -0.01em;
  color: var(--color-ink);
  margin: 40px 0 var(--space-xs);
}
.step p { position: relative; z-index: 1; font-size: var(--fs-14); color: var(--color-ink-2); }

/* ---------- locations (same open-card pattern) ---------- */

.locations { padding: var(--section-pad) 0; }
.locations__grid {
  margin-top: var(--space-xl);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px 24px;
}
.loc {
  border: 0;
  border-top: 1px solid var(--color-border);
  border-radius: 0;
  padding: var(--space-lg) 0 0;
  position: relative;
  background: transparent;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.loc:hover { border-top-color: var(--color-accent); transform: translateY(-2px); }
.loc__city {
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-accent-dk);
}
.loc h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-31);
  letter-spacing: -0.01em;
  color: var(--color-ink);
  margin: var(--space-sm) 0 var(--space-xs);
}
.loc__fa {
  font-family: var(--font-fa);
  color: var(--color-ink-2);
  font-size: var(--fs-16);
  margin-bottom: var(--space-sm);
}
.loc__desc { color: var(--color-ink-2); font-size: var(--fs-14); max-width: 40ch; }
.loc__meta {
  margin-top: var(--space-lg);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-ink-3);
}
.loc__link { color: var(--color-accent-dk); transition: color var(--dur) var(--ease);
  display: inline-flex; align-items: center; min-height: 44px; } /* ≥44px tap target (a11y) */
.loc__link:hover { color: var(--color-ink); }

/* ---------- cta (dark pre-footer band) ---------- */

.cta {
  background: var(--color-ink);
  padding: var(--section-pad) 0;
  text-align: center;
}
.cta__inner { display: flex; flex-direction: column; align-items: center; }
.cta__title {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: var(--fs-76);
  line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--color-on-dark);
  margin: var(--space-lg) 0 var(--space-md);
}
.cta__title em { color: var(--color-accent); }
.cta__title [data-split] { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: 0.1em; }
.cta__title .char { display: inline-block; transform: translateY(115%); will-change: transform; }
.cta__sub { color: color-mix(in srgb, var(--color-on-dark) 70%, transparent); margin-bottom: var(--space-xl); font-size: var(--fs-16); }
.cta__actions { display: flex; gap: var(--space-sm); flex-wrap: wrap; justify-content: center; }

/* ---------- footer (dark, 12-column, wide brand column) ---------- */

.footer {
  background: var(--color-ink);
  border-top: 1px solid color-mix(in srgb, var(--color-on-dark) 8%, transparent);
  padding: var(--space-2xl) 0 var(--space-lg);
  color: var(--color-on-dark);
}
.footer__grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-lg) var(--space-md);
  padding-bottom: var(--space-xl);
}
.footer__brand { grid-column: 1 / 6; display: flex; flex-direction: column; gap: var(--space-sm); }
.footer__col { grid-column: span 2; }
.footer__col:nth-of-type(2) { grid-column: 7 / 9; }
.footer__sig { font-size: var(--fs-31); color: var(--color-accent); }
.footer__col h4 {
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}
.footer__col p { font-size: var(--fs-14); color: color-mix(in srgb, var(--color-on-dark) 70%, transparent); margin-bottom: var(--space-xs); }
.footer__col a { transition: color var(--dur) var(--ease); }
.footer__col p a { display: inline-flex; align-items: center; min-height: 44px; } /* ≥44px tap target (a11y) */
.footer__col a:hover { color: var(--color-accent); }
.footer__base {
  border-top: 1px solid color-mix(in srgb, var(--color-on-dark) 10%, transparent);
  padding-top: var(--space-md);
  display: flex;
  justify-content: space-between;
  gap: var(--space-sm);
  flex-wrap: wrap;
  font-size: var(--fs-12);
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: color-mix(in srgb, var(--color-on-dark) 55%, transparent);
}

/* ---------- reveal defaults (pre-JS state) ---------- */

[data-reveal] { opacity: 0; transform: translateY(36px); will-change: transform, opacity; }

/* JS/CDN failure fallbacks. `no-js` sits on <html> and is removed by an inline
   script on every page; `gsap-off` is added when the GSAP CDN never loaded (or
   by the preloader failsafe). Either way, all content must be readable. */
.no-js [data-reveal], .gsap-off [data-reveal] { opacity: 1 !important; transform: none !important; }
.no-js .preloader, .gsap-off .preloader { display: none; }
.gsap-off .hero__line .char, .gsap-off .cta__title .char { transform: none !important; }
.gsap-off [data-hero-fade] { opacity: 1 !important; transform: none !important; }

/* ---------- responsive ---------- */

@media (max-width: 1024px) {
  .h2 { font-size: var(--fs-39); }
  .cta__title { font-size: var(--fs-49); }
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 48px; }
  .stats__row { grid-template-columns: repeat(2, 1fr); row-gap: var(--space-lg); }
  .footer__grid { grid-template-columns: repeat(2, 1fr); }
  .footer__brand, .footer__col, .footer__col:nth-of-type(2) { grid-column: auto; }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 820px) {
  .nav__links, .nav__cta { display: none; }
  .nav__burger { display: block; }

  /* On mobile, let the signature + scroll flow after the buttons so they
     can never overlap the CTAs on short viewports. */
  .hero { padding-bottom: 56px; }
  .hero__signature {
    position: static;
    inset: auto;
    margin-top: var(--space-lg);
    text-align: start;
  }
  html[dir="rtl"] .hero__signature { text-align: right; }
  .hero__scroll {
    position: static;
    margin-top: var(--space-lg);
  }

  .about__grid { grid-template-columns: 1fr; gap: var(--space-xl); }
  .about__body { margin-top: 0; }
  .about__portrait { max-width: 420px; }

  .services__grid { grid-template-columns: 1fr; gap: 40px 24px; }
  .card { min-height: 0; }

  .locations__grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .h2 { font-size: var(--fs-31); }
  .cta__title { font-size: var(--fs-39); }
  .preloader__word { font-size: var(--fs-31); }
  .steps { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .hero__actions .btn { width: 100%; }
  .cta__actions { width: 100%; flex-direction: column; }
  .cta__actions .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    transition-duration: 0.001s !important;
  }
}

/* ============================================================
   INTERNAL PAGES — gallery + journal + treatments
   ============================================================ */

.page { background: var(--color-bg); }

/* page header (light, editorial) */
.ph { padding: 160px 0 var(--space-xl); }
.ph--ink {
  background: var(--color-bg);
  color: var(--color-ink);
  border-bottom: 1px solid var(--color-border);
}
.back {
  display: inline-flex; align-items: center; gap: var(--space-xs);
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--color-accent-dk); margin-bottom: var(--space-md);
  transition: color var(--dur) var(--ease);
}
.back:hover { color: var(--color-ink); }
.ph__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: var(--fs-61); line-height: 1.08;
  letter-spacing: -0.01em;
  color: var(--color-ink); margin: var(--space-sm) 0 var(--space-md);
}
.ph__title em { font-style: italic; color: var(--color-accent); }
.ph__title .char { display: inline-block; will-change: transform; }
.ph__sub {
  max-width: 65ch; color: var(--color-ink-2);
  font-size: var(--fs-16);
}

/* ---------- gallery ---------- */

.results { padding: var(--space-lg) 0 var(--section-pad); }
.results__note {
  display: flex; align-items: center; gap: var(--space-xs);
  color: var(--color-ink-2); font-size: var(--fs-14);
  font-family: var(--font-display); font-style: italic; /* serif caption voice */
  margin-bottom: var(--space-xl);
}
.results__note svg { color: var(--color-accent); flex-shrink: 0; }
.results__grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl) var(--space-md);
}
.filters {
  display: flex; flex-wrap: wrap; gap: var(--space-xs);
  margin-bottom: var(--space-lg);
}
.filters:empty { display: none; }
.filter {
  background: var(--color-surface); border: 1px solid var(--color-border);
  color: var(--color-ink-2); font-family: inherit; cursor: pointer;
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  padding: 8px 16px; min-height: 36px; border-radius: var(--radius);
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease),
              background-color var(--dur) var(--ease);
}
.filter:hover { border-color: var(--color-accent); color: var(--color-accent-dk); }
.filter.is-active { background: var(--color-accent-dk); border-color: var(--color-accent-dk); color: var(--color-surface); }
html[dir="rtl"] .filter { letter-spacing: 0; }
/* two-level case caption: serif italic name / label detail */
.case__caption {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: var(--space-sm); margin-top: var(--space-sm); flex-wrap: wrap;
}
.case__name {
  font-family: var(--font-display); font-style: italic;
  font-size: var(--fs-20); letter-spacing: -0.01em; color: var(--color-ink);
}
.case__detail {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-ink-3);
}

/* before / after slider (mechanics untouched — clip-path + handle left%) */
.ba {
  position: relative; aspect-ratio: 4 / 5; overflow: hidden;
  border: 1px solid var(--color-border); background: var(--color-accent-lt);
  touch-action: pan-y; user-select: none; -webkit-user-select: none;
  cursor: ew-resize;
}
.ba__img { position: absolute; inset: 0; }
.ba__img img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  pointer-events: none; -webkit-user-drag: none;
}
.ba__img--before { z-index: 2; clip-path: inset(0 50% 0 0); will-change: clip-path; }
.ba__handle {
  position: absolute; top: 0; bottom: 0; left: 50%;
  width: 2px; background: var(--color-accent); transform: translateX(-50%);
  z-index: 3; cursor: ew-resize;
}
.ba__handle::before { /* invisible wide hit-area */
  content: ""; position: absolute; top: 0; bottom: 0; left: 50%;
  width: 48px; transform: translateX(-50%);
}
.ba__grip {
  position: absolute; top: 50%; left: 50%;
  width: 46px; height: 46px; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: var(--color-accent); display: grid; place-items: center;
  box-shadow: var(--shadow-md); /* a genuinely floating element */
}
.ba__grip::before, .ba__grip::after {
  content: ""; position: absolute; width: 0; height: 0;
  border-block: 5px solid transparent;
}
.ba__grip::before { border-right: 7px solid var(--color-surface); left: 11px; }
.ba__grip::after { border-left: 7px solid var(--color-surface); right: 11px; }
.ba__handle:focus-visible { outline: none; }
.ba__handle:focus-visible .ba__grip {
  box-shadow: 0 0 0 2px var(--color-surface), 0 0 0 4px var(--color-accent), var(--shadow-md);
}
/* frosted-glass minimal badges */
.ba__tag {
  position: absolute; top: 16px; z-index: 4;
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  padding: 6px 12px;
  background: color-mix(in srgb, var(--color-surface) 72%, transparent);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  color: var(--color-ink);
  border: 1px solid color-mix(in srgb, var(--color-surface) 55%, transparent);
  border-radius: var(--radius);
}
.ba__tag--before { left: 16px; }
.ba__tag--after { right: 16px; }
.ba__hint {
  position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%);
  z-index: 4; font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--color-ink);
  background: color-mix(in srgb, var(--color-surface) 72%, transparent);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border: 1px solid color-mix(in srgb, var(--color-surface) 55%, transparent);
  padding: 6px 16px; border-radius: 32px; white-space: nowrap;
  transition: opacity var(--dur) var(--ease);
}
.ba--touched .ba__hint { opacity: 0; }

/* ---------- home before & after strip ---------- */
/* Same slider mechanics, but non-interactive: the handle sweeps on its own
   (CSS) and js/app.js rotates the cases through the slots. */
.bahome { padding: var(--section-pad) 0; }
.bahome__head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: var(--space-sm); flex-wrap: wrap; margin-bottom: var(--space-lg);
}
.bahome__more {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--color-accent-dk); white-space: nowrap;
  border-bottom: 1px solid currentColor; padding-bottom: 4px;
  transition: color var(--dur) var(--ease);
}
.bahome__more:hover { color: var(--color-ink); }
.bahome__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); }
.bahome__grid .case { transition: opacity var(--dur) var(--ease); }
.bahome__grid.is-swapping .case { opacity: 0; }
.bahome__grid.is-swapping .case:nth-child(2) { transition-delay: 70ms; }
.bahome__grid.is-swapping .case:nth-child(3) { transition-delay: 140ms; }
.bahome .case__name { font-size: var(--fs-20); }

.ba--auto { cursor: default; pointer-events: none; }
.ba--auto .ba__grip { width: 34px; height: 34px; }
.ba--auto .ba__img--before { animation: baSweepClip 7s var(--ease) infinite; }
.ba--auto .ba__handle { animation: baSweepHandle 7s var(--ease) infinite; }
/* offset each card so the row doesn't sweep in lockstep */
.bahome__grid .case:nth-child(2) .ba--auto :is(.ba__img--before, .ba__handle) { animation-delay: -2.3s; }
.bahome__grid .case:nth-child(3) .ba--auto :is(.ba__img--before, .ba__handle) { animation-delay: -4.6s; }
@keyframes baSweepClip  { 0%, 100% { clip-path: inset(0 28% 0 0); } 50% { clip-path: inset(0 72% 0 0); } }
@keyframes baSweepHandle { 0%, 100% { left: 72%; } 50% { left: 28%; } }

/* the global reduce block only shortens durations — an infinite sweep at 0.001s
   would strobe, so stop it outright */
@media (prefers-reduced-motion: reduce) {
  .ba--auto .ba__img--before, .ba--auto .ba__handle { animation: none !important; }
}

@media (max-width: 900px) {
  /* one slider on mobile — app.js still rotates the full set through it */
  .bahome__grid { grid-template-columns: 1fr; max-width: 380px; margin-inline: auto; }
  .bahome__grid .case:nth-child(n + 2) { display: none; }
}

/* ---------- blog ---------- */

.blog { padding: var(--space-lg) 0 var(--section-pad); }
.featured {
  display: grid; grid-template-columns: 1.05fr 1fr;
  gap: 0; align-items: stretch;
  background: var(--color-surface);
  border: 1px solid var(--color-border); border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: var(--space-xl);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.featured:hover { border-color: var(--color-accent); transform: translateY(-2px); }
.featured__media { position: relative; overflow: hidden; min-height: 280px; }
.featured__media img { width: 100%; height: 100%; object-fit: cover; }
.featured__body { padding: 48px; display: flex; flex-direction: column; justify-content: center; }
.featured__tag, .post__cat {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-accent-dk);
}
.featured__title {
  font-family: var(--font-display); font-weight: 400;
  font-size: var(--fs-31); letter-spacing: -0.01em; color: var(--color-ink);
  margin: var(--space-sm) 0; line-height: 1.15;
}
.featured__excerpt { color: var(--color-ink-2); max-width: 50ch; }
.featured__meta, .post__meta {
  margin-top: var(--space-md); display: flex; gap: var(--space-md);
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-ink-3);
}

.posts {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 48px 24px; /* same card-grid pattern as services */
}
.post {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--color-border);
  border-radius: 0;
  padding: var(--space-md) 0 0;
  display: flex; flex-direction: column; min-height: 280px;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.post:hover { border-top-color: var(--color-accent); transform: translateY(-2px); }
.post__title {
  font-family: var(--font-display); font-weight: 400; font-size: var(--fs-25);
  letter-spacing: -0.01em;
  color: var(--color-ink); margin: var(--space-sm) 0; line-height: 1.15;
}
.post__excerpt { color: var(--color-ink-2); font-size: var(--fs-14); flex: 1; }
.post__more {
  margin-top: var(--space-sm); color: var(--color-accent-dk);
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  transition: color var(--dur) var(--ease);
}
.post:hover .post__more { color: var(--color-ink); }
.post__meta { margin-top: var(--space-sm); }

/* ---------- internal-pages responsive ---------- */

@media (max-width: 900px) {
  .ph__title { font-size: var(--fs-49); }
  .results__grid { grid-template-columns: 1fr; max-width: 520px; margin-inline: auto; }
  .featured { grid-template-columns: 1fr; }
  .featured__media { min-height: 220px; aspect-ratio: 16 / 10; }
  .featured__body { padding: var(--space-lg); }
  .featured__title { font-size: var(--fs-25); }
  .posts { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .ph__title { font-size: var(--fs-39); }
}

/* ============================================================
   ARTICLE PAGE (also styles SSR treatment pages)
   ============================================================ */

.article { padding: 160px 0 0; }
.article__wrap { max-width: 720px; } /* readable measure gutter */
.article__head { margin-bottom: var(--space-lg); }
.article__cat {
  display: inline-block; font-size: var(--fs-12); letter-spacing: var(--track-label);
  text-transform: uppercase; color: var(--color-accent-dk); margin-bottom: var(--space-sm);
}
.article__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: var(--fs-49); line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--color-ink); margin-bottom: var(--space-sm);
}
.article__meta {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-ink-3);
}
.article__hero {
  aspect-ratio: 16 / 8; overflow: hidden; margin: var(--space-lg) 0 48px;
  border: 1px solid var(--color-border);
}
.article__hero img { width: 100%; height: 100%; object-fit: cover; }

.prose { color: var(--color-ink-2); }
.prose__lead {
  font-family: var(--font-display); font-style: italic;
  font-size: var(--fs-20); line-height: 1.55;
  color: var(--color-ink); margin-bottom: var(--space-lg);
}
.prose p { font-size: var(--fs-16); line-height: 1.7; margin-bottom: var(--space-md); max-width: 68ch; }
.prose__h2 {
  font-family: var(--font-display); font-weight: 500; color: var(--color-ink);
  font-size: var(--fs-25); letter-spacing: -0.01em; margin: 40px 0 var(--space-sm);
}
/* blockquote: vertical bronze hairline, italic 25px */
.prose__quote {
  font-family: var(--font-display); font-style: italic; color: var(--color-accent-dk);
  font-size: var(--fs-25); line-height: 1.45;
  margin: 40px 0; padding-inline-start: var(--space-md);
  border-inline-start: 1px solid var(--color-accent);
}
.prose a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 3px;
  transition: color var(--dur) var(--ease);
}
.prose a:hover { color: var(--color-accent-dk); }

/* keyboard focus (a11y): one visible ring everywhere, mouse clicks unaffected.
   Elements with their own focus treatment (ba__handle, skip-link) override it. */
:is(a, button, input, textarea, select, [tabindex]):focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* skip-to-content link (a11y): hidden until keyboard-focused */
.skip-link {
  position: absolute; left: 8px; top: -60px; z-index: 200;
  background: var(--color-ink); color: var(--color-surface);
  padding: 10px 16px; border-radius: var(--radius);
  font-size: var(--fs-14); letter-spacing: var(--track-label);
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: 8px; outline: 2px solid var(--color-accent); outline-offset: 2px; }
html[dir="rtl"] .skip-link { left: auto; right: 8px; }

/* SSR page (treatments/doctor) mobile menu — pure-CSS, no JS */
.ssr-navtoggle { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.ssr-menu { display: none; }
.ssr-menu__inner { display: flex; flex-direction: column; gap: var(--space-md); padding: 104px var(--gutter) var(--space-xl); }
.ssr-menu__link { font-family: var(--font-display); font-size: var(--fs-25); color: var(--color-ink); }
.ssr-menu__link--gold { color: var(--color-accent-dk); }
@media (max-width: 820px) {
  .ssr-navtoggle:checked ~ .ssr-menu {
    display: block; position: fixed; inset: 0; z-index: 90;
    background: var(--color-surface); overflow-y: auto;
  }
  .ssr-navtoggle:checked ~ header .nav__burger span:nth-child(1) { top: 21px; transform: rotate(45deg); }
  .ssr-navtoggle:checked ~ header .nav__burger span:nth-child(2) { top: 21px; transform: rotate(-45deg); }
}

/* treatment ⇄ city cross-links */
.tx-cities {
  margin: var(--space-md) 0; padding-top: var(--space-sm);
  border-top: 1px solid var(--color-border);
  font-size: var(--fs-14); color: var(--color-ink-3);
}
.tx-cities a { margin: 0 2px; }
/* treatment-index card whose title/excerpt is one link + a city-links row */
.post__link { display: flex; flex-direction: column; flex: 1; color: inherit; }
.post .tx-cities { margin-top: auto; }

.byline {
  display: flex; align-items: center; gap: var(--space-sm);
  margin: var(--space-xl) 0 var(--space-sm); padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
}
.byline .mono { width: 40px; height: 40px; }
.byline__name { display: block; font-family: var(--font-display); font-size: var(--fs-20); color: var(--color-ink); }
.byline__role { display: block; font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-accent-dk); margin-top: 4px; }

.related__h {
  font-family: var(--font-display); font-weight: 400; color: var(--color-ink);
  font-size: var(--fs-31); letter-spacing: -0.01em;
  margin: var(--space-2xl) 0 var(--space-md);
}
.related {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 48px 24px; /* same card-grid pattern */
  margin-bottom: var(--space-2xl);
}
.rel {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--color-border);
  border-radius: 0;
  padding: var(--space-md) 0 0;
  display: flex; flex-direction: column; gap: var(--space-xs);
  min-height: 160px;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.rel:hover { border-top-color: var(--color-accent); transform: translateY(-2px); }
.rel__cat { font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-accent-dk); }
.rel__title { font-family: var(--font-display); font-size: var(--fs-20); letter-spacing: -0.01em; color: var(--color-ink); line-height: 1.15; flex: 1; }
.rel__read { font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-ink-3); }

/* ============================================================
   CONTACT / BOOKING — clinical underline form
   ============================================================ */

.contact { padding: var(--space-lg) 0 var(--section-pad); }
.contact__grid {
  display: grid; grid-template-columns: 7fr 5fr;
  gap: var(--space-2xl); align-items: start;
}
/* deliberate asymmetry: the cards column starts lower than the form */
.contact__aside { margin-top: var(--space-xl); }
.contact__h {
  font-family: var(--font-display); font-weight: 400; font-size: var(--fs-25);
  letter-spacing: -0.01em;
  color: var(--color-ink); margin-bottom: var(--space-lg);
}
.form { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-lg) var(--space-md); }
.field { display: flex; flex-direction: column; gap: var(--space-xs); }
.field--full { grid-column: 1 / -1; }
.field span {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase; color: var(--color-ink-2);
}
.field input, .field select, .field textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--color-border);
  border-radius: 0;
  color: var(--color-ink); font-family: var(--font-body); font-size: var(--fs-16);
  padding: 8px 0; width: 100%;
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.field input::placeholder, .field textarea::placeholder { font-size: var(--fs-14); color: var(--color-ink-3); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: none; /* focus state lives in the underline itself */
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--color-accent-dk);
  box-shadow: 0 1px 0 0 var(--color-accent-dk); /* underline thickens to 2px, no layout shift */
}
.field select { appearance: none; cursor: pointer; }
.field textarea { resize: vertical; }
.form .btn { grid-column: 1 / -1; justify-self: start; margin-top: var(--space-xs); }
.form__success {
  grid-column: 1 / -1; color: var(--color-accent-dk); font-size: var(--fs-14);
  padding: 16px; border: 1px solid var(--color-accent);
  border-radius: var(--radius); background: var(--color-accent-lt);
}
.form__error {
  grid-column: 1 / -1; color: #9b2c2c; font-size: var(--fs-14);
  padding: 16px; border: 1px solid #e0b4b4;
  border-radius: var(--radius); background: #fbf0f0;
}

.contact__or {
  font-size: var(--fs-12); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--color-accent-dk); margin-bottom: var(--space-md);
}
.vcard {
  border: 0;
  border-top: 1px solid var(--color-border);
  border-radius: 0;
  padding: var(--space-md) 0 0;
  margin-bottom: var(--space-md); background: transparent;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.vcard:hover { border-top-color: var(--color-accent); transform: translateY(-2px); }
.vcard h3 { font-family: var(--font-display); font-weight: 400; font-size: var(--fs-20); letter-spacing: -0.01em; color: var(--color-ink); margin-bottom: var(--space-xs); }
.vcard__addr { font-family: var(--font-fa); color: var(--color-ink-2); font-size: var(--fs-16); margin-bottom: var(--space-xs); }
.vcard__line { font-size: var(--fs-14); color: var(--color-ink-2); }
.contact__channels { display: flex; gap: var(--space-xs); flex-wrap: wrap; margin: var(--space-md) 0; }
.contact__channels .btn { flex: 1; min-width: 130px; padding-inline: 16px; }
.contact__note { font-size: var(--fs-14); color: var(--color-ink-3); line-height: 1.7; }

/* Clickable map: OSM tile for the visual, whole card links to Google Maps
   directions (iframe is pointer-events:none so clicks fall through). */
.mapcard {
  position: relative; display: block; margin-top: var(--space-md);
  max-width: 420px; border: 1px solid var(--color-border);
  border-radius: var(--radius); overflow: hidden; line-height: 0;
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.mapcard:hover { border-color: var(--color-accent); transform: translateY(-2px); }
.mapcard__frame {
  display: block; width: 100%; height: 190px; border: 0;
  pointer-events: none; /* clicks fall through to the <a> → Google Maps */
  background: #e8e4d8; /* tile-loading placeholder tone */
}
.mapcard__cta {
  position: absolute; inset-block-end: 10px; inset-inline-end: 10px;
  background: var(--color-ink); color: var(--color-bg);
  font-size: var(--fs-14); line-height: 1; padding: 8px 12px;
  border-radius: var(--radius); box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}
.mapcard:hover .mapcard__cta { background: var(--color-accent); color: var(--color-ink); }
/* on the dark #locations section */
.mapcard--onink { margin-top: 2.5rem; border-color: rgba(245, 239, 228, 0.22); }

/* internal pages — extra responsive */
@media (max-width: 820px) {
  .contact__grid { grid-template-columns: 1fr; gap: var(--space-xl); }
  .contact__aside { margin-top: 0; }
  .related { grid-template-columns: 1fr; }
  .article__hero { aspect-ratio: 16 / 10; }
  .article__title { font-size: var(--fs-39); }
}
@media (max-width: 540px) {
  .form { grid-template-columns: 1fr; }
  .article__title { font-size: var(--fs-31); }
}

/* ============================================================
   PERSIAN (fa) — RTL layout & Vazirmatn typography
   (every new component gets its mirror here, same release)
   ============================================================ */

html[lang="fa"] body { font-family: var(--font-fa); }

html[lang="fa"] :is(.hero__title, .h2, .lead, .cta__title,
  .card h3, .step h3, .loc h3, .menu__link, .marquee__group span,
  .results__note) {
  font-family: var(--font-fa);
}

/* Persian doesn't use italics or wide tracking */
html[lang="fa"] :is(.hero__line--italic, .h2 em, .cta__title em, .lead,
  .marquee__group span, .menu__link--gold, .results__note, .case__name) {
  font-style: normal;
}
html[dir="rtl"] :is(.kicker, .hero__eyebrow, .hero__sig-sub, .hero__scroll,
  .nav__links a, .btn, .stat__label, .loc__city, .loc__meta, .menu__foot,
  .footer__col h4, .footer__base, .card h3 small,
  .back, .results__note, .case__detail, .ba__tag, .ba__hint,
  .featured__tag, .post__cat, .featured__meta, .post__meta, .post__more,
  .article__cat, .article__meta, .byline__role, .rel__cat, .rel__read,
  .field span, .contact__or, .contact__note, .vcard__line, .loc__link,
  .form__success, .form__error, .filters .filter) {
  letter-spacing: 0;
}

/* Persian display sizing — no negative tracking, taller line-height */
html[lang="fa"] :is(.hero__title, .h2, .cta__title, .ph__title, .article__title,
  .featured__title, .post__title, .case__name, .card h3, .step h3, .loc h3,
  .prose__h2, .prose__quote, .related__h, .rel__title, .byline__name,
  .contact__h, .vcard h3) {
  letter-spacing: 0;
}
html[lang="fa"] .hero__title {
  font-size: clamp(44px, 9vw, 106px);
  line-height: 1.3;
  font-weight: 300;
}
html[lang="fa"] .hero__line { padding-bottom: 0.16em; }
html[lang="fa"] .h2 { font-weight: 300; line-height: 1.4; }
html[lang="fa"] .lead { font-weight: 300; line-height: 1.9; }
html[lang="fa"] .body-copy, html[lang="fa"] .card p,
html[lang="fa"] .step p, html[lang="fa"] .loc__desc, html[lang="fa"] .hero__sub {
  line-height: 2;
}
html[lang="fa"] .cta__title { line-height: 1.45; font-weight: 300; }
html[lang="fa"] .cta__title [data-split] { padding-bottom: 0.16em; }
html[lang="fa"] .card h3 { font-weight: 500; }
html[lang="fa"] .step h3 { font-weight: 500; }
html[lang="fa"] .menu__link { font-weight: 300; }
html[lang="fa"] .marquee__group span { font-size: var(--fs-16); font-weight: 400; }
html[lang="fa"] .stat__suffix { font-size: 0.42em; font-style: normal; letter-spacing: 0; }
html[lang="fa"] .btn { font-size: var(--fs-14); font-weight: 500; }

/* the transliterated location line flips to Latin in fa mode */
html[dir="rtl"] .loc__fa { font-family: var(--font-body); letter-spacing: var(--track-label); text-transform: uppercase; font-size: var(--fs-12); }

/* keep serif italic numerals as brand accents in both languages */
html[lang="fa"] :is(.card__num, .step__num, .about__points li span) {
  font-family: var(--font-display);
}

/* Latin digits & brand stay LTR inside RTL text */
html[dir="rtl"] .stat__num { direction: ltr; }
html[dir="rtl"] :is(.hero__signature, .footer__sig, .portrait-frame__caption) { direction: ltr; }
html[dir="rtl"] .hero__scroll-line::after { animation-direction: reverse; }

/* desktop RTL: text + CTAs sit on the right, so move the signature to the
   empty bottom-left corner to avoid overlapping the buttons */
@media (min-width: 821px) {
  html[dir="rtl"] .hero__signature {
    right: auto;
    left: clamp(24px, 5vw, 80px);
    text-align: left;
  }
}

/* ---------- internal-pages Persian (RTL) ---------- */

html[lang="fa"] :is(.ph__title, .featured__title, .post__title, .case__name) {
  font-family: var(--font-fa); font-weight: 300;
}
html[lang="fa"] .ph__title { line-height: 1.35; }
html[lang="fa"] .post__title, html[lang="fa"] .case__name { font-weight: 500; }
html[dir="rtl"] .featured__meta, html[dir="rtl"] .post__meta { letter-spacing: 0.04em; }

/* article + contact + treatments — Persian */
html[lang="fa"] :is(.article__title, .prose__lead, .prose__h2, .prose__quote,
  .related__h, .rel__title, .byline__name, .contact__h, .vcard h3) {
  font-family: var(--font-fa);
}
html[lang="fa"] .article__title { font-weight: 300; line-height: 1.35; }
html[lang="fa"] .prose__lead { font-style: normal; line-height: 1.9; }
html[lang="fa"] .prose p { line-height: 2.1; }
html[lang="fa"] .prose__quote { font-style: normal; line-height: 1.8; }
html[dir="rtl"] .prose, html[dir="rtl"] .ph__sub { text-align: right; }
