/* Hallmark · direction: custom (brand-led, colours from the Quiro Piel logo) · genre: editorial · signature: the vertebrae column that settles into a healthy curve and becomes the scroll spine · tools: "where does it hurt" body map + WhatsApp booking builder · nav: wordmark + anchors + one action · footer: mast */
/* critique: photos are amateur 640px shots, so they live in mid-size frames and type, motion and the spine carry the scale; one accent (orchid), aqua only as the one vertebra and focus ring. */
/* waive 58: the page carries two working tools (pain map, booking builder) and the full list of real treatments; the copy is functional. */
/* answered: motion is the user's explicit ask; every effect has a reduced-motion fallback and content is visible without JS. */

:root {
  --plum-950: #1b1320;
  --plum-900: #251b2b;
  --plum-800: #33263a;
  --plum-700: #45354d;
  --mist: #e8e1e6;
  --mist-2: #ddd3db;
  --mist-3: #cfc2cd;
  --ink: #221a26;
  --ink-soft: #5a4f5e;
  --on-dark: #efe8ed;
  --on-dark-soft: #bdb0bb;
  --orchid: #b36fa5;
  --orchid-deep: #874879;
  --orchid-pale: #e6cadf;
  --lagoon: #7bbdcd;
  --lagoon-pale: #cfe3e7;
  --lagoon-ink: #2f5963;
  --focus: #7bbdcd;
  --shadow: rgb(27 19 32 / 0.18);
  --shadow-deep: rgb(0 0 0 / 0.5);
  --glow: rgb(179 111 165 / 0.24);
  --glow-soft: rgb(179 111 165 / 0.08);
  --spot: rgb(230 202 223 / 0.16);
  --line-dark: rgb(239 232 237 / 0.14);
  --line-dark-2: rgb(239 232 237 / 0.3);
  --plum-veil: rgb(27 19 32 / 0.9);
  --plum-veil-2: rgb(27 19 32 / 0.6);
  --orchid-ring: rgb(179 111 165 / 0.35);
  --lagoon-line: rgb(47 89 99 / 0.2);
  --dot: rgb(135 72 121 / 0.22);
  --wash-orchid: rgb(179 111 165 / 0.16);
  --wash-lagoon: rgb(123 189 205 / 0.16);
  --line-faint: rgb(239 232 237 / 0.035);

  --f-display: "Cormorant Garamond", "Times New Roman", serif;
  --f-body: "Plus Jakarta Sans", system-ui, sans-serif;

  --r-lg: 28px;
  --r-md: 16px;
  --r-pill: 999px;
  --container: 1240px;
  --gap: clamp(16px, 1.6vw, 24px);
  --col-gap: clamp(32px, 5vw, 72px);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3 {
  font-family: var(--f-display);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.01em;
  margin: 0;
  overflow-wrap: break-word;
  min-width: 0;
  text-wrap: balance;
}
p { margin: 0; }
.wrap { width: min(100% - 2 * clamp(20px, 4vw, 48px), var(--container)); margin-inline: auto; }

:where(a, button, input, [tabindex]):focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 8px;
  transition: none;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 28px;
  border-radius: var(--r-pill);
  font: 600 15px/1 var(--f-body);
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.35s var(--ease), background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.35s var(--ease);
}
.btn i { font-size: 20px; }
.btn:disabled, .btn[aria-disabled="true"], .car-btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-primary { background: var(--orchid-pale); color: var(--plum-950); box-shadow: 0 12px 32px -14px var(--orchid); }
.btn-primary:hover { background: var(--on-dark); }
.btn-primary.dark, .on-light .btn-primary { background: var(--plum-950); color: var(--on-dark); box-shadow: 0 12px 32px -16px var(--shadow); }
.btn-primary.dark:hover, .on-light .btn-primary:hover { background: var(--orchid-deep); }
.btn-quiet { color: var(--on-dark); border-color: var(--line-dark-2); background: transparent; }
.btn-quiet:hover { border-color: var(--on-dark); }
.on-light .btn-quiet { color: var(--ink); border-color: var(--mist-3); }
.on-light .btn-quiet:hover { border-color: var(--ink); }
.magnetic { will-change: transform; }

