/* Las fuentes se piden con <link> desde el <head>. Un @import aquí encadenaba
   HTML → CSS → CSS de fuentes → woff2 antes de poder pintar una sola letra. */

:root {
  --c-bg: #FCFBFA;
  --c-surface: #FFFFFF;
  --c-text: #2D2926;
  /* El gris de apoyo daba 4.41 sobre el fondo crema, justo por debajo del mínimo legible
     de 4.5. Este tono es prácticamente idéntico a la vista y ya cumple (4.53). */
  --c-text-muted: #78736F;
  --c-accent: #D1BBA4;
  --c-accent-dark: #B59C82;
  /* El dorado de marca es precioso pero como TEXTO sobre crema solo daba 2.53: ilegible para
     mucha gente. Se separan tres usos en vez de oscurecerlo todo (en el pie oscuro el dorado
     claro es justo el que funciona):
       --c-accent-dark  decorativo y sobre fondos oscuros
       --c-accent-icon  iconos y trazos sobre crema  (3.02, el mínimo para gráficos)
       --c-accent-text  texto pequeño sobre crema     (4.51, el mínimo para texto) */
  --c-accent-icon: #A58E76;
  --c-accent-text: #84715E;
  --c-border: #EBE6E0;
  
  --f-sans: 'Inter', sans-serif;
  --f-serif: 'Playfair Display', serif;
  
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 2rem;
  --space-4: 4rem;
  --space-5: 8rem;
  
  --radius: 12px;
  --transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--f-sans);
  color: var(--c-text);
  background-color: var(--c-bg);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  /* Los atributos width/height del HTML (que reservan espacio y evitan saltos de maquetación)
     el navegador los aplica como CSS. Sin este `height: auto`, `max-width` encoge el ancho pero
     la altura se queda clavada en el valor del atributo y la imagen sale deformada. */
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

/* Typography */
h1, h2, h3, h4 {
  font-family: var(--f-serif);
  font-weight: 400;
  line-height: 1.25;
  color: var(--c-text);
}

.title-xl { font-size: clamp(2.5rem, 8vw, 5rem); letter-spacing: -0.02em; }
.title-lg { font-size: clamp(1.8rem, 5vw, 3rem); letter-spacing: -0.01em; }
.title-md { font-size: 1.5rem; }

.text-small { font-size: 0.875rem; text-transform: uppercase; letter-spacing: 0.1em; }

/* Iconos SVG en línea (sustituyen a Font Awesome). Escalan con font-size, igual que hacía
   la fuente de iconos, para no tener que retocar cada sitio donde se usaban. */
.icon {
  width: 1em;
  height: 1em;
  display: inline-block;
  vertical-align: -0.125em;
  flex-shrink: 0;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 2.5rem;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
  border-radius: 100px;
  transition: var(--transition);
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  background-color: var(--c-text);
  color: var(--c-bg);
}

.btn-primary:hover {
  background-color: var(--c-accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(181, 156, 130, 0.2);
}

.btn-outline {
  background-color: transparent;
  border-color: var(--c-border);
  color: var(--c-text);
}

.btn-outline:hover {
  border-color: var(--c-text);
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1.5rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: rgba(252, 251, 250, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: var(--transition);
}

header.scrolled {
  padding: 1rem 5%;
  border-bottom: 1px solid var(--c-border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
}

.brand-mark {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand-monogram {
  font-family: 'Dancing Script', cursive;
  font-size: 2.5rem;
  line-height: 1;
}

.brand-wing {
  position: absolute;
  top: -8px;
  right: -18px;
  width: 32px;
  fill: var(--c-accent-dark);
  transform: rotate(10deg);
  pointer-events: none;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-family: var(--f-serif);
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1;
}

.brand-subtitle {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--c-text-muted);
  margin-top: 2px;
}

.nav-links {
  display: flex;
  gap: 3rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--c-text);
  transition: var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-cta-mobile { display: none; }

/* Mobile hamburger toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  margin-right: -0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 101;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background-color: var(--c-text);
  border-radius: 2px;
  /* Transición propia en vez de la genérica de 0.6s: en un control que respondes con el
     dedo, medio segundo se siente pastoso.
     Solo se animan `transform` y `opacity`, que la GPU compone sin recalcular la maquetación.
     Antes animaba `width` de la raya central y, si la transición se interrumpía, la raya se
     quedaba colapsada y el icono aparecía con dos rayas en vez de tres. */
  transition:
    transform 0.34s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.18s ease;
  transform-origin: center;
}

/* Las rayas de arriba y abajo cierran la X; la del medio se recoge hacia el centro. */
.menu-toggle.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0.1); }
.menu-toggle.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.menu-toggle:active span { background-color: var(--c-accent-text); }

