/* Mossley Dental Care · Invisalign campaign concept
   Brand: Mossley blue #002E68 + pink #FD396E, deepened ink stage.
   Type: Sora (display) + Manrope (body), both SIL OFL 1.1, served locally. */

@font-face {
  font-family: "Sora";
  src: url("assets/sora.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("assets/manrope.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #071C2B;
  --ink-2: #0B2438;
  --ink-3: #04121D;
  --navy: #002E68;
  --navy-2: #0A3C7D;
  --pink: #FD396E;
  --pink-deep: #C8174B;      /* pink for small text on light surfaces (AA) */
  --ice: #EEF4FA;
  --ice-2: #E3EDF7;
  --white: #FFFFFF;
  --text: #0B2236;
  --text-2: #4A5D73;
  --on-dark: #FFFFFF;
  --on-dark-2: rgba(232, 241, 250, 0.76);
  --on-dark-3: rgba(232, 241, 250, 0.62);
  --soft-blue: #A9C9EE;
  --line-dark: rgba(214, 232, 255, 0.16);
  --line-light: rgba(0, 46, 104, 0.14);

  --font-display: "Sora", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;

  --container: 1320px;
  --gutter: clamp(20px, 4vw, 56px);
  --pad: clamp(72px, 8vw, 132px);
  --header-h: 72px;
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 12px;

  --ease-out: cubic-bezier(0.2, 0.7, 0.1, 1);
  --ease-camera: cubic-bezier(0.62, 0.02, 0.18, 1);
}

/* ---------- Reset and base ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
  background: var(--ink);
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--ink);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

h1,
h2,
h3,
p,
dl,
dd,
ol,
ul,
figure,
address,
fieldset {
  margin: 0;
}

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

address {
  font-style: normal;
}

a {
  color: inherit;
}

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

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--pink);
  outline-offset: 3px;
}

main:focus {
  outline: none;
}

section[id] {
  scroll-margin-top: 12px;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease-out);
}

.skip-link:focus {
  transform: none;
}

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
}

.pink {
  color: var(--pink);
}

/* ---------- Buttons and links ---------- */

.btn {
  --btn-h: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  min-height: var(--btn-h);
  padding: 0 1.5em;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.005em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.btn--pink {
  background: var(--pink);
  color: var(--ink);
  box-shadow: 0 14px 34px -16px rgba(253, 57, 110, 0.75);
}

.btn--pink:hover {
  background: #FF5482;
  box-shadow: 0 18px 40px -16px rgba(253, 57, 110, 0.85);
}

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

.btn--sm {
  --btn-h: 42px;
  padding: 0 1.15em;
  font-size: 0.9375rem;
}

.btn--lg {
  --btn-h: 58px;
  padding: 0 1.75em;
  font-size: 1.0625rem;
}

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

.btn--line {
  background: transparent;
  border-color: rgba(0, 46, 104, 0.3);
  color: var(--navy);
}

.btn--line:hover {
  border-color: var(--navy);
  background: rgba(0, 46, 104, 0.04);
}

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 2px;
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
}

.link-arrow svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s var(--ease-out);
}

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

.link-arrow--light {
  color: var(--white);
}

/* ---------- Shared labels and headings ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-2);
}

.eyebrow__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--pink);
  box-shadow: 0 0 0 4px rgba(253, 57, 110, 0.2);
}

.label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
}

.label::after {
  content: "";
  flex: 0 0 44px;
  height: 1px;
  background: currentColor;
  opacity: 0.3;
}

.label__idx {
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--pink-deep);
  font-variant-numeric: tabular-nums;
}

.label--dark {
  color: var(--on-dark-2);
}

.label--dark .label__idx {
  color: var(--pink);
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.2rem + 2.6vw, 3.4rem);
  font-weight: 500;
  line-height: 1.06;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.section-head {
  max-width: 46rem;
}

.section-head h2 {
  margin-top: 16px;
}

.section-head__lede {
  margin-top: 16px;
  max-width: 36rem;
  font-size: 1.0625rem;
  color: var(--text-2);
}

.fineprint {
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--text-2);
}

/* Registration marks: the precision framing motif */
.reg {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 0 solid rgba(214, 232, 255, 0.55);
  pointer-events: none;
}

.reg--tl { border-top-width: 1px; border-left-width: 1px; }
.reg--tr { border-top-width: 1px; border-right-width: 1px; }
.reg--bl { border-bottom-width: 1px; border-left-width: 1px; }
.reg--br { border-bottom-width: 1px; border-right-width: 1px; }

/* ---------- Header ---------- */

.site-header {
  position: relative;
  z-index: 40;
  color: var(--white);
  background: var(--ink);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 64px;
}

.brand {
  margin-right: auto;
  font-family: var(--font-display);
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-decoration: none;
}

.brand__strong {
  font-weight: 600;
}

.brand__soft {
  font-weight: 300;
  color: var(--on-dark-2);
}

.site-nav,
.site-header__cta {
  display: none;
}

@media (min-width: 1024px) {
  section[id] {
    scroll-margin-top: calc(var(--header-h) + 8px);
  }

  .site-header {
    position: sticky;
    top: 0;
    background: transparent;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
  }

  .site-header.is-scrolled {
    background: rgba(7, 28, 43, 0.94);
    box-shadow: 0 1px 0 var(--line-dark);
  }

  @supports ((-webkit-backdrop-filter: blur(8px)) or (backdrop-filter: blur(8px))) {
    .site-header.is-scrolled {
      background: rgba(7, 28, 43, 0.8);
      -webkit-backdrop-filter: saturate(140%) blur(14px);
      backdrop-filter: saturate(140%) blur(14px);
    }
  }

  .site-header__inner {
    min-height: var(--header-h);
  }

  .site-nav {
    display: flex;
    gap: 2px;
  }

  .site-nav a {
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--on-dark-2);
    text-decoration: none;
    transition: color 0.18s ease, background-color 0.18s ease;
  }

  .site-nav a:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.06);
  }

  .site-header__cta {
    display: inline-flex;
    transition: opacity 0.25s ease, visibility 0s, background-color 0.18s ease;
  }

  /* Visibility flips instantly when shown (so focus can return to it) and
     only after the fade when hidden. */
  .site-header__cta.is-suppressed {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0s linear 0.25s;
  }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(70% 60% at 70% 28%, rgba(0, 46, 104, 0.7) 0%, rgba(0, 46, 104, 0) 70%),
    linear-gradient(180deg, var(--ink) 0%, #061828 100%);
}

