/* ============================================================
   Horno San Miguel — hoja de estilos
   Paleta: crema harina + tinta casi negra + oro tostado (acento)
   Tipografía: Anton (display) + Archivo (texto/utilidad)
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Anton&family=Archivo:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400&display=swap");

/* Web siempre en modo oscuro — sin variante clara ni dependencia del
   tema del sistema operativo del visitante. */
:root {
  --bg: #171310;
  --bg-alt: #1d1712;
  --surface: #221b15;
  --ink: #f2ead9;
  --ink-soft: #cdc0a9;
  --ink-faint: #93876f;
  --line: rgba(242, 234, 217, 0.14);
  --accent: #d3a24f;
  --accent-ink: #e8bd6e;
  --footer-bg: #0c0906;
  --footer-ink: #ece4d4;
  --footer-line: rgba(236, 228, 212, 0.14);
  --star: #d3a24f;

  --font-display: "Anton", "Arial Narrow", sans-serif;
  --font-body: "Archivo", "Helvetica Neue", Arial, sans-serif;

  --container: 1240px;
  --edge: clamp(20px, 5vw, 64px);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--edge);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}

h1, h2, h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 0.96;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.86rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.95em 1.7em;
  border-radius: 999px;
  border: 1.5px solid currentColor;
  cursor: pointer;
  transition: background-color 220ms var(--ease), color 220ms var(--ease), transform 220ms var(--ease), border-color 220ms var(--ease);
  white-space: nowrap;
}
.btn svg { width: 15px; height: 15px; flex: none; }
.btn-dark {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}
.btn-dark:hover { background: var(--accent); border-color: var(--accent); color: #1c1712; transform: translateY(-2px); }
.btn-outline {
  background: transparent;
  border-color: currentColor;
  color: inherit;
}
.btn-outline:hover { background: var(--accent); border-color: var(--accent); color: #1c1712; transform: translateY(-2px); }
.btn-light {
  background: transparent;
  border-color: rgba(246,240,227,0.6);
  color: #f6f0e3;
}
.btn-light:hover { background: #f6f0e3; color: #1c1712; border-color: #f6f0e3; transform: translateY(-2px); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 22px var(--edge);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #f6f0e3;
  transition: background-color 320ms var(--ease), padding 320ms var(--ease), box-shadow 320ms var(--ease), color 320ms var(--ease);
}
.nav.is-scrolled {
  background: var(--bg);
  color: var(--ink);
  padding: 14px var(--edge);
  box-shadow: 0 1px 0 var(--line);
}
.nav-logo {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: 1.1rem;
  letter-spacing: 0.03em;
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.nav-logo span {
  font-family: var(--font-body);
  text-transform: uppercase;
  font-weight: 600;
  font-size: 0.56rem;
  letter-spacing: 0.3em;
  opacity: 0.75;
  margin-top: 4px;
}
.nav-links {
  display: flex;
  gap: 2.2rem;
  list-style: none;
  margin: 0; padding: 0;
  font-weight: 600;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
}
.nav-links a { position: relative; padding: 4px 0; }
.nav-links a::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -2px;
  height: 1.5px; background: currentColor;
  transform: scaleX(0); transform-origin: left;
  transition: transform 260ms var(--ease);
}
.nav-links a:hover::after { transform: scaleX(1); }

.nav-right { display: flex; align-items: center; gap: 1.4rem; }
.nav-phone {
  display: flex; align-items: center; gap: 0.5em;
  font-weight: 700; font-size: 0.86rem;
  font-variant-numeric: tabular-nums;
}
.nav-phone svg { width: 15px; height: 15px; }

.nav-toggle {
  display: none;
  background: none; border: none; color: currentColor;
  cursor: pointer; padding: 6px;
}
.nav-toggle svg { width: 24px; height: 24px; }

.nav-mobile {
  position: fixed; inset: 0;
  background: var(--ink);
  color: var(--bg);
  z-index: 99;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2rem;
  transform: translateY(-100%);
  transition: transform 380ms var(--ease);
}
.nav-mobile.is-open { transform: translateY(0); }
.nav-mobile a {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: 2rem;
}
.nav-mobile .nav-phone { font-family: var(--font-body); font-size: 1rem; }

/* ---------- Hero ----------
   Normal-flow section (no pinning): the video and the name scroll up together
   as a single block, exactly like the rest of the page. */
.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
  background: #17130f;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 62%;
}
.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(15,12,9,0.55) 0%, rgba(15,12,9,0.15) 30%, rgba(15,12,9,0.35) 62%, rgba(12,9,7,0.92) 100%);
}
.hero-titlewrap {
  position: relative;
  z-index: 2;
  padding: 0 clamp(10px, 3vw, 28px);
  transform-origin: left bottom;
  will-change: transform, opacity;
}
.hero-title {
  color: #f6f0e3;
  font-size: clamp(3.6rem, 13vw, 11.5rem);
  letter-spacing: -0.01em;
  line-height: 0.86;
  margin-bottom: -0.06em;
}
.hero-bottom {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 22px var(--edge) 36px;
  color: #f6f0e3;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-meta {
  display: flex; align-items: center; gap: 0.6em;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(246,240,227,0.8);
}
.hero-meta svg { width: 15px; height: 15px; }

