/* =========================================================
   Dra. Pâmela Aguilera — v3
   Direção: fotografia em primeiro plano. Paleta tirada da
   própria clínica: paredes claras, dourado das letras e o
   vinho que a Dra. usa nas fotos.
   ========================================================= */

:root {
  --bg: #f6f1eb;
  --sand: #ede4d9;
  --ink: #221c19;
  --muted: #655a52;      /* 5.9:1 sobre --bg */
  --wine: #6a2238;
  --gold: #b48a55;
  --line: rgba(34, 28, 25, 0.14);
  --white: #fff;
  --wa: #25d366;

  --serif: "Bodoni Moda", "Didot", "Times New Roman", serif;
  --sans: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --script: "Pinyon Script", cursive;

  --pad: clamp(1.25rem, 4.5vw, 4rem);
  --max: 1320px;
  --r: 6px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --shadow: 0 24px 50px -28px rgba(34, 28, 25, 0.45);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0 0 1rem; }
h1, h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -0.02em; margin: 0; }
em { font-style: italic; color: var(--wine); }
figure { margin: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--wine); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 90; background: var(--ink); color: var(--bg); padding: 0.6rem 1rem; }
.skip:focus { top: 1rem; }
.ico { width: 1.15em; height: 1.15em; flex-shrink: 0; }
.center { text-align: center; margin-top: 3rem; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem;
  min-height: 50px; padding: 0.85rem 1.5rem; border-radius: var(--r); border: 1px solid transparent;
  font: 500 0.95rem/1 var(--sans); text-decoration: none; cursor: pointer;
  transition: background-color 250ms, color 250ms, border-color 250ms, transform 250ms var(--ease);
}
.btn:active { transform: scale(0.97); }
.btn--sm { min-height: 44px; padding: 0.6rem 1.1rem; font-size: 0.9rem; }
.btn--ink { background: var(--ink); color: var(--bg); }
.btn--ink:hover { background: var(--wine); }
.btn--line { border-color: rgba(34, 28, 25, 0.3); }
.btn--line:hover { border-color: var(--ink); background: var(--white); }
.btn--light { background: var(--white); color: var(--ink); }
.btn--light:hover { background: var(--sand); }

/* ---------- Cabeçalho ---------- */
.top {
  position: fixed; inset: 0 0 auto; z-index: 40;
  display: flex; align-items: center; gap: 2rem;
  padding: 0.9rem var(--pad);
  transition: background-color 300ms, box-shadow 300ms, transform 400ms var(--ease);
}
.top.is-solid { background: rgba(246, 241, 235, 0.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: 0 1px 0 var(--line); }
.top.is-away { transform: translateY(-100%); }
.brand { display: inline-flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand__pa { font: 2.3rem/1 var(--script); color: var(--wine); }
.brand__txt { display: flex; flex-direction: column; line-height: 1.15; }
.brand__txt b { font: 500 1.05rem var(--serif); }
.brand__txt small { font-size: 0.72rem; color: var(--muted); letter-spacing: 0.04em; }
.nav { display: flex; gap: 1.8rem; margin-left: auto; font-size: 0.93rem; }
.nav a { text-decoration: none; color: var(--muted); padding: 0.4rem 0; transition: color 200ms; }
.nav a:hover, .nav a.is-here { color: var(--ink); }
.nav a.is-here { box-shadow: inset 0 -1px var(--wine); }
.burger { display: none; }

/* ---------- Entradas ---------- */
.mask { display: block; overflow: hidden; padding-bottom: 0.1em; margin-bottom: -0.08em; }
.mask > span { display: block; }
.js .mask > span { transform: translateY(105%); transition: transform 1.1s var(--ease); }
.js .mask + .mask > span { transition-delay: 110ms; }
.is-ready .mask > span { transform: none; }
.js [data-in] { opacity: 0; transform: translateY(22px); transition: opacity 800ms var(--ease), transform 800ms var(--ease); }
.js [data-in].is-in { opacity: 1; transform: none; }

/* ---------- Hero ---------- */
.hero {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 5vw, 5rem); align-items: center;
  max-width: var(--max); margin: 0 auto; min-height: 100svh; padding: 7rem var(--pad) 4rem;
}
.hero__kicker { font-size: 0.9rem; color: var(--muted); margin-bottom: 1.4rem; }
.hero__title { font-size: clamp(3.1rem, 6.6vw, 6.4rem); line-height: 0.95; margin-bottom: 1.6rem; }
.hero__lede { font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem); color: var(--muted); max-width: 40ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin: 2rem 0 2.4rem; }
.proof { display: flex; align-items: center; gap: 1rem; }
.proof p { margin: 0; font-size: 0.95rem; color: var(--muted); }
.proof strong { color: var(--ink); }
.proof__faces { display: flex; }
.proof__faces img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 3px solid var(--bg); }
.proof__faces img + img { margin-left: -14px; }

