/* =========================================================
   YUKAN SUSHI — menu.css
   Brand surface. Mexican-izakaya neon voice.
   Voice words: warm, hand-cut, late-night, romantic.
   ========================================================= */

/* ---- Type system -------------------------------------- */
/* Self-hosted (woff2, font-display: swap). No external @import. */
@font-face {
  font-family: 'League Gothic';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/league-gothic-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/open-sans-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/open-sans-700.woff2') format('woff2');
}

/* ---- Tokens (OKLCH) ----------------------------------- */
:root {
  /* Brand seed: #f4af00  → oklch(0.823 0.171 84.5) */
  --brand-yellow:        oklch(0.823 0.171 84.5);
  --brand-yellow-soft:   oklch(0.823 0.171 84.5 / 0.18);
  --brand-yellow-glow:   oklch(0.823 0.171 84.5 / 0.45);

  /* Accent — deep romantic red, drawn from the hero hearts */
  --accent-red:          oklch(0.555 0.214 25.0);
  --accent-red-soft:     oklch(0.555 0.214 25.0 / 0.22);

  /* Surfaces — near-black with a touch of warmth */
  --bg-deep:             oklch(0.155 0.012 60);
  --bg-base:             oklch(0.205 0.014 60);
  --bg-raised:           oklch(0.245 0.015 60);
  --bg-veil:             oklch(0.205 0.014 60 / 0.92);

  /* Ink */
  --ink-strong:          oklch(0.985 0.004 80);   /* near-white warm */
  --ink-medium:          oklch(0.880 0.012 80);
  --ink-muted:           oklch(0.700 0.018 70);   /* ≥4.5:1 on --bg-base */
  --ink-faint:           oklch(0.560 0.020 70);

  /* Dividers */
  --rule:                oklch(0.985 0.004 80 / 0.08);
  --rule-strong:         oklch(0.985 0.004 80 / 0.16);

  /* Type */
  --font-display: 'League Gothic', 'Bebas Neue', 'Oswald', system-ui, sans-serif;
  --font-body:    'Open Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  /* Fluid type — clamp(min, fluid, max). Refuse cramped or shouty. */
  --fs-hero:     clamp(3.25rem,  2.4rem + 4.2vw, 5.5rem);   /* 52 → 88 */
  --fs-h1:       clamp(2.50rem,  2.0rem + 2.5vw, 4.0rem);   /* 40 → 64 */
  --fs-h2:       clamp(2.25rem,  1.8rem + 2.0vw, 3.5rem);   /* 36 → 56 */
  --fs-h3:       clamp(1.85rem,  1.55rem + 1.4vw, 2.5rem);  /* 30 → 40 */
  --fs-price:    clamp(1.85rem,  1.55rem + 1.4vw, 2.5rem);
  --fs-list:     clamp(1.65rem,  1.4rem + 1.2vw, 2.15rem);
  --fs-body:     clamp(0.95rem,  0.9rem + 0.2vw, 1.05rem);
  --fs-meta:     clamp(0.75rem,  0.72rem + 0.15vw, 0.85rem);
  --fs-eyebrow:  clamp(0.70rem,  0.68rem + 0.10vw, 0.80rem);

  /* Spacing rhythm — generous, varying */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;
  --s-10: 8rem;

  /* Layout */
  --container:  min(72rem, 100% - 2.5rem);
  --container-tight: min(56rem, 100% - 2rem);

  /* Radii — modest. Cards top out at 14. */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --r-pill: 999px;

  /* Motion */
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-out-expo:  cubic-bezier(0.16, 1, 0.3, 1);
  --t-fast: 150ms;
  --t-med:  260ms;
  --t-slow: 480ms;

  /* Semantic z-index scale */
  --z-nav: 50;
  --z-modal: 80;
  --z-toast: 90;
  --z-tooltip: 95;
}