.hero__media {
  position: relative;
  z-index: -1;
  aspect-ratio: 5 / 4;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 60%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 60%, transparent 100%);
}

.hero__plate {
  position: absolute;
  left: -62%;
  top: -18%;
  width: 165%;
  aspect-ratio: 3 / 2;
}

.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: hero-settle 1.6s var(--ease-out) both;
}

.hero__plate .reg--tl { left: 41%; top: 23.5%; }
.hero__plate .reg--tr { right: 4.5%; top: 23.5%; }
.hero__plate .reg--bl { left: 41%; bottom: 31%; }
.hero__plate .reg--br { right: 4.5%; bottom: 31%; }

.hero__plate .reg {
  animation: reg-in 0.9s 0.35s var(--ease-out) both;
}

.hero__sheen {
  position: absolute;
  top: -10%;
  bottom: -10%;
  left: 0;
  width: 40%;
  background: linear-gradient(100deg, rgba(58, 82, 114, 0) 0%, rgba(58, 82, 114, 0.95) 50%, rgba(58, 82, 114, 0) 100%);
  mix-blend-mode: color-dodge;
  opacity: 0;
  pointer-events: none;
  animation: sweep 1.5s 0.45s var(--ease-out) both;
}

.hero__inner {
  position: relative;
  margin-top: -36px;
  padding-bottom: 48px;
}

.hero__title {
  margin-top: 18px;
  font-family: var(--font-display);
  font-size: min(9.6vw, 2.75rem);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.hero__title > span {
  display: block;
}

.hero__title-soft {
  font-weight: 300;
  color: var(--soft-blue);
}

.hero__lede {
  margin-top: 18px;
  max-width: 34rem;
  color: var(--on-dark-2);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 26px;
  margin-top: 26px;
}

.hero__fee {
  margin-top: 14px;
  font-size: 0.875rem;
  color: var(--on-dark-2);
}

.hero__fee-sep {
  margin: 0 4px;
  color: var(--pink);
}

.hero__spec {
  margin-top: 36px;
  border-top: 1px solid var(--line-dark);
}

.hero__spec > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line-dark);
}

.hero__spec dt {
  flex: none;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-3);
  padding-top: 3px;
}

.hero__spec dd {
  font-size: 0.9375rem;
  font-weight: 600;
  text-align: right;
}

.hero__caption {
  margin-top: 18px;
  font-size: 0.75rem;
  letter-spacing: 0.03em;
  color: var(--on-dark-3);
}

@keyframes hero-settle {
  from { opacity: 0; transform: scale(1.035); }
  to { opacity: 1; transform: none; }
}

@keyframes reg-in {
  from { opacity: 0; transform: scale(1.6); }
  to { opacity: 1; transform: none; }
}

@keyframes sweep {
  0% { transform: translateX(-120%) skewX(-12deg); opacity: 0; }
  18% { opacity: 1; }
  100% { transform: translateX(270%) skewX(-12deg); opacity: 0; }
}

@media (max-width: 479px) {
  .hero__actions .btn {
    width: 100%;
    padding: 0 12px;
    font-size: 1rem;
  }

  .hero__actions .link-arrow {
    padding-block: 4px;
  }
}

/* Small phones with little height: keep the CTA above the fold */
@media (max-width: 639px) and (max-height: 740px) {
  .hero__media {
    aspect-ratio: 2 / 1;
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 72%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 72%, transparent 100%);
  }

  .hero__plate {
    left: -38%;
    top: -36%;
    width: 130%;
  }

  .hero__inner {
    margin-top: -20px;
  }

  .site-header__inner {
    min-height: 56px;
  }

  .hero__title,
  .hero__lede {
    margin-top: 12px;
  }

  .hero__lede {
    font-size: 1rem;
    line-height: 1.55;
  }

  .hero__actions {
    margin-top: 18px;
  }
}

@media (min-width: 640px) {
  .hero__media {
    aspect-ratio: 16 / 9;
  }

  .hero__plate {
    left: -28%;
    top: -12%;
    width: 120%;
  }

  .hero__title {
    font-size: clamp(2.75rem, 1rem + 3.9vw, 4.25rem);
  }

  .hero__lede {
    font-size: 1.125rem;
  }

  .hero__spec {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-width: 58rem;
  }

  .hero__spec > div {
    display: block;
    padding: 16px 20px 0 0;
    border-bottom: 0;
  }

  .hero__spec > div + div {
    padding-left: 20px;
    border-left: 1px solid var(--line-dark);
  }

  .hero__spec dd {
    margin-top: 6px;
    text-align: left;
  }
}

