/* ==========================================================================
   MALA HIERBA BEER — DISEÑO 3 v2: «EL TAPIZADO»
   Afiche psicodélico sobre un bosque de enredaderas. Las dos puertas son dos
   etiquetas de botella (holográfica y negro-oro). Cero dependencias, fuentes locales.
   ========================================================================== */

/* ---- Fuentes locales ---- */
@font-face {
  font-family: "Fraunces";
  src: url("assets/fonts/fraunces-latin.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/ibm-plex-mono-latin.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Sans";
  src: url("assets/fonts/instrument-sans-latin.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

/* ---- Tokens ---- */
:root {
  --selva: #0c3320;
  --selva-honda: #06180f;
  --chala: #1b8a4b;
  --chala-oscuro: #0f5a2e;
  --calavera: #f2b418;
  --oro: #e7b53a;
  --hueso: #f6ebd2;
  --hueso-sombra: #e6d6ae;
  --tinta: #1a1208;
  --wa: #25d366;
  --atenuado: #cfdcc8;
  --atenuado-tinta: #5a4a2c;

  --ok: #34d058;
  --poco: #ffc400;
  --agotado: #8a8f8b;

  --fuente-display: "Fraunces", "Cooper Black", Georgia, serif;
  --fuente-texto: "Instrument Sans", system-ui, sans-serif;
  --fuente-datos: "IBM Plex Mono", ui-monospace, monospace;

  --radio: 0.4rem;
  --sombra-sticker: 0.3rem 0.4rem 0 var(--selva-honda);
  --alto-aviso: 1.9rem;
}

/* ---- Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

[hidden] { display: none !important; }

html {
  height: 100%;
  font-size: clamp(16px, 0.35vw + 10px, 28px);
  -webkit-text-size-adjust: 100%;
}

/* Pantallas de TV / 4K: el texto escala con el ancho para leerse desde lejos */
@media (min-width: 2200px) {
  html { font-size: 1.18vw; }
}

body {
  height: 100%;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--selva);
  color: var(--hueso);
  font-family: var(--fuente-texto);
  font-size: 1rem;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

/* Tapizado: imagen del Chino + capa de selva para sostener el contraste */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background: var(--selva) url("assets/bosque-m.webp") center / cover no-repeat;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: radial-gradient(ellipse 70% 60% at 50% 45%, rgba(6, 24, 15, 0.8), rgba(6, 24, 15, 0.56) 60%, rgba(6, 24, 15, 0.4));
  pointer-events: none;
}

@media (min-width: 860px) and (orientation: landscape) {
  body::before { background-image: url("assets/bosque-d.webp"); }
}

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

button, a { font: inherit; color: inherit; }
button { cursor: pointer; }

.solo-lectura {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Aviso de prototipo obligatorio (D-023) */
.aviso-prototipo {
  flex: none;
  background: var(--calavera);
  color: var(--tinta);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  padding: 0.3rem 0.75rem;
}

/* ---- Wordmark (el logo del Chino, recoloreable) ---- */
.wordmark {
  display: block;
  background: currentColor;
  -webkit-mask: center / contain no-repeat;
  mask: center / contain no-repeat;
}

.wordmark-linea {
  height: 1.35rem;
  aspect-ratio: 1400 / 162;
  color: var(--hueso);
  -webkit-mask-image: url("assets/wordmark-linea.webp");
  mask-image: url("assets/wordmark-linea.webp");
}

/* Título de la portada: el logotipo del Chino en una línea, debajo de la calavera */
.wordmark-titulo {
  width: 100%;
  aspect-ratio: 1400 / 162;
  margin-inline: auto;
  color: var(--calavera);
  -webkit-mask-image: url("assets/wordmark-linea.webp");
  mask-image: url("assets/wordmark-linea.webp");
  filter: drop-shadow(0.12rem 0.16rem 0 var(--selva-honda));
}

/* En el inicio el logotipo ya es el título: la barra no lo repite */
.marco-aplicacion[data-vista="home"] .barra-superior .wordmark { display: none; }

/* ---- Marco ---- */
.marco-aplicacion {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 90rem;
  margin: 0 auto;
}

/* ---- Barra superior ---- */
.barra-superior {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem clamp(0.75rem, 2.5vw, 2rem);
}

.marca-chica { display: flex; align-items: center; gap: 0.75rem; min-width: 0; }

.chip-vidrio {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--tinta);
  background: var(--hueso);
  border-radius: 99px;
  padding: 0.2rem 0.65rem;
  white-space: nowrap;
}

.acciones-cabecera { display: flex; align-items: center; gap: 0.6rem; }

.badge-edad {
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  border-radius: 50%;
  background: transparent;
  padding: 0.2rem;
}

.sello {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 50%;
  background: var(--hueso);
}

.btn-carrito-badge {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.75rem;
  padding: 0 0.9rem;
  border: 2px solid var(--tinta);
  border-radius: 99px;
  background: var(--calavera);
  color: var(--tinta);
  font-weight: 600;
  box-shadow: 0.15rem 0.2rem 0 var(--selva-honda);
  transition: transform 0.15s ease;
}

.btn-carrito-badge:hover { transform: translate(-1px, -1px); }

.icono-bolsa { width: 1.1rem; height: 1.1rem; }

.contador-badge {
  display: grid;
  place-items: center;
  min-width: 1.5rem;
  height: 1.5rem;
  border-radius: 99px;
  background: var(--tinta);
  color: var(--hueso);
  font-family: var(--fuente-datos);
  font-size: 0.875rem;
  font-weight: 600;
}

.pulso-icono { animation: rebote 0.4s ease; }

@keyframes rebote {
  30% { transform: scale(1.12) rotate(-3deg); }
  60% { transform: scale(0.96) rotate(2deg); }
}

/* ---- Vistas ---- */
.vista-seccion {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 0.5rem clamp(0.75rem, 2.5vw, 2rem) clamp(0.75rem, 2vw, 1.5rem);
  overflow-x: hidden;
  overflow-y: auto;
}

.vista-oculta { display: none !important; }
.vista-activa { display: flex; }

/* ==========================================================================
   INICIO
   ========================================================================== */
.home-grilla {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) auto;
  grid-template-areas:
    "tradicionales hero guarda"
    "novedad novedad sellos";
  column-gap: clamp(1rem, 3vw, 3rem);
  row-gap: 0.9rem;
  align-items: stretch;
}

#btn-ir-tradicionales { grid-area: tradicionales; }
#btn-ir-guarda { grid-area: guarda; }
.hero-centro { grid-area: hero; }
.novedad { grid-area: novedad; }
.sellos { grid-area: sellos; }

.hero-centro {
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  text-align: center;
}

.calavera-envoltorio {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  max-height: 30rem;
  width: 100%;
  display: flex;
  justify-content: center;
}

/* Halo amarillo: separa la calavera verde del tapizado verde */
.calavera-envoltorio::before {
  content: "";
  position: absolute;
  inset: -12% -22%;
  background: radial-gradient(closest-side, rgba(242, 180, 24, 0.5), rgba(242, 180, 24, 0.14) 60%, transparent 78%);
}

.calavera-img {
  position: relative;
  height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0.5rem 0.9rem rgba(6, 24, 15, 0.6));
}