/* ---- Reset -------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  overflow-x: hidden;
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
  -webkit-text-size-adjust: 100%;
}

/* --- Barra de Navegación Fija --- */
.sticky-nav-wrapper {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    padding: 0.5rem 0;
    margin-bottom: 1rem;
    background-color: rgba(26, 26, 26, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    box-sizing: border-box;
}

.nav-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0.5rem 0;
    overflow-x: auto;
    white-space: nowrap;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.nav-list::-webkit-scrollbar { display: none; }

.nav-list li a {
    font-family: 'League Gothic', sans-serif;
    text-decoration: none;
    color: var(--text-medium);
    font-size: 1.5rem;
    letter-spacing: 0.05em;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: background-color 0.3s, color 0.3s;
}

.nav-list li a:hover, .nav-list li a.active {
    background-color: var(--brand-yellow);
    color: var(--background-color);
}

/* En móvil el sticky-nav es mas compacto (≈54px). Ajustamos el offset
   para que las secciones no queden tapadas por la nav al navegar por
   los enlaces de la sticky-nav. */
@media (max-width: 540px) {
  html { scroll-padding-top: 4rem; }
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg-base);
  color: var(--ink-strong);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

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

button { font: inherit; cursor: pointer; }

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

::selection { background: var(--brand-yellow); color: var(--bg-deep); }

/* Subtle paper-grain on body, extremely faint.
   Refuse obvious "diagonal stripes" or grid overlay decorations. */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  background:
    radial-gradient(60% 50% at 50% 0%, var(--accent-red-soft), transparent 70%),
    radial-gradient(40% 35% at 50% 100%, oklch(0 0 0 / 0.5), transparent 70%);
  z-index: -1;
}

/* ---- Layout container --------------------------------- */
.container {
  width: var(--container);
  margin: 0 auto;
  padding-inline: var(--s-4);
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* =========================================================
   HEADER / HERO
   ========================================================= */
.site-header {
  position: relative;
  width: 100%;
  min-height: clamp(560px, 92vh, 880px);
  display: grid;
  grid-template-rows: auto 1fr auto;
  isolation: isolate;
  overflow: hidden;
  border-bottom: 1px solid var(--rule);
}

.site-header__bg {
  position: absolute;
  inset: 0;
  background-image: url('background.webp');
  background-size: cover;
  background-position: center;
  z-index: -2;
  filter: saturate(1.05) contrast(1.02);
}

.site-header__bg::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, oklch(0.10 0.01 60 / 0.55) 0%, oklch(0.10 0.01 60 / 0.10) 35%, oklch(0.10 0.01 60 / 0.85) 100%),
    radial-gradient(70% 60% at 50% 30%, transparent, oklch(0.10 0.01 60 / 0.55) 100%);
}

/* Floating-heart drift — slow, peaceful. Respects reduced-motion. */
.site-header__bg::before {
  content: "";
  position: absolute; inset: -10% -5%;
  background:
    radial-gradient(circle at 18% 22%, var(--accent-red-soft) 0 6px, transparent 7px),
    radial-gradient(circle at 78% 30%, var(--accent-red-soft) 0 4px, transparent 5px),
    radial-gradient(circle at 35% 65%, var(--accent-red-soft) 0 5px, transparent 6px),
    radial-gradient(circle at 88% 70%, var(--accent-red-soft) 0 3px, transparent 4px),
    radial-gradient(circle at 60% 85%, var(--accent-red-soft) 0 4px, transparent 5px);
  background-size: 100% 100%;
  animation: drift 18s ease-in-out infinite alternate;
  opacity: 0.7;
  pointer-events: none;
  will-change: transform;
}

@keyframes drift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(-2%, 1.5%, 0) scale(1.05); }
}

.site-header__top {
  display: flex;
  justify-content: center;
  padding: var(--s-6) var(--s-4) 0;
}

