/* ==========================================================
   RS Dental Clinic — base styles
   Palette "Logo" (every colour comes from the logo: its teal, sandy gold and warm white)
   Split 60 / 30 / 10: light neutrals (ivory, mist) / teal / gold accents.
   Gold is jewellery: details only (labels, signature, thin lines, dots), never a surface.
   Fonts: Inter Tight (text), Instrument Serif italic (accents),
          Cinzel (labels, from the logo), Great Vibes (signature)
   ========================================================== */

:root {
  /* Teal: the brand (30 %) */
  --teal-950: #03262b;   /* footer, deepest */
  --teal-900: #06343b;   /* ink: all text, dark sections */
  --teal-800: #0b5258;   /* hero background */
  --teal-700: #025460;   /* the logo's teal: primary buttons, final call to action */

  /* Neutrals: the backgrounds (60 %) */
  --ivory: #f8f6f1;      /* main light background, warm like the logo's white */
  --mist:  #e6f1f0;      /* fresh clinic background: contact */
  --white: #ffffff;      /* cards only, never a section background */

  /* Gold: jewellery (10 %) */
  --gold-600: #9a7a42;   /* gold on light: labels, signature */
  --gold-500: #c4a56a;   /* the logo's gold: lines, dots, icons */
  --gold-400: #d6bb82;   /* gold for the letter-by-letter titles on dark (a gradient can't follow animated letters) */
  --gold-300: #e3cf9f;   /* gold text on dark */
  /* polished gold for large italic words on dark: light catching a metal surface */
  --gold-metal: linear-gradient(100deg, #8a6b36 0%, #c4a56a 28%, #ead6a4 48%, #c4a56a 66%, #9a7a42 100%);

  /* Text */
  --text:       #06343b;
  --text-muted: #4a6b6f;

  /* Fonts */
  --font-display: "Inter Tight", system-ui, sans-serif;
  --font-serif:   "Instrument Serif", Georgia, serif;
  --font-label:   "Cinzel", Georgia, serif;
  --font-script:  "Great Vibes", cursive;
  --font-body:    "Inter Tight", system-ui, sans-serif;

  /* Layout */
  --container: 1200px;
  --gutter: 20px;
  --section-pad: 96px;
  --radius: 14px;
  --header-h: 80px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

/* Lenis smooth scrolling (js/smooth.js) */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* Reveal on scroll: content glides up softly as it enters the screen */
.js-reveal .reveal {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition:
    opacity .6s cubic-bezier(.16, 1, .3, 1) var(--reveal-delay, 0ms),
    transform .65s cubic-bezier(.16, 1, .3, 1) var(--reveal-delay, 0ms);
}
.js-reveal .reveal.is-visible {
  opacity: 1;
  transform: none;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--teal-900);
  line-height: 1.15;
  margin: 0 0 .5em;
}

/* Italic serif accent inside headings: <h2>Complete care <em>for every smile</em></h2> */
h1 em, h2 em, h3 em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--teal-700);
}

/* ----- Layout helpers ----- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-pad); }

/* Small capital label above headings (Cinzel, like the logo) */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  font-family: var(--font-label);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold-600);
}
.eyebrow::before {
  content: "";
  width: 32px;
  height: 1px;
  background: var(--gold-500);
}

/* Centered heading block used at the top of sections */
.section-head {
  max-width: 680px;
  margin: 0 auto 56px;
  text-align: center;
}
.section-head h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 16px;
}
.section-head p:not(.eyebrow) {
  margin: 0;
  font-size: 17px;
  color: var(--text-muted);
}
.section-head .eyebrow::after {
  content: "";
  width: 32px;
  height: 1px;
  background: var(--gold-500);
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}
.btn-primary { background: var(--teal-700); color: var(--white); }
.btn-primary:hover { background: var(--teal-900); color: var(--white); }
.btn-outline { border-color: var(--teal-900); color: var(--teal-900); }
.btn-outline:hover { background: var(--teal-900); color: var(--white); }
.btn-light { border-color: rgba(255, 255, 255, .7); color: var(--white); }
.btn-light:hover { background: var(--ivory); border-color: var(--ivory); color: var(--teal-900); }
/* on dark backgrounds: an ivory button (gold stays for details) */
.btn-ivory { background: var(--ivory); color: var(--teal-900); }
.btn-ivory:hover { background: var(--gold-300); color: var(--teal-900); }

/* ----- Header ----- */
/* Transparent over the dark hero; a soft frosted bar appears once the page scrolls.
   The logo, links and button are light at all times (both backgrounds are dark). */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background .3s ease, border-color .3s ease, backdrop-filter .3s ease;
}
/* Scrolled: deep teal that fades into the page, with a soft blur behind it */
.site-header { isolation: isolate; }
.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 -48px 0;
  z-index: -1;
  opacity: 0;
  background: linear-gradient(180deg, rgba(6, 52, 59, .78) 0%, rgba(6, 52, 59, .55) 50%, rgba(6, 52, 59, 0) 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
  transition: opacity .45s ease;
  pointer-events: none;
}
.site-header.is-scrolled::before { opacity: 1; }
.site-header .brand,
.site-header .brand-mark,
.site-header .brand-name,
.site-header .main-nav a,
.site-header .nav-toggle span { transition: color .45s ease, stroke .45s ease, background .45s ease; }
.site-header .brand { color: var(--white); }
.site-header .brand-mark { stroke: var(--white); }
.site-header .brand-name b,
.site-header .brand-script { color: var(--gold-300); }
.site-header .header-cta { background: var(--ivory); color: var(--teal-900); }
.site-header .header-cta:hover { background: var(--gold-300); color: var(--teal-900); }
.site-header .nav-toggle { border-color: rgba(255, 255, 255, .4); }
.site-header .nav-toggle span { background: var(--white); }