.marca-titulo { width: min(100%, 36rem); line-height: 0; }

.marca-bajada {
  font-family: var(--fuente-display);
  font-size: clamp(1.15rem, 1.6vw + 0.5rem, 1.9rem);
  font-weight: 600;
  line-height: 1.15;
  max-width: 22ch;
  text-wrap: balance;
}

.marca-origen { font-size: 0.9rem; color: var(--atenuado); }

/* Puertas: dos etiquetas de botella */
.etiqueta-puerta {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 0;
  border: 0;
  border-radius: var(--radio);
  padding: clamp(1rem, 2.4vw, 2rem);
  text-align: left;
  color: var(--hueso);
  overflow: hidden;
  box-shadow: var(--sombra-sticker);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#btn-ir-tradicionales { rotate: -1.4deg; }
#btn-ir-guarda { rotate: 1.2deg; }

.etiqueta-puerta:hover {
  rotate: 0deg;
  transform: translateY(-0.25rem);
  box-shadow: 0.4rem 0.7rem 0 var(--selva-honda);
}

.etiqueta-puerta[data-linea="tradicionales"] {
  background:
    linear-gradient(to top, rgba(6, 24, 15, 0.92) 0%, rgba(6, 24, 15, 0.78) 38%, rgba(6, 24, 15, 0.38) 62%, transparent 82%),
    url("assets/holo.webp") center / cover;
}

.etiqueta-puerta[data-linea="guarda"] {
  background:
    linear-gradient(to top, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.7) 40%, transparent 72%),
    url("assets/oro-sup.webp") top right / 75% auto no-repeat,
    url("assets/oro-inf.webp") bottom left / 65% auto no-repeat,
    #000;
  color: var(--hueso);
}