/* Hero */
.hero {
  min-height: 100vh;
  /* dvh tracks the *visible* viewport, so the hero doesn't get pushed under
     iOS Safari's collapsing URL bar (the classic 100vh mobile jump). */
  min-height: 100dvh;
  display: flex;
  align-items: center;
  padding: 8rem 5% 4rem;
  position: relative;
}

.hero-container {
  display: flex;
  align-items: center;
  gap: 4rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

.hero-content {
  flex: 1;
  max-width: 600px;
}

.hero-subtitle {
  display: inline-block;
  margin-bottom: 1.5rem;
  color: var(--c-accent-text);
}

.hero-content p {
  margin: 2rem 0 3rem;
  font-size: 1.125rem;
  color: var(--c-text-muted);
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-image {
  flex: 1;
  position: relative;
  height: 80vh;
  border-radius: 200px 200px 20px 20px;
  overflow: hidden;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Default 50% center crops the mouth/chin out on common laptop heights
     (~768-900px tall viewports) since the portrait photo is taller than the
     nearly-square frame. Anchoring lower keeps eyes+nose+mouth in frame
     across breakpoints (verified at desktop/laptop/phone heights). */
  object-position: 50% 68%;
}

/* Services */
.section {
  padding: 8rem 5%;
}

.section-header {
  text-align: center;
  margin-bottom: 5rem;
  max-width: 600px;
  margin-inline: auto;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.service-card {
  background: var(--c-surface);
  padding: 3rem 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--c-border);
  text-align: center;
  transition: var(--transition);
}

/* Lift only on real pointers: on touch, :hover latches after a tap and leaves
   the card stuck in its raised state until you tap elsewhere. */
@media (hover: hover) and (pointer: fine) {
  .service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.03);
    border-color: var(--c-accent);
  }
}

.service-icon {
  font-size: 2.5rem;
  color: var(--c-accent-icon);
  margin-bottom: 1.5rem;
}

.service-card p {
  color: var(--c-text-muted);
  margin-top: 1rem;
  font-size: 0.95rem;
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1400px;
  margin: 0 auto;
}

/* Cada pieza del portafolio es un enlace a su publicación en Instagram. Es un <a>, así que
   necesita `display: block` para comportarse como la tarjeta que era. */
.gallery-item {
  display: block;
  position: relative;
  aspect-ratio: 4/5;
  border-radius: var(--radius);
  overflow: hidden;
}

.gallery-item:focus-visible {
  outline: 2px solid var(--c-accent-dark);
  outline-offset: 3px;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1s ease;
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.68) 0%, rgba(0,0,0,0.15) 45%, transparent 70%);
  /* Visible by DEFAULT. Revealing the caption on :hover alone hid it forever on
     touch devices — phones never fire hover, so the labels were dead weight. */
  opacity: 1;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 0.4rem;
  padding: 1.5rem;
}

.gallery-label {
  color: white;
  font-family: var(--f-serif);
  font-size: 1.5rem;
  line-height: 1.2;
}

/* Deja claro que la foto lleva a algún sitio; sin esto parece decorativa. */
.gallery-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Pointer devices keep the original reveal-on-hover behaviour. */
@media (hover: hover) and (pointer: fine) {
  .gallery-overlay { opacity: 0; }
  .gallery-item:hover .gallery-overlay,
  .gallery-item:focus-visible .gallery-overlay { opacity: 1; }
  .gallery-item:hover img { transform: scale(1.05); }
}