/* Desktop menu on the dark bar: light links, a hairline under them, the current section underlined */
@media (min-width: 901px) {
  .main-nav ul { position: relative; padding-bottom: 12px; margin-bottom: -13px; border-bottom: 1px solid transparent; transition: border-color .45s ease; }
  .main-nav a { position: relative; }
  .main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -13px;
    height: 2px;
    background: currentColor;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .5s cubic-bezier(.16, 1, .3, 1);
  }
  .main-nav a.is-active::after { transform: scaleX(1); }
  .site-header .main-nav ul { border-bottom-color: rgba(255, 255, 255, .22); }
  .site-header .main-nav a { color: rgba(255, 255, 255, .78); }
  .site-header .main-nav a:hover,
  .site-header .main-nav a.is-active { color: var(--white); }
}
.header-inner {
  max-width: none;                          /* full width, aligned with the hero */
  padding-inline: clamp(20px, 3.5vw, 64px);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
/* Text wordmark echoing the logo: tooth + RS DENTAL CLINIC + script name */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--teal-900);
}
.brand-mark {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: var(--teal-900);
  stroke-width: 1.2;
}
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-name {
  font-family: var(--font-label);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .12em;
}
.brand-name b { color: var(--gold-600); font-weight: 500; }
.brand-script {
  font-family: var(--font-script);
  font-size: 17px;
  color: var(--gold-600);
  margin-top: 3px;
}
.main-nav ul { display: flex; gap: 32px; }
.main-nav a { color: var(--teal-900); font-size: 15px; transition: color .2s; }
.main-nav a:hover { color: var(--teal-700); }
.main-nav .nav-cta { display: none; }
.main-nav .btn-primary,
.main-nav .btn-primary:hover { color: var(--white); }

/* Hamburger button (shown on small screens) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 11px;
  border: 1px solid rgba(6, 52, 59, .2);
  border-radius: 10px;
  background: transparent;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: var(--teal-900);
  transition: transform .3s, opacity .2s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.nav-toggle:focus-visible {
  outline: 3px solid var(--gold-500);
  outline-offset: 2px;
}

/* ----- 01 Hero ----- */
.hero {
  position: relative;
  z-index: 2;            /* above the next section, so the tooth can hang over it */
  overflow: visible;     /* the waves stay inside (their canvas is inset 0); the tooth may overflow */
  overflow-x: clip;
  /* exactly one screen tall on any device (svh = visible height on phones) */
  height: 100vh;                            /* full screen; the header floats on top */
  height: 100svh;
  min-height: 300px;
  display: flex;
  background:
    radial-gradient(ellipse at 50% 72%, rgba(248, 246, 241, .07), transparent 55%),
    var(--teal-800);
  color: var(--ivory);
  padding-block: calc(var(--header-h) + 28px) 0; /* room for the header; content runs to the bottom edge */
}
/* Animated waves behind the hero content */
.hero-waves {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.hero-waves.is-ready { opacity: 1; }
.hero-inner {
  z-index: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: none;                          /* full width, no empty side margins */
  padding-inline: clamp(20px, 3.5vw, 64px);
}
.hero-meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
  color: rgba(248, 246, 241, .7);
}
.hero-meta .label {
  font-family: var(--font-label);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ivory);
}
.hero-title {
  position: relative;
  z-index: 1;
  margin: 2.5vh 0 0;
  text-align: center;
  /* follows both the width and the height of the screen */
  font-size: clamp(3.4rem, min(11.5vw, 17vh), 12rem);
  font-weight: 300;
  line-height: .92;
  letter-spacing: -0.045em;
  color: #bcd5d1;
}
/* tone on tone: a pale sea-glass teal, lighter at the top, so the gold word is the one that shines */
.hero-title .line {
  background: linear-gradient(180deg, #d3e5e1 5%, #9fc0bc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-title .line { display: block; }
.hero-title .line--strong { font-weight: 500; }
.hero-title em {
  font-size: 1.08em;
  letter-spacing: -0.02em;
  padding-right: .06em; /* the italic's last letter leans out of its box; keep it inside the gradient */
  color: var(--gold-500);
  background: var(--gold-metal);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Stage: tooth in the middle, text on both sides */
.hero-stage {
  position: relative;
  flex: 1;
  min-height: 0;          /* lets the stage shrink to the space that's left */
  display: grid;
  grid-template-columns: 1fr minmax(260px, 470px) 1fr;
  grid-template-rows: minmax(0, 1fr); /* row = the space left, never the image's own height */
  align-items: stretch;
  gap: 32px;
  margin-top: -5vh;       /* the tooth's crown sits right under the headline */
}
.hero-visual {
  position: relative;
  z-index: 2;
  grid-column: 2;
  grid-row: 1;
  height: calc(100% + 24vh); /* larger tooth that runs past the bottom edge: the roots are cropped */
  min-height: 0;
  will-change: transform; /* glides into the next section while scrolling (main.js) */
}
.hero-visual picture { position: absolute; inset: 0; }
.hero-tooth {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 34px 38px rgba(3, 38, 43, .45));
}
.hero-visual picture { display: block; width: 100%; height: 100%; }
.hero-canvas {
  /* taller than its box so the tilted crown and the root tips are never clipped */
  position: absolute;
  top: -22%;
  left: -10%;
  z-index: 2;
  width: 120%;
  height: 145%;
  display: block;
  pointer-events: none;      /* no CSS filter here: re-shadowing a live 3D canvas every frame is costly */
}
/* Soft teal halo behind the tooth so the white porcelain stands out */
.hero-visual::before {
  content: "";
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 46%;
  width: 115%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(248, 246, 241, .16), rgba(248, 246, 241, .06) 55%, rgba(248, 246, 241, 0) 100%);
  filter: blur(8px);
  pointer-events: none;
  opacity: calc(1 - var(--glide, 0) * .6); /* softer once the tooth sits on the white section */
}
/* once the 3D model is ready, the static image steps aside */
.hero-visual.has-3d picture { visibility: hidden; }

.hero-side { position: relative; z-index: 3; grid-row: 1; align-self: end; padding-bottom: 4vh; }
.hero-side--left { grid-column: 1; }
.hero-side--right { grid-column: 3; justify-self: end; text-align: right; }
.hero-side p {
  max-width: 260px;
  margin: 0 0 clamp(10px, 2.2vh, 20px);
  font-size: clamp(14px, 2.3vh, 18px);
  line-height: 1.35;
  color: rgba(248, 246, 241, .85);
}
.hero-side--right p { margin-left: auto; }
.hero-more { display: none; } /* phones only: see the 560px breakpoint */
.hero-accent {
  font-family: var(--font-serif);
  font-size: 1.15em;
  padding-right: .06em;
  color: var(--gold-500);
  background: var(--gold-metal);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: color .2s;
}
.hero-link:hover { color: var(--teal-700); }
.hero .hero-link { color: var(--ivory); }
.hero .hero-link:hover { color: var(--gold-300); }


/* Short screens (laptops with a small window, landscape tablets):
   tighten the hero so everything still fits in one screen */
@media (min-width: 901px) and (max-height: 760px) {
  .hero { padding-block: calc(var(--header-h) + 1.5vh) 0; }
  .hero-title { margin-top: 1.5vh; }
  .hero-side .btn { padding: 1.2vh 22px; font-size: 14px; }
  .hero-link { font-size: 14px; }
}
@media (min-width: 901px) and (max-height: 560px) {
  .hero-meta { display: none; }
}

/* ----- 02 Trust ----- */
/* A full-screen panel; on desktop the photo behind the statement drifts gently
   as the page scrolls (parallax, main.js). */
.trust {
  --side: clamp(20px, 3.5vw, 64px);  /* same side spacing as the header */
  background: var(--ivory);
  padding-block: 0;
}
.trust-panel {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: calc(var(--header-h) + 24px) 48px;
}
.trust-panel > .container { position: relative; z-index: 1; width: 100%; } /* text sits over the photo */

.trust-photo {
  position: relative;
  z-index: 0;
  margin: -28px var(--gutter) 0 auto; /* tucked under the last line of text */
  max-width: 230px;
  aspect-ratio: 768 / 816;
  border-radius: 22px;
  overflow: hidden;
  background: var(--mist);
  box-shadow: 0 30px 60px -30px rgba(6, 52, 59, .35);
}
.trust-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (min-width: 901px) {
  /* statement sits in the upper part of the screen */
  .trust-panel { justify-content: flex-start; padding-top: calc(var(--header-h) + 9vh); }
  /* let the statement run out to the same right edge as the header button */
  /* the statement never takes more than 62% of the screen, so the jaw always has room beside it */
  .trust .trust-statement { max-width: min(840px, 62vw); margin-right: calc(-1 * max(0px, 50vw - var(--container) / 2 + var(--gutter) - var(--side))); }
  .trust-photo {
    position: absolute;
    right: calc(var(--side) + 6vw);
    bottom: 11vh;           /* where it rests, just below the statement */
    width: auto;
    height: min(30vh, 19vw);
    max-width: none;
    margin: 0;
  }
}
@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  .trust-photo, .trust-photo img { will-change: transform; } /* moved by the scroll (main.js) */
}