.hero__media { position: relative; height: min(78vh, 780px); min-height: 460px; }
.hero__main, .hero__second { position: absolute; overflow: hidden; border-radius: var(--r); will-change: transform; }
.hero__main { right: 0; top: 0; width: 70%; height: 94%; box-shadow: var(--shadow); }
.hero__second { left: 0; bottom: 0; width: 44%; aspect-ratio: 1; border: 8px solid var(--bg); box-shadow: var(--shadow); }
.hero__main img, .hero__second img { width: 100%; height: 100%; object-fit: cover; }
.hero__main img { object-position: 50% 20%; }
.js .hero__main img, .js .hero__second img { scale: 1.12; transition: scale 1.6s var(--ease); }
.is-ready .hero__main img, .is-ready .hero__second img { scale: 1; }
.hero__chip {
  position: absolute; left: 4%; top: 10%; z-index: 2;
  display: flex; align-items: center; gap: 0.75rem; padding: 0.5rem 1rem 0.5rem 0.5rem;
  background: var(--white); border-radius: var(--r); box-shadow: var(--shadow); text-decoration: none;
  font-size: 0.82rem; line-height: 1.3; color: var(--muted);
  transition: transform 300ms var(--ease);
}
.hero__chip:hover { transform: translateY(-3px); }
.hero__chip img { width: 52px; height: 52px; object-fit: cover; border-radius: 4px; }
.hero__chip b { display: block; color: var(--ink); font-weight: 600; }

/* ---------- Faixa de fotos ---------- */
.ribbon { overflow: hidden; padding: 1rem 0 0; }
.ribbon__track { display: flex; gap: 12px; width: max-content; animation: ribbon 70s linear infinite; }
.ribbon:hover .ribbon__track { animation-play-state: paused; }
.ribbon img { height: clamp(150px, 18vw, 230px); width: auto; border-radius: 4px; object-fit: cover; }
@keyframes ribbon { to { transform: translateX(-50%); } }

/* ---------- Cabeçalhos de seção ---------- */
.head { max-width: var(--max); margin: 0 auto 2.8rem; padding: 0 var(--pad); }
.head--row { display: flex; justify-content: space-between; align-items: end; gap: 1.5rem; flex-wrap: wrap; }
.head__title { font-size: clamp(2.5rem, 5.4vw, 4.8rem); line-height: 1; margin-bottom: 1rem; }
.head__sub { color: var(--muted); max-width: 52ch; }

/* ---------- Resultados ---------- */
.results { padding: clamp(5rem, 10vw, 8rem) 0; }
.filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.5rem; }
.filter {
  min-height: 42px; padding: 0.5rem 1.1rem; border-radius: 999px; border: 1px solid rgba(34, 28, 25, 0.25);
  background: transparent; cursor: pointer; font-size: 0.9rem; transition: background-color 200ms, color 200ms, border-color 200ms;
}
.filter:hover { border-color: var(--ink); }
.filter.is-on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.results__grid {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--pad);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.2rem 1.4rem; align-items: start;
}
.results__grid > [hidden] { display: none; }
.results__grid figcaption, .about__strip figcaption { margin-top: 0.8rem; font-size: 0.92rem; color: var(--muted); }
.results__grid figcaption b { display: block; font: 500 1.25rem/1.2 var(--serif); color: var(--ink); }

/* antes (metade de cima) e depois (metade de baixo), foto inteira com a logo */
.ba .zoom { position: relative; }
.ba__tag { position: absolute; left: 0.8rem; padding: 0.3rem 0.7rem; border-radius: 4px; background: rgba(34, 28, 25, 0.72); color: var(--white); font-size: 0.75rem; font-weight: 500; pointer-events: none; }
.ba__tag--top { top: 0.8rem; }
.ba__tag--bottom { top: calc(50% + 0.8rem); }

.zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; overflow: hidden; border-radius: var(--r); }
.zoom img { width: 100%; transition: transform 700ms var(--ease); }
.zoom:hover img { transform: scale(1.04); }