/* Intro curtain (first visit only, added by JS) */
.intro { display: none; }
.js .intro.run {
  display: grid; place-items: center;
  position: fixed; inset: 0; z-index: 100;
  background: var(--plum-950);
  animation: curtain 0.9s var(--ease-in-out) 0.85s forwards;
}
.intro-mark {
  width: 120px; height: 120px; background: var(--orchid-pale);
  -webkit-mask: url("img/favicon.png") center / contain no-repeat;
  mask: url("img/favicon.png") center / contain no-repeat;
  animation: markIn 0.8s var(--ease) both;
}
@keyframes markIn { from { opacity: 0; transform: translateY(16px) scale(0.92); } }
@keyframes curtain { to { transform: translateY(-100%); visibility: hidden; } }

/* Scroll spine (fixed, right edge, desktop) */
.progress-spine {
  position: fixed; right: 20px; top: 50%; z-index: 20;
  transform: translateY(-50%);
  display: grid; gap: 8px;
  pointer-events: none;
}
.progress-spine span {
  display: block; width: 16px; height: 4px; border-radius: var(--r-pill);
  background: var(--mist-3);
  transition: background-color 0.4s var(--ease), transform 0.4s var(--ease);
}
.progress-spine span.lit { background: var(--orchid); transform: scaleX(1.5); }
.progress-spine.dark span:not(.lit) { background: var(--plum-700); color: var(--on-dark); }

/* Nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 30;
  transition: background-color 0.4s var(--ease), transform 0.5s var(--ease);
}
.nav.scrolled { background: var(--plum-veil); }
.nav.hide { transform: translateY(-100%); }
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--on-dark); }
.brand-mark {
  width: 32px; height: 32px; background: var(--orchid-pale);
  -webkit-mask: url("img/favicon.png") center / contain no-repeat;
  mask: url("img/favicon.png") center / contain no-repeat;
}
.brand-name { font: 500 26px/1 var(--f-display); }
.nav-links { display: flex; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { position: relative; color: var(--on-dark-soft); text-decoration: none; font-size: 15px; transition: color 0.25s var(--ease); }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px; background: var(--orchid-pale);
  transform: scaleX(0); transform-origin: right; transition: transform 0.4s var(--ease);
}
.nav-links a:hover { color: var(--on-dark); }
.nav-links a:hover::after, .nav-links a.active::after { transform: scaleX(1); transform-origin: left; }
.nav-links a.active { color: var(--on-dark); }
.nav .btn { padding: 12px 20px; font-size: 14px; }

/* Hero */
.hero {
  position: relative;
  background: var(--plum-950);
  color: var(--on-dark);
  min-height: min(100dvh, 920px);
  display: grid; align-items: center;
  padding: 104px 0 64px;
  isolation: isolate;
  overflow: clip;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(40% 55% at var(--gx, 72%) var(--gy, 45%), var(--glow), transparent 70%),
    radial-gradient(30% 40% at 12% 90%, var(--glow-soft), transparent 70%);
}
.hero::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  left: -6%; bottom: -14%; width: min(46vw, 620px); aspect-ratio: 1;
  background: var(--orchid); opacity: 0.06;
  -webkit-mask: url("img/favicon.png") center / contain no-repeat;
  mask: url("img/favicon.png") center / contain no-repeat;
}
.hero-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); align-items: center; }
.hero-copy { grid-column: 1 / 7; }
.hero h1 { font-size: clamp(3.4rem, 6.8vw, 6.6rem); line-height: 1.02; }
.kinetic .ln { display: block; overflow: hidden; padding-bottom: 0.06em; }
.kinetic .ln > span { display: inline-block; }
.hero-lead { margin-top: 24px; max-width: 30ch; font-size: clamp(17px, 1.35vw, 20px); color: var(--on-dark-soft); }
.hero-actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }

.hero-visual { grid-column: 7 / 13; position: relative; display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: center; }
.hero-photo {
  position: relative; overflow: hidden;
  border-radius: var(--r-lg);
  aspect-ratio: 4 / 5;
  max-height: 74vh;
  box-shadow: 0 40px 80px -40px var(--shadow-deep);
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); }
.hero-photo-2 {
  position: absolute; left: 24px; bottom: -40px; width: 38%;
  border-radius: var(--r-md); overflow: hidden;
  border: 4px solid var(--plum-950);
  aspect-ratio: 4 / 3;
  box-shadow: 0 24px 48px -24px var(--shadow-deep);
}
.hero-photo-2 img { width: 100%; height: 100%; object-fit: cover; }

