
/* ============================================================
   MIRADIO FRECUENCIA FACIAL — Global Stylesheet
   Design tokens, layout, components, motion, responsive
   ============================================================ */

:root {
  --porcelain: #F7F3EE;
  --blush: #E7D0CC;
  --taupe: #C5B5A5;
  --espresso: #302824;
  --muted: #786B62;
  --border: rgba(48, 40, 36, 0.12);
  --white: #FFFFFF;
  --serif: "Cormorant Garamond", "Playfair Display", "EB Garamond", Georgia, "Times New Roman", serif;
  --sans: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --container: 1240px;
  --radius: 2px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--porcelain);
  color: var(--espresso);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.menu-open, body.lightbox-open { overflow: hidden; }

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--espresso);
  outline-offset: 3px;
  border-radius: var(--radius);
}

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; line-height: 1.15; margin: 0 0 .5em; }
p { margin: 0 0 1.2em; }

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 2000;
  background: var(--espresso); color: var(--white);
  padding: .75rem 1.25rem; font-size: .85rem; letter-spacing: .08em;
  transition: top .25s var(--ease);
}
.skip-link:focus { top: 1rem; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 900;
  transition: background .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(247, 243, 238, .92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--border);
}
.header-inner {
  max-width: var(--container); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem clamp(1.25rem, 4vw, 3rem);
}
.wordmark { display: inline-block; line-height: 1.05; }
.wordmark .wm-main {
  display: block; font-family: var(--serif); font-size: 1.35rem; letter-spacing: .42em;
  font-weight: 500;
}
.wordmark .wm-sub {
  display: block; font-size: .55rem; letter-spacing: .52em; color: var(--muted);
  margin-top: .2rem; text-transform: uppercase;
}

.main-nav ul { display: flex; gap: clamp(1.25rem, 2.4vw, 2.5rem); list-style: none; margin: 0; padding: 0; align-items: center; }
.main-nav a.nav-link {
  font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; color: var(--espresso);
  position: relative; padding: .4rem 0;
}
.main-nav a.nav-link::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%;
  background: var(--espresso); transform: scaleX(0); transform-origin: right;
  transition: transform .3s var(--ease);
}
.main-nav a.nav-link:hover::after, .main-nav a.nav-link[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  font-family: var(--sans); font-size: .78rem; letter-spacing: .2em; text-transform: uppercase;
  padding: .95rem 2.1rem; border: 1px solid var(--espresso); cursor: pointer;
  background: transparent; color: var(--espresso);
  transition: background .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease);
  min-height: 44px;
}
.btn:hover { background: var(--espresso); color: var(--porcelain); }
.btn--solid { background: var(--espresso); color: var(--porcelain); }
.btn--solid:hover { background: transparent; color: var(--espresso); }
.btn--light { border-color: rgba(247,243,238,.6); color: var(--porcelain); }
.btn--light:hover { background: var(--porcelain); color: var(--espresso); }
.btn--small { padding: .6rem 1.4rem; font-size: .72rem; }

.menu-toggle {
  display: none; background: none; border: 0; cursor: pointer; padding: .75rem;
  flex-direction: column; gap: 6px; z-index: 1001;
}
.menu-toggle span { display: block; width: 26px; height: 1.5px; background: var(--espresso); transition: transform .3s var(--ease), opacity .3s var(--ease); }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 950; background: var(--porcelain);
  display: flex; flex-direction: column; justify-content: center;
  padding: 5rem clamp(1.5rem, 8vw, 4rem) 3rem;
  transform: translateY(-100%); visibility: hidden;
  transition: transform .5s var(--ease), visibility 0s .5s;
}
.mobile-menu.open { transform: translateY(0); visibility: visible; transition: transform .5s var(--ease); }
.mobile-menu nav ul { list-style: none; margin: 0 0 2.5rem; padding: 0; }
.mobile-menu nav li { margin-bottom: .35rem; }
.mobile-menu nav a {
  display: block; font-family: var(--serif); font-size: clamp(1.9rem, 7vw, 2.6rem);
  padding: .35rem 0; border-bottom: 1px solid var(--border);
  transition: padding-left .3s var(--ease), color .3s var(--ease);
}
.mobile-menu nav a:hover, .mobile-menu nav a[aria-current="page"] { padding-left: .75rem; color: var(--muted); }
.mobile-menu .mobile-book { align-self: flex-start; }