/* About Section */
.about {
  background: var(--c-surface);
}

.about-container {
  display: flex;
  align-items: center;
  gap: 6rem;
  max-width: 1200px;
  margin: 0 auto;
}

.about-image {
  flex: 1;
  position: relative;
}

.about-image::before {
  content: '';
  position: absolute;
  inset: -1rem 1rem 1rem -1rem;
  border: 1px solid var(--c-accent);
  border-radius: var(--radius);
  z-index: 0;
}

.about-image img {
  position: relative;
  z-index: 1;
  border-radius: var(--radius);
  /* A diferencia del resto, esta imagen es un GRÁFICO CON TEXTO (la cita y el reconocimiento
     de la Alcaldía de Portoviejo). Encajarla en un 4/5 con object-fit: cover se comía las
     palabras por los lados, así que aquí manda la proporción real de la imagen: se ve entera. */
  width: 100%;
  height: auto;
}

.about-content {
  flex: 1;
}

.about-content p {
  margin-bottom: 1.5rem;
  color: var(--c-text-muted);
  font-size: 1.1rem;
}

/* Footer */
footer {
  background: var(--c-text);
  color: var(--c-bg);
  padding: 6rem 5% 3rem;
  text-align: center;
}

.footer-brand {
  margin-bottom: 3rem;
}

.footer-brand .brand-monogram {
  color: var(--c-accent);
}

.footer-brand .brand-wing {
  width: 60px;
  top: -20px;
  right: -30px;
  fill: var(--c-accent);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 3rem;
}

.footer-links a {
  font-size: 1.5rem;
  color: var(--c-bg);
  transition: var(--transition);
  /* 44px minimum tap area — the bare glyphs were only 21px wide. */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
}

.footer-links a:hover {
  color: var(--c-accent);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 3rem;
  font-size: 0.875rem;
  color: rgba(255,255,255,0.5);
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
/* Pricing — flex-wrap + justify-center so an incomplete last row (e.g. 5 cards:
   3 + 2) centers itself instead of hugging the left edge like a leftover CSS
   Grid row does. Fixed-ish basis (no grow) keeps every card the same width
   whether its row has 3 items or 2. */
.pricing-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--c-bg);
  padding: 3rem 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--c-border);
  text-align: center;
  position: relative;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  flex: 0 1 320px;
}

@media (hover: hover) and (pointer: fine) {
  .pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
    border-color: var(--c-accent);
  }
}

.pricing-card.popular {
  border-color: var(--c-accent-dark);
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--c-text);
  color: var(--c-bg);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.3rem 1rem;
  border-radius: 20px;
}

.price {
  font-family: var(--f-serif);
  font-size: 3rem;
  margin: 1.5rem 0;
  color: var(--c-text);
}

.price-old {
  font-size: 1.25rem;
  color: var(--c-text-muted);
  text-decoration: line-through;
  margin-left: 0.5rem;
}

.pricing-features {
  list-style: none;
  margin-bottom: 2.5rem;
  flex-grow: 1;
}

.pricing-features li {
  margin-bottom: 1rem;
  color: var(--c-text-muted);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.pricing-features .icon {
  color: var(--c-accent-icon);
}

/* Only meaningful for the mobile swipe strip; the desktop grid shows everything. */
.pricing-hint { display: none; }

/* Sticky WhatsApp */
.sticky-wa {
  position: fixed;
  /* Clear the iPhone home-indicator bar instead of sitting under it. */
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  right: calc(20px + env(safe-area-inset-right, 0px));
  width: 60px;
  height: 60px;
  background-color: #25D366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 35px;
  box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3);
  z-index: 1000;
  transition: var(--transition);
  opacity: 0;
  pointer-events: none;
}

.sticky-wa:hover {
  transform: scale(1.1);
}

