/* ============================================
   Dra. Parra — Salud Bucal
   Palette: porcelana / petróleo / menta / encía
   ============================================ */
:root {
  --porcelana: #f6f8f7;
  --petroleo: #0b2e33;
  --petroleo-2: #124b52;
  --menta: #93dcc6;
  --rosa: #dca7b9;      /* rosa de marca (@saludbucal.draparra) */
  --rosa-suave: #f3e2e8;
  --encia: #c9748f;
  --tinta-suave: #4a6468;
  --radius: 22px;
  --font-display: "Bricolage Grotesque", sans-serif;
  --font-body: "Figtree", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--porcelana);
  color: var(--petroleo);
  line-height: 1.6;
}

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

a { color: inherit; }

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem clamp(1.2rem, 4vw, 3rem);
  mix-blend-mode: normal;
}
.nav__brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: #fff;
  background: var(--petroleo);
  padding: 0.5rem 1rem;
  border-radius: 999px;
}
.nav__links {
  display: flex;
  gap: 0.5rem;
}
.nav__links a {
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.5rem 1.05rem;
  border-radius: 999px;
  background: rgba(246, 248, 247, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(11, 46, 51, 0.12);
  transition: background 0.2s, color 0.2s;
}
.nav__links a:hover,
.nav__links a[aria-current="page"] {
  background: var(--petroleo);
  color: var(--menta);
}
.nav__links a:focus-visible {
  outline: 3px solid var(--encia);
  outline-offset: 2px;
}

/* ---------- Hero: scroll-scrubbed tooth ---------- */
.hero {
  height: 340vh; /* scroll runway that drives the rotation */
  position: relative;
}
.hero__stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  display: grid;
}
.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__word {
  position: absolute;
  top: 12vh;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(4rem, 15vw, 12rem);
  letter-spacing: 0.04em;
  color: transparent;
  -webkit-text-stroke: 2px rgba(246, 248, 247, 0.55);
  pointer-events: none;
  white-space: nowrap;
  user-select: none;
}
.hero__bottom {
  position: absolute;
  inset: auto 0 0 0;
  padding: clamp(1.5rem, 4vw, 3.5rem);
  padding-top: 8rem;
  background: linear-gradient(to top, rgba(11, 46, 51, 0.92), rgba(11, 46, 51, 0.55) 55%, transparent);
  color: var(--porcelana);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
}
.hero__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.6rem);
  line-height: 1.05;
  max-width: 14ch;
}
.hero__title em {
  font-style: normal;
  color: var(--menta);
}
.hero__aside {
  max-width: 34ch;
  display: grid;
  gap: 1rem;
  justify-items: start;
}
.hero__aside p { font-size: 1.05rem; color: rgba(246, 248, 247, 0.85); }
.hero__scrollhint {
  position: absolute;
  top: 50%;
  right: clamp(1rem, 3vw, 2.5rem);
  transform: translateY(-50%);
  writing-mode: vertical-rl;
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(246, 248, 247, 0.7);
}

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  text-decoration: none;
  padding: 0.85rem 1.7rem;
  border-radius: 999px;
  background: var(--menta);
  color: var(--petroleo);
  transition: transform 0.15s ease, background 0.2s;
}
.btn:hover { transform: translateY(-2px); background: #aef0dc; }
.btn:focus-visible { outline: 3px solid var(--encia); outline-offset: 2px; }
.btn--ghost {
  background: transparent;
  border: 2px solid var(--petroleo);
  color: var(--petroleo);
}
.btn--ghost:hover { background: var(--petroleo); color: var(--menta); }
.btn--wa {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #25d366;
  color: #063c22;
}
.btn--wa:hover { background: #3ee07c; }
.btn--light {
  background: rgba(246, 248, 247, 0.16);
  color: var(--porcelana);
  border: 1px solid rgba(246, 248, 247, 0.5);
}
.btn--light:hover { background: rgba(246, 248, 247, 0.3); }
.btn--big { font-size: 1.15rem; padding: 1.05rem 2.2rem; }

.hero__place {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rosa);
  margin-bottom: 0.7rem;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.7rem; }

/* Cinta de especialidades */
.marquee {
  background: var(--petroleo);
  color: var(--rosa);
  overflow: hidden;
  border-top: 1px solid rgba(220, 167, 185, 0.35);
  padding: 0.9rem 0;
}
.marquee__track {
  display: flex;
  white-space: nowrap;
  width: max-content;
  animation: marquee 28s linear infinite;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; }
}

/* Bienvenida / sobre la doctora */
.about {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.about__media { position: relative; }
.about__media::before {
  content: "";
  position: absolute;
  inset: -14px 14px 14px -14px;
  border-radius: var(--radius);
  background: var(--rosa-suave);
  z-index: -1;
}
.about__media img {
  border-radius: var(--radius);
  border: 1px solid rgba(11, 46, 51, 0.1);
}
.about__body h2 { margin-bottom: 1.2rem; }
.about__body p { color: var(--tinta-suave); margin-bottom: 1rem; max-width: 55ch; }
.about__body strong { color: var(--petroleo); }
.about__points {
  list-style: none;
  display: grid;
  gap: 0.55rem;
  margin-top: 1.4rem;
}
.about__points li {
  position: relative;
  padding-left: 1.7rem;
  color: var(--tinta-suave);
}
.about__points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 0.75em;
  height: 0.75em;
  border-radius: 50%;
  background: var(--rosa);
  border: 2px solid var(--petroleo-2);
}