/* The open jaw the hero tooth settles into (js/jaw3d.js).
   Desktop: in the free space left of the statement. Phones: under the text, left of the photo. */
.trust-jaw {
  position: absolute;
  z-index: 0;
  pointer-events: none;
}
.trust-jaw canvas { display: block; width: 100%; height: 100%; }
/* desktop: the jaw's canvas moves to this fixed layer, which follows its spot (main.js) */
.jaw-float { position: fixed; z-index: 1; pointer-events: none; will-change: transform; }
.jaw-float canvas { display: block; width: 100%; height: 100%; }
/* the clinic title appears behind the jaw as it crosses the screen: a soft edge follows the jaw */
.clinic-title.is-revealed-by-jaw {
  -webkit-mask-image: linear-gradient(90deg, #000 calc(var(--reveal, 0px) - 80px), transparent var(--reveal, 0px));
  mask-image: linear-gradient(90deg, #000 calc(var(--reveal, 0px) - 80px), transparent var(--reveal, 0px));
}
@media (min-width: 901px) {
  .trust-jaw {
    left: var(--side);
    top: calc(var(--header-h) + 1vh);
    /* exactly the free space left of the statement (its width, the side margins, a small gap) */
    width: clamp(240px, calc(100vw - min(840px, 62vw) - 2 * var(--side) - 2vw), 900px);
    height: min(72vh, 880px);
  }
}
@media (max-width: 900px) {
  .trust-jaw {
    left: var(--gutter);
    bottom: 76px;
    width: calc(100% - 2 * var(--gutter) - 110px);
    height: 250px;
  }
}
/* phones and tablets: the statement starts right after the hero, with a smaller photo
   that drifts up into place as on desktop (main.js) */
@media (max-width: 900px) {
  .trust-panel { min-height: 0; justify-content: flex-start; padding-block: 56px 96px; } /* bottom: room for the photo to rise from */
  .trust-photo { max-width: 120px; margin-top: 96px; } /* below the text, beside the jaw */
}
@media (max-width: 900px) and (prefers-reduced-motion: no-preference) {
  .trust-photo, .trust-photo img { will-change: transform; }
}


.trust-statement {
  margin: 0 0 0 auto; /* sits on the right side of the page */
  max-width: 1120px;
  font-size: clamp(1.6rem, 3.3vw, 3.2rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-indent: 22%;
}
.trust-statement em { font-size: 1.06em; }

/* Rounded picture pills inside the statement */
.pill {
  --velvet: var(--teal-950); /* the dark teal at the edges of the gold photos */
  display: inline-block;
  width: 1.9em;
  height: .9em;
  margin: 0 .12em;
  border-radius: 999px;
  vertical-align: -0.06em;
  /* the whole object stays in view: the photo fits the pill's height and its
     sides melt into the same deep teal */
  background:
    linear-gradient(90deg, var(--velvet) 4%, transparent 22%, transparent 78%, var(--velvet) 96%),
    var(--pill-photo) center / auto 100% no-repeat,
    var(--velvet);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .6);
}
.pill--a { --pill-photo: url("../assets/images/pill-gold-teeth.webp"); }
.pill--b { --pill-photo: url("../assets/images/pill-gold-tooth.webp"); }

/* ----- 03 Inside the clinic (photo gallery) -----
   Phones / no JS: a row of photos you swipe sideways.
   Desktop: main.js adds .is-pinned; the panel then stays on screen while the
   vertical scroll slides the row sideways, like the reference video. */
.clinic {
  --side: clamp(20px, 3.5vw, 64px);
  position: relative;
  z-index: 3; /* rises over the About section (and the tooth) */
  background: var(--teal-900);
}
.clinic-title {
  max-width: 900px;
  margin: 0 auto 40px;
  padding-inline: var(--side);
  font-size: clamp(1.8rem, 3.4vw, 3.2rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.03em;
  text-align: center;
  color: var(--white);
}
.clinic-title em,
.clinic-closing em { color: var(--gold-400); }
/* closing line: on phones it sits under the photos; on desktop it is written over the
   full-screen photo at the end of the gallery */
.clinic-closing {
  margin: 40px auto 0;
  padding-inline: var(--side);
  max-width: 900px;
  font-size: clamp(1.8rem, 3.4vw, 3.2rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.03em;
  text-align: center;
  color: var(--white);
}
/* letter-by-letter blur effect (main.js splits the line into .tx-char spans) */
.tx-word { display: inline-block; white-space: nowrap; }
.tx-ready .tx-char {
  display: inline-block;
  opacity: 0;
  filter: blur(10px) brightness(0%);
  transition: opacity .9s ease, filter .9s ease, transform .9s ease;
  transition-delay: calc(var(--i) * 30ms);
}
.tx-ready.is-in .tx-char { opacity: 1; filter: blur(0) brightness(100%); transform: none; }
.tx-ready.is-out .tx-char { opacity: 0; filter: blur(10px) brightness(0%); transform: translateY(-30px); }
.clinic-pin {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100vh;
  min-height: 100svh;
  padding-block: calc(var(--header-h) + 24px) 48px;
}
.clinic-track {
  display: flex;
  gap: clamp(14px, 1.6vw, 28px);
  padding-inline: var(--side);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.clinic-track::-webkit-scrollbar { display: none; }
.clinic-shot {
  flex: none;
  width: 82vw;
  height: 52svh;
  margin: 0;
  overflow: hidden;
  border-radius: 4px;
  scroll-snap-align: center;
  background: linear-gradient(135deg, var(--teal-900), var(--teal-700) 60%, var(--teal-800));
}
.clinic-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* the About panel waits underneath while the clinic section slides up over it */
@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {
  .stack .trust { position: sticky; top: 0; }
  /* the tooth settles into the jaw (main.js: 25vh of scroll) before the wall comes */
  .trust-hold { height: 30vh; }
}
/* in the pinned layout the line sits centred; the photos then rise up from below */
.clinic.is-pinned .clinic-title {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  margin: 0 auto;
  transform: translateY(-50%);
}
/* at the very end the screen deepens into the plain teal of the next section (main.js) */
.clinic-fade { display: none; }
.clinic.is-pinned .clinic-fade {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 3;
  background: var(--teal-900);
  opacity: 0;
  pointer-events: none;
}
.clinic.is-pinned .clinic-closing {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  z-index: 4;            /* stays above the final teal fade */
  margin: 0 auto;
  transform: translateY(-50%);
  text-shadow: 0 2px 30px rgba(3, 38, 43, .35);
}
.clinic.is-pinned .clinic-pin {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}
.clinic.is-pinned .clinic-track {
  overflow: visible;
  will-change: transform;
}
.clinic.is-pinned .clinic-shot { height: min(62vh, 46vw); }
.clinic.is-pinned .clinic-shot--wide { width: min(72vw, 120vh); }
.clinic.is-pinned .clinic-shot--mid { width: min(52vw, 86vh); }
.clinic.is-pinned .clinic-shot--narrow { width: min(32vw, 54vh); }
/* the last photo is the widest: it ends centred, then grows to fill the whole screen */
.clinic.is-pinned .clinic-shot--last { width: min(80vw, 132vh); position: relative; z-index: 1; will-change: transform; }
/* once it fills the screen, a light veil dims it a little (opacity set by main.js):
   a soft neutral shade, darker towards the bottom, with only a hint of blur */
.clinic-shot--last::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: var(--veil, 0);
  background: linear-gradient(180deg, rgba(3, 38, 43, .12), rgba(3, 38, 43, .38));
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  pointer-events: none;
}
/* the picture drifts a little inside its frame while the row slides */
.clinic.is-pinned .clinic-img { width: 112%; max-width: none; margin-left: -6%; will-change: transform; }

/* ----- 04 Our Services -----
   Phones / reduced motion: a simple list of services.
   Desktop: main.js adds .is-pinned; the panel stays on screen while a large wheel on the
   left turns, bringing each numbered service to the connector line and swapping the text. */
.services {
  --side: clamp(20px, 3.5vw, 64px);
  position: relative;
  background: var(--teal-900);
  color: var(--white);
}
.svc-pin {
  position: relative;
  padding: calc(var(--header-h) + 40px) var(--side) 72px;
}
.services-title {
  margin: 0 0 40px;
  font-size: clamp(2.2rem, 4.4vw, 4.2rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--white);
}
.services-title em { font-size: 1.06em; }

/* the wheel, the connector and the counter only exist in the pinned layout */
.svc-wheel,
.svc-link,
.svc-count { display: none; }

.svc-slide {
  position: relative;
  padding: 28px 0;
  border-top: 1px solid rgba(248, 246, 241, .14);
}
.svc-ghost {
  display: block;
  margin-bottom: 10px;
  font-family: var(--font-serif);
  font-size: 15px;
  color: rgba(248, 246, 241, .62);
}
.svc-slide h3 {
  margin: 0 0 12px;
  font-size: clamp(1.7rem, 3vw, 3rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--white);
}
.svc-slide h3 em { font-size: 1.06em; }
.svc-slide p {
  max-width: 460px;
  margin: 0 0 18px;
  font-size: 17px;
  line-height: 1.55;
  color: rgba(248, 246, 241, .78);
}
.svc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.svc-tags li {
  padding: 7px 14px;
  border: 1px solid rgba(248, 246, 241, .24);
  border-radius: 999px;
  font-size: 13px;
  color: var(--mist);
}
.svc-cta {
  margin: 32px 0 0;
  font-size: 15px;
  color: rgba(248, 246, 241, .7);
}
.svc-cta .hero-link { margin-left: 6px; color: var(--white); }

/* ---------- pinned wheel (desktop) ---------- */
.services.is-pinned {
  --d: min(96vh, 64vw);                      /* wheel diameter */
  --link-x: calc(var(--d) * .56);            /* the rim at 3 o'clock (most of the wheel is off-screen) */
  --link-w: clamp(110px, 11vw, 190px);       /* connector length */
}
.services.is-pinned .svc-pin {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  padding: 0;
  overflow: hidden;
}
.services.is-pinned .services-title {
  position: absolute;
  top: calc(var(--header-h) + 3vh);
  left: 0;
  right: 0;
  margin: 0;
  text-align: center;
}
.services.is-pinned .svc-wheel {
  display: block;
  position: absolute;
  top: 56%;
  left: calc(var(--d) * -.44);
  width: var(--d);
  height: var(--d);
  transform: translateY(-50%);
  border: 1px solid rgba(248, 246, 241, .26);
  border-radius: 50%;
  background: radial-gradient(circle at 72% 50%, rgba(248, 246, 241, .06), rgba(6, 52, 59, 0) 62%);
}
.svc-teeth {
  position: absolute;
  left: 72%;                 /* centre of the visible part of the circle */
  top: 50%;
  width: 30%;
  aspect-ratio: 481 / 655;
  transform: translate(-50%, -50%);
}
.svc-tooth {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transform: scale(.9) rotate(-8deg);
  filter: drop-shadow(0 30px 40px rgba(0, 0, 0, .35)) blur(6px);
  transition: opacity .8s ease, transform 1.1s cubic-bezier(.16, 1, .3, 1), filter .8s ease;
}
.svc-tooth.is-active {
  opacity: 1;
  transform: none;
  filter: drop-shadow(0 30px 40px rgba(0, 0, 0, .35)) blur(0);
}
/* numbered marks around the rim (placed by main.js) */
.svc-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  transition: opacity .3s ease;
}
.svc-dot {
  position: absolute;
  left: -4px;
  top: -4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e2c98a;
}
.svc-badge {
  position: absolute;
  left: var(--bx, 0px);
  top: var(--by, 0px);
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin: -15px 0 0 -15px;
  border: 1px solid rgba(248, 246, 241, .5);
  border-radius: 50%;
  font-size: 13px;
  color: var(--mist);
  transition: opacity .4s ease;
}
/* the active number is shown big on the connector instead */
.svc-mark.is-active .svc-badge { opacity: 0; }
.services.is-pinned .svc-link {
  display: flex;
  align-items: center;
  position: absolute;
  top: 56%;
  left: var(--link-x);
  width: var(--link-w);
  height: 1px;
  background: rgba(248, 246, 241, .7);
}
.svc-link-num {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin-left: auto;
  margin-right: -29px;
  border-radius: 50%;
  background: var(--mist);
  font-family: var(--font-display);
  font-size: 26px;
  color: var(--teal-900);
  box-shadow: 0 0 0 8px rgba(248, 246, 241, .08);
}
.svc-link-num.is-swapping { animation: svc-pop .6s cubic-bezier(.16, 1, .3, 1); }
@keyframes svc-pop {
  from { transform: scale(.6); opacity: 0; }
  to { transform: none; opacity: 1; }
}
.services.is-pinned .svc-slides {
  position: absolute;
  top: 56%;
  left: calc(var(--link-x) + var(--link-w) + 70px);
  right: var(--side);
  max-width: 620px;
  height: 0;
}
.services.is-pinned .svc-slide {
  position: absolute;
  left: 0;
  top: 0;
  width: max-content;        /* as wide as its text, so the big number centres on it */
  max-width: 100%;
  padding: 0;
  border: 0;
  transform: translateY(-50%);
  visibility: hidden;
  transition: visibility 0s linear .7s;
}
.services.is-pinned .svc-slide.is-active { visibility: visible; transition: none; }
/* each part of the text drifts up out of a blur, one after the other */
.services.is-pinned .svc-slide > * {
  opacity: 0;
  transform: translateY(24px);
  filter: blur(6px);
  transition: opacity .6s ease, transform .9s cubic-bezier(.16, 1, .3, 1), filter .6s ease;
}
.services.is-pinned .svc-slide.is-active > * { opacity: 1; transform: none; filter: blur(0); }
.services.is-pinned .svc-slide.is-active > h3 { transition-delay: .08s; }
.services.is-pinned .svc-slide.is-active > p { transition-delay: .18s; }
.services.is-pinned .svc-slide.is-active > .svc-tags { transition-delay: .28s; }
/* the big faint number behind the text */
.services.is-pinned .svc-ghost {
  position: absolute;
  left: 50%;                 /* centred behind the text */
  top: 50%;
  margin: -0.5em 0 0;
  transform: translateX(-50%);
  font-size: clamp(9rem, 19vw, 18rem);
  line-height: 1;
  color: rgba(248, 246, 241, .05);
  pointer-events: none;
}
.services.is-pinned .svc-slide.is-active > .svc-ghost { opacity: 1; transform: translateX(-50%); }
.services.is-pinned .svc-slide h3 { position: relative; font-size: clamp(2rem, 3.6vw, 3.4rem); }
.services.is-pinned .svc-slide p,
.services.is-pinned .svc-tags { position: relative; }
.services.is-pinned .svc-count {
  display: block;
  position: absolute;
  right: var(--side);
  bottom: 5vh;
  margin: 0;
  font-family: var(--font-serif);
  font-size: 15px;
  letter-spacing: .04em;
  color: rgba(248, 246, 241, .55);
}
.svc-count-now { font-size: 30px; color: var(--white); }
.services.is-pinned .svc-cta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 5vh;
  margin: 0;
  text-align: center;
}

/* ----- 06 Meet Your Dentist ----- */
.dentist {
  --side: clamp(20px, 3.5vw, 64px);
  /* "fixed": the dark topographic background stays put while the card scrolls over it,
     and it lines up exactly with the full-screen panel at the end of the quote scene */
  background: var(--teal-900) url("../assets/images/topo.svg") center / cover no-repeat fixed;
}

.dentist-quote {
  margin: 0;
  font-weight: 400;
  letter-spacing: -0.03em;
  color: var(--teal-900);
}
.dentist-quote em {
  font-family: var(--font-serif);
  font-size: 1.06em;
  letter-spacing: -0.01em;
  color: var(--teal-700);
}
.dentist-sign {
  font-family: var(--font-script);
  font-size: 34px;
  line-height: 1;
  letter-spacing: 0;
  color: var(--gold-600);
}

/* The quote scene. Phones: the quote on the dark panel. Desktop (main.js adds .is-pinned):
   it stays on screen on white while the dark panel grows out from behind "trust". */
.dentist-intro-pin {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px var(--side);
  background: var(--ivory);
  overflow: hidden;
}
.dentist-intro .dentist-quote {
  max-width: 1040px;
  margin: 0 auto;
  font-size: clamp(1.8rem, 3.8vw, 3.6rem);
  line-height: 1.12;
  text-align: center;
}
.dentist-intro .dentist-sign { margin: 28px 0 0; }
.dentist-dark {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: inherit;
  /* fixed, like the section background, so the lines never jump when the scene scrolls away */
  background: var(--teal-900) url("../assets/images/topo.svg") center / cover no-repeat fixed;
  clip-path: var(--clip, none);
}
.dentist-dark .dentist-quote { color: var(--mist); }
/* italic words on the dark sections: polished gold */
.services-title em,
.svc-slide h3 em,
.dentist-dark .dentist-quote em {
  padding-right: .06em;
  color: var(--gold-500);
  background: var(--gold-metal);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.dentist-dark .dentist-sign { color: var(--gold-300); }
.dentist.is-pinned .dentist-intro-pin {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
}
.dentist.is-pinned .dentist-intro .dentist-quote { will-change: opacity; }

/* the doctor's details: a card over the dark panel, the portrait on the left
   and an ivory panel with the text on the right */
.dentist-main {
  padding-block: 96px;
  max-width: none;
  padding-inline: max(var(--gutter), calc((100% - var(--container)) / 2 + var(--gutter)));
}
.dentist-card {
  display: grid;
  grid-template-columns: minmax(0, 37fr) minmax(0, 63fr);
  max-width: 1120px;
  margin-inline: auto;
  overflow: hidden;
  border-radius: 8px;
  background: var(--ivory);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .6);
}
.dentist-figure {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  margin: 0;
  padding-top: 28px;
  background: radial-gradient(circle at 50% 30%, var(--teal-700), var(--teal-900) 72%);
}
.dentist-figure img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center bottom;
}
.dentist-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(28px, 4vw, 56px);
}
.dentist-role {
  margin: 0 0 14px;
  font-family: var(--font-label);
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold-600);
}
.dentist-name {
  margin: 0;
  font-size: clamp(2.4rem, 4.4vw, 4.4rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.04em;
}
.dentist-name em { font-size: 1.06em; letter-spacing: -0.02em; }
.dentist-bio {
  max-width: 540px;
  margin: 28px 0 22px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-muted);
}
.dentist-facts {
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
}
.dentist-facts li {
  position: relative;
  padding-left: 18px;
  font-size: 15px;
  color: var(--teal-900);
}
.dentist-facts li + li { margin-top: 8px; }
.dentist-facts li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .62em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal-700);
}
.dentist-btn { margin-top: auto; }