.logo {
  width: clamp(140px, 18vw, 220px);
  height: auto;
  aspect-ratio: 1 / 1;
  filter: drop-shadow(0 4px 24px oklch(0 0 0 / 0.6));
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--s-6) var(--s-4);
  gap: var(--s-3);
}

.hero__eyebrow {
  font-family: var(--font-display);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--brand-yellow);
  margin: 0;
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-hero);
  line-height: 0.95;
  letter-spacing: 0.02em;
  color: var(--ink-strong);
  margin: 0;
  text-wrap: balance;
  text-shadow: 0 4px 32px oklch(0 0 0 / 0.55);
}

.hero__title em {
  font-style: normal;
  color: var(--brand-yellow);
  display: block;
  font-size: 0.86em;
  letter-spacing: 0.06em;
  margin-top: -0.05em;
}

.hero__sub {
  font-size: var(--fs-body);
  color: var(--ink-medium);
  margin: var(--s-3) 0 0;
  max-width: 32ch;
}

/* Quick category tiles — ahora 5 elementos: 4 categorías + Contacto.
   Mobile: columna de 5 filas (1 col).
   Tablet (541-719): 2 columnas.
   Desktop (≥720): 5 columnas en una fila. */
.cat-tiles {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-3);
  padding: 0 var(--s-4) var(--s-7);
  width: var(--container);
  margin: 0 auto;
}

@media (min-width: 541px) and (max-width: 719px) {
  .cat-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 720px) {
  .cat-tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

.cat-tile {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--s-4) var(--s-3);
  min-height: 64px;
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  letter-spacing: 0.04em;
  color: var(--ink-strong);
  background: var(--bg-veil);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid var(--rule-strong);
  border-radius: var(--r-md);
  opacity: 0.5;
  transition: opacity var(--t-fast) var(--ease-out-quart),
              transform var(--t-fast) var(--ease-out-quart),
              background-color var(--t-fast) var(--ease-out-quart),
              border-color var(--t-fast) var(--ease-out-quart),
              color var(--t-fast) var(--ease-out-quart);
}

.cat-tile:hover,
.cat-tile:focus-visible {
  background: var(--brand-yellow);
  color: var(--bg-deep);
  border-color: var(--brand-yellow);
  transform: translateY(-2px);
  outline: none;
}

.cat-tile:focus-visible {
  box-shadow: 0 0 0 3px var(--brand-yellow-glow);
}

.menu-note {
  width: var(--container);
  max-width: 56rem;
  margin: var(--s-5) auto 0;
  padding: var(--s-3) var(--s-4);
  font-family: var(--font-body);
  font-size: var(--fs-meta);
  line-height: 1.6;
  color: var(--ink-medium);
  text-align: center;
  background: var(--bg-raised);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
}
.menu-note strong {
  color: var(--brand-yellow);
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* =========================================================
   STICKY NAV
   ========================================================= */
.sticky-nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  background: var(--bg-veil);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--rule);
  box-shadow: 0 6px 24px oklch(0 0 0 / 0.25);
}

.sticky-nav__inner {
  position: relative;
}

.sticky-nav__inner::after {
  content: "";
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 32px;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--bg-veil) 80%);
  /* JS toggle: se oculta cuando el UL está al final del scroll horizontal.
     Reduce el "area lateral" visual cuando no hay contenido a la derecha. */
  opacity: 1;
  transition: opacity var(--t-fast) var(--ease-out-quart);
}

.sticky-nav__inner.scrolled-end::after {
  opacity: 0;
}

/* En desktop (>=960px) el UL ya no scrollea (flex-wrap:wrap + overflow:visible)
   asi que el ::after nunca deberia mostrarse. */
@media (min-width: 960px) {
  .sticky-nav__inner::after { display: none; }
}

.sticky-nav__inner {
  width: var(--container);
  margin: 0 auto;
  padding: var(--s-3) var(--s-4);
}