.scroll-cue {
  position: absolute;
  right: var(--edge);
  bottom: 130px;
  z-index: 2;
  writing-mode: vertical-rl;
  color: rgba(246,240,227,0.75);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  display: flex; align-items: center; gap: 10px;
  animation: cue-float 2.6s ease-in-out infinite;
  transition: opacity 200ms linear;
}
.scroll-cue::after {
  content: "";
  width: 1px; height: 34px;
  background: rgba(246,240,227,0.6);
}
@keyframes cue-float {
  0%, 100% { transform: translateY(0); opacity: 0.7; }
  50% { transform: translateY(8px); opacity: 1; }
}
@media (max-width: 720px) { .scroll-cue { display: none; } }

@media (max-width: 600px) {
  .hero-bottom { padding-bottom: 28px; }
  .hero-actions { width: 100%; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; }
}

/* ---------- Manifesto (pinned shrink text) ---------- */
.manifesto {
  position: relative;
  background: var(--bg);
  padding: clamp(50px, 8vw, 90px) var(--edge) clamp(60px, 9vw, 110px);
  text-align: center;
}
.manifesto-inner {
  max-width: 880px;
  margin: 0 auto;
}
.manifesto-title {
  font-size: clamp(2.4rem, 7vw, 5rem);
  margin-bottom: 26px;
}
.manifesto-text {
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 56ch;
  margin: 0 auto;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 760ms var(--ease), transform 760ms var(--ease);
}
.reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal-1.in-view { transition-delay: 80ms; }
.reveal-2.in-view { transition-delay: 180ms; }
.reveal-3.in-view { transition-delay: 280ms; }

