/* ---- BASE ---- */

body {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  background: url('../assets/fondo.jpg') center center / cover fixed no-repeat;
  color: #2b2b2b;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  box-sizing: border-box;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.15);
  pointer-events: none;
  z-index: 0;
}

body > * {
  position: relative;
  z-index: 1;
}

/* ---- CONTENEDOR CARTA ---- */

main {
  max-width: 500px;
  margin: 50px auto;
  padding: 50px;
  border-radius: 18px;
  position: relative;
}

/* ---- TITULO ---- */

h1 {
  text-align: center;
  font-family: 'Playfair Display', serif;
  font-size: 36px;
  letter-spacing: 3px;
  margin-top: 10px;
  margin-bottom: 20px;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,0.4);
  text-transform: uppercase;
}

/* ---- BOTON VOLVER ---- */

.back-btn {
  display: inline-block;
  margin: 25px;
  color: white;
  text-decoration: none;
  font-weight: 600;
}

/* ---- ITEM MENU ---- */

.menu-card {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
  padding-bottom: 6px;
  padding-left: 8px;
  padding-right: 8px;
  padding-top: 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 3px 12px rgba(0,0,0,0.07);
  position: relative;
  transition: box-shadow 0.2s ease;
  width: 100%;
  box-sizing: border-box;
}

.menu-card:hover {
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

.menu-info {
  flex: 1;
  min-width: 0;
}

.menu-info h3 {
  margin: 0 0 5px 0;
  font-size: 18px;
  font-weight: 600;
  color: black;
  text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.precio {
  font-weight: 700;
  font-size: 17px;
  color: black;
  margin-top: 10px;
}

.descripcion {
  margin: 4px 0 0 0;
  font-size: 9pt;
  color: black;
  line-height: 1.0;
}

/* ---- IMAGEN ---- */

.menu-image {
  flex-shrink: 0;
  width: 90px;
  height: 90px;
}

.menu-image img {
  width: 90px;
  height: 90px;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  cursor: zoom-in;
}

/* Placeholder cuando no hay imagen */
.menu-image-placeholder {
  flex-shrink: 0;
  width: 110px;
  height: 110px;
  border-radius: 10px;
  background: rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
}

/* ---- BADGE RECOMENDADO ---- */

.badge.recomendado {
  display: inline-block;
  background: #ac2a21;
  color: white;
  font-size: 10px;
  padding: 3px 9px;
  border-radius: 20px;
  margin-bottom: 6px;
  letter-spacing: 1px;
  font-weight: 600;
}

/* ---- AGOTADO ---- */

.menu-card.agotado {
  opacity: 0.5;
}

.menu-card.agotado::after {
  content: "AGOTADO";
  position: absolute;
  right: 0;
  top: 0;
  background: #073b4c;
  color: white;
  font-size: 9px;
  padding: 5px 9px;
  letter-spacing: 2px;
  border-radius: 0 14px 0 10px;
}

/* ---- ANCHO UNIFORME ITEMS ---- */

#menu-container {
  display: flex;
  flex-direction: column;
  width: 100%;
}

#menu-container .menu-card:first-child {
  margin-top: 0;
}

/* ---- HEADER LOGO + IDIOMA ---- */

.menu-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 40px;
}

.logo {
  max-width: 250px;
  width: 100%;
  height: auto;
}

/* ---- TARJETAS DE CATEGORIAS (index) ---- */

.categories-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  width: 100%;
  max-width: 900px;
  padding-bottom: env(safe-area-inset-bottom, 80px);
}

.category-card {
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 14px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
  text-align: center;
  padding: 15px 12px;
  flex: 1 1 120px;
  width: auto;
  text-decoration: none;
  min-height: 100px;
  color: #fff;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.3);
}

.category-card img {
  max-width: 100%;
  height: auto;
}

.category-card h2 {
  font-family: 'Playfair Display', serif;
  font-size: 14px;
  margin: 6px 0 3px 0;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.category-card p {
  font-size: 11px;
  color: rgba(255,255,255,0.9);
  margin: 0;
}

/* ---- LIGHTBOX ---- */

.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
  backdrop-filter: blur(6px);
  animation: fadeIn 0.2s ease;
}

.lightbox-overlay.active {
  display: flex;
}

.lightbox-overlay img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 16px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.6);
  object-fit: contain;
  animation: zoomIn 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: default;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 25px;
  color: white;
  font-size: 36px;
  font-weight: 300;
  cursor: pointer;
  line-height: 1;
  opacity: 0.8;
  transition: opacity 0.2s;
  user-select: none;
}

.lightbox-close:hover {
  opacity: 1;
}

.lightbox-caption {
  position: absolute;
  bottom: 30px;
  left: 0;
  right: 0;
  text-align: center;
  color: white;
  font-family: 'Montserrat', sans-serif;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 1px;
  opacity: 0.85;
}

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