/* Signature: the spine */
.spine { height: 78%; display: flex; flex-direction: column; justify-content: space-between; align-items: center; }
.vert {
  width: calc(var(--w, 1) * 48px); height: 12px;
  border-radius: var(--r-pill);
  background: var(--orchid);
  transform: translateX(var(--dx, 0px)) rotate(var(--rot, 0deg));
  transition: transform 1.1s var(--ease), background-color 0.6s var(--ease);
  transition-delay: calc(var(--i) * 40ms);
}
.vert.lagoon { background: var(--lagoon); }

/* Marquee band */
.band { background: var(--orchid-pale); color: var(--plum-950); overflow: hidden; padding: 20px 0; }
.band-track { display: flex; align-items: center; gap: 32px; width: max-content; }
.band-track span { font: 500 clamp(1.6rem, 2.4vw, 2.2rem)/1 var(--f-display); white-space: nowrap; }
.band-track i { color: var(--orchid-deep); font-size: 16px; }
.js .band-track { animation: marquee 38s linear infinite; }
.band:hover .band-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Sections */
section { padding: clamp(80px, 10vw, 140px) 0; }
.sec-head { max-width: 760px; margin-bottom: clamp(36px, 5vw, 64px); }
.sec-head h2, .pain h2, .gallery-bar h2, .rev-top h2, .carlos-copy h2, .book h2 { font-size: clamp(2.6rem, 5vw, 4.4rem); }
.sec-head p { margin-top: 16px; color: var(--ink-soft); max-width: 52ch; }

/* Bento */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: minmax(220px, auto); gap: var(--gap); }
.tile { position: relative; border-radius: var(--r-lg); overflow: hidden; background: var(--mist-2); text-decoration: none; transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease); }
.tile:hover { transform: translateY(-4px); box-shadow: 0 24px 48px -28px var(--shadow); }
.spot::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), var(--spot), transparent 70%);
  transition: opacity 0.4s var(--ease);
}
.spot:hover::after { opacity: 1; }
.tile-osteo { grid-column: span 2; grid-row: span 2; display: grid; grid-template-rows: minmax(0, 1fr) auto; background: var(--plum-950); color: var(--on-dark); }
.tile-osteo .ph { min-height: 300px; overflow: hidden; }
.tile .ph img, .tile-room img { width: 100%; height: 100%; object-fit: cover; }
.tile-body { position: relative; z-index: 1; padding: clamp(24px, 2.4vw, 32px); }
.tile h3 { font-size: clamp(2rem, 2.8vw, 2.7rem); }
.tile p { margin-top: 8px; max-width: 40ch; }
.tile-osteo p, .tile-quiro p { color: var(--on-dark-soft); }
.tile-quiro { grid-column: span 2; background: var(--plum-800); color: var(--on-dark); display: flex; flex-direction: column; justify-content: flex-end; }
.tile-quiro::before {
  content: ""; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%;
  border: 1px solid var(--orchid-ring);
}
.js .tile-quiro::before { animation: breathe 6s var(--ease-in-out) infinite; }
@keyframes breathe { 50% { transform: scale(1.12); opacity: 0.5; } }
.tile-rating { background: var(--orchid-pale); display: flex; flex-direction: column; justify-content: space-between; padding: 24px; }
.rating-num { font: 500 clamp(4rem, 6vw, 5.4rem)/0.9 var(--f-display); color: var(--plum-950); }
.stars { display: flex; gap: 4px; color: var(--orchid-deep); font-size: 18px; }
.rating-txt { font-size: 15px; color: var(--ink); }
.rating-txt span { color: var(--orchid-deep); font-weight: 600; }
.tile-room { overflow: hidden; }
.tile-est { grid-column: span 4; background: var(--lagoon-pale); color: var(--ink); display: flex; align-items: end; justify-content: space-between; gap: 24px; min-height: 220px; }
.tile-est p { color: var(--lagoon-ink); }
.tile-go { position: relative; z-index: 1; margin: 0 32px 32px 0; display: inline-flex; align-items: center; gap: 8px; color: var(--lagoon-ink); font-weight: 600; white-space: nowrap; }
.tile-go i { font-size: 22px; transition: transform 0.4s var(--ease); }
.tile-est:hover .tile-go i { transform: translate(4px, 4px); }