/* desktop: the card fits in one screen, whatever its size */
@media (min-width: 901px) {
  .dentist-main {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;
    min-height: 100svh;
    padding-block: calc(var(--header-h) + 3vh) 4vh;
  }
  .dentist-card { width: 100%; min-height: min(74vh, 720px); }
  .dentist-figure img { width: auto; max-width: 100%; height: min(70vh, 690px); }
  .dentist-info { padding-block: clamp(22px, 5vh, 64px); }
  .dentist-name { font-size: clamp(2.2rem, min(4.4vw, 8vh), 4.4rem); }
  .dentist-bio { margin: 3vh 0 2.2vh; font-size: clamp(14px, 1.9vh, 16px); }
  .dentist-facts { margin-bottom: 3vh; }
  .dentist-facts li { font-size: clamp(13px, 1.7vh, 15px); }
  .dentist-facts li + li { margin-top: .8vh; }
}

/* ----- 08 Smile Transformations ----- */
.transformations {
  --container: 1560px;   /* the grid runs wider than the rest of the page */
  background: var(--ivory);
}
.transformations .container { padding-inline: clamp(20px, 5vw, 96px); } /* breathing room at the sides */
.cases-head {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  align-items: end;
  gap: 32px;
  margin-bottom: 48px;
}
.cases-head h2 {
  margin: 0;
  font-size: clamp(2.4rem, 5.5vw, 5rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.035em;
}
.cases-head h2 em { font-size: 1.06em; }
.cases-intro {
  max-width: 360px;
  margin: 0 0 8px auto;
  font-size: 17px;
  line-height: 1.5;
  color: var(--text-muted);
}

/* one tall result on the left, four on the right; thin lines between the photos */
.results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 2px;
  height: min(86vh, 900px);
  min-height: 520px;
  background: var(--ivory);
}
.result {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: radial-gradient(circle at 45% 40%, var(--white), var(--mist) 70%);
}
.result--tall { grid-row: span 2; }
.result img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(.16, 1, .3, 1);
}
.result:hover img { transform: scale(1.04); }
.result figcaption {
  position: absolute;
  left: clamp(14px, 1.6vw, 26px);
  bottom: clamp(14px, 1.6vw, 26px);
}
.result-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.result-tags li {
  padding: 9px 22px;
  background: var(--ivory);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--teal-900);
}

