/* ============================================================
   Ambrosia.ds — Coctelería & Catering
   Estilos minimalistas, luminosos y elegantes
   ============================================================ */

:root {
  --fucsia: #E91E7C;
  --fucsia-dark: #C2165F;
  --fucsia-soft: #FDF2F7;
  --rose: #FFF7FB;
  --white: #FFFFFF;
  --ink: #1A1A1A;
  --muted: #6B6B70;
  --line: #F0E3EB;
  --shadow: 0 10px 40px rgba(233, 30, 124, 0.08);
  --shadow-hover: 0 18px 50px rgba(233, 30, 124, 0.16);
  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1140px;
  --font-title: 'Playfair Display', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { text-decoration: none; color: inherit; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .01em;
  padding: .7rem 1.3rem;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
  white-space: nowrap;
  line-height: 1.1;
}
.btn-lg { padding: .95rem 1.7rem; font-size: 1rem; }
.btn-block { width: 100%; }

.btn-primary {
  background: var(--fucsia);
  color: #fff;
  box-shadow: 0 8px 22px rgba(233, 30, 124, 0.28);
}
.btn-primary:hover { background: var(--fucsia-dark); transform: translateY(-2px); box-shadow: 0 12px 30px rgba(233, 30, 124, 0.35); }

.btn-outline {
  background: transparent;
  color: var(--fucsia);
  border-color: var(--fucsia);
}
.btn-outline:hover { background: var(--fucsia-soft); transform: translateY(-2px); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { border-color: var(--fucsia); color: var(--fucsia); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 12px;
  padding-bottom: 12px;
}
.brand { display: flex; align-items: center; gap: .65rem; }
.brand-logo {
  height: 48px;
  width: auto;
  max-height: 48px;
  object-fit: contain;
  border-radius: 10px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: var(--font-title); font-size: 1.25rem; font-weight: 700; }
.brand-text .dot { color: var(--fucsia); }
.brand-text small { color: var(--muted); font-size: .72rem; letter-spacing: .04em; text-transform: uppercase; }
.header-actions { display: flex; align-items: center; gap: .6rem; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, var(--rose) 0%, #ffffff 100%);
  padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(3rem, 6vw, 5.5rem);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--fucsia);
  background: var(--fucsia-soft);
  padding: .35rem .85rem;
  border-radius: 999px;
  margin-bottom: 1.1rem;
}
.hero-copy h1 {
  font-family: var(--font-title);
  font-weight: 600;
  font-size: clamp(2.1rem, 5.2vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin-bottom: 1.1rem;
}
.hero-sub {
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  color: var(--muted);
  margin-bottom: 1.8rem;
}
.hero-buttons { display: flex; flex-wrap: wrap; gap: .8rem; }

.hero-media { position: relative; }
.hero-media > img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: var(--shadow-hover);
}
.hero-badge {
  position: absolute;
  bottom: -22px; left: -22px;
  background: #fff;
  padding: 10px;
  border-radius: 20px;
  box-shadow: var(--shadow);
}
.hero-badge img { width: 72px; height: 72px; border-radius: 14px; object-fit: cover; }

/* ---------- Secciones ---------- */
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section-soft { background: var(--fucsia-soft); }
.section-head { max-width: 640px; margin: 0 auto clamp(2rem, 4vw, 3rem); text-align: center; }
.section-head h2 {
  font-family: var(--font-title);
  font-weight: 600;
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
  line-height: 1.12;
  margin: .3rem 0 .6rem;
}
.section-lead { color: var(--muted); font-size: 1.05rem; }

/* ---------- Cards servicios ---------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.3rem;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  display: flex;
  flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); border-color: transparent; }
.card h3 { font-family: var(--font-title); font-weight: 600; font-size: 1.3rem; margin-bottom: .6rem; }
.card p { color: var(--muted); font-size: .96rem; flex-grow: 1; margin-bottom: 1.2rem; }
.card-link { color: var(--fucsia); font-weight: 600; font-size: .95rem; transition: gap .2s; }
.card-link:hover { color: var(--fucsia-dark); }

/* ---------- Filtros galería ---------- */
.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .6rem;
  margin-bottom: 2rem;
}
.filter {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: .9rem;
  padding: .5rem 1.1rem;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  transition: all .2s ease;
}
.filter:hover { border-color: var(--fucsia); color: var(--fucsia); }
.filter.is-active { background: var(--fucsia); border-color: var(--fucsia); color: #fff; }

/* ---------- Galería ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.gallery-item {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--shadow);
  background: #fff;
  transition: opacity .35s ease, transform .35s ease;
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  transition: transform .5s ease;
}
.gallery-item:hover img { transform: scale(1.07); }
.gallery-item figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 1.4rem .9rem .8rem;
  font-size: .85rem;
  font-weight: 500;
  color: #fff;
  background: linear-gradient(0deg, rgba(26,26,26,.78), transparent);
  opacity: 0;
  transform: translateY(8px);
  transition: all .3s ease;
}
.gallery-item:hover figcaption { opacity: 1; transform: translateY(0); }
.gallery-item.is-hidden { display: none; }

/* ---------- Cotizador ---------- */
.quote-wrap { max-width: 760px; }
.quote-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 3vw, 2.2rem);
  box-shadow: var(--shadow);
}
.field { display: flex; flex-direction: column; gap: .4rem; }
.field-full { grid-column: 1 / -1; }
.field label { font-size: .85rem; font-weight: 600; color: var(--ink); }
.field input, .field select {
  font-family: var(--font-body);
  font-size: .98rem;
  color: var(--ink);
  padding: .75rem .9rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--rose);
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
}
.field input:focus, .field select:focus {
  outline: none;
  border-color: var(--fucsia);
  box-shadow: 0 0 0 3px rgba(233, 30, 124, 0.12);
  background: #fff;
}
.field input::placeholder { color: #b7a9b1; }
.quote-actions { display: flex; flex-direction: column; gap: .7rem; margin-top: .3rem; }

/* ---------- Info entrega ---------- */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.3rem;
  max-width: 820px;
  margin: 0 auto;
}
.info-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.8rem;
  text-align: center;
  transition: transform .25s, box-shadow .25s;
}
.info-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.info-icon { font-size: 2rem; margin-bottom: .6rem; }
.info-card h3 { font-family: var(--font-title); font-weight: 600; font-size: 1.3rem; margin-bottom: .4rem; }
.info-card p { color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: #fff;
  padding: 2.6rem 0 2rem;
}
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 1.2rem; text-align: center; }
.footer-brand { display: flex; align-items: center; gap: .8rem; }
.footer-brand img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.footer-brand strong { font-family: var(--font-title); display: block; font-size: 1.2rem; }
.footer-brand span { color: #c9c9ce; font-size: .85rem; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem 1.8rem; }
.footer-links a { color: #fff; font-weight: 500; font-size: .95rem; border-bottom: 1.5px solid var(--fucsia); padding-bottom: 2px; transition: color .2s; }
.footer-links a:hover { color: var(--fucsia); }
.footer-legal { color: #9a9aa0; font-size: .82rem; }

/* ---------- WhatsApp flotante ---------- */
.wa-float {
  position: fixed;
  right: 18px; bottom: 18px;
  z-index: 60;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(37, 211, 102, 0.45);
  transition: transform .2s ease;
}
.wa-float:hover { transform: scale(1.08) translateY(-2px); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(26, 26, 26, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: 90vw;
  max-height: 82vh;
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.lightbox-caption {
  position: absolute;
  bottom: 28px; left: 0; right: 0;
  text-align: center;
  color: #fff;
  font-size: .95rem;
  padding: 0 1rem;
}
.lightbox-close, .lightbox-nav {
  position: absolute;
  background: rgba(255,255,255,.12);
  border: none;
  color: #fff;
  width: 46px; height: 46px;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.lightbox-close:hover, .lightbox-nav:hover { background: var(--fucsia); }
.lightbox-close { top: 20px; right: 20px; }
.lightbox-nav.prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-nav.next { right: 20px; top: 50%; transform: translateY(-50%); }

/* ---------- Scroll reveal ----------
   A prueba de fallos: por defecto TODO es visible.
   El estado oculto solo se aplica cuando el JS añade la clase .js a <html>.
   Si el JS tarda o falla, el contenido nunca queda invisible. */
.reveal { opacity: 1; transform: none; }

html.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .7s cubic-bezier(.16,.8,.3,1), transform .7s cubic-bezier(.16,.8,.3,1);
  will-change: opacity, transform;
}
html.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { order: 1; }
  .hero-media { order: 2; max-width: 420px; margin: 1.6rem auto 0; }
  .hero-buttons { justify-content: center; }
  .eyebrow { margin-top: 0; }
  .gallery { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 680px) {
  .header-actions .btn-ghost { display: none; }
  .brand-text { display: none; }
  .header-actions .btn-primary { padding: .55rem 1rem; font-size: .85rem; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: .7rem; }
  .quote-form { grid-template-columns: 1fr; }
  .hero-badge { left: 50%; transform: translateX(-50%); bottom: -26px; }
  .btn { font-size: .9rem; }
  .lightbox-nav.prev { left: 10px; }
  .lightbox-nav.next { right: 10px; }
}

@media (max-width: 400px) {
  .gallery { grid-template-columns: 1fr 1fr; }
}

/* Respeta usuarios con preferencia de menos movimiento */
@media (prefers-reduced-motion: reduce) {
  html.js .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