.sticky-nav__list {
  display: flex;
  gap: var(--s-2);
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  min-width: 0;
  overscroll-behavior-x: contain;
  touch-action: pan-x pinch-zoom;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--s-4);
}

.sticky-nav__list::-webkit-scrollbar { display: none; }

.sticky-nav__link {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  padding: var(--s-2) var(--s-4);
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  letter-spacing: 0.04em;
  color: var(--ink-medium);
  border-radius: var(--r-sm);
  scroll-snap-align: start;
  white-space: nowrap;
  transition: color var(--t-fast) var(--ease-out-quart),
              background-color var(--t-fast) var(--ease-out-quart),
              transform var(--t-fast) var(--ease-out-quart);
}

.sticky-nav__link:hover { color: var(--ink-strong); }

.sticky-nav__link:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--brand-yellow-glow);
}

.sticky-nav__link.is-active {
  color: var(--bg-deep);
  background: var(--brand-yellow);
}

@media (min-width: 960px) {
  .sticky-nav__list { justify-content: center; flex-wrap: wrap; overflow-x: visible; }
}

/* =========================================================
   MAIN MENU — sections & items
   ========================================================= */
.menu {
  width: var(--container);
  margin: 0 auto;
  padding: var(--s-9) 0 var(--s-10);
}

.section {
  margin-block: var(--s-9);
  scroll-margin-top: 6rem;
}

.section__head {
  display: grid;
  gap: var(--s-3);
  margin-bottom: var(--s-7);
  text-align: center;
}

.section__eyebrow {
  font-family: var(--font-display);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.45em;
  text-transform: uppercase;
  color: var(--accent-red);
  margin: 0;
  display: inline-block;
  padding: var(--s-1) var(--s-3);
  border: 1px solid var(--accent-red-soft);
  border-radius: var(--r-sm);
}

.section__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-h1);
  line-height: 0.95;
  letter-spacing: 0.03em;
  color: var(--ink-strong);
  margin: 0;
  text-wrap: balance;
}

.section__title--alt { color: var(--accent-red); }

.section__subtitle {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-h2);
  letter-spacing: 0.04em;
  color: var(--brand-yellow);
  margin: var(--s-6) 0 var(--s-5);
  text-align: center;
}

.section__legend {
  font-family: var(--font-body);
  font-size: var(--fs-meta);
  color: var(--ink-medium);
  letter-spacing: 0.04em;
  text-align: center;
  margin: var(--s-3) auto 0;
  max-width: 36rem;
}
.section__legend strong {
  color: var(--brand-yellow);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.section__divider {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--s-3);
  margin-top: var(--s-3);
  color: var(--accent-red);
  font-size: 0;
  line-height: 0;
}

.section__divider::before,
.section__divider::after {
  content: "";
  flex: 0 0 clamp(40px, 12vw, 120px);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-red) 50%, transparent);
}

.section__divider > span {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-red);
  box-shadow:
    12px 0 0 var(--accent-red-soft),
    -12px 0 0 var(--accent-red-soft);
}

/* Item: hand-cut editorial row. NOT a card grid. */
.menu-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s-3) var(--s-5);
  align-items: start;
  padding: var(--s-5) 0;
  border-top: 1px solid var(--rule);
  position: relative;
}

.section > .menu-item:first-of-type { border-top: none; padding-top: var(--s-4); }

.menu-item__head {
  grid-column: 1 / -1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4);
  flex-wrap: wrap;
}

.menu-item__name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-h3);
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--brand-yellow);
  margin: 0;
  display: inline-flex;
  align-items: baseline;
  gap: var(--s-3);
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
  text-align: left;
  overflow-wrap: anywhere;
  transition: color var(--t-fast) var(--ease-out-quart);
}

.menu-item__name:hover,
.menu-item__name:focus-visible {
  color: var(--ink-strong);
  outline: none;
}