.puerta-texto { position: relative; display: grid; gap: 0.5rem; max-width: 26ch; }

.puerta-titulo {
  font-family: var(--fuente-display);
  font-size: clamp(1.6rem, 2.4vw + 0.6rem, 3rem);
  font-weight: 700;
  line-height: 1.02;
  text-wrap: balance;
}

[data-linea="guarda"] .puerta-titulo { color: var(--oro); }

.puerta-desc { font-size: 1rem; line-height: 1.3; }

.puerta-accion {
  justify-self: start;
  margin-top: 0.3rem;
  padding: 0.55rem 1rem;
  border: 2px solid var(--tinta);
  border-radius: 99px;
  background: var(--calavera);
  color: var(--tinta);
  font-weight: 600;
}

.novedad {
  justify-self: start;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 2.75rem;
  padding: 0.3rem 1.1rem 0.3rem 0.35rem;
  border-radius: 99px;
  background: var(--hueso);
  color: var(--tinta);
  text-decoration: none;
  font-weight: 600;
  box-shadow: 0.15rem 0.2rem 0 var(--selva-honda);
}

.novedad:hover { background: #fff6dc; }

.novedad-marca {
  padding: 0.35rem 0.85rem;
  border-radius: 99px;
  background: var(--chala-oscuro);
  color: var(--hueso);
  font-family: var(--fuente-display);
  font-weight: 700;
}

.sellos {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  list-style: none;
}

.sellos li { width: 2.75rem; }

/* ==========================================================================
   PANTALLAS DE LÍNEA
   ========================================================================== */
.cabecera-seccion {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.6rem;
}

.btn-volver {
  min-height: 2.75rem;
  padding: 0 1rem;
  border: 2px solid var(--hueso);
  border-radius: 99px;
  background: rgba(6, 24, 15, 0.55);
  color: var(--hueso);
  font-weight: 600;
}

.btn-volver:hover { background: var(--hueso); color: var(--tinta); }

.nombre-seccion {
  font-family: var(--fuente-display);
  font-size: clamp(1.4rem, 2vw + 0.6rem, 2.4rem);
  font-weight: 700;
  line-height: 1.05;
  text-align: right;
}

.nombre-seccion:focus { outline: none; }

.selector-birras {
  flex: none;
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.2rem 0.3rem 0.8rem 0;
  scroll-snap-type: x proximity;
}

.chip-birra {
  flex: none;
  min-height: 2.75rem;
  padding: 0 1rem;
  border: 2px solid var(--hueso);
  border-radius: 99px;
  background: rgba(6, 24, 15, 0.55);
  color: var(--hueso);
  font-weight: 600;
  white-space: nowrap;
  scroll-snap-align: start;
}

.chip-birra[aria-pressed="true"] {
  background: var(--calavera);
  border-color: var(--tinta);
  color: var(--tinta);
}

.chip-birra[data-estado="proximamente"]::after { content: " · pronto"; }

.tarjeta-producto-central {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.3fr);
  gap: clamp(1rem, 3vw, 2.5rem);
  align-items: stretch;
}

/* Etiqueta-afiche */
.afiche {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 0;
  padding: clamp(0.9rem, 2vw, 1.6rem);
  border-radius: var(--radio);
  overflow: hidden;
  box-shadow: var(--sombra-sticker);
  rotate: -0.8deg;
}

.afiche[data-mundo="holo"] {
  background: url("assets/holo.webp") center / cover;
  --plano: rgba(246, 235, 210, 0.94);
  --plano-texto: var(--tinta);
  --barra-fondo: rgba(26, 18, 8, 0.16);
  --barra-relleno: var(--chala-oscuro);
}