@media (max-width: 1024px) {
  .hero-container {
    flex-direction: column-reverse;
    text-align: center;
    gap: 3rem;
  }
  .hero-content { margin: 0 auto; }
  .hero-buttons { justify-content: center; }
  .hero-image {
    width: 100%;
    max-width: 500px;
    height: 60vh;
  }
  .about-container {
    flex-direction: column;
    text-align: center;
    gap: 4rem;
  }
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  header { padding: 1rem 5%; justify-content: space-between; }
  .nav-cta-desktop { display: none; }
  .menu-toggle { display: flex; }

  /* Menú a pantalla completa. Antes entraba deslizándose entero desde arriba y los enlaces
     aparecían de golpe, apretados en el centro: se veía tosco. Ahora el panel aparece con un
     fundido suave y cada enlace entra escalonado. */
  /* El header lleva `backdrop-filter`, y un filtro convierte al elemento en el marco de
     referencia de sus hijos `position: fixed`. Por eso este menú se medía contra el header
     (77px de alto) en vez de contra la pantalla, y los primeros enlaces quedaban cortados
     arriba. Con el menú abierto se quita el filtro —tapado por el panel, no se nota— y el
     overlay vuelve a referirse a la ventana. */
  body.menu-abierto header {
    backdrop-filter: none;
    background: transparent;
    border-bottom-color: transparent;
  }

  .nav-links {
    position: fixed;
    inset: 0;
    flex-direction: column;
    /* Centrado con márgenes automáticos en vez de `justify-content: center`: si la lista no
       cabe, los márgenes se anulan y nada se sale por arriba (con `center` el desbordamiento
       se reparte a los dos lados y la parte de arriba queda inalcanzable). */
    justify-content: flex-start;
    align-items: stretch;
    gap: 0;
    /* Deja libre la franja del header para que el logo y la X sigan visibles. */
    padding: calc(5.5rem + env(safe-area-inset-top)) 8% calc(2.5rem + env(safe-area-inset-bottom));
    background: rgba(252, 251, 250, 0.985);
    backdrop-filter: blur(20px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, visibility 0.35s;
    overflow-y: auto;
    z-index: 99;
  }
  .nav-links.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  /* Cada enlace en su propia línea, separado por un filete: se lee como una lista real
     y da un objetivo táctil mucho más ancho que el texto suelto de antes. */
  .nav-links > li {
    border-bottom: 1px solid var(--c-border);
    opacity: 0;
    transform: translateY(14px);
  }
  /* Centra el grupo cuando sobra sitio; cuando no, los `auto` valen 0 y nada se recorta. */
  .nav-links > li:first-child { margin-top: auto; }
  .nav-links > li:last-child { margin-bottom: auto; }
  .nav-links.open > li {
    animation: nav-entra 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  }
  .nav-links.open > li:nth-child(1) { animation-delay: 0.05s; }
  .nav-links.open > li:nth-child(2) { animation-delay: 0.10s; }
  .nav-links.open > li:nth-child(3) { animation-delay: 0.15s; }
  .nav-links.open > li:nth-child(4) { animation-delay: 0.20s; }
  .nav-links.open > li:nth-child(5) { animation-delay: 0.25s; }
  .nav-links.open > li:nth-child(6) { animation-delay: 0.32s; }

  @keyframes nav-entra {
    to { opacity: 1; transform: translateY(0); }
  }

  .nav-links > li.nav-cta-mobile { border-bottom: none; }
  /* Filas amplias: el enlace ocupa todo el ancho, así se puede tocar en cualquier parte
     de la línea y no solo sobre las letras. */
  .nav-links a {
    font-family: var(--f-serif);
    font-size: 1.6rem;
    text-transform: none;
    letter-spacing: 0;
    display: flex;
    align-items: center;
    min-height: 64px;
    width: 100%;
  }
  /* El subrayado animado del escritorio no aporta nada en una lista a pantalla completa. */
  .nav-links a::after { display: none; }
  .nav-links a:active { color: var(--c-accent-dark); }

  .nav-cta-mobile { display: block; margin-top: 1.75rem; }
  .nav-cta-mobile a {
    justify-content: center;
    font-family: var(--f-sans);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    min-height: 56px;
  }

  .section { padding: 3.5rem 5%; }
  .section-header { margin-bottom: 2.5rem; }

  /* El hero móvil medía 1084px en una pantalla de 844: se abría el sitio y solo se veía un
     hueco y la foto — el titular y los botones de reservar quedaban por debajo del borde.
     Se recorta el relleno superior (el header ya ocupa 77px) y se limita la altura de la
     foto para que el mensaje y al menos un botón entren en la primera pantalla. */
  .hero {
    min-height: auto;
    padding: 4.75rem 5% 2rem;
  }
  .hero-container { gap: 1.25rem; }
  .hero-content p { margin: 0.85rem 0 1.35rem; font-size: 1rem; }
  .hero-subtitle { margin-bottom: 0.85rem; }
  /* Los dos botones comparten fila: apilados sumaban 124px y empujaban el de "Reservar"
     fuera de la primera pantalla, que es justo la acción que debe verse sin desplazar. */
  .hero-buttons { gap: 0.6rem; flex-wrap: nowrap; }
  .hero-buttons .btn {
    flex: 1 1 0;
    /* `min-width: 0` es la pieza clave: por defecto un elemento flex no encoge por debajo
       del ancho de su contenido, así que con `nowrap` los dos botones sumaban 362px en
       351 disponibles y la fila se salía por la derecha (20px de margen a la izquierda
       contra 9px a la derecha). Ahora pueden ceder y la fila queda centrada de verdad. */
    min-width: 0;
    width: auto;
    padding-inline: 0.7rem;
    white-space: nowrap;
  }
  /* Al acortar el hero, la foto quedó en una caja APAISADA (351x280) y un retrato ahí se
     recorta a la altura de la frente: se veía media cara. La solución no es estirarla de
     alto —eso devolvería los botones fuera de pantalla— sino ESTRECHARLA y darle forma
     vertical: cabe el rostro entero y el hero sigue siendo corto. */
  .hero-image {
    width: min(64%, 250px);
    margin-inline: auto;
    aspect-ratio: 4 / 5;
    height: auto;
    min-height: 0;
    max-height: none;
    /* 999px se recorta solo a la mitad del ancho: cúpula perfecta sea cual sea el tamaño. */
    border-radius: 999px 999px 12px 12px;
  }
  /* En una caja 4/5 el retrato entra casi completo, así que se centra en vez de anclarlo
     abajo (el 68% existe para las cajas anchas de escritorio). */
  .hero-image img { object-position: 50% 45%; }

  .services-grid, .pricing-grid { gap: 1.25rem; }
  .service-card, .pricing-card { padding: 2rem 1.5rem; }

  /* Pricing becomes a horizontal snap-scroll strip to avoid a tall stack.
     `flex-wrap: nowrap` is REQUIRED here: the base rule wraps (so an incomplete
     desktop row centers), and without resetting it the cards wrapped into a
     2300px-tall stack and the snap-scroll silently did nothing. */
  .pricing-grid {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    /* Natural card heights. Stretching every card to the tallest one left a big
       dead gap above the CTA, and in a one-card-at-a-time carousel the aligned
       buttons that stretching buys you are never seen side by side anyway. */
    align-items: flex-start;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    /* overflow-x:auto also clips vertically, which beheaded the "Más pedido"
       badge sitting at top:-12px. This padding gives it room. */
    padding-top: 1.25rem;
    padding-bottom: 0.5rem;
    margin: 0 -5%;
    padding-left: 5%;
    padding-right: 5%;
  }
  .pricing-grid::-webkit-scrollbar { display: none; }
  .pricing-card {
    flex: 0 0 86%;
    scroll-snap-align: center;
  }
  /* Let the CTA sit right under the last feature instead of being pushed to the
     bottom of an over-tall card. */
  .pricing-features {
    flex-grow: 0;
    margin-bottom: 1.75rem;
  }
  .price { margin: 1rem 0; }

  /* Swipe affordance: without it the peeking card is the only hint there's more */
  .pricing-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1.25rem;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--c-text-muted);
  }

  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 0.85rem; }

  .about { padding-top: 3.5rem; }
  .about-image::before { display: none; }
  .about-content p { font-size: 1rem; margin-bottom: 1.1rem; }

  .sticky-wa { opacity: 1; pointer-events: auto; } /* Show sticky WhatsApp on mobile */
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  display: flex;
  justify-content: center;
  align-items: center;
  /* El formulario creció con los campos nuevos y ya no cabe en una pantalla de móvil:
     sin este relleno (y sin el scroll de abajo) el título y el botón quedaban pegados
     a los bordes, incluso cortados. También se respeta la zona segura del iPhone. */
  padding: max(1.25rem, env(safe-area-inset-top)) 1rem max(1.25rem, env(safe-area-inset-bottom));
  overflow-y: auto;
  overscroll-behavior: contain;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: var(--c-surface);
  width: 100%;
  max-width: 500px;
  border-radius: var(--radius);
  padding: 2.5rem;
  position: relative;
  /* `margin: auto` centra la tarjeta cuando cabe y la deja crecer con aire arriba y abajo
     cuando no; el scroll vive en el overlay, así el botón nunca queda fuera de alcance. */
  margin: auto;
  transform: translateY(20px);
  transition: transform 0.3s ease;
  box-shadow: 0 25px 50px rgba(0,0,0,0.2);
}

