/* Paleta dorado y marfil; tipografías Spectral (títulos) y Work Sans (texto). */
:root {
  --marfil: #faf6ee;
  --crema: #f3ecdf;
  --dorado: #b08d57;
  --dorado-oscuro: #8a6a36;
  --verde-noche: #1e3530;
  --texto: #2b2621;
  --texto-suave: #6b6258;
  --borde: #e4d9c6;
  --blanco: #ffffff;
  --sombra: 0 18px 40px rgba(43, 38, 33, 0.18);
  --serif: "Spectral", Georgia, serif;
  --sans: "Work Sans", "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--marfil);
  color: var(--texto);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; margin: 0; }

/* Barra de anuncio */
.barra-anuncio {
  background: var(--verde-noche);
  color: #f3ecdf;
  text-align: center;
  font-size: 0.9rem;
  padding: 0.7rem 1rem;
  letter-spacing: 0.01em;
}
.barra-anuncio a { color: #fff; font-weight: 600; }
.barra-anuncio .separador { opacity: 0.5; margin: 0 0.8rem; }

/* Encabezado */
.encabezado {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 246, 238, 0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--borde);
}
.encabezado-fila {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 1.1rem 2rem 0.6rem;
}
.logo {
  grid-column: 2;
  font-family: var(--serif);
  font-size: 2rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--dorado-oscuro);
  white-space: nowrap;
}
.encabezado-cta { grid-column: 3; justify-self: end; }
.navegacion {
  display: flex;
  justify-content: center;
  gap: 2.6rem;
  padding: 0.4rem 1rem 1rem;
}
.navegacion a {
  text-decoration: none;
  font-size: 1.02rem;
  position: relative;
  padding-bottom: 2px;
}
.navegacion a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: var(--dorado);
  transform: scaleX(0);
  transition: transform 0.25s ease;
}
.navegacion a:hover::after { transform: scaleX(1); }
.nav-destacado { color: var(--dorado-oscuro); font-weight: 500; }
.menu-movil { display: none; }