.cases-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 32px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid rgba(6, 52, 59, .15);
}
.cases-foot p {
  margin: 0;
  font-size: 14px;
  color: var(--text-muted);
}

/* ----- 10 FAQ ----- */
.faq { background: var(--ivory); }
.faq-inner {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  align-items: start;
  gap: 72px;
}
.faq-intro {
  position: sticky;
  top: calc(var(--header-h) + 32px);
}
.faq-intro h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  margin-bottom: 16px;
}
.faq-intro > p:not(.eyebrow) {
  margin: 0 0 32px;
  font-size: 17px;
  color: var(--text-muted);
}
.faq-contact {
  padding: 28px;
  border-radius: var(--radius);
  background: var(--teal-700);
}
.faq-contact h3 {
  font-size: 18px;
  color: var(--white);
  margin-bottom: 8px;
}
.faq-contact p {
  margin: 0 0 20px;
  font-size: 15px;
  color: var(--mist);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.faq-item {
  border: 1px solid rgba(6, 52, 59, .12);
  border-radius: var(--radius);
  background: var(--white);
  transition: border-color .25s, box-shadow .25s;
}
.faq-item[open] {
  border-color: var(--gold-300);
  box-shadow: 0 10px 30px rgba(6, 52, 59, .08);
}
.faq-item summary {
  position: relative;
  padding: 20px 64px 20px 24px;
  font-weight: 600;
  font-size: 16px;
  color: var(--teal-900);
  cursor: pointer;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  /* plus sign that turns into a minus when open */
  content: "+";
  position: absolute;
  top: 50%;
  right: 20px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--mist);
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  color: var(--teal-700);
  transform: translateY(-50%);
  transition: background .25s, color .25s;
}
.faq-item[open] summary::after {
  content: "−";
  background: var(--gold-500);
  color: var(--teal-900);
}
.faq-item summary:hover { color: var(--teal-700); }
.faq-item summary:focus-visible {
  outline: 3px solid var(--gold-500);
  outline-offset: 2px;
  border-radius: var(--radius);
}
.faq-answer { padding: 0 24px 22px; }
.faq-answer p {
  margin: 0;
  font-size: 15px;
  color: var(--text-muted);
}