/* ---------- Layout helpers ---------- */
.container { max-width: var(--container); margin: 0 auto; padding: 0 clamp(1.25rem, 4vw, 3rem); }
.section { padding: clamp(4.5rem, 9vw, 8rem) 0; }
.section--tight { padding: clamp(3rem, 6vw, 5rem) 0; }
.section--white { background: var(--white); }
.section--blush { background: var(--blush); }
.section--espresso { background: var(--espresso); color: var(--porcelain); }
.eyebrow {
  font-size: .72rem; letter-spacing: .34em; text-transform: uppercase; color: var(--muted);
  margin-bottom: 1.4rem; display: block;
}
.section--espresso .eyebrow { color: var(--taupe); }
.h-display { font-size: clamp(2.6rem, 6vw, 4.6rem); letter-spacing: .01em; }
.h-large { font-size: clamp(2rem, 4.2vw, 3.2rem); }
.h-medium { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
.lead { font-size: clamp(1.02rem, 1.4vw, 1.18rem); color: var(--muted); max-width: 56ch; }
.section--espresso .lead { color: var(--taupe); }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.5rem, 3vw, 2.5rem); }

/* ---------- Media / editorial ---------- */
.media-frame { overflow: hidden; background: var(--blush); }
.media-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.media-frame:hover img { transform: scale(1.04); }
.ratio-portrait { aspect-ratio: 4 / 5; }
.ratio-square { aspect-ratio: 1 / 1; }
.ratio-wide { aspect-ratio: 16 / 10; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }
.reveal-img { clip-path: inset(0 0 100% 0); transition: clip-path .85s var(--ease); }
.reveal-img.in-view { clip-path: inset(0 0 0 0); }
.reveal-img img { transform: scale(1.12); transition: transform 1.1s var(--ease); }
.reveal-img.in-view img { transform: scale(1); }
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-img { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .reveal-img img { transform: none !important; }
}

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100svh; display: flex; align-items: center; overflow: hidden; }
.hero--split .hero-grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem);
  width: 100%; max-width: var(--container); margin: 0 auto;
  padding: 7.5rem clamp(1.25rem, 4vw, 3rem) 4rem; align-items: center;
}
.hero-copy .h-display { margin-bottom: 1.4rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.2rem; }
.hero-figure { position: relative; }
.hero-figure .media-frame { border-radius: 999px 999px var(--radius) var(--radius); aspect-ratio: 4 / 5; max-height: 72vh; }
.hero-tagline { font-size: .72rem; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); margin-top: 2.4rem; display: block; }

.hero--full { min-height: 92svh; align-items: flex-end; }
.hero--full .hero-bg { position: absolute; inset: 0; }
.hero--full .hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.hero--full .hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(48,40,36,.55) 0%, rgba(48,40,36,.12) 45%, rgba(48,40,36,.08) 100%);
}
.hero--full .hero-copy { position: relative; z-index: 2; color: var(--porcelain); padding-bottom: clamp(3rem, 8vw, 6rem); }
.hero--full .hero-copy .eyebrow, .hero--full .hero-copy .lead { color: rgba(247,243,238,.85); }

@keyframes heroUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: none; } }
.hero .stagger > * { animation: heroUp .9s var(--ease) both; }
.hero .stagger > *:nth-child(1) { animation-delay: .1s; }
.hero .stagger > *:nth-child(2) { animation-delay: .25s; }
.hero .stagger > *:nth-child(3) { animation-delay: .4s; }
.hero .stagger > *:nth-child(4) { animation-delay: .55s; }
.hero .stagger > *:nth-child(5) { animation-delay: .7s; }
@media (prefers-reduced-motion: reduce) { .hero .stagger > * { animation: none; } }

.page-hero { padding: 9.5rem 0 clamp(3rem, 6vw, 5rem); }
.page-hero .lead { margin-top: 1.2rem; }