/* Tarjetas de servicios (sin fotos) */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.2rem;
}
.card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  text-decoration: none;
  background: #fff;
  border: 1px solid rgba(11, 46, 51, 0.1);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  transition: transform 0.2s ease, border-color 0.2s, box-shadow 0.2s;
}
.card:hover {
  transform: translateY(-5px);
  border-color: var(--rosa);
  box-shadow: 0 16px 34px -18px rgba(11, 46, 51, 0.35);
}
.card:focus-visible { outline: 3px solid var(--encia); outline-offset: 2px; }
.card__icon {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: var(--rosa-suave);
  color: var(--petroleo);
  margin-bottom: 0.4rem;
}
.card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
}
.card p { color: var(--tinta-suave); font-size: 0.97rem; flex: 1; }
.card__go {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--encia);
}

/* Contacto */
.contact {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  text-align: left;
}
.contact address { font-style: normal; margin-bottom: 1.4rem; }
.contact address p { color: rgba(246, 248, 247, 0.85); font-size: 1.1rem; line-height: 1.7; }
.contact__list { list-style: none; display: grid; gap: 0.7rem; }
.contact__list li { display: flex; align-items: baseline; gap: 1rem; }
.contact__list span {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--rosa);
  min-width: 6.5rem;
}
.contact__list a { color: var(--porcelana); font-weight: 600; text-decoration-color: var(--rosa); }
.contact__action {
  background: rgba(246, 248, 247, 0.06);
  border: 1px solid rgba(220, 167, 185, 0.3);
  border-radius: var(--radius);
  padding: clamp(1.6rem, 3vw, 2.5rem);
  display: grid;
  gap: 1.4rem;
  justify-items: start;
}
.contact__action p { color: rgba(246, 248, 247, 0.85); }

/* Botón flotante de WhatsApp */
.wa-float {
  position: fixed;
  right: 1.4rem;
  bottom: 1.4rem;
  z-index: 60;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #25d366;
  color: #fff;
  box-shadow: 0 10px 26px -8px rgba(6, 60, 34, 0.55);
  transition: transform 0.15s ease;
}
.wa-float:hover { transform: scale(1.08); }
.wa-float:focus-visible { outline: 3px solid var(--petroleo); outline-offset: 3px; }

/* Revelado al hacer scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal--in { opacity: 1; transform: none; }

/* ---------- Sections ---------- */
.section {
  padding: clamp(4rem, 9vw, 8rem) clamp(1.2rem, 5vw, 4rem);
  max-width: 1200px;
  margin: 0 auto;
}
.eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--encia);
  margin-bottom: 0.8rem;
}
.section h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1.1;
  max-width: 22ch;
  margin-bottom: 1rem;
}
.section > p.lead {
  max-width: 58ch;
  font-size: 1.1rem;
  color: var(--tinta-suave);
  margin-bottom: 3rem;
}

/* Results gallery */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.2rem;
}
.gallery figure {
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(11, 46, 51, 0.1);
  transition: transform 0.2s ease;
}
.gallery figure:hover { transform: translateY(-4px); }
.gallery img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.gallery figcaption {
  padding: 0.9rem 1.1rem;
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}
.gallery figcaption span {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--petroleo);
  background: var(--menta);
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
  white-space: nowrap;
}

/* CTA band */
.cta-band {
  background: var(--petroleo);
  color: var(--porcelana);
}
.cta-band .section { text-align: center; }
.cta-band h2 { margin-inline: auto; }
.cta-band p { color: rgba(246, 248, 247, 0.8); max-width: 50ch; margin: 0 auto 2rem; }

/* ---------- Services page ---------- */
.page-head {
  padding: clamp(7rem, 14vw, 10rem) clamp(1.2rem, 5vw, 4rem) 0;
  max-width: 1200px;
  margin: 0 auto;
}
.page-head h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.05;
  max-width: 16ch;
}
.page-head p { max-width: 58ch; color: var(--tinta-suave); font-size: 1.12rem; margin-top: 1rem; }

.service {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(1.5rem, 4vw, 4rem);
  align-items: center;
  padding: clamp(3rem, 7vw, 5.5rem) clamp(1.2rem, 5vw, 4rem);
  max-width: 1200px;
  margin: 0 auto;
}
.service:nth-of-type(even) .service__media { order: 2; }
.service__media img {
  border-radius: var(--radius);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  width: 100%;
  border: 1px solid rgba(11, 46, 51, 0.12);
}
.service__body h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.7rem, 3.5vw, 2.5rem);
  line-height: 1.1;
  margin-bottom: 1rem;
}
.service__body p { color: var(--tinta-suave); margin-bottom: 1rem; }
.service__body h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 1.4rem 0 0.5rem;
}
.service__body ul {
  list-style: none;
  display: grid;
  gap: 0.45rem;
}
.service__body li {
  padding-left: 1.6rem;
  position: relative;
  color: var(--tinta-suave);
}
.service__body li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 0.7em;
  height: 0.7em;
  border-radius: 50%;
  background: var(--menta);
  border: 2px solid var(--petroleo-2);
}
.service + .service { border-top: 1px solid rgba(11, 46, 51, 0.1); }

/* ---------- Footer ---------- */
footer {
  background: var(--petroleo);
  color: rgba(246, 248, 247, 0.75);
  padding: 2.5rem clamp(1.2rem, 5vw, 4rem);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  font-size: 0.92rem;
}
footer .brand { font-family: var(--font-display); font-weight: 700; color: var(--porcelana); }
footer a { color: var(--menta); }

/* ---------- Responsive & a11y ---------- */
@media (max-width: 860px) {
  .about, .contact { grid-template-columns: 1fr; }
  .about__media { max-width: 420px; }
}
@media (max-width: 760px) {
  .service { grid-template-columns: 1fr; }
  .service:nth-of-type(even) .service__media { order: 0; }
  .hero__word { top: 16vh; }
  .hero__scrollhint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .gallery figure, .btn { transition: none; }
}