/* ----- 11 Contact / Visit Our Clinic ----- */
/* a quiet grey map fills the section; the clinic's details sit on a card on the right */
.contact {
  position: relative;
  background: var(--mist);
}
.contact-map {
  position: relative;
  height: 52svh;
  min-height: 320px;
  overflow: hidden;
}
.contact-map-img,
.contact-map iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}
/* the real map, tinted to the site's soft teal */
.contact-map iframe { filter: grayscale(1) sepia(.3) hue-rotate(130deg) saturate(1.3) brightness(1.04); }
.contact-pin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 52px;
  transform: translate(-50%, -100%);
  filter: drop-shadow(0 10px 12px rgba(0, 0, 0, .25));
}
.contact-pin svg { display: block; width: 100%; }
.contact-pin-drop { fill: var(--teal-900); }
.contact-pin g path { fill: var(--gold-300); }

.contact-card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  background: var(--white);
  color: var(--teal-900);
}
.contact-label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 28px 28px 0;
  font-size: 13px;
}
.contact-dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-500);
}
.contact-dot--ring { background: none; box-shadow: inset 0 0 0 1.2px var(--gold-500); }
.contact-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 26px 28px 30px;
  border-bottom: 1px solid rgba(6, 52, 59, .12);
}
.contact-card-head h2 {
  margin: 0;
  font-size: clamp(2.4rem, 3.6vw, 3.6rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.035em;
  color: var(--teal-900);
}
.contact-card-head h2 em { color: var(--teal-700); }
.contact-round {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(6, 52, 59, .18);
  border-radius: 50%;
  background: var(--white);
  color: var(--teal-900);
  transition: background .3s, color .3s, border-color .3s;
}
.contact-round:hover { background: var(--teal-900); border-color: var(--teal-900); color: var(--white); }
.contact-round svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-block {
  margin: 0 28px;
  padding: 22px 26px 26px;
  border-bottom: 1px solid rgba(6, 52, 59, .12);
}
.contact-block--main {
  margin-top: 28px;
  border-bottom: 0;
  background: var(--mist);
}
.contact-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}
.contact-block-head h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--teal-900);
}
.contact-block-head .contact-round { width: 34px; height: 34px; background: transparent; }
.contact-block-head .contact-round svg { width: 14px; height: 14px; }
.contact-rows li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 14px;
  line-height: 1.5;
}
.contact-rows li + li { margin-top: 12px; }
.contact-key {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  margin-top: -1px;
  border: 1px solid rgba(6, 52, 59, .2);
  border-radius: 50%;
  background: var(--white);
  font-size: 11px;
  font-weight: 500;
}
.contact-rows a {
  text-decoration: underline;
  text-decoration-color: rgba(6, 52, 59, .4);
  text-underline-offset: 3px;
  transition: text-decoration-color .3s, color .3s;
}
.contact-rows a:hover { color: var(--teal-700); text-decoration-color: currentColor; }
.contact-hours {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px 16px;
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
}
.contact-hours dt { color: var(--text-muted); }
.contact-hours dd { margin: 0; font-weight: 500; }