/* Pain map */
.pain { background: var(--plum-900); color: var(--on-dark); }
.pain-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: var(--col-gap); align-items: center; }
.pain-intro { margin-top: 16px; color: var(--on-dark-soft); max-width: 46ch; }
.zones { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.zone-btn {
  padding: 12px 20px; border-radius: var(--r-pill);
  border: 1px solid var(--line-dark-2); background: transparent; color: var(--on-dark);
  font-size: 15px; cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.zone-btn:hover { border-color: var(--orchid-pale); }
.zone-btn:active { transform: scale(0.97); }
.zone-btn[aria-selected="true"] { background: var(--orchid-pale); color: var(--plum-950); border-color: var(--orchid-pale); }
.zone-card { margin-top: 24px; padding: 28px; border-radius: var(--r-lg); background: var(--plum-800); color: var(--on-dark); display: grid; gap: 12px; justify-items: start; }
.zone-card h3 { font-size: clamp(2rem, 3vw, 2.6rem); }
.zone-card p { color: var(--on-dark-soft); max-width: 48ch; }
.zone-card .btn { margin-top: 8px; }
.zone-card .btn-primary.dark { background: var(--orchid-pale); color: var(--plum-950); }
.zone-card .btn-primary.dark:hover { background: var(--on-dark); }
.zone-tags { font-size: 14px; color: var(--orchid-pale) !important; }
.zone-card.swap > * { animation: swapIn 0.6s var(--ease) both; }
.zone-card.swap > *:nth-child(2) { animation-delay: 0.05s; }
.zone-card.swap > *:nth-child(3) { animation-delay: 0.1s; }
@keyframes swapIn { from { opacity: 0; transform: translateY(12px); } }
.pain-note { margin-top: 16px; font-size: 14px; color: var(--on-dark-soft); }
.body-map { position: relative; aspect-ratio: 1; max-width: 520px; width: 100%; justify-self: center; }
.figure {
  position: absolute; inset: 0;
  background: var(--plum-700);
  -webkit-mask: url("img/favicon.png") center / contain no-repeat;
  mask: url("img/favicon.png") center / contain no-repeat;
}
.body-map::before {
  content: ""; position: absolute; inset: 10%; border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 65%);
}
.hot {
  position: absolute; left: var(--x); top: var(--y);
  width: 14px; height: 14px; translate: -50% -50%; padding: 0;
  border-radius: 50%; border: 0; cursor: pointer;
  background: var(--orchid-pale);
  box-shadow: 0 0 0 4px var(--orchid-ring);
  transition: transform 0.4s var(--ease), background-color 0.3s var(--ease);
}
.hot:hover { transform: scale(1.3); }
.hot.on { background: var(--lagoon); transform: scale(1.35); }
.js .hot.on::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 1px solid var(--lagoon);
  animation: ping 1.6s var(--ease) infinite;
}
@keyframes ping { to { transform: scale(2.2); opacity: 0; } }

/* Estética tabs */
.est-wrap { display: grid; grid-template-columns: minmax(0, 280px) minmax(0, 1fr); gap: var(--col-gap); }
.est-tabs { display: grid; gap: 4px; align-content: start; }
.est-tab {
  text-align: left; padding: 16px 20px; border-radius: var(--r-md); border: 0;
  background: transparent; color: var(--ink-soft); font-size: 17px; cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease);
}
.est-tab:hover { color: var(--ink); background: var(--mist-2); }
.est-tab[aria-selected="true"] { background: var(--lagoon-pale); color: var(--lagoon-ink); font-weight: 600; }
.est-panels { display: grid; position: relative; }
.js .est-list:not(.on) { position: absolute; inset: 0 0 auto 0; }
.est-list { grid-area: 1 / 1; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); align-content: start; }
.js .est-list { opacity: 0; visibility: hidden; transform: translateY(16px); transition: opacity 0.5s var(--ease), transform 0.6s var(--ease), visibility 0s 0.5s; }
.js .est-list.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.est-list li { padding: 28px; border-radius: var(--r-lg); background: var(--mist-2); transition: background-color 0.4s var(--ease), transform 0.4s var(--ease); }
.est-list li:hover { background: var(--lagoon-pale); transform: translateY(-3px); }
.est-list h3 { font-size: clamp(1.7rem, 2.2vw, 2.1rem); }
.est-list p { margin-top: 8px; color: var(--ink-soft); font-size: 15px; }