.afiche[data-mundo="oro"] {
  background:
    url("assets/oro-sup.webp") top right / 80% auto no-repeat,
    url("assets/oro-inf.webp") bottom left / 70% auto no-repeat,
    #000;
  --plano: #000;
  --plano-texto: var(--oro);
  --barra-fondo: rgba(231, 181, 58, 0.25);
  --barra-relleno: var(--oro);
}

.afiche-calavera {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  width: auto;
  max-width: 78%;
  object-fit: contain;
  filter: drop-shadow(0 0.4rem 0.7rem rgba(6, 24, 15, 0.55));
}

.afiche-botella {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  width: auto;
  max-width: 82%;
  object-fit: contain;
  filter: drop-shadow(0 0.6rem 1.2rem rgba(0, 0, 0, 0.6));
  border-radius: var(--radio-sm, 8px);
}

.barril-svg {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
  width: min(100%, 15rem);
  filter: drop-shadow(0 0.4rem 0.7rem rgba(0, 0, 0, 0.7));
}

.pincelada {
  position: relative;
  align-self: stretch;
  padding: 0.5rem 1rem;
  background: linear-gradient(100deg, #b8862a, var(--oro) 40%, #f5d27a 60%, #b8862a);
  color: var(--tinta);
  font-family: var(--fuente-display);
  font-weight: 700;
  text-align: center;
  clip-path: polygon(0 12%, 4% 0, 96% 8%, 100% 0, 98% 88%, 100% 100%, 3% 92%, 0 100%);
}

.medidores {
  position: relative;
  align-self: stretch;
  display: grid;
  gap: 0.5rem;
  padding: 0.75rem 0.9rem;
  border-radius: 0.3rem;
  background: var(--plano);
  color: var(--plano-texto);
}

.medidor-fila { display: grid; grid-template-columns: 2.6rem 1fr; align-items: center; gap: 0.5rem; }

.medidor-fila dt { font-family: var(--fuente-datos); font-size: 0.85rem; font-weight: 600; }

.medidor-fila dd { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 0.6rem; }

.barra {
  display: block;
  height: 0.7rem;
  border-radius: 99px;
  background: var(--barra-fondo);
  overflow: hidden;
}

.barra-relleno {
  display: block;
  height: 100%;
  width: calc(var(--v, 0) * 100%);
  border-radius: 99px;
  background: var(--barra-relleno);
  transition: width 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.medidor-valor {
  min-width: 3.2rem;
  text-align: right;
  font-family: var(--fuente-datos);
  font-size: 0.95rem;
  font-weight: 600;
}

.nota-estimado {
  position: relative;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.15rem 0.6rem;
  border-radius: 99px;
  background: var(--calavera);
  color: var(--tinta);
}

/* Aclaración de que la foto es una ilustración (las botellas reales todavía no se fotografiaron) */
.nota-imagen { font-size: 0.8125rem; font-weight: 500; background: rgba(6, 24, 15, 0.78); color: var(--hueso); justify-self: center; }

/* Panel de compra: papel de etiqueta */
.info-producto {
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.6rem;
  padding: clamp(1rem, 2.4vw, 2rem);
  border-radius: var(--radio);
  background: var(--hueso);
  color: var(--tinta);
  box-shadow: var(--sombra-sticker);
  overflow-y: auto;
  rotate: 0.4deg;
}

.cambiador-estilo { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }

.btn-flecha {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  border: 2px solid var(--tinta);
  border-radius: 50%;
  background: var(--hueso-sombra);
  color: var(--tinta);
  font-size: 1.5rem;
  line-height: 1;
  transition: background 0.15s ease;
}

.btn-flecha:hover { background: var(--calavera); }

.producto-nombre {
  flex: 1;
  font-family: var(--fuente-display);
  font-size: clamp(1.6rem, 2.2vw + 0.6rem, 2.8rem);
  font-weight: 700;
  line-height: 1.02;
  text-align: center;
  text-wrap: balance;
}

.producto-envase { font-weight: 600; text-align: center; color: var(--chala-oscuro); }

.producto-desc { max-width: 52ch; margin-inline: auto; text-align: center; font-size: 1.05rem; line-height: 1.4; }

.estado-stock {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
}

.luz { width: 0.85rem; height: 0.85rem; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 2px var(--tinta); }

.estado-stock[data-estado="pocas"] .luz { background: var(--poco); animation: parpadeo 1.1s ease-in-out infinite; }
.estado-stock[data-estado="agotado"] .luz { background: var(--agotado); }
.estado-stock[data-estado="proximamente"] .luz { background: var(--chala); }

@keyframes parpadeo { 50% { opacity: 0.2; } }

.selector-formato-grupo { display: grid; gap: 0.4rem; }

.selector-titulo { font-size: 0.9rem; font-weight: 600; color: var(--atenuado-tinta); }

.grilla-formatos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }

.btn-formato {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.1rem;
  min-height: 3.6rem;
  padding: 0.4rem 0.3rem;
  border: 2px solid rgba(26, 18, 8, 0.35);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--tinta);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btn-formato:hover { border-color: var(--tinta); }

.btn-formato.formato-activo { border-color: var(--tinta); background: var(--calavera); }

.fmt-nombre { font-size: 0.95rem; font-weight: 600; }
.fmt-precio { font-family: var(--fuente-datos); font-size: 1rem; font-weight: 600; }
.fmt-ahorro { font-size: 0.875rem; font-weight: 600; color: var(--chala-oscuro); }
.fmt-ahorro:empty { display: none; }
.formato-activo .fmt-ahorro { color: var(--tinta); }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 3.2rem;
  padding: 0.6rem 1.1rem;
  border: 2px solid var(--tinta);
  border-radius: 0.6rem;
  font-family: var(--fuente-display);
  font-size: 1.1rem;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.btn-accion-compra {
  width: 100%;
  justify-content: space-between;
  background: var(--calavera);
  color: var(--tinta);
  box-shadow: 0.25rem 0.3rem 0 var(--tinta);
}

.btn-accion-compra:hover, .btn-principal:hover, .btn-checkout-wa:hover, .btn-avisar:hover { transform: translate(-1px, -1px); }

.btn-accion-compra:active, .btn-principal:active, .btn-checkout-wa:active, .btn-avisar:active {
  transform: translate(0.15rem, 0.2rem);
  box-shadow: 0.05rem 0.08rem 0 var(--tinta);
}

.btn-precio-actual { font-family: var(--fuente-datos); font-size: 1.1rem; }

.btn-avisar {
  background: var(--wa);
  color: var(--tinta);
  box-shadow: 0.25rem 0.3rem 0 var(--tinta);
}

.precio-a-definir { text-align: center; font-weight: 600; color: var(--atenuado-tinta); }

/* ==========================================================================
   PEDIDO (ticket)
   ========================================================================== */
.drawer-lateral {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  justify-content: flex-end;
  visibility: hidden;
  transition: visibility 0.3s ease;
}

.drawer-activo { visibility: visible; }

.drawer-overlay {
  position: absolute;
  inset: 0;
  background: rgba(6, 24, 15, 0.75);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.drawer-activo .drawer-overlay { opacity: 1; }

.drawer-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 25rem;
  height: 100%;
  padding: 1.25rem;
  background: var(--hueso);
  color: var(--tinta);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.drawer-activo .drawer-panel { transform: translateX(0); }

.drawer-cabecera {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.75rem;
  border-bottom: 2px dashed rgba(26, 18, 8, 0.4);
}

.drawer-titulo { font-family: var(--fuente-display); font-size: 1.7rem; font-weight: 700; }

.btn-cerrar-drawer {
  width: 2.75rem;
  height: 2.75rem;
  border: 2px solid var(--tinta);
  border-radius: 50%;
  background: transparent;
  font-size: 1.6rem;
  line-height: 1;
}

.btn-cerrar-drawer:hover { background: var(--calavera); }

.drawer-lista-items { flex: 1; overflow-y: auto; padding: 0.75rem 0; display: flex; flex-direction: column; gap: 0.25rem; }

.carrito-vacio { margin-top: 2rem; text-align: center; color: var(--atenuado-tinta); }

.item-carrito-fila {
  display: grid;
  gap: 0.5rem;
  padding: 0.75rem 0;
  border-bottom: 1px dashed rgba(26, 18, 8, 0.35);
}

.item-carrito-nombre { font-family: var(--fuente-display); font-size: 1.15rem; font-weight: 700; line-height: 1.1; }

.item-carrito-formato { font-family: var(--fuente-datos); font-size: 0.85rem; color: var(--atenuado-tinta); }

.item-carrito-controles { display: flex; align-items: center; gap: 0.5rem; }

.btn-cant {
  width: 2.75rem;
  height: 2.75rem;
  border: 2px solid var(--tinta);
  border-radius: 0.5rem;
  background: transparent;
  font-family: var(--fuente-datos);
  font-size: 1.2rem;
  font-weight: 600;
}

.btn-cant:hover { background: var(--calavera); }

.item-cant-numero { min-width: 2rem; text-align: center; font-family: var(--fuente-datos); font-size: 1.1rem; font-weight: 600; }

.item-subtotal { margin-left: auto; font-family: var(--fuente-datos); font-weight: 600; }

.btn-item-eliminar {
  min-height: 2.75rem;
  padding: 0 0.6rem;
  border: 0;
  background: transparent;
  text-decoration: underline;
  color: var(--atenuado-tinta);
}

.drawer-pie { padding-top: 0.75rem; border-top: 2px dashed rgba(26, 18, 8, 0.4); }

.drawer-nota { font-size: 0.875rem; color: var(--atenuado-tinta); }

.drawer-total-fila { display: flex; align-items: baseline; justify-content: space-between; margin: 0.4rem 0 0.75rem; }

.etiqueta-total { font-weight: 600; }

.monto-total { font-family: var(--fuente-datos); font-size: 1.7rem; font-weight: 600; }

.aviso-inline { margin-bottom: 0.6rem; padding: 0.5rem 0.75rem; border-radius: 0.4rem; background: var(--calavera); font-weight: 600; }

.btn-checkout-wa {
  width: 100%;
  background: var(--wa);
  color: var(--tinta);
  box-shadow: 0.25rem 0.3rem 0 var(--tinta);
}

.btn-vaciar {
  width: 100%;
  min-height: 2.75rem;
  margin-top: 0.4rem;
  border: 0;
  background: transparent;
  text-decoration: underline;
  color: var(--atenuado-tinta);
}

/* ==========================================================================
   CARTEL +18
   ========================================================================== */
.modal-edad {
  position: fixed;
  inset: 0;
  margin: auto;
  width: min(92vw, 26rem);
  padding: 1.5rem;
  border: 3px solid var(--tinta);
  border-radius: var(--radio);
  background: var(--hueso);
  color: var(--tinta);
  box-shadow: 0.4rem 0.5rem 0 var(--selva-honda);
}

.modal-edad::backdrop { background: rgba(6, 24, 15, 0.82); }

.modal-contenido { display: grid; justify-items: center; gap: 0.75rem; text-align: center; }

.sello-grande { width: 6rem; }

.modal-titulo { font-family: var(--fuente-display); font-size: 1.9rem; font-weight: 700; line-height: 1.05; }

.modal-bajada { max-width: 30ch; }

.modal-acciones { display: grid; gap: 0.6rem; width: 100%; }

.btn-principal { background: var(--calavera); color: var(--tinta); box-shadow: 0.25rem 0.3rem 0 var(--tinta); }

.btn-secundario { background: transparent; color: var(--tinta); }

.btn-secundario:hover { background: var(--hueso-sombra); }

.modal-aviso { font-size: 0.875rem; color: var(--atenuado-tinta); }

/* ==========================================================================
   404
   ========================================================================== */
.cuerpo-error { align-items: center; justify-content: center; }

.pantalla-fija { width: min(92vw, 32rem); padding: 1.75rem; border-radius: var(--radio); background: var(--hueso); color: var(--tinta); text-align: center; box-shadow: var(--sombra-sticker); }

.pantalla-fija .calavera-img { display: block; height: 9rem; margin: 0 auto 0.5rem; }

.titulo-error { font-family: var(--fuente-display); font-size: 2.2rem; font-weight: 700; line-height: 1.05; margin-bottom: 0.5rem; }

.bajada-error { margin-bottom: 1.25rem; }

.acciones-error { display: grid; gap: 0.6rem; }

/* ==========================================================================
   MOVIMIENTO (una sola entrada al cargar; el resto responde a acciones)
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .calavera-envoltorio { animation: subir 0.9s cubic-bezier(0.2, 0.9, 0.25, 1.15) both; }
  .wordmark-titulo { animation: inflar 0.7s 0.25s cubic-bezier(0.2, 0.9, 0.25, 1.3) both; }
  #btn-ir-tradicionales { animation: entrar-izq 0.7s 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
  #btn-ir-guarda { animation: entrar-der 0.7s 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
}

@keyframes subir { from { translate: 0 3rem; scale: 0.9; opacity: 0; } }
@keyframes inflar { from { scale: 0.6; opacity: 0; } }
@keyframes entrar-izq { from { translate: -3rem 0; opacity: 0; } }
@keyframes entrar-der { from { translate: 3rem 0; opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .estado-stock[data-estado="pocas"] .luz { box-shadow: 0 0 0 2px var(--tinta), 0 0 0 5px var(--poco); }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 860px) {
  .home-grilla {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1.5fr) minmax(0, 0.55fr) minmax(0, 0.55fr) auto auto;
    grid-template-areas: "hero" "tradicionales" "guarda" "novedad" "sellos";
    row-gap: 0.7rem;
  }

  .marca-origen { display: none; }

  .etiqueta-puerta { padding: 0.8rem 1rem; align-items: center; }
  .etiqueta-puerta[data-linea="guarda"] {
    background:
      linear-gradient(90deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.6) 70%, rgba(0, 0, 0, 0.25)),
      url("assets/oro-sup.webp") top right / 75% auto no-repeat,
      url("assets/oro-inf.webp") bottom left / 65% auto no-repeat,
      #000;
  }
  .puerta-texto { gap: 0.25rem; max-width: none; }
  .puerta-titulo { font-size: 1.5rem; }
  .puerta-desc { font-size: 0.9rem; }
  .puerta-accion { display: none; }

  .sellos { justify-content: center; }
  .sellos li { width: 2.4rem; }
  .novedad { justify-self: stretch; }

  .tarjeta-producto-central { flex: none; min-height: auto; grid-template-columns: minmax(0, 1fr); grid-auto-rows: auto; }
  .afiche { flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0.75rem; }
  .afiche-calavera { flex: none; height: 8rem; width: auto; max-width: 30%; }
  .afiche-botella { flex: none; height: 9.5rem; width: auto; max-width: 38%; }
  .barril-svg { flex: none; width: 8rem; height: 7rem; }
  .medidores { flex: 1 1 11rem; }
  .pincelada { flex: 1 1 100%; }
  .nota-estimado { flex: 1 1 100%; text-align: center; }
  .nota-imagen { order: 9; }
  .info-producto { overflow: visible; }
  .producto-desc { font-size: 1rem; }
}

@media (max-height: 700px) and (min-width: 861px) {
  .marca-origen { display: none; }
}

@media (max-width: 520px) {
  .chip-vidrio, .etiqueta-carrito { display: none; }
  .wordmark-linea { height: 1.15rem; }
  .btn-carrito-badge { padding: 0 0.7rem; }
}

@media (max-height: 720px) and (max-width: 860px) {
  .sellos { display: none; }
  .puerta-desc { display: none; }
}

.lugar-instalar { display: flex; align-items: center; }
@media (max-width: 520px) { .marco-aplicacion:not([data-vista="home"]) .lugar-instalar { display: none; } }

/* pwa:inicio — bloque común de modo app (fuente: herramientas/pwa/modo-app.css; se copia con node herramientas/pwa/sincronizar.mjs) */
:root { --modo-app: 0; }
@media (display-mode: fullscreen), (display-mode: standalone), (display-mode: minimal-ui) {
  :root { --modo-app: 1; }
  html { overscroll-behavior-y: contain; -webkit-tap-highlight-color: transparent; }
}
/* pwa:fin */
