@font-face { font-family: "Unbounded"; src: url("fonts/unbounded-var.woff2") format("woff2"); font-weight: 200 900; font-display: swap; }
@font-face { font-family: "Hanken Grotesk"; src: url("fonts/hanken-grotesk-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("fonts/instrument-serif-latin-400-italic.woff2") format("woff2"); font-style: italic; font-weight: 400; font-display: swap; }

:root {
  --ink: #0b0d0d;
  --ink-2: #121615;
  --ink-3: #1a201f;
  --line: rgba(232, 240, 237, .12);
  --text: #e9efec;
  --muted: #a3b0ac;
  --teal: #6e9893;
  --teal-2: #9cc7c0;
  --glow: #9ff0e2;
  --paper: #eef2f1;
  --paper-ink: #142120;
  --wa: #25d366;
  --wa-ink: #062b14;
  --radius: 22px;
  --top-h: 72px;
  --gut: clamp(16px, 4vw, 56px);
  --display: "Unbounded", "Hanken Grotesk", system-ui, sans-serif;
  --body: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: var(--top-h); }
html:not(.lenis) { scroll-behavior: smooth; }
html.has-dialog { overflow: hidden; }
body { margin: 0; background: var(--ink); color: var(--text); font-family: var(--body); font-size: 17px; line-height: 1.6; overflow-x: clip; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 500; line-height: 1.08; letter-spacing: -.01em; }
p { margin: 0; }
svg { width: 1.2em; height: 1.2em; flex: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--glow); outline-offset: 3px; border-radius: 6px; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 300; padding: 10px 16px; background: var(--paper); color: var(--paper-ink); border-radius: 10px; }
.skip:focus { top: 12px; }

.progress { position: fixed; inset: 0 0 auto; height: 2px; z-index: 210; pointer-events: none; }
.progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--glow)); transform-origin: 0 50%; transform: scaleX(0); }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55em; min-height: 46px; padding: 0 20px; border-radius: 999px; border: 1px solid transparent; font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; transition: transform .25s cubic-bezier(.2,.8,.2,1), background-color .25s, border-color .25s, color .25s; background: none; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn--lg { min-height: 54px; padding: 0 26px; font-size: 16px; }
.btn--block { width: 100%; }
.btn--wa { background: var(--wa); color: var(--wa-ink); }
.btn--wa:hover { background: #3ae07a; }
.btn--ghost { border-color: var(--line); color: var(--text); }
.btn--ghost:hover { border-color: var(--teal-2); color: #fff; }
.btn--light { background: var(--paper); color: var(--paper-ink); }
.btn svg { width: 1.15em; height: 1.15em; }

.kicker { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 18px; color: var(--teal-2); font-size: 13px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.kicker::before { content: ""; width: 26px; height: 1px; background: currentColor; }
h2 { font-family: var(--display); font-weight: 400; font-size: clamp(30px, 4.4vw, 60px); letter-spacing: -.035em; line-height: 1.04; }

/* Encabezado */
.top { position: fixed; inset: 0 0 auto; z-index: 200; height: var(--top-h); display: flex; align-items: center; gap: 24px; padding: 0 var(--gut); transition: background-color .35s, border-color .35s, backdrop-filter .35s; border-bottom: 1px solid transparent; }
.top.is-solid { background: rgba(11, 13, 13, .78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-color: var(--line); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; margin-right: auto; }
.brand img { width: 26px; height: auto; }
.brand-name { display: flex; flex-direction: column; font-family: var(--display); font-size: 15px; font-weight: 500; letter-spacing: .32em; text-transform: uppercase; line-height: 1.2; }
.brand-name small { font-family: var(--body); font-size: 10px; font-weight: 600; letter-spacing: .26em; color: var(--muted); }
.nav { display: flex; gap: 26px; }
.nav a { position: relative; font-size: 14px; font-weight: 500; color: var(--muted); text-decoration: none; transition: color .2s; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 1px; background: var(--glow); transform: scaleX(0); transform-origin: 100% 50%; transition: transform .35s cubic-bezier(.2,.8,.2,1); }
.nav a:hover { color: var(--text); }
.nav a:hover::after { transform: scaleX(1); transform-origin: 0 50%; }
.top-cta { min-height: 40px; padding: 0 16px; font-size: 14px; }
.menu { display: none; position: relative; }
.menu summary { list-style: none; width: 44px; height: 44px; display: grid; place-content: center; gap: 6px; cursor: pointer; border: 1px solid var(--line); border-radius: 50%; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary span { display: block; width: 18px; height: 1.5px; background: var(--text); transition: transform .3s; }
.menu[open] summary span:first-child { transform: translateY(3.75px) rotate(45deg); }
.menu[open] summary span:last-child { transform: translateY(-3.75px) rotate(-45deg); }
.menu-panel { position: absolute; right: 0; top: 54px; width: min(78vw, 300px); padding: 10px; border-radius: 18px; background: var(--ink-2); border: 1px solid var(--line); box-shadow: 0 30px 60px rgba(0,0,0,.5); display: grid; }
.menu-panel a { padding: 13px 14px; border-radius: 12px; text-decoration: none; font-weight: 500; }
.menu-panel a:hover { background: var(--ink-3); }

/* Portada */
.hero { position: relative; min-height: 100svh; padding: calc(var(--top-h) + 28px) var(--gut) 56px; display: flex; align-items: center; overflow: hidden; isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: radial-gradient(60% 70% at 72% 40%, rgba(110, 152, 147, .22), transparent 70%), radial-gradient(40% 40% at 10% 90%, rgba(159, 240, 226, .07), transparent 70%); }
.hero-word { position: absolute; inset: auto 0 2vh; z-index: -1; display: flex; flex-direction: column; align-items: center; font-family: var(--display); font-weight: 700; font-size: clamp(64px, 15.5vw, 250px); line-height: .86; letter-spacing: .06em; color: transparent; -webkit-text-stroke: 1px rgba(156, 199, 192, .16); user-select: none; pointer-events: none; white-space: nowrap; }
.hero-grid { width: 100%; max-width: 1360px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 22px; font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--teal-2); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--glow); box-shadow: 0 0 0 0 rgba(159,240,226,.6); animation: ping 2.4s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(159,240,226,.55); } 70% { box-shadow: 0 0 0 12px rgba(159,240,226,0); } 100% { box-shadow: 0 0 0 0 rgba(159,240,226,0); } }
.hero h1 { font-family: var(--display); font-weight: 400; font-size: clamp(40px, 6.3vw, 96px); line-height: .98; letter-spacing: -.045em; max-width: 11ch; }
.hero h1 em { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -.01em; color: var(--glow); padding-right: .06em; }
.hero-lead { margin-top: 26px; max-width: 44ch; font-size: clamp(17px, 1.35vw, 20px); color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-facts { list-style: none; margin: 46px 0 0; padding: 22px 0 0; display: flex; flex-wrap: wrap; gap: 14px 40px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.hero-facts b { display: block; font-family: var(--display); font-weight: 500; font-size: 20px; color: var(--text); letter-spacing: -.02em; }
.hero-portrait { margin: 0; justify-self: center; width: min(100%, 470px); }
.scan-frame { position: relative; aspect-ratio: 2 / 3; border-radius: 28px; overflow: hidden; background: #050606; box-shadow: 0 40px 90px rgba(0,0,0,.55), 0 0 0 1px var(--line); }
.scan-photo, .scan-wire img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scan-wire { position: absolute; inset: 0; clip-path: inset(0 0 0 0); }
.scan-wire { background: #031413; }
.scan-wire img { filter: grayscale(1) contrast(2.2) brightness(.95) sepia(1) hue-rotate(125deg) saturate(2.4); opacity: .78; }
.scan-wire::after { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 50% at 50% 30%, rgba(159,240,226,.22), transparent 70%); }
.scan-wire::before { content: ""; position: absolute; inset: 0; z-index: 1; background: repeating-linear-gradient(0deg, rgba(159,240,226,.2) 0 1px, transparent 1px 14px), repeating-linear-gradient(90deg, rgba(159,240,226,.14) 0 1px, transparent 1px 14px); }
.scan-line { position: absolute; left: -10%; right: -10%; top: 0; height: 2px; background: var(--glow); box-shadow: 0 0 18px 4px rgba(159,240,226,.7), 0 0 60px 14px rgba(159,240,226,.25); opacity: 0; pointer-events: none; }
.scan-corner { position: absolute; width: 26px; height: 26px; border: 1.5px solid rgba(159,240,226,.7); }
.scan-corner.tl { top: 14px; left: 14px; border-right: 0; border-bottom: 0; border-radius: 10px 0 0 0; }
.scan-corner.tr { top: 14px; right: 14px; border-left: 0; border-bottom: 0; border-radius: 0 10px 0 0; }
.scan-corner.bl { bottom: 14px; left: 14px; border-right: 0; border-top: 0; border-radius: 0 0 0 10px; }
.scan-corner.br { bottom: 14px; right: 14px; border-left: 0; border-top: 0; border-radius: 0 0 10px 0; }
.hero-portrait figcaption { display: flex; flex-direction: column; margin-top: 16px; font-family: var(--display); font-size: 15px; letter-spacing: .02em; }
.hero-portrait figcaption span { font-family: var(--body); font-size: 13px; color: var(--muted); }
.hero-hint { position: absolute; left: 50%; bottom: 22px; width: 26px; height: 42px; margin-left: -13px; border: 1.5px solid var(--line); border-radius: 20px; }
.hero-hint span { position: absolute; left: 50%; top: 9px; width: 3px; height: 8px; margin-left: -1.5px; border-radius: 3px; background: var(--glow); animation: hint 1.8s infinite; }
@keyframes hint { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(14px); opacity: 0; } 100% { opacity: 0; } }
/* Sin animación activa el escaneo de la portada ya está terminado */
.scan-wire { clip-path: inset(0 0 100% 0); }
.anim .scan-wire { clip-path: inset(0 0 0 0); }

/* Escaneo con scroll */
.scan { position: relative; background: var(--ink); }
.anim .scan { height: 340vh; }
.scan-sticky { position: relative; min-height: 100svh; display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(28px, 5vw, 80px); align-items: center; padding: calc(var(--top-h) + 30px) var(--gut) 50px; max-width: 1440px; margin: 0 auto; }
.anim .scan-sticky { position: sticky; top: 0; height: 100svh; }
.chapters { list-style: none; margin: 36px 0 0; padding: 0; display: grid; gap: 6px; }
.chapter { display: flex; gap: 18px; padding: 18px 0; border-top: 1px solid var(--line); transition: opacity .45s; }
.anim .chapter { opacity: .32; }
.anim .chapter.is-on { opacity: 1; }
.ch-n { font-family: var(--display); font-size: 13px; color: var(--teal-2); padding-top: 4px; }
.chapter h3 { font-family: var(--display); font-weight: 500; font-size: 21px; letter-spacing: -.02em; margin-bottom: 6px; }
.chapter p { color: var(--muted); max-width: 40ch; }
.monitor { margin: 0; }
.monitor-bar { display: flex; align-items: center; gap: 7px; padding: 12px 16px; background: #dfe5e4; border-radius: 20px 20px 0 0; color: #3d4d4b; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.monitor-bar i { width: 10px; height: 10px; border-radius: 50%; background: #b9c4c2; }
.monitor-bar span { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; }
.monitor-bar span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #22a37f; }
.monitor-screen { position: relative; background: #f1f3f6; border-radius: 0 0 20px 20px; overflow: hidden; box-shadow: 0 50px 100px rgba(0,0,0,.5); }
.monitor-screen canvas { display: none; width: 100%; height: auto; aspect-ratio: 720 / 440; }
.anim .monitor-screen canvas { display: block; }
.anim .scan-fallback { display: none; }
.scan-fallback { width: 100%; }
.monitor-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(20,33,32,.08); }
.monitor-progress span { display: block; height: 100%; background: var(--teal); transform-origin: 0 50%; transform: scaleX(1); }
.monitor figcaption { margin-top: 14px; font-size: 13px; color: var(--muted); }

/* Tratamientos */
.services { position: relative; background: var(--ink-2); border-top: 1px solid var(--line); }
.services-sticky { padding: clamp(80px, 10vw, 130px) 0; overflow: hidden; }
.services-head { padding: 0 var(--gut); max-width: 1440px; margin: 0 auto 44px; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 10px 40px; }
.services-head .kicker { grid-column: 1 / -1; margin-bottom: 0; }
.services-note { color: var(--muted); max-width: 32ch; font-size: 15px; }
.track { display: flex; gap: 20px; padding: 0 var(--gut); overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.track::-webkit-scrollbar { display: none; }
.card { position: relative; flex: 0 0 clamp(280px, 30vw, 400px); scroll-snap-align: start; border-radius: var(--radius); background: var(--ink-3); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; transition: border-color .3s, transform .4s cubic-bezier(.2,.8,.2,1); }
.card:hover { border-color: rgba(159,240,226,.4); }
.card-media { aspect-ratio: 4 / 3.4; overflow: hidden; background: #000; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); transition: transform 1s cubic-bezier(.2,.8,.2,1); }
.card-media--light { background: #f1f3f6; }
.card-media--light img { object-fit: contain; }
.card:hover .card-media img { transform: scale(1.08); }
.card-body { position: relative; padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-n { font-family: var(--display); font-size: 12px; color: var(--teal-2); letter-spacing: .1em; }
.card h3 { font-family: var(--display); font-weight: 500; font-size: 22px; letter-spacing: -.025em; }
.card p { color: var(--muted); font-size: 15.5px; flex: 1; }
.card-open { margin-top: 8px; align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--text); font-weight: 600; font-size: 15px; cursor: pointer; }
.card-open::after { content: ""; position: absolute; inset: 0; }
.card-open svg { transition: transform .3s; }
.card:hover .card-open svg { transform: translateX(5px); }
.card--cta { justify-content: flex-end; padding: 28px; text-decoration: none; background: linear-gradient(160deg, #1d2a28, #0f1413); min-height: 360px; gap: 12px; }
.card--cta strong { font-family: var(--display); font-weight: 400; font-size: 30px; line-height: 1.05; letter-spacing: -.03em; }
.card-cta-go { display: inline-flex; align-items: center; gap: 8px; color: var(--glow); font-weight: 600; }
html:not(.js) .card-open { display: none; }

/* Frase */
.statement { padding: clamp(110px, 16vw, 220px) var(--gut); max-width: 1300px; margin: 0 auto; text-align: center; }
.statement-text { font-family: var(--display); font-weight: 300; font-size: clamp(28px, 4.2vw, 60px); line-height: 1.12; letter-spacing: -.035em; }
.statement-sign { margin-top: 34px; font-family: var(--serif); font-style: italic; font-size: 26px; color: var(--teal-2); }

/* El doctor */
.doctor { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(30px, 6vw, 96px); align-items: center; padding: 0 var(--gut) clamp(90px, 12vw, 160px); max-width: 1440px; margin: 0 auto; }
.doctor-media { border-radius: 28px; overflow: hidden; aspect-ratio: 3 / 4; }
.doctor-media img { width: 100%; height: 115%; object-fit: cover; }
.doctor-copy > p { margin-top: 24px; color: var(--muted); font-size: 18px; max-width: 52ch; }
.creds { margin: 34px 0 0; display: grid; gap: 0; }
.creds div { display: grid; grid-template-columns: 170px 1fr; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); }
.creds dt { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--teal-2); padding-top: 3px; }
.creds dd { margin: 0; }
.logos { list-style: none; margin: 30px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.logos li { height: 58px; padding: 0 18px; display: grid; place-items: center; background: #fff; border-radius: 14px; }
.logos img { max-height: 30px; width: auto; }
.logos li:nth-child(2) img { max-height: 44px; }

/* Pacientes */
.patients { padding: clamp(90px, 11vw, 150px) 0; background: var(--ink-2); border-top: 1px solid var(--line); overflow: hidden; }
.patients-head { padding: 0 var(--gut); max-width: 1440px; margin: 0 auto 50px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 60px; align-items: end; }
.patients-head .kicker { grid-column: 1 / -1; margin-bottom: 0; }
.patients-head p { color: var(--muted); max-width: 48ch; }
.rows { display: grid; gap: 16px; }
.row { list-style: none; margin: 0; padding: 0 var(--gut); display: flex; gap: 16px; width: max-content; }
.row li { flex: none; width: clamp(180px, 19vw, 270px); aspect-ratio: 3 / 4; border-radius: 18px; overflow: hidden; background: var(--ink-3); }
.row img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.25); transition: filter .5s, transform .8s cubic-bezier(.2,.8,.2,1); }
.row li:hover img { filter: none; transform: scale(1.05); }
.reviews { padding: 46px var(--gut) 0; max-width: 1440px; margin: 0 auto; }
.reviews-card { display: inline-flex; align-items: center; gap: 22px; padding: 18px 26px 18px 22px; border-radius: 20px; border: 1px solid var(--line); text-decoration: none; transition: border-color .3s, background-color .3s; }
.reviews-card:hover { border-color: rgba(159,240,226,.4); background: var(--ink-3); }
.reviews-n { font-family: var(--display); font-size: 48px; font-weight: 400; letter-spacing: -.04em; color: var(--glow); line-height: 1; }
.reviews-card > span:last-child { display: flex; flex-direction: column; color: var(--muted); }
.reviews-card b { display: inline-flex; align-items: center; gap: 6px; color: var(--text); font-weight: 600; }

/* Instagram */
.insta { padding: clamp(90px, 11vw, 150px) var(--gut); max-width: 1440px; margin: 0 auto; }
.insta-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.insta-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.insta-grid a { position: relative; display: block; aspect-ratio: 9 / 15; border-radius: 18px; overflow: hidden; text-decoration: none; background: var(--ink-3); }
.insta-grid img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.8,.2,1); }
.insta-grid span { position: absolute; inset: auto 0 0; padding: 40px 14px 14px; font-size: 14px; font-weight: 600; line-height: 1.3; background: linear-gradient(transparent, rgba(0,0,0,.85)); }
.insta-grid a:hover img { transform: scale(1.06); }

/* Consultorio */
.place { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(30px, 6vw, 96px); align-items: center; padding: 0 var(--gut) clamp(90px, 12vw, 160px); max-width: 1440px; margin: 0 auto; }
.place-media { border-radius: 28px; overflow: hidden; aspect-ratio: 4 / 5; }
.place-media img { width: 100%; height: 118%; object-fit: cover; object-position: 50% 30%; }
.place address { font-style: normal; margin-top: 30px; display: grid; gap: 14px; font-size: 18px; }
.place address p { display: flex; gap: 14px; align-items: flex-start; }
.place address svg { margin-top: 4px; color: var(--teal-2); }
.place address a { text-decoration: none; border-bottom: 1px solid var(--line); }
.place-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.travel { margin-top: 40px; padding: 24px; border-radius: 20px; background: var(--ink-2); border: 1px solid var(--line); }
.travel h3 { font-family: var(--display); font-weight: 500; font-size: 18px; margin-bottom: 8px; letter-spacing: -.02em; }
.travel p { color: var(--muted); }

/* Agenda */
.agenda { padding: 0 var(--gut) clamp(90px, 12vw, 150px); }
.agenda-in { max-width: 1360px; margin: 0 auto; padding: clamp(32px, 5vw, 70px); border-radius: 34px; background: var(--paper); color: var(--paper-ink); display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(30px, 5vw, 80px); }
.agenda .kicker { color: #3f6d67; }
.agenda-copy > p { margin-top: 22px; color: #44524f; max-width: 42ch; }
.agenda-direct { display: inline-flex; align-items: center; gap: 10px; margin-top: 26px; font-weight: 600; text-decoration: none; border-bottom: 1px solid rgba(20,33,32,.25); padding-bottom: 3px; }
.form { display: grid; gap: 20px; }
.field { display: grid; gap: 8px; border: 0; margin: 0; padding: 0; min-width: 0; }
.field label, .field legend { font-size: 14px; font-weight: 600; padding: 0; }
.field input, .field select, .field textarea { width: 100%; min-height: 50px; padding: 12px 16px; border-radius: 14px; border: 1px solid rgba(20,33,32,.18); background: #fff; color: var(--paper-ink); transition: border-color .2s, box-shadow .2s; }
.field textarea { resize: vertical; min-height: 96px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: #3f6d67; box-shadow: 0 0 0 4px rgba(63,109,103,.16); }
.field.is-bad input { border-color: #b3261e; }
.opt { font-weight: 400; color: #6b7774; }
.error { color: #b3261e; font-size: 14px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips label { position: relative; cursor: pointer; }
.chips input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chips span { display: inline-flex; align-items: center; min-height: 42px; padding: 0 16px; border-radius: 999px; border: 1px solid rgba(20,33,32,.18); background: #fff; font-size: 14.5px; font-weight: 500; transition: background-color .2s, color .2s, border-color .2s, transform .2s; }
.chips label:hover span { border-color: #3f6d67; }
.chips input:checked + span { background: var(--paper-ink); color: #fff; border-color: var(--paper-ink); }
.chips input:focus-visible + span { outline: 2px solid #3f6d67; outline-offset: 2px; }
.form-note { font-size: 13.5px; color: #5a6865; text-align: center; }

/* Pie */
.foot { padding: 0 var(--gut) 100px; overflow: hidden; }
.foot-in { max-width: 1440px; margin: 0 auto; border-top: 1px solid var(--line); padding-top: 50px; }
.foot-word { font-family: var(--display); font-weight: 700; font-size: clamp(40px, 10.6vw, 170px); letter-spacing: .05em; line-height: .9; color: transparent; -webkit-text-stroke: 1px rgba(156,199,192,.22); white-space: nowrap; text-align: center; }
.foot-cols { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; margin-top: 40px; color: var(--muted); font-size: 15px; }
.foot-title { color: var(--text); font-weight: 600; margin-bottom: 6px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.foot-links a { text-decoration: none; }
.foot-links a:hover { color: var(--text); }
.foot-legal { margin-top: 34px; font-size: 13px; color: #7a8784; max-width: 70ch; }

.wa-float { position: fixed; right: 18px; bottom: 18px; z-index: 190; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: var(--wa); color: var(--wa-ink); box-shadow: 0 14px 30px rgba(0,0,0,.4); transition: transform .3s cubic-bezier(.2,.8,.2,1); }
.wa-float svg { width: 28px; height: 28px; }
.wa-float:hover { transform: scale(1.08); }

/* Ficha del tratamiento */
.ficha { padding: 0; border: 0; background: transparent; color: var(--text); width: min(1040px, calc(100vw - 32px)); max-width: none; height: min(720px, calc(100svh - 48px)); max-height: none; overflow: visible; }
.ficha::backdrop { background: rgba(4,6,6,.72); backdrop-filter: blur(6px); }
.ficha-shell { height: 100%; display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); border-radius: 26px; overflow: hidden; background: var(--ink-2); border: 1px solid var(--line); box-shadow: 0 50px 120px rgba(0,0,0,.6); }
.ficha-media { background: #000; min-height: 0; }
.ficha-media img { width: 100%; height: 100%; object-fit: cover; }
.ficha-main { display: flex; flex-direction: column; min-height: 0; }
.ficha-head { position: relative; padding: 30px 72px 18px 32px; border-bottom: 1px solid var(--line); }
.ficha-head .kicker { margin-bottom: 10px; }
.ficha-head h2 { font-size: clamp(26px, 3vw, 38px); }
.ficha-x { position: absolute; top: 22px; right: 22px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: none; display: grid; place-items: center; cursor: pointer; transition: border-color .2s, transform .3s; }
.ficha-x:hover { border-color: var(--teal-2); transform: rotate(90deg); }
.ficha-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 24px 32px 30px; color: #cbd5d2; }
.ficha-body > * + * { margin-top: 14px; }
.ficha-body h4 { margin-top: 26px; font-family: var(--display); font-weight: 500; font-size: 16px; color: var(--text); letter-spacing: -.01em; }
.ficha-body ul, .ficha-body ol { padding-left: 1.2em; display: grid; gap: 8px; }
.ficha-body li::marker { color: var(--teal-2); }
.ficha-body b { color: var(--text); }
.f-lead { font-size: 19px; color: var(--text); }
.f-note { padding: 14px 16px; border-radius: 14px; background: var(--ink-3); font-size: 15px; }
.ficha-actions { flex: none; display: flex; gap: 10px; padding: 16px 32px 20px; border-top: 1px solid var(--line); background: var(--ink-2); }
.ficha-actions .btn--wa { flex: 1; }

/* Estado inicial de lo animado: solo con animación activa */
.anim [data-lines], .anim #hero-title { visibility: hidden; }
.anim.ready [data-lines], .anim.ready #hero-title { visibility: visible; }
@media (min-width: 1024px) {
  html:not(.anim) .track { flex-wrap: wrap; overflow: visible; }
  html:not(.anim) .card { flex: 1 1 300px; }
}

@media (max-width: 1100px) {
  .nav { display: none; }
  .menu { display: block; }
  .insta-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  :root { --top-h: 64px; }
  .hero { min-height: auto; padding-top: calc(var(--top-h) + 20px); padding-bottom: 70px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-portrait { order: -1; width: min(78%, 340px); }
  .scan-frame { aspect-ratio: 4 / 4.4; }
  .scan-photo, .scan-wire img { object-position: 50% 12%; }
  .hero-word { inset: 30vh 0 auto; }
  .scan-sticky { grid-template-columns: 1fr; align-content: center; gap: 22px; }
  .chapters { margin-top: 18px; }
  .chapter { padding: 12px 0; }
  .anim .chapter:not(.is-on) { display: none; }
  .anim .chapter { opacity: 1; }
  .services-head, .patients-head { grid-template-columns: 1fr; }
  .doctor, .place { grid-template-columns: 1fr; }
  .doctor-media { aspect-ratio: 4 / 3.6; }
  .place-media { aspect-ratio: 4 / 3.4; }
  .agenda-in { grid-template-columns: 1fr; }
  .ficha-shell { grid-template-columns: 1fr; grid-template-rows: 150px minmax(0, 1fr); }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .top-cta span { display: none; }
  .top-cta { width: 44px; padding: 0; }
  .brand-name { font-size: 13px; letter-spacing: .26em; }
  .brand-name small { font-size: 9px; letter-spacing: .2em; }
  .hero h1 { font-size: clamp(36px, 10.5vw, 48px); }
  .hero-actions .btn { width: 100%; }
  .hero-facts { gap: 14px 26px; }
  .hero-facts li { flex: 1 1 40%; }
  .chapter p { font-size: 15px; }
  .card { flex-basis: 82vw; }
  .insta-grid { grid-template-columns: repeat(2, 1fr); }
  .creds div { grid-template-columns: 1fr; gap: 4px; }
  .field-row { grid-template-columns: 1fr; }
  .reviews-card { gap: 16px; padding: 16px 18px; }
  .reviews-n { font-size: 38px; }
  .ficha { width: 100vw; height: 100svh; margin: 0; }
  .ficha-shell { border-radius: 0; grid-template-rows: 120px minmax(0, 1fr); }
  .ficha-head { padding: 20px 66px 14px 20px; }
  .ficha-x { top: 14px; right: 14px; }
  .ficha-body { padding: 18px 20px 24px; }
  .ficha-actions { padding: 12px 20px calc(14px + env(safe-area-inset-bottom)); }
  .wa-float { width: 52px; height: 52px; right: 14px; bottom: 14px; }
}
@media (min-width: 1024px) {
  /* En escritorio la pista de tratamientos avanza con el scroll vertical */
  .anim .services { height: var(--track-h, 300vh); }
  .anim .services-sticky { position: sticky; top: 0; height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: calc(var(--top-h) + 10px) 0 40px; }
  .anim .track { overflow: visible; scroll-snap-type: none; width: max-content; }
  .anim .services-head { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  .dot { animation: none; }
}