.menu-item__name:focus-visible {
  text-decoration: underline;
  text-decoration-color: var(--brand-yellow);
  text-underline-offset: 6px;
  text-decoration-thickness: 2px;
}

button.menu-item__name { transition: color var(--t-fast) var(--ease-out-quart), transform var(--t-fast) var(--ease-out-quart); }
button.menu-item__name:active { transform: scale(0.985); }

.menu-item__camera {
  font-size: 0.5em;
  color: var(--ink-faint);
  font-family: var(--font-body);
  letter-spacing: 0;
}

.menu-item__price {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-price);
  letter-spacing: 0.02em;
  color: var(--ink-strong);
  white-space: nowrap;
  line-height: 1;
}

.menu-item__price-label {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-meta);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--s-1);
  text-align: right;
}

.menu-item__body {
  grid-column: 1 / -1;
  display: grid;
  gap: var(--s-3);
}

.menu-item__desc {
  margin: 0;
  font-size: var(--fs-body);
  line-height: 1.55;
  color: var(--ink-medium);
  max-width: 65ch;
}

.menu-item__desc + .menu-item__desc {
  margin-top: calc(-1 * var(--s-1));
}

.menu-item__desc strong {
  color: var(--ink-strong);
  font-weight: 700;
}

.menu-item__desc .desc__hint {
  color: var(--ink-faint);
  font-style: italic;
  font-size: 0.92em;
}

.menu-item__meta {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-top: var(--s-2);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-family: var(--font-display);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--bg-deep);
  background: var(--brand-yellow);
  padding: 4px 10px;
  border-radius: var(--r-sm);
  line-height: 1;
}

.tag--red {
  background: var(--accent-red);
  color: var(--ink-strong);
}

/* Two-column lists (Bebidas / Cervezas / Extras) */
.cols {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-8);
}

@media (min-width: 720px) {
  .cols { grid-template-columns: 1fr 1fr; gap: var(--s-7); }
}

.cols__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-h2);
  letter-spacing: 0.03em;
  color: var(--brand-yellow);
  margin: 0 0 var(--s-5);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--rule-strong);
}

.row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-3) 0;
  border-bottom: 1px dotted var(--rule);
}

.row:last-child { border-bottom: 0; }

.row__name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-list);
  letter-spacing: 0.04em;
  color: var(--brand-yellow);
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
}

.row__dots {
  flex: 1 1 auto;
  border-bottom: 1px dotted var(--rule-strong);
  transform: translateY(-3px);
  margin: 0 var(--s-3);
  min-width: 1rem;
}

.row__price {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--fs-list);
  letter-spacing: 0.02em;
  color: var(--ink-strong);
  flex: 0 0 auto;
}

.row__hint {
  display: inline-block;
  margin-left: var(--s-2);
  font-family: var(--font-body);
  font-size: var(--fs-meta);
  font-weight: 400;
  letter-spacing: 0;
  color: var(--ink-faint);
  text-transform: lowercase;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  width: 100%;
  margin-top: var(--s-9);
  padding: var(--s-7) var(--s-4);
  border-top: 1px solid var(--rule);
  background: var(--bg-deep);
}

.site-footer__inner {
  width: var(--container);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  padding-bottom: env(safe-area-inset-bottom);
}

.site-footer__brand {
  display: flex;
  align-items: center;
  gap: var(--s-4);
}

.site-footer__brand img {
  width: 56px;
  height: 56px;
  object-fit: contain;
}

.site-footer__copy {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  letter-spacing: 0.05em;
  color: var(--brand-yellow);
  line-height: 1;
}