@media (min-width: 1024px) {
  .hero {
    display: flex;
    align-items: stretch;
    min-height: clamp(620px, calc(100svh - var(--header-h)), 920px);
  }

  /* Media is anchored to the content column and capped, so it never keeps
     growing on ultrawide screens. */
  .hero__media {
    position: absolute;
    top: 50%;
    right: calc((100% - min(100% - 2 * var(--gutter), var(--container))) / 2 - 40px);
    width: min(72vw, 1240px);
    aspect-ratio: 3 / 2;
    transform: translateY(-50%);
    -webkit-mask-image: radial-gradient(ellipse 60% 66% at 63% 50%, #000 50%, rgba(0, 0, 0, 0.55) 72%, transparent 94%);
    mask-image: radial-gradient(ellipse 60% 66% at 63% 50%, #000 50%, rgba(0, 0, 0, 0.55) 72%, transparent 94%);
  }

  .hero__plate {
    inset: 0;
    width: 100%;
  }

  .hero__inner {
    display: grid;
    grid-template-rows: 1fr auto;
    align-items: center;
    margin-top: 0;
    padding-top: 40px;
    padding-bottom: 40px;
  }

  .hero__copy {
    max-width: 46rem;
  }

  .hero__lede {
    font-size: 1.1875rem;
  }

  .hero__spec {
    margin-top: 40px;
  }

  .hero__caption {
    position: absolute;
    top: 8px;
    right: max(var(--gutter), env(safe-area-inset-right));
    margin: 0;
    text-align: right;
  }
}

/* ---------- Routine: signature material stage ---------- */

.routine {
  padding-block: var(--pad);
  background: var(--ice);
  color: var(--text);
}

.routine__grid {
  display: grid;
  gap: 20px;
  margin-top: clamp(32px, 4vw, 56px);
}

.stage {
  position: relative;
}

.stage__view {
  position: relative;
  isolation: isolate;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: radial-gradient(90% 80% at 62% 48%, #12355E 0%, #0A2442 46%, #061726 100%);
  box-shadow: 0 44px 80px -52px rgba(0, 30, 70, 0.6), 0 0 0 1px rgba(0, 46, 104, 0.08);
  contain: layout paint;
}

.stage__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 68% 50%;
}

/* Live camera: the image keeps its natural pixel box and is moved/scaled with
   one composited transform per state, computed in app.js. */
.stage.is-live .stage__img {
  inset: auto;
  left: 0;
  top: 0;
  width: 1536px;
  height: 1024px;
  object-fit: fill;
  transform-origin: 0 0;
  transform: translate3d(var(--tx, 0px), var(--ty, 0px), 0) scale(var(--s, 0.4));
  transition: transform 1.15s var(--ease-camera);
}

/* Light aperture: a soft-edged ellipse that keeps the focus bright and dims the rest. */
.stage__aperture {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
  width: var(--aw, 0px);
  height: var(--ah, 0px);
  border: 1px solid rgba(214, 232, 255, 0.42);
  border-radius: 50%;
  box-shadow: inset 0 0 44px 6px rgba(4, 16, 28, 0.3), 0 0 0 200vmax rgba(4, 16, 28, 0.5);
  transform: translate3d(var(--ax, 0px), var(--ay, 0px), 0);
  opacity: 0;
  pointer-events: none;
  transition:
    width 1.15s var(--ease-camera),
    height 1.15s var(--ease-camera),
    transform 1.15s var(--ease-camera),
    box-shadow 0.8s ease,
    opacity 0.6s ease;
}

.stage.is-live .stage__aperture {
  opacity: 1;
}

.stage[data-state="wear"] .stage__aperture {
  box-shadow: inset 0 0 46px 6px rgba(150, 200, 255, 0.12), 0 0 0 200vmax rgba(4, 16, 28, 0.56);
}

.stage[data-state="remove"] .stage__aperture {
  box-shadow: inset 0 0 52px 8px rgba(4, 16, 28, 0.32), 0 0 0 200vmax rgba(4, 16, 28, 0.44);
}

.stage[data-state="change"] .stage__aperture {
  box-shadow: inset 0 0 46px 8px rgba(253, 57, 110, 0.16), 0 0 0 200vmax rgba(4, 16, 28, 0.56);
}

.stage__aperture i {
  position: absolute;
  background: rgba(214, 232, 255, 0.75);
}

.stage__aperture i:nth-child(1) { left: 50%; top: -8px; width: 2px; height: 16px; margin-left: -1px; background: var(--pink); }
.stage__aperture i:nth-child(2) { top: 50%; right: -7px; width: 14px; height: 1px; }
.stage__aperture i:nth-child(3) { left: 50%; bottom: -7px; width: 1px; height: 14px; }
.stage__aperture i:nth-child(4) { top: 50%; left: -7px; width: 14px; height: 1px; }

/* One light sweep across the clear material on each state change */
.stage__sweep {
  position: absolute;
  top: -10%;
  bottom: -10%;
  left: 0;
  z-index: 2;
  width: 45%;
  background: linear-gradient(100deg, rgba(60, 84, 116, 0) 0%, rgba(60, 84, 116, 0.9) 50%, rgba(60, 84, 116, 0) 100%);
  mix-blend-mode: color-dodge;
  opacity: 0;
  pointer-events: none;
}

.stage.is-sweeping .stage__sweep {
  animation: sweep 1.25s var(--ease-out) both;
}

/* Detail annotation: a pin on the material, a fine leader and a label parked
   in a clear corner of the stage, so it never sits on the aligner. */
.note {
  position: absolute;
  inset: 0;
  z-index: 3;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.note.is-on {
  opacity: 1;
}

.note__leader {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  overflow: visible;
}

.note__leader line {
  stroke: rgba(232, 241, 250, 0.82);
  stroke-width: 1;
  stroke-dasharray: var(--len, 0);
  stroke-dashoffset: 0;
}

.note.is-on .note__leader line {
  animation: leader-draw 0.6s 0.1s var(--ease-out) both;
}

.note__leader circle {
  fill: rgba(232, 241, 250, 0.95);
}

.note__pin {
  position: absolute;
  left: calc(var(--px, 0px) - 6px);
  top: calc(var(--py, 0px) - 6px);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--pink);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.92), 0 0 0 10px rgba(253, 57, 110, 0.22);
}

.note.is-on .note__pin {
  animation: pin-in 0.55s var(--ease-out) both;
}

.note__label {
  position: absolute;
  left: var(--lx, 0px);
  top: var(--ly, 0px);
  padding: 7px 13px;
  border: 1px solid rgba(214, 232, 255, 0.24);
  border-radius: 999px;
  background: rgba(7, 28, 43, 0.8);
  color: var(--white);
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.stage__hud {
  position: absolute;
  top: 18px;
  left: 38px;
  right: 38px;
  z-index: 4;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(232, 241, 250, 0.78);
}

.stage:not(.is-live) .stage__count {
  display: none;
}

.stage__count {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}

.stage .reg {
  z-index: 4;
  border-color: rgba(214, 232, 255, 0.5);
}

.stage .reg--tl { left: 14px; top: 14px; }
.stage .reg--tr { right: 14px; top: 14px; }
.stage .reg--bl { left: 14px; bottom: 14px; }
.stage .reg--br { right: 14px; bottom: 14px; }

.stage__caption {
  position: absolute;
  left: 38px;
  bottom: 17px;
  z-index: 4;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(232, 241, 250, 0.78);
}

@media (max-width: 519px) {
  .stage__hud {
    left: 30px;
    right: 30px;
  }

  .stage__caption {
    left: 30px;
  }
}

@keyframes pin-in {
  0% { transform: scale(0.2); }
  60% { transform: scale(1.18); }
  100% { transform: scale(1); }
}

@keyframes leader-draw {
  from { stroke-dashoffset: var(--len, 0); }
  to { stroke-dashoffset: 0; }
}

/* Routine controls and readable state panels */
.routine__panel {
  display: grid;
  align-content: start;
  gap: 24px;
}

.routine__tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: var(--white);
  box-shadow: 0 0 0 1px var(--line-light), 0 12px 30px -24px rgba(0, 46, 104, 0.5);
}

.tab {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-2);
  font-size: 0.9375rem;
  font-weight: 700;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.25s ease, color 0.25s ease;
}