@media (max-width: 480px) {
  .modal-content { padding: 2rem 1.35rem; }
  .modal-header { margin-bottom: 1.5rem; }
  .modal-header h3 { font-size: 1.65rem; }
  .form-group { margin-bottom: 1.15rem; }
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: none;
  border: none;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--c-text-muted);
  cursor: pointer;
  transition: color 0.3s;
  /* Was a 14x27 hit area — too small to close reliably with a thumb. */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
}

.modal-close:hover {
  color: var(--c-text);
}

.modal-header {
  margin-bottom: 2rem;
  text-align: center;
}

.modal-header h3 {
  font-family: var(--f-serif);
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.modal-header p {
  color: var(--c-accent-text);
  font-weight: 500;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--c-text);
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 1rem;
  border: 1px solid var(--c-border);
  border-radius: 8px;
  font-family: var(--f-sans);
  /* 1rem = 16px: por debajo de eso, iOS hace zoom automático al tocar el campo. */
  font-size: 1rem;
  transition: border-color 0.3s;
  background: var(--c-bg);
  color: var(--c-text);
}

.form-group select {
  appearance: none;
  cursor: pointer;
  /* Flecha propia: la nativa cambia de aspecto en cada navegador. */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%237A7571' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round' d='M1 1.5 6 6.5l5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 12px;
  padding-right: 2.5rem;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--c-accent-dark);
}