.site-footer__tag {
  font-size: var(--fs-meta);
  color: var(--ink-muted);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.site-footer__legal {
  width: var(--container);
  margin: 0 auto;
  padding: var(--s-4) var(--s-4) 0;
  text-align: center;
  font-size: var(--fs-meta);
  color: var(--ink-muted);
  border-top: 1px solid var(--rule);
}

.site-footer__legal a {
  color: var(--ink-strong);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color var(--t-fast) var(--ease-out-quart);
}
.site-footer__legal a:hover { border-bottom-color: var(--brand-yellow); }
.site-footer__legal a:focus-visible {
  outline: none;
  border-bottom-color: var(--brand-yellow);
}

.site-footer__legal a[href*="atedicion"] {
  color: oklch(0.19 0.012 60);
  border-bottom-color: transparent;
  transition: color var(--t-fast) var(--ease-out-quart),
              border-bottom-color var(--t-fast) var(--ease-out-quart);
}

.site-footer__legal a[href*="atedicion"]:hover,
.site-footer__legal a[href*="atedicion"]:focus-visible {
  color: oklch(0.35 0.015 60);
  border-bottom-color: var(--brand-yellow);
}

.site-footer__social {
  display: flex;
  gap: var(--s-3);
}

.icon-btn {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-pill);
  background: var(--bg-raised);
  border: 1px solid var(--rule-strong);
  transition: transform var(--t-fast) var(--ease-out-quart),
              background-color var(--t-fast) var(--ease-out-quart);
}

.icon-btn:hover,
.icon-btn:focus-visible {
  transform: translateY(-2px);
  background: var(--brand-yellow);
  outline: none;
}

.icon-btn svg, .icon-btn img { width: 22px; height: 22px; }

.icon-btn--whatsapp:hover { background: oklch(0.700 0.155 145); border-color: oklch(0.700 0.155 145); }
.icon-btn--instagram:hover { background: oklch(0.555 0.215 340); border-color: oklch(0.555 0.215 340); }



/* =========================================================
   MODAL
   ========================================================= */
.modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--s-4);
  background: oklch(0 0 0 / 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity var(--t-med) var(--ease-out-quart);
}

.modal.is-open {
  display: flex;
  opacity: 1;
  animation: modalIn var(--t-med) var(--ease-out-expo);
}

@keyframes modalIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal__figure {
  position: relative;
  max-width: min(720px, 95vw);
  max-height: 88vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  transform: scale(0.94) translateY(8px);
  transition: transform var(--t-med) var(--ease-out-expo);
}

.modal.is-open .modal__figure {
  transform: scale(1) translateY(0);
}

.modal__img {
  width: auto;
  height: auto;
  max-width: min(720px, 92vw);
  max-height: 76vh;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--r-md);
  border: 1px solid var(--rule-strong);
  box-shadow: 0 24px 60px oklch(0 0 0 / 0.6),
              0 0 0 1px var(--brand-yellow-soft),
              0 0 80px var(--brand-yellow-soft);
}

.modal__caption {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  letter-spacing: 0.04em;
  color: var(--brand-yellow);
  margin: 0;
  text-align: center;
}

.modal__close {
  position: absolute;
  top: var(--s-3);
  right: var(--s-3);
  z-index: 2;
  width: 48px;
  height: 48px;
  border-radius: var(--r-pill);
  border: 2px solid var(--brand-yellow);
  background: var(--bg-raised);
  color: var(--brand-yellow);
  font-size: 1.75rem;
  line-height: 1;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform var(--t-fast) var(--ease-out-quart),
              background-color var(--t-fast) var(--ease-out-quart),
              box-shadow var(--t-fast) var(--ease-out-quart);
}

.modal__close:hover { background: var(--brand-yellow); color: var(--bg-deep); }

.modal__close:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--brand-yellow-glow);
}

.modal__close:active { transform: scale(0.94); }

/* =========================================================
   Reduced motion
   ========================================================= */
@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;
  }
  .site-header__bg::before { display: none; }
}

/* =========================================================
   Reduced transparency — fallback for backdrop-filter
   on low-end devices that flag this preference.
   ========================================================= */
@media (prefers-reduced-transparency: reduce) {
  .cat-tile,
  .sticky-nav,
  .modal {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background: var(--bg-raised);
  }
  .modal { background: oklch(0 0 0 / 0.95); }
}