.tab:hover {
  color: var(--navy);
}

.tab[aria-selected="true"] {
  background: var(--ink);
  color: var(--white);
}

.tab__idx,
.tab__fact {
  display: none;
}

.routine__panels {
  display: grid;
  gap: 28px;
}

.state {
  display: grid;
  gap: 18px;
}

.state + .state {
  padding-top: 28px;
  border-top: 1px solid var(--line-light);
}

.routine.is-enhanced .state + .state {
  padding-top: 0;
  border-top: 0;
}

.state__figure {
  display: flex;
  align-items: center;
  gap: 22px;
}

.dial {
  position: relative;
  flex: none;
  width: 112px;
  height: 112px;
}

.dial svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.dial circle {
  fill: none;
}

.dial__ticks {
  stroke: rgba(0, 46, 104, 0.34);
  stroke-width: 5;
  stroke-dasharray: 0.08 0.92;
  stroke-dashoffset: 0.04;
}

.dial__track {
  stroke: rgba(0, 46, 104, 0.1);
  stroke-width: 3;
}

.dial__arc {
  stroke-width: 3;
  stroke-linecap: round;
}

.dial__arc--wear { stroke: var(--pink); stroke-dasharray: 22 2; }
.dial__arc--worn { stroke: rgba(0, 46, 104, 0.26); stroke-dasharray: 21.6 2.4; stroke-linecap: butt; }
.dial__arc--out { stroke: var(--pink); stroke-dasharray: 2 22; stroke-dashoffset: -22; }
.dial__arc--week1 { stroke: var(--pink); stroke-dasharray: 7 7; }
.dial__arc--week2 {
  stroke: var(--pink);
  stroke-linecap: butt;
  opacity: 0.55;
  stroke-dasharray: 0 7.3 0.5 0.45 0.5 0.45 0.5 0.45 0.5 0.45 0.5 0.45 0.5 0.45 0.5 0.45;
}

.dial__value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.875rem;
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--navy);
}

.dial__value small {
  margin-left: 1px;
  font-size: 0.6em;
  align-self: flex-start;
  margin-top: 36px;
}

.dial__value--word {
  font-size: 1.375rem;
}

.state__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--navy);
}

.state__idx {
  margin-right: 4px;
  font-size: 0.8125rem;
  color: var(--pink-deep);
  font-variant-numeric: tabular-nums;
}

.state__unit {
  margin-top: 2px;
  font-weight: 600;
  color: var(--text-2);
}

.state__text {
  max-width: 30rem;
}

.routine.is-enhanced .state.is-entering {
  animation: panel-in 0.42s var(--ease-out) both;
}

.routine.is-enhanced .state.is-entering .dial svg {
  animation: dial-in 0.9s var(--ease-out) both;
}

@keyframes panel-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

@keyframes dial-in {
  from { opacity: 0; transform: rotate(-150deg); }
  to { opacity: 1; transform: rotate(-90deg); }
}

@media (min-width: 640px) {
  .stage__view {
    aspect-ratio: 16 / 11;
  }
}

@media (min-width: 1024px) {
  .routine__grid {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    align-items: center;
    gap: clamp(32px, 4.4vw, 72px);
  }

  .stage__view {
    aspect-ratio: 5 / 4;
  }

  .routine__panel {
    gap: 32px;
  }

  .routine__tabs {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
    border-top: 1px solid var(--line-light);
    border-radius: 0;
    background: none;
    box-shadow: none;
  }

  .tab {
    justify-content: flex-start;
    gap: 16px;
    min-height: 70px;
    padding: 0 4px;
    border-bottom: 1px solid var(--line-light);
    border-radius: 0;
    font-family: var(--font-display);
    font-size: 1.3125rem;
    font-weight: 500;
    letter-spacing: -0.01em;
  }

  .tab[aria-selected="true"] {
    background: none;
    color: var(--navy);
  }

  .tab::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 100%;
    height: 2px;
    background: var(--pink);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.6s var(--ease-out);
  }

  .tab[aria-selected="true"]::after {
    transform: scaleX(1);
  }

  .tab__idx {
    display: inline;
    min-width: 2ch;
    font-size: 0.8125rem;
    color: var(--pink-deep);
    font-variant-numeric: tabular-nums;
  }

  .tab__fact {
    display: inline;
    margin-left: auto;
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0;
    color: var(--text-2);
  }
}

/* Resize and reduced-motion updates apply without camera travel */
.stage.is-instant .stage__img,
.stage.is-instant .stage__aperture,
.stage.is-instant .note {
  transition: none !important;
}

/* ---------- Local expertise + first step ---------- */

.consult {
  padding-block: var(--pad);
  background: var(--white);
  color: var(--text);
}

.consult__grid {
  display: grid;
  gap: 48px;
}

.consult__lede {
  margin-top: 16px;
  max-width: 32rem;
  font-size: 1.0625rem;
  color: var(--text-2);
}

.consult__intro h2 {
  margin-top: 16px;
}

.clinician {
  position: relative;
  margin-top: 32px;
  padding: 28px 24px 24px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, var(--ice) 0%, #F6F9FC 100%);
  box-shadow: inset 0 0 0 1px var(--line-light);
}

.clinician::before {
  content: "";
  position: absolute;
  left: 24px;
  top: 0;
  width: 40px;
  height: 2px;
  background: var(--pink);
}

.clinician__kicker {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-2);
}

.clinician__name {
  margin-top: 8px;
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--navy);
}

.ledger {
  margin-top: 22px;
  border-top: 1px solid var(--line-light);
}