/* Fecha y hora comparten fila en pantallas con sitio; se apilan en móvil. */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 420px) {
  .form-row { grid-template-columns: 1fr; gap: 0; }
}

.form-group input[type="date"] {
  appearance: none;
  color: var(--c-text);
  cursor: pointer;
}

.form-group .opcional {
  font-weight: 400;
  color: var(--c-text-muted);
}

.form-nota {
  margin-top: 1rem;
  font-size: 0.75rem;
  line-height: 1.5;
  text-align: center;
  color: var(--c-text-muted);
}

/* ============================================================
   MICRO-ANIMACIONES — lenguaje de maquillaje
   Todo con transform/opacity (compositado en GPU) para que el
   celular no sufra, y con estados :active porque en táctil no
   existe :hover.
   ============================================================ */

/* --- Botones: barrido de brillo, como el destello de un gloss --- */
.btn {
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg,
    transparent 38%, rgba(255, 255, 255, 0.55) 50%, transparent 62%);
  transform: translateX(-130%);
  pointer-events: none;
  /* Above the fill (a negative z-index would bury it behind the button's own
     background); passing over the label is what sells it as a gloss. */
  z-index: 1;
}

@media (hover: hover) and (pointer: fine) {
  .btn:hover::after { animation: gloss-sweep 0.75s ease-out; }
}
/* En celular el barrido se dispara al tocar. */
.btn:active::after { animation: gloss-sweep 0.6s ease-out; }
.btn:active { transform: scale(0.97); }