/* ---------- Sobre ---------- */
.about {
  max-width: var(--max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--pad);
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 6vw, 5.5rem); align-items: center;
}
.about__big { border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); }
.about__big img { width: 100%; }
.about__body > p { color: var(--muted); max-width: 48ch; }
.about__strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.9rem; margin: 2.2rem 0 1rem; }
.about__strip .zoom { aspect-ratio: 4 / 5; }
.about__strip .zoom img { height: 100%; object-fit: cover; }
.about__strip figcaption { font-size: 0.82rem; margin-top: 0.5rem; }
.about__sign { font: 2.8rem/1 var(--script); color: var(--wine); margin-top: 1rem; }

/* ---------- Número ---------- */
.stat { display: grid; grid-template-columns: 1fr 1fr; background: var(--wine); color: var(--bg); margin-top: clamp(3rem, 6vw, 5rem); }
.stat__img { min-height: 420px; overflow: hidden; }
.stat__img img { width: 100%; height: 100%; object-fit: cover; }
.stat__txt { display: flex; flex-direction: column; justify-content: center; padding: clamp(2.5rem, 7vw, 6rem); }
.stat__num { font: 400 clamp(4.5rem, 12vw, 10rem)/0.9 var(--serif); letter-spacing: -0.04em; margin: 0 0 1.2rem; }
.stat__plus { font-family: var(--sans); font-weight: 300; font-size: 0.62em; vertical-align: 0.28em; margin-right: 0.06em; letter-spacing: 0; }
.stat__label { font-size: clamp(1.1rem, 1.6vw, 1.35rem); max-width: 26ch; color: rgba(246, 241, 235, 0.85); margin: 0; }

/* ---------- Procedimentos ---------- */
.procs { padding: clamp(5rem, 10vw, 8rem) 0; }
.procs__grid { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; }
.proc { position: relative; display: block; aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; text-decoration: none; color: var(--white); background: var(--ink); }
.proc img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease), opacity 400ms; }
.proc::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(20, 14, 12, 0.85)); }
.proc__body { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 1.5rem; display: flex; flex-direction: column; gap: 0.35rem; }
.proc__body b { font: 400 1.75rem/1.1 var(--serif); }
.proc__body span { font-size: 0.92rem; color: rgba(255, 255, 255, 0.82); }
.proc__body i { font-style: normal; font-weight: 600; font-size: 0.9rem; margin-top: 0.5rem; opacity: 0; transform: translateY(8px); transition: opacity 300ms, transform 400ms var(--ease); }
.proc:hover img, .proc:focus-visible img { transform: scale(1.06); opacity: 0.85; }
.proc:hover i, .proc:focus-visible i { opacity: 1; transform: none; }

/* ---------- Galeria ---------- */
.gallery { padding: 0 0 clamp(5rem, 10vw, 8rem); }
.masonry { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); columns: 3 260px; column-gap: 1rem; }
.tile { margin-bottom: 1rem; break-inside: avoid; }

/* ---------- Visite ---------- */
.visit { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad) clamp(5rem, 10vw, 8rem); display: grid; grid-template-columns: 7fr 5fr; align-items: center; }
.visit__photo { border-radius: var(--r); overflow: hidden; grid-column: 1; grid-row: 1; }
.visit__photo img { width: 100%; aspect-ratio: 4 / 3.4; object-fit: cover; object-position: 50% 100%; }
.visit__card { grid-column: 2; grid-row: 1; margin-left: -18%; position: relative; background: var(--white); padding: clamp(1.8rem, 3.5vw, 3rem); border-radius: var(--r); box-shadow: var(--shadow); }
.visit__card .head__title { font-size: clamp(2.2rem, 3.6vw, 3.2rem); }
.visit__addr { font-size: 1rem; }
.visit__also { color: var(--muted); font-size: 0.92rem; }
.visit__now { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; color: var(--muted); }
.visit__now::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #b0a69e; }
.visit__now.is-open { color: #1f5e33; }
.visit__now.is-open::before { background: #1f8a45; }
.visit__now:empty { display: none; }
.hours { width: 100%; border-collapse: collapse; font-size: 0.93rem; margin-bottom: 1.6rem; }
.hours th, .hours td { padding: 0.4rem 0; border-bottom: 1px solid var(--line); font-weight: 400; text-align: left; }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours tr.is-today th, .hours tr.is-today td { color: var(--wine); font-weight: 600; }
.visit__actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }

/* ---------- CTA final ---------- */
.final { position: relative; min-height: 78vh; display: grid; align-items: center; overflow: hidden; color: var(--white); }
.final__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 75% 30%; }
.final::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(25, 16, 14, 0.82) 0%, rgba(25, 16, 14, 0.55) 45%, rgba(25, 16, 14, 0.1) 100%); }
.final__inner { position: relative; z-index: 2; max-width: var(--max); width: 100%; margin: 0 auto; padding: 4rem var(--pad); }
.final h2 { font-size: clamp(2.6rem, 6vw, 5.4rem); line-height: 1; max-width: 11em; margin-bottom: 1.2rem; }
.final em { color: #e7c3b8; }
.final p { font-size: 1.15rem; color: rgba(255, 255, 255, 0.85); margin-bottom: 2rem; }

/* ---------- Rodapé ---------- */
.foot { max-width: var(--max); margin: 0 auto; padding: 3rem var(--pad) 2rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; }
.social { list-style: none; display: flex; gap: 0.5rem; margin: 0; padding: 0; }
.social a { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); transition: background-color 200ms, color 200ms; }
.social a:hover { background: var(--ink); color: var(--bg); }
.social .ico { width: 1.2rem; height: 1.2rem; }
.foot__legal { width: 100%; font-size: 0.82rem; color: var(--muted); margin: 0; padding-top: 1.5rem; border-top: 1px solid var(--line); }