/* Botones */
.boton {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  padding: 0.8rem 1.8rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}
.boton-dorado { background: var(--dorado); color: #fff; }
.boton-dorado:hover { background: var(--dorado-oscuro); }
.boton-claro { background: rgba(255, 255, 255, 0.92); color: var(--texto); }
.boton-claro:hover { background: #fff; }
.boton-contorno { border-color: var(--dorado); color: var(--dorado-oscuro); padding: 0.6rem 1.3rem; }
.boton-contorno:hover { background: var(--dorado); color: #fff; }
.boton-grande { padding: 1rem 3rem; font-size: 1.05rem; }
.boton:disabled { opacity: 0.6; cursor: wait; }

/* Portada con video */
.portada {
  position: relative;
  height: min(78vh, 760px);
  min-height: 460px;
  overflow: hidden;
  display: grid;
  place-items: center;
  text-align: center;
  color: #fff;
}
.portada-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.portada-velo {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(20, 16, 10, 0.45), rgba(20, 16, 10, 0.6));
}
.portada-texto p { text-shadow: 0 1px 12px rgba(0, 0, 0, 0.6); }
.portada-texto { position: relative; padding: 0 1.5rem; max-width: 820px; }
.portada-pre {
  font-family: var(--serif);
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 1.1rem;
  margin: 0 0 0.6rem;
}
.portada h1 {
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.08;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.35);
}
.portada-sub { font-size: 1.15rem; margin: 1rem 0 2rem; font-weight: 300; }
.portada-botones { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Secciones */
.seccion { padding: 5.5rem 2rem; scroll-margin-top: 110px; }
.seccion-crema { background: var(--crema); }
.seccion-titulo { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.antetitulo {
  color: var(--dorado-oscuro);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.82rem;
  font-weight: 500;
  margin: 0 0 0.7rem;
}
.seccion-titulo h2, .nosotros-texto h2 { font-size: clamp(2rem, 4vw, 2.8rem); line-height: 1.15; }
.seccion-bajada { color: var(--texto-suave); margin: 0.9rem 0 0; }

/* Catálogo */
.catalogo {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1180px;
  margin: 0 auto;
}
.producto {
  background: var(--blanco);
  border: 1px solid var(--borde);
  cursor: pointer;
  transition: box-shadow 0.35s ease, border-color 0.35s ease, transform 0.35s ease;
  text-align: center;
  outline: none;
}
.producto-foto { overflow: hidden; aspect-ratio: 1 / 1; }
.producto-foto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.producto:hover, .producto:focus-visible { box-shadow: var(--sombra); transform: translateY(-4px); border-color: var(--dorado); }
.producto:hover .producto-foto img, .producto:focus-visible .producto-foto img { transform: scale(1.12); }
.producto-pie { padding: 1.1rem 1rem 1.3rem; }
.producto-codigo {
  font-family: var(--serif);
  font-size: 1.5rem;
  letter-spacing: 0.12em;
  color: var(--texto);
}
.producto-accion { font-size: 0.85rem; color: var(--texto-suave); margin-top: 0.2rem; }
.producto.seleccionado { border: 2px solid var(--dorado); }
.producto.seleccionado .producto-accion { color: var(--dorado-oscuro); font-weight: 600; }
.nota-fotos { text-align: center; color: var(--texto-suave); font-size: 0.85rem; margin-top: 2rem; }

/* Cómo funciona */
.pasos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1040px;
  margin: 0 auto;
  text-align: center;
}
.paso-numero {
  display: inline-grid;
  place-items: center;
  width: 3.2rem;
  height: 3.2rem;
  border: 1px solid var(--dorado);
  border-radius: 50%;
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--dorado-oscuro);
  margin-bottom: 1rem;
}
.paso h3 { font-size: 1.6rem; margin-bottom: 0.5rem; }
.paso p { color: var(--texto-suave); margin: 0; }

/* Nosotros */
.nosotros {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
}
.nosotros-foto img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.nosotros-texto p { color: var(--texto-suave); font-size: 1.05rem; }
.nosotros-texto h2 { margin-bottom: 1.2rem; }
.nosotros-firma {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.35rem !important;
  color: var(--dorado-oscuro) !important;
  margin-top: 1.6rem;
}

/* Formulario */
.formulario {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.3rem 1.6rem;
  max-width: 900px;
  margin: 0 auto;
  background: var(--blanco);
  border: 1px solid var(--borde);
  padding: 2.6rem;
}
.campo { display: flex; flex-direction: column; gap: 0.4rem; }
.campo-ancho { grid-column: 1 / -1; }
.campo label, .etiqueta { font-size: 0.92rem; font-weight: 500; }
.campo input, .campo textarea, .desplegable-boton {
  font: inherit;
  font-size: 1rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--borde);
  background: var(--marfil);
  color: var(--texto);
  border-radius: 0;
  width: 100%;
}
.campo input:focus, .campo textarea:focus, .desplegable-boton:focus {
  outline: 2px solid var(--dorado);
  outline-offset: 0;
  border-color: var(--dorado);
}
.campo.error input, .campo.error textarea, .campo.error .desplegable-boton { border-color: #b3261e; }
.campo-oculto { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Lista desplegable con casillas */
.desplegable { position: relative; }
.desplegable-boton {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  cursor: pointer;
}
.desplegable-texto { color: var(--texto-suave); }
.desplegable-boton.con-seleccion .desplegable-texto { color: var(--texto); }
.desplegable-flecha {
  width: 0.55rem; height: 0.55rem;
  border-right: 1.5px solid var(--texto);
  border-bottom: 1.5px solid var(--texto);
  transform: rotate(45deg) translateY(-3px);
  transition: transform 0.2s;
}
.desplegable-boton[aria-expanded="true"] .desplegable-flecha { transform: rotate(-135deg); }
.desplegable-lista {
  position: absolute;
  top: calc(100% + 4px);
  left: 0; right: 0;
  background: var(--blanco);
  border: 1px solid var(--borde);
  box-shadow: var(--sombra);
  z-index: 20;
  max-height: 320px;
  overflow-y: auto;
}
.opcion {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.6rem 0.9rem;
  cursor: pointer;
}
.opcion:hover { background: var(--crema); }
.opcion input { width: 1.1rem; height: 1.1rem; accent-color: var(--dorado); }
.opcion img { width: 44px; height: 44px; object-fit: cover; }
.opcion span { font-family: var(--serif); font-size: 1.1rem; letter-spacing: 0.08em; }

.formulario-pie { text-align: center; }
.mensaje-formulario { min-height: 1.5rem; margin: 0 0 1rem; }
.mensaje-formulario.ok { color: #2f6b3a; }
.mensaje-formulario.mal { color: #b3261e; }

/* Pie */
.pie {
  background: var(--verde-noche);
  color: #e9e1d2;
  text-align: center;
  padding: 3.5rem 2rem 2.5rem;
}
.pie-logo { font-family: var(--serif); font-size: 1.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: #d8bd86; margin: 0; }
.pie-frase { font-family: var(--serif); font-style: italic; margin: 0.3rem 0 1.6rem; }
.pie-nav { display: flex; justify-content: center; gap: 2rem; flex-wrap: wrap; margin-bottom: 1.8rem; }
.pie-nav a { text-decoration: none; opacity: 0.85; }
.pie-nav a:hover { opacity: 1; }
.pie-legal { font-size: 0.85rem; opacity: 0.7; margin: 0; }

/* WhatsApp flotante */
.whatsapp {
  position: fixed;
  right: 1.4rem;
  bottom: 1.4rem;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  z-index: 60;
  transition: transform 0.2s;
}
.whatsapp[hidden] { display: none; }
.whatsapp:hover { transform: scale(1.08); }
.whatsapp svg { width: 32px; height: 32px; }

/* Aparición suave al hacer scroll */
.revelar { opacity: 0; transform: translateY(24px); transition: opacity 0.8s ease, transform 0.8s ease; }
.revelar.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .revelar { opacity: 1; transform: none; transition: none; }
  .producto, .producto-foto img { transition: none; }
}

/* Tablet y celular */
@media (max-width: 960px) {
  .catalogo { grid-template-columns: repeat(2, 1fr); gap: 1.3rem; }
  .nosotros { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 720px) {
  .barra-anuncio { font-size: 0.8rem; }
  .barra-anuncio .separador { margin: 0 0.4rem; }
  .encabezado-fila { padding: 0.9rem 1rem; grid-template-columns: auto 1fr auto; }
  .logo { grid-column: 2; justify-self: center; font-size: 1.25rem; letter-spacing: 0.1em; }
  .encabezado-cta { display: none; }
  .menu-movil {
    display: flex; flex-direction: column; gap: 5px;
    grid-column: 1; background: none; border: 0; padding: 0.4rem; cursor: pointer;
  }
  .menu-movil span { width: 22px; height: 1.5px; background: var(--texto); }
  .navegacion { display: none; flex-direction: column; gap: 0; padding: 0; border-top: 1px solid var(--borde); }
  .navegacion.abierta { display: flex; }
  .navegacion a { padding: 0.9rem 1.2rem; border-bottom: 1px solid var(--borde); }
  .navegacion a::after { display: none; }
  .seccion { padding: 4rem 1rem; scroll-margin-top: 60px; }
  .pasos { grid-template-columns: 1fr; }
  .formulario { grid-template-columns: 1fr; padding: 1.4rem; }
  .boton-grande { width: 100%; }
}
@media (max-width: 440px) {
  .catalogo { grid-template-columns: 1fr; }
}
.nav-admin { color: var(--texto-suave); font-size: 0.92rem !important; }

/* Consentimiento del formulario */
.casilla { display: flex; gap: 0.7rem; align-items: flex-start; font-weight: 400 !important; cursor: pointer; }
.casilla input { width: 1.15rem; height: 1.15rem; margin-top: 0.2rem; accent-color: var(--dorado); flex-shrink: 0; }
.casilla a { color: var(--dorado-oscuro); }
.campo-consentimiento.error .casilla span { color: #b3261e; }
.pie-legal a { color: inherit; }
.pie-legal + .pie-legal { margin-top: 0.4rem; }

/* Página legal */
.legal { max-width: 820px; margin: 0 auto; }
.legal h1 { font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: 0.4rem; }
.legal h2 { font-size: 1.7rem; margin: 2.4rem 0 0.8rem; }
.legal h3 { font-size: 1.25rem; margin: 1.4rem 0 0.4rem; }
.legal p, .legal li { color: var(--texto-suave); }
.legal a { color: var(--dorado-oscuro); }
.legal-fecha { font-size: 0.9rem; }
.legal-volver { margin-top: 2.4rem; }
.legal-volver a { color: #fff; }