/* =========================================================
   Input method — differentiate touch vs mouse.
   On coarse-pointer devices, suppress hover transforms so
   taps don't leave stuck hover state. Add active feedback.
   ========================================================= */
@media (hover: none) and (pointer: coarse) {
  .cat-tile:hover,
  .cat-tile:focus-visible { transform: none; }
  .menu-item__name:hover { color: var(--brand-yellow); }
  .icon-btn:hover { transform: none; background: var(--bg-raised); }
  .icon-btn:active { transform: scale(0.94); background: var(--brand-yellow); }
}

@media (hover: hover) and (pointer: fine) {
  .cat-tile:focus-visible { transform: translateY(-2px); }
}

/* =========================================================
   Print — clean menu printout, single column, hide chrome.
   ========================================================= */
@media print {
  :root {
    --bg-deep: #fff;
    --bg-base: #fff;
    --bg-raised: #fff;
    --bg-veil: #fff;
    --ink-strong: #000;
    --ink-medium: #222;
    --ink-muted: #444;
    --ink-faint: #666;
    --brand-yellow: #000;
    --accent-red: #000;
    --rule: #ddd;
    --rule-strong: #bbb;
  }
  body { background: #fff; color: #000; }
  .site-header { min-height: auto; padding: 1rem 0; border-bottom: 2px solid #000; }
  .site-header__bg, .site-header__bg::before, .site-header__bg::after { display: none !important; }
  .sticky-nav, .cat-tiles, .menu-note, .section__legend, .menu-item__camera,
  .site-footer__social, .modal { display: none !important; }
  .site-footer { background: #fff; color: #000; border-top: 1px solid #000; }
  .menu { padding: 0; }
  .section { margin-block: 1.5rem; page-break-inside: avoid; }
  .section__head { margin-bottom: 0.5rem; }
  .section__title { color: #000; }
  .menu-item { padding: 0.4rem 0; border-top: 1px dotted #888; page-break-inside: avoid; }
  .menu-item__name { color: #000; }
  .menu-item__price { color: #000; }
  .menu-item__desc { color: #222; max-width: none; }
  button.menu-item__name { color: #000; text-decoration: none; }
  a { color: #000; text-decoration: underline; }
  @page { margin: 1.5cm; }
}

/* =========================================================
   Mobile fine-tuning
   ========================================================= */
@media (max-width: 540px) {
  .menu-item__head { gap: var(--s-2); }
  .menu-item__price { font-size: clamp(1.5rem, 5vw, 2rem); }
  .hero__sub { display: none; }
  .cat-tile { font-size: var(--fs-h3); min-height: 56px; padding: var(--s-3); }
  .section__head { gap: var(--s-2); }
  .section__title { letter-spacing: 0.02em; }
  .menu-item { padding: var(--s-4) 0; }
  /* Compactar el footer en una columna para que el tag + legal + marca
     no se acumulen horizontalmente. */
  .site-footer__inner {
    flex-direction: column;
    text-align: center;
    gap: var(--s-4);
  }
  .site-footer__brand { justify-content: center; }
}

@media (max-width: 380px) {
  .container, .sticky-nav__inner, .cat-tiles, .menu, .site-footer__inner {
    padding-inline: var(--s-3);
  }
  .hero__title em { letter-spacing: 0.04em; }
  .section__eyebrow { letter-spacing: 0.35em; }
  /* Force horizontal scroll nav to scroll snap for narrow screens */
  .sticky-nav__link { padding: var(--s-2) var(--s-3); }
}

/* Landscape mobile — modal and sticky-nav adjustments */
@media (max-height: 480px) and (orientation: landscape) {
  .modal__img { max-height: 70vh; }
  .site-header { min-height: 70vh; }
  .sticky-nav__link { padding: var(--s-1) var(--s-3); }
}