/* Gallery */
.gallery { padding-top: 0; }
.gallery-bar { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: clamp(32px, 4vw, 48px); }
.car-ctrl { display: flex; gap: 12px; }
.car-btn {
  width: 52px; height: 52px; border-radius: 50%;
  border: 1px solid var(--mist-3); background: transparent; color: var(--ink);
  display: grid; place-items: center; font-size: 20px; cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease), border-color 0.3s var(--ease);
}
.car-btn:hover { background: var(--plum-950); color: var(--on-dark); }
.car-btn:active { transform: scale(0.94); }
.car-btn.dark { color: var(--on-dark); border-color: var(--line-dark-2); }
.car-btn.dark:hover { background: var(--orchid-pale); color: var(--plum-950); }
.track {
  display: grid; grid-auto-flow: column;
  grid-auto-columns: clamp(240px, 26vw, 340px);
  gap: var(--gap);
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 4px max(20px, calc((100% - var(--container)) / 2)) 24px;
  scrollbar-width: none;
  cursor: grab;
}
.track::-webkit-scrollbar { display: none; }
.track.dragging { cursor: grabbing; scroll-snap-type: none; }
.slide { scroll-snap-align: start; margin: 0; }
.slide .frame { border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 5; background: var(--mist-2); transition: transform 0.6s var(--ease); }
.slide:hover .frame { transform: translateY(-4px); }
.slide.wide { grid-column: span 2; }
.slide.wide .frame { aspect-ratio: auto; height: 100%; }
.slide img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; user-select: none; }
.slide-video .frame {
  background: var(--plum-900); color: var(--on-dark);
  display: grid; place-content: center; text-align: center; gap: 12px; padding: 28px;
}
.play { position: relative; width: 68px; height: 68px; border-radius: 50%; margin: 0 auto; display: grid; place-items: center; background: var(--orchid-pale); color: var(--plum-950); font-size: 26px; }
.js .play::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--orchid-pale); animation: ping 2s var(--ease) infinite; }
.slide-video p { font: 500 1.7rem/1.1 var(--f-display); }
.slide-video small { color: var(--on-dark-soft); font-size: 14px; }
.track-bar { height: 2px; background: var(--mist-3); border-radius: var(--r-pill); overflow: hidden; }
.track-bar span { display: block; height: 100%; width: 100%; background: var(--plum-950); transform-origin: left; transform: scaleX(0.2); transition: transform 0.3s var(--ease); }

/* Carlos */
.carlos { background: var(--mist-2); }
.carlos-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); align-items: center; }
.carlos-photo { grid-column: 1 / 6; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 5; box-shadow: 0 32px 64px -32px var(--shadow); }
.carlos-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; }
.carlos-copy { grid-column: 7 / 13; }
.carlos-copy > p { margin-top: 20px; color: var(--ink-soft); max-width: 48ch; }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--mist-3); }
.facts div { display: grid; gap: 8px; }
.facts b { font: 500 clamp(4rem, 7vw, 6.4rem)/0.85 var(--f-display); color: var(--orchid-deep); }
.facts span { max-width: 20ch; color: var(--ink-soft); font-size: 15px; }