/* ---------- Split (Obrador) ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  background: var(--bg-alt);
}
.split-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 22px;
  padding: clamp(50px, 8vw, 100px) clamp(28px, 6vw, 90px);
}
.split-text h2 {
  font-size: clamp(2rem, 4vw, 3.1rem);
}
.split-text p {
  color: var(--ink-soft);
  font-size: 1.02rem;
  max-width: 42ch;
}
.split-figures {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(18px, 4vw, 48px) clamp(20px, 4vw, 48px);
  margin-top: 10px;
}
.split-figure b {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--accent-ink);
}
.split-figure span {
  font-size: 0.76rem;
  letter-spacing: 0.05em;
  color: var(--ink-faint);
  text-transform: uppercase;
}
.split-actions { margin-top: 6px; }
.split-image { position: relative; min-height: 360px; overflow: hidden; }
.split-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform 900ms var(--ease);
}
.split-image:hover img { transform: scale(1.08); }

@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .split-image { min-height: 320px; order: -1; }
}

/* ---------- Products ---------- */
.products {
  position: relative;
  padding: clamp(80px, 12vw, 150px) var(--edge);
  color: #f6f0e3;
  background: #1a140f;
  isolation: isolate;
  text-align: center;
}
.products-bg {
  position: absolute; inset: 0;
  background-image: url("assets/obrador-pan.jpg");
  background-size: cover;
  background-position: center 30%;
  z-index: -2;
  filter: saturate(0.9);
}
.products-bg::after { content: ""; }
.products-scrim {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,11,8,0.88) 0%, rgba(15,11,8,0.78) 45%, rgba(15,11,8,0.92) 100%);
  z-index: -1;
}
.products .eyebrow { color: #e7c988; justify-content: center; }
.products .eyebrow::before { display: none; }
.products h2 { font-size: clamp(2.2rem, 5vw, 3.6rem); margin: 16px 0 12px; }
.products-intro {
  color: rgba(246,240,227,0.78);
  max-width: 50ch;
  margin: 0 auto 56px;
}
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(24px, 3vw, 44px);
  max-width: 980px;
  margin: 0 auto;
}
.product-card { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.product-photo {
  width: clamp(96px, 12vw, 132px);
  height: clamp(96px, 12vw, 132px);
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid rgba(246,240,227,0.25);
  box-shadow: 0 16px 40px rgba(0,0,0,0.35);
}
.product-photo img { width: 100%; height: 100%; object-fit: cover; }
.product-card h3 {
  font-family: var(--font-body);
  text-transform: none;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: 0.01em;
}
.product-card p {
  font-size: 0.86rem;
  color: rgba(246,240,227,0.68);
  line-height: 1.5;
}
@media (max-width: 760px) {
  .products-grid { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
}

/* ---------- Gallery ---------- */
.gallery { background: var(--bg); padding: clamp(70px, 10vw, 130px) var(--edge); }
.gallery-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px; margin-bottom: 40px; flex-wrap: wrap;
}
.gallery-head h2 { font-size: clamp(1.9rem, 4vw, 2.9rem); }
.gallery-head p { color: var(--ink-soft); max-width: 42ch; }
.gallery-carousel {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}
.gallery-track {
  display: flex;
  gap: 16px;
  width: max-content;
  animation: gallery-scroll 55s linear infinite;
  animation-play-state: running !important;
}
.gallery-track figure { margin: 0; flex: none; overflow: hidden; border-radius: 6px; }
.gallery-track img {
  display: block;
  height: 260px;
  width: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  cursor: pointer;
  transition: transform 500ms var(--ease);
}
.gallery-track figure:hover img { transform: scale(1.05); }
@keyframes gallery-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (max-width: 760px) {
  .gallery-track img { height: 190px; }
}

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 8, 6, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 260ms var(--ease);
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox-img {
  max-width: min(90vw, 1100px);
  max-height: 86vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: rgba(246,240,227,0.08);
  border: 1px solid rgba(246,240,227,0.25);
  color: #f6f0e3;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background-color 200ms var(--ease), transform 200ms var(--ease);
}
.lightbox-close:hover,
.lightbox-nav:hover { background: rgba(246,240,227,0.18); }
.lightbox-close { top: 22px; right: 22px; width: 44px; height: 44px; }
.lightbox-close svg { width: 20px; height: 20px; }
.lightbox-nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; }
.lightbox-nav:hover { transform: translateY(-50%) scale(1.08); }
.lightbox-nav svg { width: 22px; height: 22px; }
.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }
@media (max-width: 640px) {
  .lightbox-nav { width: 42px; height: 42px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-close { top: 12px; right: 12px; }
}

/* ---------- Location ---------- */
.location { background: var(--bg-alt); padding: clamp(70px, 10vw, 130px) var(--edge); }
.location-grid {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: start;
}
.location-card h2 { font-size: clamp(2rem, 4vw, 2.9rem); margin: 14px 0 22px; }
.rating-row { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.rating-score {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--ink);
}
.stars { display: flex; gap: 3px; }
.stars svg { width: 16px; height: 16px; fill: var(--star); }
.rating-count { color: var(--ink-faint); font-size: 0.86rem; }

.info-list { display: flex; flex-direction: column; gap: 18px; margin-bottom: 30px; }
.info-row { display: flex; gap: 14px; align-items: flex-start; }
.info-row svg { width: 19px; height: 19px; flex: none; margin-top: 2px; color: var(--accent-ink); }
.info-row b { display: block; font-size: 0.95rem; }
.info-row span { color: var(--ink-soft); font-size: 0.92rem; }
.info-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.map-frame {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  min-height: 420px;
  border: 1px solid var(--line);
  filter: grayscale(0.15) contrast(1.02);
}
.map-frame iframe { width: 100%; height: 100%; min-height: 420px; border: 0; display: block; }

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

/* ---------- CTA banner + reseñas a los lados ---------- */
.cta-banner {
  position: relative;
  isolation: isolate;
  padding: clamp(70px, 11vw, 130px) var(--edge);
  text-align: center;
  color: #f6f0e3;
}
.cta-banner-bg {
  position: absolute; inset: 0; z-index: -2;
  background-image: url("assets/obrador-mostrador.jpg");
  background-size: cover;
  background-position: center 30%;
  background-attachment: fixed;
}
.cta-banner-scrim {
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(12,9,7,0.82), rgba(12,9,7,0.78));
}
.cta-banner .eyebrow { color: #e7c988; justify-content: center; }
.cta-banner .eyebrow::before { display: none; }
.cta-banner h2 { font-size: clamp(2.1rem, 5.4vw, 3.8rem); margin: 16px 0 20px; }
.cta-banner p { color: rgba(246,240,227,0.82); max-width: 46ch; margin: 0 auto 34px; }
.cta-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

@media (max-width: 600px) {
  .cta-banner-bg { background-attachment: scroll; }
}

.cta-layout {
  display: grid;
  grid-template-columns: 1fr minmax(0, 640px) 1fr;
  align-items: center;
  gap: clamp(20px, 3vw, 40px);
  max-width: 1320px;
  margin: 0 auto;
}
.cta-center { grid-column: 2; }

.review-card {
  background: rgba(246, 240, 227, 0.08);
  border: 1px solid rgba(246, 240, 227, 0.22);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 10px;
  padding: 26px 24px;
  text-align: left;
}
.review-card .stars { display: flex; gap: 3px; margin-bottom: 14px; }
.review-card .stars svg { width: 15px; height: 15px; fill: var(--star); }
.review-quote {
  font-size: 0.92rem;
  line-height: 1.6;
  color: rgba(246, 240, 227, 0.92);
}
.review-name {
  margin-top: 16px;
  font-weight: 700;
  font-size: 0.86rem;
  color: #f6f0e3;
}
.review-name span { font-weight: 500; color: rgba(246, 240, 227, 0.6); }

@media (max-width: 980px) {
  .cta-layout { grid-template-columns: 1fr; }
  .cta-center { grid-column: 1; order: -1; }
  .review-card { max-width: 440px; margin: 0 auto; }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--footer-bg);
  color: var(--footer-ink);
  padding: clamp(56px, 8vw, 88px) var(--edge) 26px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 44px;
  border-bottom: 1px solid var(--footer-line);
}
.footer-brand .nav-logo { color: var(--footer-ink); margin-bottom: 16px; }
.footer-brand p {
  color: rgba(236,228,212,0.66);
  max-width: 34ch;
  font-size: 0.92rem;
  margin-bottom: 20px;
}
.footer-social { display: flex; gap: 14px; }
.footer-social a {
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--footer-line);
  display: flex; align-items: center; justify-content: center;
  transition: background-color 220ms var(--ease), transform 220ms var(--ease);
}
.footer-social a:hover { background: var(--accent); border-color: var(--accent); transform: translateY(-2px); }
.footer-social svg { width: 17px; height: 17px; }