.ledger > div {
  display: grid;
  grid-template-columns: minmax(0, 8.5rem) minmax(0, 1fr);
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-light);
}

.ledger dt {
  padding-top: 2px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-2);
}

.ledger dd {
  font-weight: 600;
  color: var(--text);
}

.clinician .fineprint {
  margin-top: 14px;
}

.consult__first-title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--navy);
}

.steps {
  display: grid;
  margin-top: 20px;
  border-top: 1px solid var(--line-light);
}

.steps__item {
  display: grid;
  grid-template-columns: 2.75rem minmax(0, 1fr);
  column-gap: 8px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line-light);
}

.steps__idx {
  grid-row: span 2;
  padding-top: 3px;
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--pink-deep);
  font-variant-numeric: tabular-nums;
}

.steps__item h4 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--text);
}

.steps__item p {
  margin-top: 4px;
  color: var(--text-2);
}

.consult__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 28px;
}

.consult__fee {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-2);
}

.proof {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 14px;
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px dashed rgba(0, 46, 104, 0.22);
}

.proof__stat {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--navy);
}

.proof__count {
  font-weight: 700;
  color: var(--text);
}

.proof__scope {
  flex-basis: 100%;
  font-size: 0.8125rem;
  color: var(--text-2);
}

.proof__scope a {
  font-weight: 700;
  color: var(--navy);
}

@media (min-width: 720px) {
  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
  }
}

@media (min-width: 1024px) {
  .consult__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(48px, 6vw, 112px);
    align-items: start;
  }

  .clinician {
    margin-top: 40px;
    padding: 32px 32px 28px;
  }

  .clinician::before {
    left: 32px;
  }

  .consult__first {
    padding-top: 10px;
  }
}

/* ---------- Journey + investment ---------- */

.costs {
  position: relative;
  overflow: hidden;
  padding-block: var(--pad);
  background:
    radial-gradient(60% 50% at 88% 0%, rgba(78, 130, 200, 0.22) 0%, rgba(78, 130, 200, 0) 70%),
    linear-gradient(180deg, var(--navy) 0%, #00285B 100%);
  color: var(--white);
}

.costs .section-head h2 {
  color: var(--white);
}

.costs__grid {
  display: grid;
  gap: 40px;
  margin-top: clamp(36px, 4vw, 60px);
}

.journey {
  position: relative;
  display: grid;
  gap: 30px;
  padding-left: 34px;
}

.journey::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 10px;
  bottom: 10px;
  width: 1px;
  background: linear-gradient(180deg, var(--pink) 0%, rgba(214, 232, 255, 0.35) 30%, rgba(214, 232, 255, 0.2) 100%);
}

.journey__step {
  position: relative;
}

.journey__node {
  position: absolute;
  left: -34px;
  top: 4px;
  width: 13px;
  height: 13px;
  border: 1px solid rgba(214, 232, 255, 0.7);
  border-radius: 50%;
  background: var(--navy);
}

.journey__step:first-child .journey__node {
  border-color: var(--pink);
  background: var(--pink);
  box-shadow: 0 0 0 5px rgba(253, 57, 110, 0.22);
}

.journey__idx {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-3);
}

.journey__step h3 {
  margin-top: 6px;
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.journey__step p:last-child {
  margin-top: 6px;
  max-width: 30rem;
  color: var(--on-dark-2);
}

.invest {
  padding: 28px 22px 24px;
  border-radius: var(--radius-lg);
  background: var(--white);
  color: var(--text);
  box-shadow: 0 50px 90px -50px rgba(0, 10, 30, 0.75);
}

.invest__kicker {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-2);
}

.prices {
  margin-top: 14px;
  border-top: 1px solid var(--line-light);
}

.prices__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line-light);
}

.prices dt {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text);
}

.prices dt span {
  display: block;
  margin-top: 2px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--text-2);
}

.prices dd {
  flex: none;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}

.prices__from {
  margin-right: 4px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-2);
}

.invest .fineprint {
  margin-top: 14px;
}

.terms {
  display: grid;
  gap: 12px;
  margin: 22px 0 24px;
  padding: 18px;
  border-radius: var(--radius-sm);
  background: var(--ice);
}

.terms li {
  display: grid;
  gap: 2px;
  font-size: 0.9375rem;
}

.terms strong {
  font-weight: 800;
  color: var(--navy);
}

.terms span {
  color: var(--text-2);
}

@media (min-width: 640px) {
  .invest {
    padding: 36px 36px 32px;
  }

  .terms li {
    grid-template-columns: minmax(0, 12.5rem) minmax(0, 1fr);
    gap: 16px;
  }
}

@media (min-width: 1024px) {
  .costs__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(48px, 6vw, 112px);
    align-items: start;
  }

  .journey {
    gap: 40px;
    margin-top: 12px;
  }
}

/* ---------- Questions ---------- */

.faq {
  padding-block: var(--pad);
  background: var(--white);
  color: var(--text);
}

.faq__grid {
  display: grid;
  gap: 32px;
}

.faq__list {
  border-top: 1px solid var(--line-light);
}

.qa {
  border-bottom: 1px solid var(--line-light);
}

.qa summary {
  position: relative;
  display: block;
  padding: 22px 56px 22px 0;
  list-style: none;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.015em;
  color: var(--text);
  -webkit-tap-highlight-color: transparent;
}

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

.qa summary::marker {
  content: "";
}

.qa summary:hover .qa__q {
  color: var(--navy);
}

.qa__icon {
  position: absolute;
  right: 2px;
  top: 50%;
  width: 34px;
  height: 34px;
  margin-top: -17px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(0, 46, 104, 0.24);
  transition: background-color 0.25s ease;
}

.qa__icon::before,
.qa__icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 1.5px;
  margin: -0.75px 0 0 -6px;
  background: var(--navy);
  transition: transform 0.3s var(--ease-out), background-color 0.25s ease;
}

.qa__icon::after {
  transform: rotate(90deg);
}

.qa[open] .qa__icon {
  background: var(--ink);
}

.qa[open] .qa__icon::before,
.qa[open] .qa__icon::after {
  background: var(--white);
}

.qa[open] .qa__icon::after {
  transform: rotate(0deg);
}