/* desktop: the map fills the screen and the card floats on the right */
@media (min-width: 901px) {
  .contact {
    /* fits the screen under the header when reached from the menu */
    height: min(calc(100svh - var(--header-h)), 900px);
    min-height: 640px;
  }
  .contact-map {
    position: absolute;
    inset: 0;
    height: auto;
  }
  .contact-pin { left: 36%; top: 54%; width: 60px; }
  .contact-card {
    position: absolute;
    top: 40px;
    bottom: 40px;
    right: clamp(20px, 4vw, 72px);
    width: min(500px, 40vw);
    overflow-y: auto;
    box-shadow: 0 30px 60px -30px rgba(6, 52, 59, .35);
  }
  .contact-block:last-child { margin-bottom: 28px; }
}

/* ----- 12 Final CTA ----- */
.final-cta {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 20%, rgba(196, 165, 106, .18), transparent 40%),
    radial-gradient(circle at 85% 90%, rgba(255, 255, 255, .08), transparent 45%),
    var(--teal-700); /* the logo's own teal, saved for this moment */
  text-align: center;
}
.final-cta-tooth {
  /* large tooth outline watermark, echoing the logo */
  position: absolute;
  top: 50%;
  right: -60px;
  width: 420px;
  height: 420px;
  fill: none;
  stroke: rgba(227, 207, 159, .14);
  stroke-width: .6;
  transform: translateY(-50%) rotate(-12deg);
  pointer-events: none;
}
.final-cta-inner {
  position: relative;
  max-width: 760px;
}
.final-cta-script {
  margin: 0 0 8px;
  font-family: var(--font-script);
  font-size: 34px;
  line-height: 1.2;
  color: var(--gold-300);
}
.final-cta h2 {
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  color: var(--white);
  margin-bottom: 18px;
}
.final-cta-text {
  margin: 0 auto 36px;
  max-width: 520px;
  font-size: 18px;
  color: rgba(248, 246, 241, .8);
}
.final-cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}
.final-cta-actions .btn { padding: 14px 32px; }