/* Reviews */
.reviews { background: var(--plum-950); color: var(--on-dark); }
.rev-top { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: clamp(36px, 5vw, 64px); }
.rev-stage { display: grid; min-height: 260px; }
.rev { grid-area: 1 / 1; margin: 0; }
.rev blockquote { margin: 0; max-width: 22ch; font: 500 clamp(2.4rem, 4.6vw, 4.2rem)/1.08 var(--f-display); text-wrap: balance; }
.rev figcaption { margin-top: 24px; color: var(--orchid-pale); font-size: 16px; }
.js .rev { opacity: 0; visibility: hidden; transform: translateY(20px); transition: opacity 0.7s var(--ease), transform 0.8s var(--ease), visibility 0s 0.7s; }
.js .rev.on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.rev-foot { margin-top: 40px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.rev-dots { display: flex; gap: 8px; }
.rev-dots button {
  width: 36px; height: 4px; padding: 0; border: 0; border-radius: var(--r-pill); cursor: pointer;
  background: var(--plum-700); position: relative; overflow: hidden;
}
.rev-dots button span { position: absolute; inset: 0; background: var(--orchid-pale); transform-origin: left; transform: scaleX(0); }
.rev-dots button.on span { animation: fill 6s linear forwards; }
.rev-dots button.done span { transform: scaleX(1); }
@keyframes fill { to { transform: scaleX(1); } }
.reviews .btn-quiet { color: var(--on-dark); }

/* Booking */
.booking { background: var(--mist); }
.book-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: var(--col-gap); align-items: start; }
.book { display: grid; gap: 24px; }
.book-sub { color: var(--ink-soft); margin-top: -8px; }
.book fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 12px; }
.book legend { padding: 0; margin-bottom: 12px; font-weight: 600; font-size: 16px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 12px 20px; border-radius: var(--r-pill);
  border: 1px solid var(--mist-3); background: transparent; color: var(--ink); font-size: 15px; cursor: pointer;
  transition: background-color 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease);
}
.chip:hover { border-color: var(--ink); }
.chip:active { transform: scale(0.96); }
.chip[aria-pressed="true"] { background: var(--plum-950); color: var(--on-dark); border-color: var(--plum-950); }
.motivo { font-size: 15px; color: var(--orchid-deep); }
.book input {
  width: 100%; padding: 16px 20px; border-radius: var(--r-md);
  border: 1px solid var(--mist-3); background: var(--mist-2); color: var(--ink); font: 400 16px/1.2 var(--f-body);
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}
.book input::placeholder { color: var(--ink-soft); }
.book input:hover { border-color: var(--ink-soft); }
.book input:focus { border-color: var(--plum-950); background: var(--mist); outline: none; }
.book input:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.preview { padding: 20px; border-radius: var(--r-lg); background: var(--plum-950); color: var(--on-dark); display: grid; gap: 12px; }
.preview-label { font-size: 14px; color: var(--on-dark-soft); }
.bubble { justify-self: start; max-width: 100%; padding: 16px 20px; border-radius: 4px var(--r-md) var(--r-md) var(--r-md); background: var(--plum-800); white-space: pre-line; font-size: 15px; line-height: 1.5; }
.bubble.pulse { animation: pulse 0.5s var(--ease); }
@keyframes pulse { 40% { transform: scale(1.015); } }
.book-error { color: var(--orchid-deep); font-weight: 600; font-size: 15px; }
.book-send { justify-self: start; }
.visit { display: grid; gap: 24px; position: sticky; top: 96px; }
.map { border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 3; background: var(--mist-2); }
.map iframe { width: 100%; height: 100%; border: 0; filter: grayscale(0.55); }
.visit-list { margin: 0; display: grid; gap: 20px; }
.visit-list div { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; }
.visit-list i { font-size: 22px; color: var(--orchid-deep); margin-top: 4px; }
.visit-list dt { font-size: 14px; color: var(--ink-soft); }
.visit-list dd { margin: 0; font-size: 17px; }
.visit-list dd a { text-decoration: none; }
.visit-list dd a:hover { text-decoration: underline; text-underline-offset: 4px; }
.pending { color: var(--orchid-deep); }
.visit .btn { justify-self: start; }

/* Footer */
.foot { background: var(--plum-900); color: var(--on-dark-soft); padding: 64px 0 40px; font-size: 15px; }
.foot-mast { font: 500 clamp(3.4rem, 11vw, 9rem)/0.9 var(--f-display); color: var(--on-dark); margin-bottom: 40px; }
.foot-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; padding-top: 28px; border-top: 1px solid var(--line-dark); }
.foot a { text-decoration: none; transition: color 0.25s var(--ease); }
.foot a:hover { color: var(--on-dark); }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 24px; }
.social a { font-size: 22px; }


/* Texture: fine grain over everything, soft light and a dotted field on the light sections */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 90; pointer-events: none;
  opacity: 0.07; mix-blend-mode: multiply;
  background-image: url("img/grain.png");
  background-size: 128px;
}
.on-light, .pain, .reviews, .foot { position: relative; isolation: isolate; }
.on-light::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(var(--dot) 1px, transparent 1.4px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(50% 38% at var(--fx, 82%) var(--fy, 35%), black, transparent 80%);
  mask-image: radial-gradient(50% 38% at var(--fx, 82%) var(--fy, 35%), black, transparent 80%);
}
.on-light::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(34% 32% at var(--fx, 82%) var(--fy, 35%), var(--wash-orchid), transparent 72%),
    radial-gradient(26% 26% at 10% 62%, var(--wash-lagoon), transparent 72%);
}
#estetica { --fx: 14%; --fy: 40%; }
.carlos { --fx: 88%; --fy: 60%; }
.booking { --fx: 18%; --fy: 35%; }
.gallery { --fx: 70%; --fy: 55%; }
.pain::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(45% 55% at 78% 50%, var(--glow), transparent 70%),
    repeating-linear-gradient(90deg, var(--line-faint) 0 1px, transparent 1px 120px);
}
.reviews::before {
  content: "“"; position: absolute; z-index: -1; pointer-events: none;
  right: 4%; top: -4%;
  font: 500 clamp(18rem, 34vw, 32rem)/1 var(--f-display);
  color: var(--plum-800);
}
.reviews::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(40% 60% at 10% 100%, var(--glow-soft), transparent 70%);
}
.foot::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  right: -4%; bottom: -10%; width: min(40vw, 520px); aspect-ratio: 1;
  background: var(--orchid); opacity: 0.05;
  -webkit-mask: url("img/favicon.png") center / contain no-repeat;
  mask: url("img/favicon.png") center / contain no-repeat;
}
.foot { overflow: clip; }
.band { background-image: linear-gradient(90deg, var(--orchid-pale), var(--mist-2) 50%, var(--orchid-pale)); }