.qa__a {
  max-width: 44rem;
  padding: 0 56px 24px 0;
  color: var(--text-2);
}

.qa[open] .qa__a {
  animation: qa-in 0.32s var(--ease-out) both;
}

@keyframes qa-in {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}

@media (min-width: 1024px) {
  .faq__grid {
    grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
    gap: clamp(48px, 6vw, 112px);
    align-items: start;
  }

  .qa summary {
    padding-block: 26px;
    font-size: 1.25rem;
  }

  .faq .section-head {
    position: sticky;
    top: calc(var(--header-h) + 40px);
  }
}

/* ---------- Request: embedded form + practical location ---------- */

.request {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: var(--pad);
  background:
    radial-gradient(60% 55% at 88% 18%, rgba(0, 46, 104, 0.62) 0%, rgba(0, 46, 104, 0) 70%),
    var(--ink);
  color: var(--white);
}

/* A quiet echo of the stage aperture */
.request::before {
  content: "";
  position: absolute;
  z-index: -1;
  right: -22vw;
  top: 50%;
  width: min(92vw, 1180px);
  aspect-ratio: 1.45;
  border: 1px solid rgba(214, 232, 255, 0.08);
  border-radius: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

.request__grid {
  display: grid;
  gap: 40px;
}

.request__intro h2 {
  margin-top: 16px;
  color: var(--white);
}

.request__lede {
  margin-top: 16px;
  max-width: 30rem;
  font-size: 1.0625rem;
  color: var(--on-dark-2);
}

.request__fee {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  font-size: 0.9375rem;
  font-weight: 600;
}

.location {
  display: grid;
  gap: 2px;
  margin-top: 32px;
  padding-top: 22px;
  border-top: 1px solid var(--line-dark);
  color: var(--on-dark-2);
}

.location__label {
  margin-bottom: 8px;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-3);
}

.location__name {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--white);
}

.location__tel {
  justify-self: start;
  margin-top: 10px;
  padding: 4px 0;
  border-bottom: 1px solid rgba(253, 57, 110, 0.75);
  font-weight: 700;
  color: var(--white);
  text-decoration: none;
}

.request__card {
  position: relative;
  border-radius: var(--radius-lg);
  background: var(--white);
  color: var(--text);
  box-shadow: 0 50px 100px -60px rgba(0, 0, 0, 0.85);
}

@media (min-width: 1024px) {
  .request__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(48px, 6vw, 112px);
    align-items: start;
  }
}

/* ---------- Shared request form (one DOM, embedded or in the dialog) ---------- */

.rq {
  display: flex;
  flex-direction: column;
}

.rq__body {
  padding: 26px 22px 6px;
}

.rq__actions {
  padding: 14px 22px 24px;
}

.rq__title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--navy);
}

.rq__demo {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--ice);
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--text-2);
}

.rq__tag {
  flex: none;
  margin-top: 1px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.rq__nojs {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: #FFF0F4;
  color: #7A0F2E;
  font-size: 0.875rem;
  font-weight: 600;
}

.rq.is-enhanced .rq__nojs {
  display: none;
}

.rq__fields {
  min-width: 0;
  margin: 18px 0 0;
  padding: 0;
  border: 0;
}

.rq__fields[disabled] {
  opacity: 0.6;
}

.rq__legend {
  float: left;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 0;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-2);
}

.rq__legend span {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

.rq__legend + .field {
  clear: both;
}

.field {
  display: grid;
  gap: 6px;
  padding-top: 14px;
}

.field label {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--text);
}

.field input {
  width: 100%;
  min-height: 52px;
  padding: 12px 16px;
  border: 1px solid rgba(0, 46, 104, 0.3);
  border-radius: 14px;
  background: var(--white);
  color: var(--text);
  font-size: 1rem;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.field input:hover {
  border-color: rgba(0, 46, 104, 0.55);
}

.field input:focus-visible,
.field input:focus {
  outline: 2px solid var(--pink);
  outline-offset: 2px;
  border-color: var(--navy);
}

.field input[aria-invalid="true"] {
  border-color: #B0103F;
  box-shadow: inset 0 0 0 1px #B0103F;
}

.field__error {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
  color: #B0103F;
}

.field__error::before {
  content: "!";
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  border-radius: 50%;
  background: #B0103F;
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 800;
}

.rq__done {
  margin-top: 18px;
  padding: 22px;
  border-radius: var(--radius-md);
  background: var(--ice);
}

.rq__done:focus {
  outline: none;
}

.rq__done:focus-visible {
  outline: 2px solid var(--pink);
  outline-offset: 3px;
}

.rq__done-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--ink);
}

.rq__done-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--pink);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.rq__done-title {
  margin-top: 14px;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--navy);
}

.rq__done p:last-child {
  margin-top: 4px;
  color: var(--text-2);
}

.rq[data-state="complete"] .rq__done {
  animation: panel-in 0.3s var(--ease-out) both;
}

.rq__after {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.rq__after .btn {
  flex: 1 1 auto;
}

.request__card .rq__close {
  display: none;
}

@media (min-width: 640px) {
  .rq__body {
    padding: 34px 36px 8px;
  }

  .rq__actions {
    padding: 16px 36px 32px;
  }
}

/* ---------- Full-screen request dialog (desktop and mobile) ---------- */

/* Height and offset follow the visual viewport (set in app.js), so the action
   bar stays above an open on-screen keyboard. */
.dialog {
  position: fixed;
  left: 0;
  right: 0;
  top: var(--vvt, 0px);
  z-index: 90;
  display: flex;
  height: var(--vvh, 100vh);
  color: var(--white);
}

.dialog__backdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(70% 60% at 80% 30%, rgba(0, 46, 104, 0.78) 0%, rgba(0, 46, 104, 0) 70%),
    var(--ink);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.dialog__backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url("assets/clear-aligner-illustration.webp") 72% 42% / cover no-repeat;
  opacity: 0.3;
  -webkit-mask-image: radial-gradient(ellipse 55% 60% at 72% 42%, #000 30%, transparent 85%);
  mask-image: radial-gradient(ellipse 55% 60% at 72% 42%, #000 30%, transparent 85%);
}

.dialog.is-open .dialog__backdrop {
  opacity: 1;
}

.dialog__frame {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  min-height: 0;
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.2s ease, transform 0.24s var(--ease-out);
}

.dialog.is-open .dialog__frame {
  opacity: 1;
  transform: none;
}

.dialog__close {
  position: absolute;
  top: max(12px, env(safe-area-inset-top));
  right: max(12px, env(safe-area-inset-right));
  z-index: 2;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(214, 232, 255, 0.34);
  border-radius: 50%;
  background: rgba(7, 28, 43, 0.6);
  color: var(--white);
  cursor: pointer;
  transition: background-color 0.18s ease;
}

.dialog__close:hover {
  background: rgba(255, 255, 255, 0.12);
}

.dialog__close svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.dialog__head {
  flex: none;
  padding: max(18px, env(safe-area-inset-top)) 72px 18px max(20px, env(safe-area-inset-left));
}

.dialog__eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-2);
}