/* ---------- WhatsApp fixo ---------- */
.wa {
  position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 45;
  width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center;
  background: var(--wa); color: var(--white); box-shadow: 0 12px 28px -8px rgba(0, 0, 0, 0.35);
  transition: transform 250ms var(--ease);
}
.wa:hover { transform: scale(1.07); }
.wa svg { width: 30px; height: 30px; }

/* ---------- Lightbox ---------- */
.lightbox { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.lightbox::backdrop { background: rgba(18, 13, 11, 0.92); }
.lightbox[open] { display: grid; place-items: center; }
.lightbox img { max-width: 92vw; max-height: 86vh; border-radius: 4px; }
.lightbox button { position: absolute; width: 52px; height: 52px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, 0.12); color: var(--white); font-size: 1.8rem; line-height: 1; cursor: pointer; }
.lightbox button:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox__close { top: 1rem; right: 1rem; }
.lightbox__nav--prev { left: 1rem; top: 50%; translate: 0 -50%; }
.lightbox__nav--next { right: 1rem; top: 50%; translate: 0 -50%; }

/* ---------- Responsivo ---------- */
@media (max-width: 1000px) {
  .procs__grid, .results__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 880px) {
  .nav {
    position: fixed; inset: 0; z-index: -1; background: var(--bg);
    flex-direction: column; justify-content: center; align-items: center; gap: 1rem;
    opacity: 0; visibility: hidden; transition: opacity 300ms, visibility 300ms;
  }
  .nav a { font: 400 2.2rem/1.2 var(--serif); color: var(--ink); }
  .nav.is-open { opacity: 1; visibility: visible; }
  .top__cta { margin-left: auto; }
  .burger { display: block; position: relative; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; }
  .burger span { position: absolute; left: 10px; right: 10px; height: 1.5px; background: var(--ink); transition: transform 300ms var(--ease); }
  .burger span:first-child { top: 18px; }
  .burger span:last-child { top: 25px; }
  .burger[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .burger[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

  .hero { grid-template-columns: 1fr; padding-top: 5.5rem; min-height: auto; }
  .hero__media { order: -1; height: 112vw; max-height: 640px; min-height: 0; }
  .hero__main { width: 78%; }
  .about, .visit { grid-template-columns: 1fr; }
  .visit__card { grid-column: 1; grid-row: 2; margin: -4rem 1rem 0; }
  .stat { grid-template-columns: 1fr; }
  .stat__img { min-height: 0; aspect-ratio: 1; }
}

@media (max-width: 600px) {
  .brand__txt { display: none; }
  .results__grid, .procs__grid { grid-template-columns: 1fr; }
  .proc { aspect-ratio: 5 / 4; }
  .proc__body i { opacity: 1; transform: none; }
  .hero__chip { top: 4%; left: 0; }
  .masonry { columns: 2 140px; column-gap: 0.6rem; }
  .tile { margin-bottom: 0.6rem; }
  .about__strip { gap: 0.5rem; }
  .wa { width: 56px; height: 56px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  .js .mask > span, .js [data-in] { transform: none; opacity: 1; }
  .js .hero__main img, .js .hero__second img { scale: 1; }
  .ribbon__track { animation: none; }
}