/* Mobile action bar */
.mbar { display: none; }

/* Reveal and entrances (visible without JS) */
.js .reveal { opacity: 0; transform: translateY(32px); transition: opacity 0.9s var(--ease), transform 1s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
.js .kinetic .ln > span { transform: translateY(110%); animation: lineUp 1.1s var(--ease) forwards; animation-delay: calc(var(--t0, 0.2s) + var(--d) * 0.12s); }
.js .hero-lead, .js .hero-actions { opacity: 0; animation: fade 1s var(--ease) forwards; animation-delay: calc(var(--t0, 0.2s) + 0.5s); }
.js .hero-photo { clip-path: inset(100% 0 0 0 round var(--r-lg)); animation: wipe 1.4s var(--ease-in-out) forwards; animation-delay: var(--t0, 0.2s); }
.js .hero-photo img { animation: settle 2.4s var(--ease) both; animation-delay: var(--t0, 0.2s); }
.js .hero-photo-2 { opacity: 0; transform: translateY(24px); animation: rise 1.1s var(--ease) forwards; animation-delay: calc(var(--t0, 0.2s) + 0.7s); }
.js.intro-on { --t0: 1.3s; }
@keyframes lineUp { to { transform: none; } }
@keyframes fade { to { opacity: 1; } }
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes wipe { to { clip-path: inset(0 0 0 0 round var(--r-lg)); } }
@keyframes settle { from { transform: scale(1.2); } to { transform: scale(1.06); } }

/* Scroll-driven drift on photos where supported */
@supports (animation-timeline: view()) {
  .js .drift { animation: drift linear both; animation-timeline: view(); scale: 1.12; }
  @keyframes drift { from { translate: 0 -5%; } to { translate: 0 5%; } }
}

/* Responsive */
@media (max-width: 1100px) {
  .progress-spine { display: none; }
}
@media (max-width: 1020px) {
  .nav-links { display: none; }
  .hero-copy { grid-column: 1 / -1; }
  .hero-visual { grid-column: 1 / -1; margin-top: 32px; }
  .hero-photo { max-height: 64vh; }
  .carlos-photo { grid-column: 1 / -1; max-width: 520px; }
  .carlos-copy { grid-column: 1 / -1; }
  .pain-grid, .book-grid { grid-template-columns: minmax(0, 1fr); }
  .body-map { max-width: 380px; order: -1; }
  .visit { position: static; }
}
@media (max-width: 760px) {
  body { font-size: 16px; padding-bottom: 72px; }
  .nav .btn { display: none; }
  .hero { padding-top: 96px; min-height: auto; }
  .hero-visual { grid-template-columns: 44px minmax(0, 1fr); }
  .vert { width: calc(var(--w, 1) * 32px); height: 9px; }
  .hero-photo-2 { left: 8px; bottom: -28px; width: 46%; }
  .bento { grid-template-columns: minmax(0, 1fr); }
  .tile-osteo, .tile-quiro, .tile-est { grid-column: auto; grid-row: auto; }
  .tile-room { min-height: 260px; }
  .tile-est { flex-direction: column; align-items: start; }
  .tile-go { margin: 0 0 28px 28px; }
  .est-wrap { grid-template-columns: minmax(0, 1fr); }
  .est-tabs { display: flex; overflow-x: auto; scrollbar-width: none; }
  .est-tab { white-space: nowrap; }
  .est-list { grid-template-columns: minmax(0, 1fr); }
  .gallery-bar, .rev-top { flex-direction: column; align-items: start; }
  .track { grid-auto-columns: 74vw; }
  .slide.wide { grid-column: span 1; }
  .slide.wide .frame { aspect-ratio: 4 / 5; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .rev-stage { min-height: 300px; }
  .mbar {
    display: grid; grid-template-columns: 1fr 1.4fr 1fr;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: var(--plum-950); padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
    gap: 8px;
  }
  .mbar a { display: grid; justify-items: center; gap: 4px; padding: 8px; border-radius: var(--r-md); color: var(--on-dark); text-decoration: none; font-size: 13px; }
  .mbar i { font-size: 20px; }
  .mbar .mbar-main { background: var(--orchid-pale); color: var(--plum-950); font-weight: 600; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: 0.01ms !important; transition-delay: 0s !important; }
  .js .reveal, .js .hero-lead, .js .hero-actions, .js .hero-photo-2 { opacity: 1; transform: none; }
  .js .kinetic .ln > span { transform: none; }
  .js .hero-photo { clip-path: none; }
  .js .intro.run { display: none; }
  .js .drift { scale: 1; translate: none; }
}

/* ---- V3: colour morph, manifesto, full-bleed photo, pinned gallery, word reveals ---- */

/* 3. One page colour that morphs between sections (JS sets --page-bg) */
.js.morph body { background-color: var(--page-bg, var(--plum-950)); transition: background-color 0.9s var(--ease); }
.js.morph main > section { background-color: transparent; }

/* 1. Manifesto: words light up as you scroll */
.manifesto { position: relative; padding: 0; color: var(--on-dark); }
.man-sticky { min-height: 70vh; display: grid; place-items: center; padding: 96px 0; }
.man-text {
  width: min(100% - 48px, 1100px); margin-inline: auto; text-align: center;
  font: 500 clamp(2.6rem, 5.8vw, 5.6rem)/1.08 var(--f-display);
  text-wrap: balance;
}
.man-text .mw { display: inline; }
@supports (animation-timeline: view()) {
  .js .manifesto { height: 240vh; view-timeline: --man block; }
  .js .man-sticky { position: sticky; top: 0; height: 100vh; min-height: 0; padding: 0; }
  .js .man-text .mw {
    animation: lit linear both;
    animation-timeline: --man;
    animation-range: contain calc(var(--s) * 1%) contain calc(var(--e) * 1%);
  }
  @keyframes lit { from { opacity: 0.16; } to { opacity: 1; } }
  .js .man-text .mw.key { animation-name: litKey; }
  @keyframes litKey { from { opacity: 0.16; color: var(--on-dark); } to { opacity: 1; color: var(--orchid-pale); } }
}

/* 2. Full-bleed photo with parallax */
.bleed { position: relative; padding: 0; height: min(88vh, 860px); overflow: hidden; }
.bleed-img { width: 100%; height: 100%; object-fit: cover; }
.bleed::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, var(--plum-veil-2), transparent 30%, transparent 75%, var(--plum-veil-2));
}
@supports (animation-timeline: view()) {
  .js .bleed-img { animation: bleedMove linear both; animation-timeline: view(); }
  @keyframes bleedMove { from { transform: scale(1.18) translateY(-6%); } to { transform: scale(1.04) translateY(6%); } }
}