/* ----- Footer ----- */
.site-footer {
  background: var(--teal-950);
  color: var(--mist);
  padding-block: 72px 28px;
  border-top: 1px solid rgba(227, 207, 159, .2);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
  gap: 48px;
  padding-bottom: 48px;
}
.footer-logo img {
  height: 72px;
  width: auto;
  border-radius: 8px;
}
.footer-brand p {
  max-width: 300px;
  margin: 20px 0 24px;
  font-size: 15px;
  color: rgba(230, 241, 242, .75);
}
.footer-social { display: flex; gap: 12px; }
.footer-social a {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(227, 207, 159, .35);
  border-radius: 50%;
  color: var(--gold-300);
  transition: background .25s, color .25s, border-color .25s;
}
.footer-social a:hover {
  background: var(--gold-500);
  border-color: var(--gold-500);
  color: var(--teal-900);
}
.footer-social svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.footer-col h3 {
  font-size: 16px;
  color: var(--white);
  margin-bottom: 18px;
}
.footer-col li {
  margin-bottom: 10px;
  font-size: 15px;
}
.footer-col a {
  color: rgba(230, 241, 242, .75);
  transition: color .2s;
}
.footer-col a:hover { color: var(--gold-300); }
.footer-contact li { color: rgba(230, 241, 242, .75); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(227, 207, 159, .2);
  font-size: 13px;
  color: rgba(230, 241, 242, .6);
}
.footer-bottom p { margin: 0; }
.footer-credit { display: block; margin-top: 4px; font-size: 12px; opacity: .8; }
.footer-credit a { text-decoration: underline; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-legal a:hover { color: var(--gold-300); }

/* ----- Responsive ----- */
@media (max-width: 900px) {
  :root { --section-pad: 64px; }
  /* Mobile menu: dropdown panel under the header */
  .nav-toggle { display: flex; }
  .header-cta { margin-left: auto; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    background: var(--mist);
    box-shadow: 0 16px 30px rgba(6, 52, 59, .15);
    transition: max-height .35s ease, visibility .35s;
  }
  .main-nav.is-open {
    max-height: 520px;
    visibility: visible;
  }
  .main-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 8px var(--gutter) 24px;
  }
  .main-nav li a:not(.btn) {
    display: block;
    padding: 15px 0;
    border-bottom: 1px solid rgba(6, 52, 59, .1);
    font-size: 17px;
  }

  /* stacked layout: at least one screen tall, content can grow below */
  .hero { height: auto; min-height: 100svh; padding-block: calc(var(--header-h) + 20px) 32px; }
  .hero-title { margin-top: 24px; font-size: clamp(2.8rem, min(13vw, 8vh), 6rem); }
  .hero-stage { flex: none; grid-template-columns: 1fr 1fr; grid-template-rows: none; gap: 24px 32px; margin-top: -2vh; }
  .hero-visual { grid-column: 1 / -1; width: min(360px, 80vw); height: 40svh; justify-self: center; margin-bottom: 7svh; }
  .hero-side { grid-row: 2; padding-top: 0; }
  .hero-side--right { grid-column: 2; }

  .trust-statement { text-indent: 0; }



  .cases-head { grid-template-columns: 1fr; gap: 20px; margin-bottom: 40px; }
  .cases-intro { margin: 0; }
  .results-grid { grid-template-columns: 1fr 1fr; grid-template-rows: none; height: auto; min-height: 0; }
  .result { aspect-ratio: 4 / 3; }
  .result--tall { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 16 / 10; }

  .faq-inner { grid-template-columns: 1fr; gap: 40px; }
  .faq-intro { position: static; }
  .faq-contact { display: none; } /* contact section follows right after on small screens */
  .faq-intro > p:not(.eyebrow) { margin-bottom: 0; }


  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px 32px; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .header-cta { display: none; }
  .nav-toggle { margin-left: auto; }
  .main-nav .nav-cta { display: block; margin-top: 20px; }
  .main-nav .nav-cta .btn { width: 100%; }
  .hero-meta span:nth-child(2) { display: none; }
  .hero-stage { margin-top: -1vh; }
  .hero-visual { height: 39svh; }
  .hero-stage { grid-template-columns: 1fr; text-align: center; }
  .hero-side,
  .hero-side--right { grid-row: auto; grid-column: 1; justify-self: center; text-align: center; }
  .hero-side p,
  .hero-side--right p { margin-inline: auto; font-size: 17px; }
  .hero-side .btn { width: 100%; }
  /* one block: sentence (with the doctor's name), main button, then the quiet link right under it */
  .hero-stage { row-gap: 20px; }
  .hero-side { padding-bottom: 0; }
  .hero-side--left p { max-width: 330px; margin-bottom: 22px; }
  .hero-more { display: inline; }
  .hero-side--right p { display: none; }

  /* the hero button on phones: iOS-style liquid glass over the dark teal */
  .hero-side .btn-ivory {
    position: relative;
    padding-block: 17px;
    border: 0;
    font-size: 17px;
    letter-spacing: .01em;
    color: var(--ivory);
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .13) 0%, rgba(255, 255, 255, .03) 48%, rgba(255, 255, 255, .09) 100%),
      rgba(3, 38, 43, .38);
    -webkit-backdrop-filter: blur(16px) saturate(150%);
    backdrop-filter: blur(16px) saturate(150%);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .28),       /* light on the top edge */
      inset 0 -12px 20px -8px rgba(248, 246, 241, .12), /* soft glow inside the bottom */
      0 12px 30px -10px rgba(3, 38, 43, .7);         /* lifted off the background */
    transition: transform .25s cubic-bezier(.2, .9, .3, 1.2), background .25s;
  }
  /* hairline rim, brighter at the top-left and bottom-right like curved glass */
  .hero-side .btn-ivory::before {
    content: "";
    position: absolute;
    inset: 0;
    padding: 1px;
    border-radius: inherit;
    background: linear-gradient(155deg, rgba(255, 255, 255, .6), rgba(255, 255, 255, .08) 38%, rgba(255, 255, 255, .06) 62%, rgba(255, 255, 255, .45));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
  }
  .hero-side .btn-ivory:hover { background: linear-gradient(180deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .05) 48%, rgba(255, 255, 255, .11)), rgba(3, 38, 43, .38); color: var(--ivory); }
  .hero-side .btn-ivory:active { transform: scale(.97); }
  .section-head { margin-bottom: 40px; }
  .dentist-card { grid-template-columns: 1fr; }
  .dentist-figure img { width: auto; max-width: 100%; max-height: 52svh; }
  .dentist-btn { width: 100%; }
  .results-grid { grid-template-columns: 1fr; }
  .result--tall { aspect-ratio: 4 / 5; }
  .result-tags li { padding: 7px 14px; font-size: 12px; }
  .contact-label { padding: 24px 20px 0; }
  .contact-card-head { padding: 20px 20px 24px; }
  .contact-block { margin-inline: 20px; padding: 20px; }
  .contact-block:last-child { margin-bottom: 20px; }
  .final-cta-actions .btn { flex: 1 1 100%; }
  .final-cta-tooth { width: 280px; height: 280px; right: -90px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