@keyframes zoomIn {
  from { transform: scale(0.85); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}

/* ---- SELECTOR DE IDIOMA ---- */

.lang-selector {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 15px;
}

.lang-selector--cat {
  display: inline-flex;
  margin: 0 25px 0 auto;
  vertical-align: middle;
}

header {
  display: flex;
  align-items: center;
}

.lang-btn {
  background: rgba(255,255,255,0.15);
  border: 2px solid rgba(255,255,255,0.4);
  color: white;
  font-family: 'Montserrat', sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 30px;
  cursor: pointer;
  letter-spacing: 1px;
  transition: all 0.25s ease;
}

.lang-btn:hover {
  background: rgba(255,255,255,0.3);
  border-color: white;
  transform: translateY(-2px);
}

.lang-btn.active {
  background: white;
  color: #0f4c5c;
  border-color: white;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.lang-btn img {
  width: 22px;
  height: 15px;
  object-fit: cover;
  border-radius: 3px;
  vertical-align: middle;
  margin-right: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* ---- RESPONSIVE ---- */

@media (max-width: 768px) {
  main {
    margin: 0;
    border-radius: 0;
    padding: 20px;
  }

  h1 {
    font-size: 26px;
  }

  .menu-card {
    gap: 14px;
  }

  .menu-image,
  .menu-image img {
    width: 85px;
    height: 85px;
  }

  .menu-image-placeholder {
    width: 85px;
    height: 85px;
    font-size: 24px;
  }

  .category-card {
    flex: 1 1 80px;
    max-width: 30%;
    min-width: 80px;
  }
}

/* ---- NAV CATEGORIAS (header de categoria.html) ---- */

.cat-nav {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 5px;
  margin-top: 12px;
  width: 100%;
  max-width: 600px;
}

/* Todas parten con z-index bajo y position relative para que z-index funcione */
.cat-nav .category-card {
  flex: 1 1 80px;
  max-width: 130px;
  opacity: 0.75;
  min-height: 0;
  position: relative;
  z-index: 1;
}

/* La activa sube por encima de sus vecinas */
.cat-nav .category-card:hover,
.cat-nav .category-card.cat-active {
  opacity: 1;
  box-shadow: 0 0 0 3px #ac2a21, 0 6px 20px rgba(0,0,0,0.3);
  transform: scale(1.18) translateY(-2px);
  z-index: 10;
}

.texto-cat {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 4px auto 0;
}

/* ---- HEADER FIJO (categoria.html) ---- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  padding: 10px 16px 8px;
  pointer-events: none;
  box-sizing: border-box;
}

.site-header.menu-header {
  gap: 0;
  margin-bottom: 0;
  pointer-events: none;
}

.site-header .header-inner {
  pointer-events: all;
  background: transparent;
  border-radius: 20px;
  box-shadow: none;
  padding: 10px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 100%;
  max-width: 608px;
  box-sizing: border-box;
  margin: 0 auto;
}

.site-header .logo          { max-width: 150px; margin-bottom: 0; }
.site-header .back-btn      { color: black; margin: 0; font-size: 13px; }
.site-header .lang-selector { margin-top: 0; gap: 5px; }
.site-header .lang-btn      { font-size: 13px; padding: 4px 10px; }
.site-header .lang-btn img  { width: 12px; height: 8px; }

.site-header .cat-nav {
  margin-top: 10px;
  gap: 5px;
  flex-wrap: nowrap;
  width: 100%;
}

.site-header .category-card {
  padding: 5px 4px;
  border-radius: 10px;
  flex: 1 1 0;
  min-width: 0;
  min-height: 0;
  background: rgba(255,255,255,0.85);
  border-color: rgba(255,255,255,0.5);
  box-sizing: border-box;
}

.site-header .category-card img:first-child {
  height: 22px;
  width: auto;
}

.site-header .texto-cat {
  max-height: 40px;
  width: auto;
}

/* ---- MAIN CON HEADER FIJO ---- */

.main-with-header {
  position: fixed;
  top: var(--header-h, 215px);
  bottom: 0;
  left: 0;
  right: 0;
  overflow-y: auto;
  padding: 5px 20px max(40px, env(safe-area-inset-bottom, 80px));
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.main-with-header::-webkit-scrollbar {
  display: none;
}

@media (max-width: 768px) {
  .main-with-header {
    top: var(--header-h, 270px);
    padding-bottom: max(80px, env(safe-area-inset-bottom, 100px));
  }

  .site-header .logo {
    max-width: 120px;
  }

  .site-header .header-inner {
    width: 95vw;
  }
}

/* ---- SOCIAL LINKS ---- */

.social-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  padding: 16px 0 8px;
  width: 100%;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-links img {
  height: 72px;
  width: auto;
  opacity: 0.85;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.social-links img:hover {
  transform: scale(1.15);
  opacity: 1;
}

/* Dirección */
.direccion {
  color: white;
  font-size: 9pt;
  font-family: 'Montserrat', sans-serif;
  text-align: center;
  padding: 0 20px 20px;
  margin: 0;
  opacity: 0.85;
}

/* En móvil el index necesita scroll */
@media (max-width: 768px) {
  body {
    overflow-y: auto;
    height: auto;
    min-height: 100vh;
  }
}
/* ================================================================
   BEBIDAS — ÍNDICE DE SUBCATEGORÍAS
   ================================================================ */

.bebidas-index {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  width: 100%;
  max-width: 600px;
  margin: 0 auto 30px;
  padding: 12px 8px;
  background: rgba(255,255,255,0.15);
  border-radius: 16px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.25);
  box-sizing: border-box;
  overflow: hidden;
}

.bebidas-index-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  padding: 6px 8px;
  border-radius: 10px;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(255,255,255,0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  min-width: 64px;
}

.bebidas-index-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
}

.bebidas-index-item img {
  max-width: 70px;
  max-height: 40px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.bebidas-index-item span {
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 600;
  color: #0f4c5c;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: center;
}


.bebidas-seccion {
  width: 100%;
  max-width: 600px;
  margin-bottom: 30px;
}

.bebidas-seccion-header {
  display: block;
  width: 55%;
  max-width: 280px;
  height: auto;
  margin: 0 auto 14px;
  object-fit: contain;
}

.bebidas-seccion-titulo {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  color: #fff;
  text-align: center;
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.bebidas-seccion-cards {
  display: flex;
  flex-direction: column;
  width: 100%;
  gap: 0;
}

.bebidas-seccion {
  scroll-margin-top: 20px;
}

@media (max-width: 768px) {
  .bebidas-index-item img {
    max-width: 56px;
    max-height: 34px;
  }

  .bebidas-seccion-header {
    width: 65%;
  }
}