/* ---------- Cards / treatments ---------- */
.treatment-card {
  background: var(--white); border: 1px solid var(--border);
  display: flex; flex-direction: column; height: 100%;
  transition: box-shadow .35s var(--ease), transform .35s var(--ease);
}
.treatment-card:hover { box-shadow: 0 24px 60px -30px rgba(48,40,36,.28); transform: translateY(-4px); }
.treatment-card .media-frame { aspect-ratio: 4 / 3.4; }
.treatment-card .card-body { padding: 1.8rem 1.8rem 2rem; display: flex; flex-direction: column; flex: 1; }
.treatment-card h3 { font-size: 1.55rem; margin-bottom: .5rem; }
.treatment-card .card-desc { color: var(--muted); font-size: .95rem; flex: 1; }
.treatment-meta { display: flex; gap: 1.5rem; margin: 1rem 0 1.3rem; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.treatment-meta strong { color: var(--espresso); font-weight: 600; }
.card-links { display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; }
.text-link {
  font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; border-bottom: 1px solid var(--espresso);
  padding-bottom: .25rem; transition: color .3s var(--ease), border-color .3s var(--ease);
}
.text-link:hover { color: var(--muted); border-color: var(--muted); }

/* ---------- Steps ---------- */
.step { border-top: 1px solid var(--border); padding: 2.2rem 0; display: grid; grid-template-columns: auto 1fr; gap: 1.75rem; align-items: start; }
.step-num { font-family: var(--serif); font-size: 2.6rem; color: var(--taupe); line-height: 1; min-width: 3.2rem; }
.step h3 { font-size: 1.4rem; margin-bottom: .4rem; }
.step p { color: var(--muted); margin: 0; max-width: 52ch; }

/* ---------- Values ---------- */
.value-item { padding: 2rem; border: 1px solid var(--border); background: var(--white); height: 100%; }
.value-item h3 { font-size: 1.35rem; }
.value-item p { color: var(--muted); font-size: .95rem; margin: 0; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 860px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item:first-child { border-top: 1px solid var(--border); }
.faq-question {
  width: 100%; background: none; border: 0; cursor: pointer; text-align: left;
  display: flex; justify-content: space-between; align-items: center; gap: 1.5rem;
  font-family: var(--serif); font-size: clamp(1.15rem, 2vw, 1.5rem); color: var(--espresso);
  padding: 1.6rem .25rem; min-height: 44px;
}
.faq-icon { flex: none; width: 34px; height: 34px; border: 1px solid var(--border); border-radius: 50%; position: relative; transition: background .3s var(--ease), transform .45s var(--ease); }
.faq-icon::before, .faq-icon::after {
  content: ""; position: absolute; background: var(--espresso); top: 50%; left: 50%;
  transition: background .3s var(--ease);
}
.faq-icon::before { width: 12px; height: 1.5px; transform: translate(-50%, -50%); }
.faq-icon::after { width: 1.5px; height: 12px; transform: translate(-50%, -50%); }
.faq-item.open .faq-icon { background: var(--espresso); transform: rotate(135deg); }
.faq-item.open .faq-icon::before, .faq-item.open .faq-icon::after { background: var(--porcelain); }
.faq-answer { overflow: hidden; max-height: 0; opacity: 0; transition: max-height .55s var(--ease), opacity .45s var(--ease); }
.faq-answer-inner { padding: 0 .25rem 1.8rem; color: var(--muted); max-width: 68ch; }
.faq-answer-inner p { margin: 0 0 .8em; }
.faq-item.open .faq-answer { opacity: 1; }

/* ---------- Gallery ---------- */
.gallery-grid { columns: 3; column-gap: 1.5rem; }
.gallery-item { break-inside: avoid; margin-bottom: 1.5rem; border: 0; padding: 0; background: none; cursor: zoom-in; display: block; width: 100%; text-align: left; }
.gallery-item .media-frame { border: 1px solid var(--border); }
.gallery-item figcaption { font-size: .82rem; color: var(--muted); padding: .7rem .15rem 0; letter-spacing: .04em; }
.gallery-note { font-size: .85rem; color: var(--muted); margin-top: 1.6rem; }

.lightbox {
  position: fixed; inset: 0; z-index: 1000; background: rgba(30, 25, 22, .94);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: opacity .35s var(--ease), visibility 0s .35s;
}
.lightbox.open { opacity: 1; visibility: visible; transition: opacity .35s var(--ease); }
.lightbox figure { margin: 0; max-width: min(88vw, 1100px); max-height: 84vh; display: flex; flex-direction: column; align-items: center; }
.lightbox img { max-width: 100%; max-height: 76vh; object-fit: contain; }
.lightbox figcaption { color: var(--taupe); font-size: .85rem; letter-spacing: .12em; margin-top: 1rem; text-transform: uppercase; }
.lb-btn {
  position: absolute; background: none; border: 1px solid rgba(247,243,238,.35); color: var(--porcelain);
  width: 48px; height: 48px; border-radius: 50%; cursor: pointer; font-size: 1.15rem;
  display: flex; align-items: center; justify-content: center; transition: background .3s var(--ease);
}
.lb-btn:hover { background: rgba(247,243,238,.12); }
.lb-close { top: 1.5rem; right: 1.5rem; }
.lb-prev { left: 1.25rem; top: 50%; transform: translateY(-50%); }
.lb-next { right: 1.25rem; top: 50%; transform: translateY(-50%); }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; }
.form-field { display: flex; flex-direction: column; gap: .45rem; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.form-field label .req { color: #A4573F; }
.form-field input, .form-field textarea {
  font-family: var(--sans); font-size: 1rem; color: var(--espresso);
  background: var(--white); border: 1px solid var(--border); padding: .9rem 1rem;
  transition: border-color .3s var(--ease); border-radius: 0; width: 100%;
}
.form-field input:focus, .form-field textarea:focus { outline: none; border-color: var(--espresso); }
.form-field textarea { min-height: 150px; resize: vertical; }
.field-error { font-size: .82rem; color: #A4573F; display: none; }
.form-field.invalid .field-error { display: block; }
.form-field.invalid input, .form-field.invalid textarea { border-color: #A4573F; }
.form-status { margin-top: 1.4rem; font-size: .95rem; padding: 1rem 1.25rem; border: 1px solid var(--border); display: none; }
.form-status.show { display: block; }
.form-status.success { background: #EFF3EC; border-color: #B9C9AE; color: #3F5231; }
.form-status.error { background: #F7ECE8; border-color: #D8B3A6; color: #8A4632; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Contact ---------- */
.contact-card { border: 1px solid var(--border); background: var(--white); padding: 2rem; height: 100%; }
.contact-card h3 { font-size: 1.3rem; }
.contact-card p, .contact-card li { color: var(--muted); font-size: .95rem; }
.contact-card ul { list-style: none; padding: 0; margin: 0; }
.contact-card li { padding: .5rem 0; border-bottom: 1px solid var(--border); }
.contact-card li:last-child { border-bottom: 0; }

/* ---------- CTA band / footer ---------- */
.cta-band { text-align: center; }
.cta-band .h-large { max-width: 20ch; margin-left: auto; margin-right: auto; }

.site-footer { background: var(--espresso); color: var(--taupe); padding: clamp(3.5rem, 7vw, 6rem) 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: clamp(2rem, 4vw, 4rem); }
.site-footer .wordmark .wm-main { color: var(--porcelain); }
.site-footer .wordmark .wm-sub { color: var(--taupe); }
.footer-desc { font-size: .9rem; max-width: 34ch; margin-top: 1.4rem; }
.footer-col h2, .footer-col h3 { font-family: var(--sans); font-size: .75rem; letter-spacing: .28em; text-transform: uppercase; color: var(--porcelain); margin-bottom: 1.3rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: .7rem; }
.footer-col a { font-size: .92rem; transition: color .3s var(--ease); }
.footer-col a:hover { color: var(--porcelain); }
.footer-bottom {
  border-top: 1px solid rgba(247,243,238,.14); margin-top: 3.5rem; padding-top: 1.6rem;
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  font-size: .82rem; color: var(--taupe);
}

/* ---------- Back to top ---------- */
.back-top {
  position: fixed; right: 1.5rem; bottom: 1.5rem; z-index: 800;
  width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--border);
  background: var(--white); color: var(--espresso); cursor: pointer; font-size: 1.05rem;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .35s var(--ease), transform .35s var(--ease), visibility 0s .35s, background .3s var(--ease);
}
.back-top.visible { opacity: 1; visibility: visible; transform: none; transition: opacity .35s var(--ease), transform .35s var(--ease); }
.back-top:hover { background: var(--blush); }

/* ---------- Treatment detail ---------- */
.detail-meta { display: flex; flex-wrap: wrap; gap: 2.5rem; padding: 1.6rem 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin: 2.2rem 0; }
.detail-meta div span { display: block; font-size: .72rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin-bottom: .3rem; }
.detail-meta div strong { font-family: var(--serif); font-size: 1.5rem; font-weight: 500; }
.info-list { list-style: none; padding: 0; margin: 0; }
.info-list li { padding: .85rem 0 .85rem 1.6rem; border-bottom: 1px solid var(--border); position: relative; color: var(--muted); }
.info-list li::before { content: ""; position: absolute; left: 0; top: 1.45rem; width: 7px; height: 7px; border-radius: 50%; background: var(--taupe); }

/* ---------- Privacy ---------- */
.legal-body { max-width: 780px; }
.legal-body h2 { font-size: 1.6rem; margin-top: 2.6rem; }
.legal-body p, .legal-body li { color: var(--muted); }
.legal-body ul { padding-left: 1.3rem; }
.review-note { border: 1px solid var(--border); background: var(--white); padding: 1.1rem 1.4rem; font-size: .9rem; color: var(--muted); margin: 1.6rem 0; }

/* ---------- 404 ---------- */
.nf-wrap { min-height: 100svh; display: flex; align-items: center; text-align: center; }
.nf-code { font-family: var(--serif); font-size: clamp(6rem, 18vw, 11rem); line-height: 1; color: var(--taupe); margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .gallery-grid { columns: 2; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  .main-nav, .header-book { display: none; }
  .menu-toggle { display: flex; }
  .hero--split .hero-grid { grid-template-columns: 1fr; padding-top: 6.5rem; gap: 3rem; }
  .hero-figure .media-frame { max-height: none; aspect-ratio: 4 / 4.6; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .step { grid-template-columns: 1fr; gap: .6rem; }
}
@media (max-width: 560px) {
  .gallery-grid { columns: 1; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .detail-meta { gap: 1.4rem; }
  .hero-cta .btn { width: 100%; }
}