/* 5. Gallery pinned: vertical scroll moves the photos sideways */
.js.pin-ok .gallery { padding: 0; height: var(--gal-h, 300vh); view-timeline: --gal block; }
.js.pin-ok .gal-sticky { position: sticky; top: 72px; height: calc(100vh - 72px); display: grid; grid-template-columns: minmax(0, 1fr); align-content: center; gap: 0; overflow: hidden; }
.js.pin-ok .gallery .car-ctrl { display: none; }
.js.pin-ok .track {
  overflow: visible; scroll-snap-type: none; cursor: default;
  grid-auto-columns: clamp(300px, 30vw, 440px);
  width: max-content; justify-self: start;
  padding-inline: max(20px, calc((100vw - var(--container)) / 2));
  animation: pan linear both; animation-timeline: --gal; animation-range: contain 0% contain 100%;
}
.js.pin-ok .track-bar span { animation: barFill linear both; animation-timeline: --gal; animation-range: contain 0% contain 100%; }
@keyframes pan { to { transform: translateX(var(--pan, 0px)); } }
@keyframes barFill { from { transform: scaleX(0.08); } to { transform: scaleX(1); } }

/* 8. Headings enter word by word */
.js .split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.js .split .w > span { display: inline-block; transform: translateY(108%); transition: transform 0.9s var(--ease); transition-delay: calc(var(--i) * 70ms); }
.js .split.in .w > span { transform: none; }

@media (prefers-reduced-motion: reduce) {
  .js .split .w > span { transform: none; }
  .js .manifesto { height: auto; }
  .js .man-sticky { position: static; height: auto; min-height: 70vh; }
  .js .man-text .mw { opacity: 1; }
}