.dialog__title {
  margin-top: 10px;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1rem + 2.4vw, 2.75rem);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--white);
  text-wrap: balance;
}

.dialog__title:focus {
  outline: none;
}

.dialog__title:focus-visible {
  outline: 2px solid var(--pink);
  outline-offset: 6px;
}

.dialog__desc {
  margin-top: 8px;
  font-size: 0.9375rem;
  color: var(--on-dark-2);
}

.dialog__slot {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  border-radius: 24px 24px 0 0;
  background: var(--white);
  color: var(--text);
}

.dialog .rq {
  flex: 1 1 auto;
  min-height: 0;
}

.dialog .rq__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 22px max(20px, env(safe-area-inset-right)) 14px max(20px, env(safe-area-inset-left));
}

.dialog .rq__title {
  display: none;
}

.dialog .rq__demo {
  margin-top: 0;
}

.dialog .rq__actions {
  flex: none;
  padding: 12px max(20px, env(safe-area-inset-right)) max(14px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  border-top: 1px solid var(--line-light);
  background: var(--white);
}

/* Keyboard open or short landscape: give the fields the room */
.dialog.is-tight .dialog__eyebrow,
.dialog.is-tight .dialog__desc {
  display: none;
}

.dialog.is-tight .dialog__head {
  padding-top: 12px;
  padding-bottom: 12px;
}

.dialog.is-tight .dialog__title {
  margin-top: 2px;
  font-size: 1.1875rem;
}

.dialog.is-tight .dialog__close {
  top: 6px;
  width: 40px;
  height: 40px;
}

.dialog.is-tight .rq__body {
  padding-top: 14px;
}

.dialog.is-tight .rq__actions {
  padding-top: 10px;
  padding-bottom: 10px;
}

@media (min-width: 900px) and (min-height: 620px) {
  .dialog__frame {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 34rem);
    align-items: center;
    gap: clamp(32px, 5vw, 96px);
    max-width: calc(var(--container) + 2 * var(--gutter));
    margin: 0 auto;
    padding: 48px var(--gutter);
  }

  .dialog__head {
    padding: 0;
  }

  .dialog__title {
    margin-top: 16px;
    font-size: clamp(2.25rem, 1rem + 2.6vw, 3.5rem);
  }

  .dialog__desc {
    margin-top: 14px;
    font-size: 1.0625rem;
  }

  .dialog__slot {
    flex: none;
    max-height: calc(var(--vvh, 100vh) - 96px);
    border-radius: var(--radius-lg);
    box-shadow: 0 60px 120px -60px rgba(0, 0, 0, 0.9);
  }

  .dialog .rq__body {
    padding: 32px 36px 12px;
  }

  .dialog .rq__actions {
    padding: 16px 36px 28px;
  }

  .dialog__close {
    top: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
  }
}

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

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

.clinic-footer {
  padding: 56px 0 48px;
  border-top: 1px solid var(--line-dark);
  background: var(--ink-3);
  color: var(--on-dark-2);
  font-size: 0.9375rem;
}

.clinic-footer__grid {
  display: grid;
  gap: 28px;
}

.clinic-footer__name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--white);
}

.clinic-footer address {
  margin-top: 8px;
}

.clinic-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  margin-top: 10px;
}

.clinic-footer__links a {
  padding: 4px 0;
  border-bottom: 1px solid rgba(214, 232, 255, 0.3);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
}

.clinic-footer__notes {
  display: grid;
  gap: 10px;
  max-width: 48rem;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--on-dark-3);
}

.clinic-footer__notes a {
  color: var(--on-dark-2);
}

@media (min-width: 1024px) {
  .clinic-footer__grid {
    grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
    gap: 64px;
  }
}

/* ---------- MATRAFOX continuation (separate from the clinic page) ---------- */

.agency {
  padding: clamp(64px, 7vw, 104px) 0 calc(clamp(64px, 7vw, 104px) + env(safe-area-inset-bottom));
  background: #F4F4F1;
  color: #0E0E10;
}

.agency__grid {
  display: grid;
  gap: 28px;
}

.agency__mark {
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.26em;
}

.agency__mark span {
  font-weight: 500;
  color: #55555C;
}

.agency h2 {
  margin-top: 18px;
  font-size: clamp(1.75rem, 1.1rem + 2vw, 2.75rem);
  color: #0E0E10;
}

.agency__body {
  display: grid;
  gap: 16px;
  max-width: 40rem;
  color: #3A3A40;
}

.agency__facts {
  display: grid;
  gap: 6px;
  padding: 16px 0;
  border-block: 1px solid rgba(0, 0, 0, 0.1);
  font-size: 0.875rem;
}

.agency__facts li {
  position: relative;
  padding-left: 18px;
}

.agency__facts li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #0E0E10;
}

.agency__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  margin-top: 4px;
}

.agency__btn {
  background: #0E0E10;
  color: var(--white);
}

.agency__btn:hover {
  background: #2A2A30;
}

.agency__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid currentColor;
  font-weight: 800;
  color: #0E0E10;
  text-decoration: none;
}

.agency__link svg,
.owner-card__link svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.agency__attr {
  font-size: 0.8125rem;
  color: #55555C;
}

.agency__attr a {
  font-weight: 800;
  color: #0E0E10;
}

@media (min-width: 1024px) {
  .agency__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(48px, 6vw, 112px);
  }
}