@keyframes gloss-sweep {
  from { transform: translateX(-130%); }
  to   { transform: translateX(130%); }
}

/* --- Logo: el delineado se "dibuja" al cargar, como trazar un ala --- */
@keyframes wing-draw {
  from { opacity: 0; transform: rotate(10deg) translateX(-10px) scaleX(0.35); }
  to   { opacity: 1; transform: rotate(10deg) translateX(0) scaleX(1); }
}

.brand-wing {
  transform-origin: left center;
  animation: wing-draw 1.1s cubic-bezier(0.16, 1, 0.3, 1) 0.25s both;
}

@keyframes monogram-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.brand-monogram {
  display: inline-block;
  animation: monogram-in 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.brand:active .brand-wing { transform: rotate(10deg) scale(1.12); }

/* --- Etiquetas de sección: trazo de labial que se pinta al aparecer --- */
.hero-subtitle {
  position: relative;
}

.hero-subtitle::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.45rem;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--c-accent), var(--c-accent-dark));
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.25s;
}

.reveal.active .hero-subtitle::after { transform: scaleX(1); }

/* --- Iconos de servicio: flotan como si estuvieran en el aire --- */
@keyframes icon-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-7px); }
}

.service-icon {
  display: inline-block;
  animation: icon-float 4.5s ease-in-out infinite;
}

.service-card:nth-child(2) .service-icon { animation-delay: 0.6s; }
.service-card:nth-child(3) .service-icon { animation-delay: 1.2s; }

/* --- Insignia "Más pedido": latido suave para atraer la vista --- */
@keyframes badge-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(181, 156, 130, 0.5); }
  70%  { box-shadow: 0 0 0 10px rgba(181, 156, 130, 0); }
  100% { box-shadow: 0 0 0 0 rgba(181, 156, 130, 0); }
}

.popular-badge {
  animation: badge-pulse 3s ease-out infinite;
}

/* --- Galería: destello diagonal al tocar/pasar --- */
.gallery-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg,
    transparent 40%, rgba(255, 255, 255, 0.28) 50%, transparent 60%);
  transform: translateX(-130%);
  pointer-events: none;
  z-index: 2;
}

@media (hover: hover) and (pointer: fine) {
  .gallery-item:hover::after { animation: gloss-sweep 0.9s ease-out; }
}
.gallery-item:active::after { animation: gloss-sweep 0.7s ease-out; }

/* --- WhatsApp flotante: anillo que late, como un timbre --- */
@keyframes wa-ring {
  0%   { box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3), 0 0 0 0 rgba(37, 211, 102, 0.45); }
  70%  { box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3), 0 0 0 14px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 10px 20px rgba(37, 211, 102, 0.3), 0 0 0 0 rgba(37, 211, 102, 0); }
}

.sticky-wa {
  animation: wa-ring 2.6s ease-out infinite;
}

.sticky-wa:active { transform: scale(0.93); }

/* --- Tarjetas: entrada escalonada, no todas de golpe --- */
.services-grid .reveal:nth-child(2),
.gallery-grid .reveal:nth-child(2) { transition-delay: 0.08s; }
.services-grid .reveal:nth-child(3),
.gallery-grid .reveal:nth-child(3) { transition-delay: 0.16s; }
.gallery-grid .reveal:nth-child(4) { transition-delay: 0.24s; }
.gallery-grid .reveal:nth-child(5) { transition-delay: 0.32s; }
.gallery-grid .reveal:nth-child(6) { transition-delay: 0.40s; }

/* Retroalimentación táctil en las tarjetas (en táctil no hay hover que las eleve). */
.service-card:active,
.pricing-card:active { transform: scale(0.985); }

/* --- Respeto por quien pide menos movimiento --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