.footer-col h4 {
  font-family: var(--font-body);
  text-transform: uppercase;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  font-weight: 700;
  color: rgba(236,228,212,0.55);
  margin-bottom: 18px;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; font-size: 0.92rem; }
.footer-col a { color: rgba(236,228,212,0.88); transition: color 200ms var(--ease); }
.footer-col a:hover { color: var(--accent-ink); }
.footer-col address { font-style: normal; color: rgba(236,228,212,0.88); font-size: 0.92rem; }

.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 22px; font-size: 0.8rem; color: rgba(236,228,212,0.5);
  flex-wrap: wrap; gap: 10px;
}

@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr; gap: 34px; }
}

/* ---------- WhatsApp FAB ---------- */
.wa-fab {
  position: fixed;
  right: 22px; bottom: 22px;
  z-index: 90;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 26px rgba(0,0,0,0.28);
  transition: transform 220ms var(--ease);
}
.wa-fab:hover { transform: scale(1.08); }
.wa-fab svg { width: 27px; height: 27px; }

/* ---------- Responsive nav switch ---------- */
@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
  .desktop-only { display: none; }
  .nav { padding: 16px var(--edge); }
  .nav.is-scrolled { padding: 12px var(--edge); }
}
@media (min-width: 881px) {
  .nav-mobile { display: none; }
}

@media (max-width: 620px) {
  .hero-bottom { flex-direction: column; align-items: flex-start; gap: 18px; }
  .location-card .info-actions .btn { flex: 1 1 auto; justify-content: center; }
}