/* ---------- Mobile sticky CTA dock ---------- */

.dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  padding: 10px max(16px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  background: rgba(7, 28, 43, 0.94);
  box-shadow: 0 -1px 0 var(--line-dark);
  transform: translateY(110%);
  visibility: hidden;
  transition: transform 0.3s var(--ease-out), visibility 0s linear 0.3s;
}

@supports ((-webkit-backdrop-filter: blur(8px)) or (backdrop-filter: blur(8px))) {
  .dock {
    background: rgba(7, 28, 43, 0.8);
    -webkit-backdrop-filter: saturate(140%) blur(14px);
    backdrop-filter: saturate(140%) blur(14px);
  }
}

.dock.is-visible {
  transform: none;
  visibility: visible;
  transition: transform 0.3s var(--ease-out), visibility 0s;
}

.dock .btn {
  --btn-h: 50px;
  padding: 0 12px;
}

@media (min-width: 1024px) {
  .dock {
    display: none;
  }
}

/* ---------- Owner preview card (MATRAFOX navigation, not the clinic CTA) ---------- */

.owner-card {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: calc(16px + env(safe-area-inset-bottom));
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: calc(100vw - 32px);
  padding: 6px 6px 6px 16px;
  border-radius: 999px;
  background: #F4F4F1;
  color: #0E0E10;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(0, 0, 0, 0.08);
  transition: opacity 0.25s ease, transform 0.25s var(--ease-out), visibility 0s;
}

.owner-card.is-away {
  opacity: 0;
  transform: translateY(12px);
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s var(--ease-out), visibility 0s linear 0.25s;
}

.owner-card__label {
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #55555C;
  white-space: nowrap;
}

.owner-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  font-size: 0.875rem;
  font-weight: 800;
  color: #0E0E10;
  text-decoration: none;
  white-space: nowrap;
}

.owner-card__link:hover {
  text-decoration: underline;
}

.owner-card__close {
  display: none;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.07);
  color: #0E0E10;
  cursor: pointer;
}

.owner-card__close:hover {
  background: rgba(0, 0, 0, 0.12);
}

.owner-card.is-enhanced .owner-card__close {
  display: grid;
}

.owner-card__close svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

@media (max-width: 1023px) {
  body.has-dock .owner-card {
    bottom: calc(80px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 420px) {
  .owner-card__label {
    display: none;
  }
}

/* ---------- Reveal and reduced motion ---------- */

.js .reveal-wait {
  opacity: 0;
  transform: translateY(18px);
}

.js .reveal-wait.is-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: var(--rd, 0s);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
  }

  .hero__sheen,
  .stage__sweep {
    display: none;
  }

  .js .reveal-wait {
    opacity: 1;
    transform: none;
  }
}

/* ---------- /ads/ gallery route ---------- */

.ads-page {
  color: var(--white);
}

.ads-top {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(7, 28, 43, 0.94);
  box-shadow: 0 1px 0 var(--line-dark);
}

.ads-top__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
}

.ads-back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 20px 0 16px;
  border-radius: 999px;
  background: #F4F4F1;
  color: #0E0E10;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.ads-back:hover {
  background: var(--white);
}

.ads-back svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ads-top__label {
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-3);
  text-align: right;
}

.ads-intro {
  padding: clamp(48px, 7vw, 96px) 0 36px;
}

.ads-title {
  margin-top: 16px;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 1.4rem + 3vw, 4rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.035em;
}

.ads-lede {
  margin-top: 16px;
  max-width: 36rem;
  font-size: 1.0625rem;
  color: var(--on-dark-2);
}

.ads-gallery {
  padding-bottom: var(--pad);
}

.ads-grid {
  display: grid;
  gap: 28px;
}

.ad-slot__frame {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--ink-2);
  box-shadow: inset 0 0 0 1px var(--line-dark);
}

.ad-slot__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ad-slot__pending {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  color: var(--on-dark-3);
  background: repeating-linear-gradient(135deg, rgba(214, 232, 255, 0.045) 0 1px, transparent 1px 14px);
}

.ad-slot__pending span {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--white);
}

.ad-slot__pending p {
  max-width: 16rem;
  font-size: 0.875rem;
}

.ad-slot__meta {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 14px;
  font-size: 0.875rem;
  color: var(--on-dark-2);
}

.ad-slot__idx {
  font-family: var(--font-display);
  color: var(--pink);
}

.ads-note {
  margin-top: 32px;
  font-size: 0.8125rem;
  color: var(--on-dark-3);
}

.clinic-footer--compact {
  padding: 36px 0;
}

.clinic-footer--compact p + p {
  margin-top: 6px;
}

.clinic-footer--compact a {
  color: var(--white);
}

@media (min-width: 720px) {
  .ads-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
  }
}

/* Codex: agency-owned presentation identity, distinct from clinic UI */
.agency{background:#0a0a0a;border-top:6px solid #ff6700;color:#fff}.agency__mark{display:flex;flex-wrap:wrap;align-items:center;gap:14px}.agency__mark img{width:260px;max-width:100%;height:auto}.agency__mark span{color:#fff;letter-spacing:.18em;font-size:12px}.agency__btn{background:#ff6700;color:#101010;border-color:#ff6700}.agency__attr a{color:#ff9753}.ad-slot__frame img{width:100%;height:auto;display:block}.ad-slot__frame{aspect-ratio:1122/1402}.ads-copy{padding:40px var(--gutter) 80px}.ads-copy h2{font:600 clamp(28px,3vw,40px)/1.2 var(--font-display);margin-bottom:20px}.ads-copy article{padding:24px 0;border-top:1px solid var(--line-light)}.ads-copy article h3{margin:0 0 12px}.ads-copy p{max-width:850px;line-height:1.7}.ads-copy a{color:var(--navy);text-decoration:underline}
/* Codex QA corrections: cover the reserved desktop gutter; agency contrast */
.dialog{width:100vw}
.agency .agency__intro h2,.agency .agency__mark,.agency .agency__attr{color:#fff}
.agency .agency__body p,.agency .agency__facts,.agency .agency__link{color:#d7d7d7}
.agency .agency__mark img{filter:invert(1)}
.agency .agency__attr a{color:#ff9753}
.ads-copy a{color:#bdd7f3}
