/* catalogo.css (AJUSTADO: simetría móvil + imágenes + kitty animación como antes) */
:root {
  --color-primario: #ff4f9a;
  --color-primario-claro: #ff5fa2;
  --color-primario-oscuro: #ff2f7a;
  --color-verde: #28a745;
  --color-azul: #3498db;
  --color-morado: #6f42c1;
  --color-rojo: #dc3545;
  --color-rosado: #ff3f87;
  --sombra-suave: 0 10px 22px rgba(0, 0, 0, 0.08);
  --sombra-media: 0 18px 35px rgba(0, 0, 0, 0.14);
  --borde-radio: 18px;
  --borde-radio-peq: 8px;
}

* { box-sizing: border-box; }

body {
  font-family: "Segoe UI", Roboto, Arial, sans-serif;
  background: linear-gradient(135deg, #ffe0ec, #fff5f9);
  margin: 0;
  padding: 0;
  text-align: center;
  color: #2c3e50;
}

/* HEADER */
.catalogo-header {
  position: sticky;
  top: 0;
  z-index: 900;
  overflow: hidden;
  padding: 36px 20px 18px;
  background: linear-gradient(180deg, #f6cfe0 0%, #f3c3d9 100%);
  box-shadow: 0 6px 18px rgba(255, 79, 154, 0.18);
  text-align: center;
  transition: padding 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.catalogo-header h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  color: #7f2b52;
  font-weight: 800;
  position: relative;
  z-index: 3;
  transition: font-size 0.25s ease, margin 0.25s ease, padding 0.25s ease;
}

.catalogo-header p {
  font-size: 1.3rem;
  position: relative;
  z-index: 3;
  transition: font-size 0.25s ease, margin 0.25s ease, padding 0.25s ease, opacity 0.25s ease;
}

.catalogo-header::before {
  content: "";
  position: absolute;
  top: 24px;
  left: -180px;
  width: 110px;
  height: 34px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  box-shadow: -20px -10px 0 0 rgba(255, 255, 255, 0.45), 20px -12px 0 0 rgba(255, 255, 255, 0.45);
  animation: nubeCruza 18s linear infinite;
}

.catalogo-header::after {
  content: "";
  position: absolute;
  top: 18px;
  right: 70px;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  z-index: 0;
  background: radial-gradient(circle at 35% 35%, #ffd7ea 0%, #ff9fc6 45%, #ff6fa9 100%);
  box-shadow: 0 0 12px rgba(255, 120, 180, 0.9),
    0 0 28px rgba(255, 120, 180, 0.7),
    0 0 52px rgba(255, 120, 180, 0.45);
  animation: solGlow 2.6s ease-in-out infinite;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.catalogo-header h1::after {
  content: "";
  position: absolute;
  top: -22px;
  left: -120px;
  width: 70px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  box-shadow: -14px -7px 0 0 rgba(255, 255, 255, 0.35), 14px -8px 0 0 rgba(255, 255, 255, 0.35);
  animation: nubeCruza2 26s linear infinite;
  pointer-events: none;
}

.catalogo-header .sun-glow {
  position: absolute;
  top: 10px;
  right: 62px;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 170, 210, 0.35) 0%, rgba(255, 170, 210, 0.08) 55%, transparent 75%);
  filter: blur(1px);
  animation: solHalo 3.2s ease-in-out infinite;
}

.mascota-peek {
  position: absolute;
  right: 170px;
  left: auto;
  width: 230px;
  bottom: -95px;
  z-index: 4;
  pointer-events: none;
  filter: drop-shadow(0 8px 12px rgba(0, 0, 0, 0.18));
  animation: asomarseKitty 6.8s ease-in-out infinite;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.nube-kitty {
  position: absolute;
  top: -8px;
  left: -260px;
  width: 170px;
  z-index: 1;
  pointer-events: none;
  opacity: 0.95;
  animation: nubeKittyCruza 24s linear infinite;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

/* ===== Toolbar compacta 1 fila ===== */
.catalogo-toolbar {
  position: relative;
  z-index: 5;
  margin: 18px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  max-width: 980px;
  flex-wrap: nowrap;
  padding: 0 4px;
}

.btn-categorias {
  border: 2px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.92);
  color: #7f2b52;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 8px 18px rgba(255, 59, 111, 0.14);
  transition: 0.2s ease;
  flex: 0 0 auto;
}

.btn-categorias:hover { transform: translateY(-1px); }
.btn-categorias:active { transform: scale(0.98); }

.chip-categoria {
  border: 1px solid rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.62);
  color: #7f2b52;
  padding: 10px 12px;
  border-radius: 999px;
  font-weight: 900;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
  flex: 0 1 auto;
  max-width: 46vw;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  min-width: 0;
}

.btn-lupa {
  border: 2px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.92);
  color: #7f2b52;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(255, 59, 111, 0.14);
  transition: 0.2s ease;
  flex: 0 0 auto;
}

.btn-lupa:hover { transform: translateY(-1px); }
.btn-lupa:active { transform: scale(0.98); }

.busqueda-wrap {
  display: none;
  flex: 1 1 auto;
  min-width: 220px;
  max-width: 520px;
  align-items: center;
}

.busqueda-wrap.is-open { display: flex; }

.busqueda {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 42px;
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border: 2px solid rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  box-shadow: 0 10px 22px rgba(255, 59, 111, 0.13);
  overflow: hidden;
}

#busquedaInput {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 800;
  color: #4a2b3a;
}

#busquedaInput::placeholder {
  color: rgba(127, 43, 82, 0.65);
  font-weight: 800;
}

.busqueda-clear {
  border: none;
  background: transparent;
  color: rgba(127, 43, 82, 0.8);
  cursor: pointer;
  font-size: 18px;
  padding: 0;
  height: 100%;
  transition: 0.15s ease;
  opacity: 0;
  pointer-events: none;
}

.busqueda-clear.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.busqueda-clear:hover {
  background: rgba(255, 255, 255, 0.55);
  color: #7f2b52;
}

/* GRID PRINCIPAL */
.catalogo-grid {
  padding: 20px;
  max-width: 1320px;
  margin: auto;
}

/* EMPTY STATE búsqueda */
.busqueda-empty {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid #ffe2ec;
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.06);
  margin: 18px auto 0;
  max-width: 720px;
  text-align: center;
}

.busqueda-empty h3 {
  margin: 0 0 8px;
  color: #7f2b52;
  font-weight: 900;
}

.busqueda-empty p {
  margin: 0;
  color: #5a3f4e;
  font-weight: 700;
}

/* SECCIONES */
.catalog-section { margin-bottom: 80px; }

.category-title {
  text-align: center;
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--color-primario-oscuro);
  margin-bottom: 45px;
  text-shadow: 2px 2px 0 rgba(255, 59, 111, 0.1);
}

.productos-wrapper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  align-items: stretch;
}

/* TARJETA PRODUCTO */
.producto {
  height: 100%;
  background: white;
  border-radius: var(--borde-radio);
  padding: 20px 16px;
  text-align: center;
  box-shadow: var(--sombra-suave);
  transition: all 0.25s ease;
  position: relative;
  display: flex;
  flex-direction: column;
  border: 2px solid #ffe2ec;
}

.producto:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--sombra-media);
  border-color: var(--color-primario-claro);
}

.producto > img,
.producto .carousel-images img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 16px;
  background: #fff;
  transition: transform 0.3s ease;
  display: block;
}

.producto:hover img { transform: scale(1.05); }

.producto h3 {
  color: var(--color-primario);
  margin: 10px 0 4px;
  font-size: 17px;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1.25;
}

.producto p {
  font-weight: bold;
  color: #2c3e50;
  margin: 8px 0;
  font-size: 1.2rem;
}

.precio-unitario {
  font-weight: bold;
  color: #444;
  margin: 4px 0;
  font-size: 15px;
  min-height: 30px;
}

.precio-mayor {
  font-size: 14px;
  color: var(--color-primario-oscuro);
  font-weight: 600;
  margin: 2px 0;
  min-height: 42px;
}

.promo-pack {
  font-size: 14px;
  color: #e67e22;
  font-weight: 600;
  margin: 2px 0;
  min-height: 42px;
}

.descripcion {
  font-size: 13px;
  color: #666;
  font-style: italic;
  margin: 4px 0;
}

.btn-comprar {
  background: linear-gradient(135deg, var(--color-primario-claro), var(--color-primario-oscuro));
  border: none;
  padding: 11px 22px;
  color: white;
  font-weight: bold;
  border-radius: 30px;
  cursor: pointer;
  transition: 0.3s ease;
  margin-top: auto;
  box-shadow: 0 6px 14px rgba(255, 59, 111, 0.4);
}

.btn-comprar:hover {
  background: linear-gradient(135deg, var(--color-primario-oscuro), #ff2d5a);
  transform: scale(1.06);
  box-shadow: 0 10px 20px rgba(255, 59, 111, 0.5);
}

.btn-comprar:active { transform: scale(0.95); }

/* BADGES */
.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  color: white;
  padding: 6px 12px;
  font-size: 1rem;
  font-weight: bold;
  border-radius: 20px;
  z-index: 20;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
  letter-spacing: 0.5px;
}

.badge.pedido { background: var(--color-morado); }
.badge.disponible { background: linear-gradient(145deg, var(--color-verde), #27ae60); }
.badge.ultimasunidades { background: var(--color-azul); }
.badge.oferta { background: var(--color-rosado); }
.badge.agotado { background: var(--color-rojo); }
.badge.proximamente { background: linear-gradient(145deg, #f1c40f, #f39c12); }

/* CARRUSEL */
.carousel {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  margin: auto;
  overflow: hidden;
}

.carousel-images { width: 100%; height: 100%; position: relative; }

.carousel-images img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: #fff;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 0.4s ease;
  border-radius: 12px;
}

.carousel-images img.active { opacity: 1; }

.prev,
.next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--color-rosado);
  color: white;
  border: none;
  padding: 8px 12px;
  cursor: pointer;
  border-radius: 50%;
  z-index: 10;
}

.prev { left: 10px; }
.next { right: 10px; }

/* SELECTORES */
.selector-colores,
.selector-aroma,
.selector-opcion {
  margin: 10px 0;
  text-align: center;
  min-height: 92px;
}

.label-color,
.label-aroma,
.label-opcion {
  font-size: 1rem;
  font-weight: 500;
  display: block;
  margin-bottom: 6px;
  color: #444;
}

.colores,
.aromas,
.opciones {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
  justify-content: center;
}

.color-opcion,
.aroma-opcion,
.opcion-btn { cursor: pointer; transition: 0.2s ease; }

.color-opcion,
.aroma-opcion {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid transparent;
}

.color-opcion:hover,
.aroma-opcion:hover { transform: scale(1.15); }

.color-opcion.activo,
.aroma-opcion.activo {
  border: 2px solid #333;
  box-shadow: 0 0 0 2px white, 0 0 0 4px var(--color-primario-claro);
  transform: scale(1.15);
}

/* Marco para colores claros */
.color-opcion[data-color="White"],
.color-opcion[data-color="white"],
.color-opcion[data-color="Blanco"],
.color-opcion[data-color="blanco"],
.color-opcion[data-color="Vainilla"],
.color-opcion[data-color="vainilla"],
.color-opcion[data-color="Rosa bebé"],
.color-opcion[data-color="rosa bebé"] {
  border-color: #b89cae;
  box-shadow: inset 0 0 0 1px #fff;
}

.opcion-btn {
  padding: 10px 18px;
  border-radius: 30px;
  border: 2px solid #d8c2cf;
  background: #fff;
  color: #5a3f4e;
  font-size: 1.05rem;
  font-weight: 600;
  min-width: 95px;
  text-align: center;
}

.opcion-btn:hover {
  background: #f5f5f5;
  transform: scale(1.05);
  box-shadow: 0 0 10px rgba(255, 77, 141, 0.5);
}

.opcion-btn.activo {
  background-color: var(--color-primario-oscuro);
  color: white;
  border-color: var(--color-primario-oscuro);
}

/* CARRITO */
.carrito-flotante {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: linear-gradient(135deg, var(--color-primario-claro), var(--color-primario-oscuro));
  color: white;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(255, 59, 111, 0.4);
  z-index: 1100;
  transition: 0.3s ease;
  border: 3px solid white;
}

.carrito-flotante:hover {
  transform: scale(1.1) rotate(3deg);
  box-shadow: 0 15px 35px rgba(255, 59, 111, 0.5);
}

.carrito-flotante span {
  position: absolute;
  top: -6px;
  right: -6px;
  background: white;
  color: var(--color-primario-oscuro);
  font-size: 15px;
  font-weight: bold;
  border-radius: 50%;
  padding: 4px 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.panel-carrito {
  position: fixed;
  top: 0;
  right: -420px;
  width: 90%;
  max-width: 420px;
  height: 100%;
  background: #ffffff;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.2);
  transition: right 0.35s ease;
  display: flex;
  flex-direction: column;
  z-index: 1000;
  border-radius: 20px 0 0 20px;
  overflow: hidden;
}

.panel-carrito.activo { right: 0; }

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background: linear-gradient(135deg, var(--color-primario-claro), var(--color-primario-oscuro));
  color: white;
  font-size: 18px;
  font-weight: bold;
}

.cerrar {
  background: rgba(255, 255, 255, 0.2);
  padding: 8px 14px;
  border-radius: 50%;
  cursor: pointer;
  transition: 0.3s;
  font-size: 1.2rem;
  line-height: 1;
}

.cerrar:hover {
  background: white;
  color: var(--color-primario-oscuro);
  transform: rotate(90deg);
}

.lista-carrito {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
}

.item-carrito {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fafafa;
  padding: 15px;
  margin-bottom: 12px;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  border: 1px solid #f0f0f0;
  transition: 0.2s;
}

.item-carrito:hover {
  background: #fff;
  box-shadow: 0 4px 12px rgba(255, 59, 111, 0.1);
  border-color: var(--color-primario-claro);
}

.info-producto {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.nombre { font-weight: 600; font-size: 1.1rem; }

.control-cantidad {
  display: flex;
  align-items: center;
  gap: 10px;
}

.control-cantidad button {
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 50%;
  background: var(--color-primario-oscuro);
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.control-cantidad button:hover {
  opacity: 0.8;
  background: var(--color-primario);
  transform: scale(1.1);
}

.lado-derecho {
  display: flex;
  align-items: center;
  gap: 15px;
  min-width: 100px;
  justify-content: flex-end;
}

.subtotal { font-weight: bold; font-size: 1.1rem; color: var(--color-primario-oscuro); }

.eliminar {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: #aaa;
  transition: 0.2s;
}

.eliminar:hover { color: var(--color-rojo); transform: scale(1.2); }

.panel-footer {
  padding: 16px;
  border-top: 1px solid #eee;
  background: #fafafa;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

#total {
  font-size: 20px;
  font-weight: bold;
  color: var(--color-primario-oscuro);
  text-align: right;
  border-bottom: 1px dashed #ddd;
  padding-bottom: 8px;
}

.btn-whatsapp {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: white;
  border: none;
  padding: 15px;
  cursor: pointer;
  border-radius: 40px;
  font-weight: bold;
  font-size: 15px;
  transition: 0.3s;
  box-shadow: 0 6px 15px rgba(37, 211, 102, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-whatsapp:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp::before { content: "📱"; font-size: 15px; }

.metodo-pago {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 14px;
  background: #f9f9f9;
  padding: 2px;
  border-radius: 2px;
}

.metodo-pago select,
.fecha-entrega input {
  padding: 8px;
  border-radius: 6px;
  border: 1px solid #ddd;
  font-size: 14px;
  background: white;
}

.condicion-pago,
.aviso-entrega {
  font-size: 11px;
  margin-top: 1px;
  color: #666;
  font-style: italic;
  background: #fff3f3;
  padding: 4px;
  border-radius: 4px;
  border-left: 2px solid var(--color-primario);
}

.aceptar-condiciones {
  margin-top: 8px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #444;
  background: #f0f0f0;
  padding: 8px;
  border-radius: 6px;
}

/* TOAST */
.toast {
  pointer-events: none;
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--color-primario-oscuro);
  color: white;
  padding: 16px 28px;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 500;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.2s ease;
  z-index: 9999;
}

.toast.show { opacity: 1; transform: translateY(0); }

/* VOLVER */
.volver { margin-bottom: 35px; }

.volver a {
  text-decoration: none;
  color: var(--color-primario-oscuro);
  font-weight: bold;
  font-size: 1.2rem;
  padding: 10px 30px;
  border-radius: 40px;
  background: white;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  transition: 0.2s;
  border: 1px solid var(--color-primario-claro);
}

.volver a:hover {
  background: var(--color-primario-claro);
  color: white;
  box-shadow: 0 8px 16px rgba(255, 59, 111, 0.2);
}

/* HEADER COMPACTO */
body.header-compact .catalogo-header {
  transform: scaleY(0.95);
  transform-origin: top center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.12);
}

body.header-compact .catalogo-header h1 {
  transform: scale(0.94);
  transform-origin: left center;
}

body.header-compact .catalogo-header p {
  opacity: 0.95;
  transform: translateY(-1px) scale(0.98);
}

body.header-compact .catalogo-header::before,
body.header-compact .catalogo-header h1::after { opacity: 0.75; }

body.header-compact .nube-kitty { opacity: 0.85; }
body.header-compact .mascota-peek { opacity: 0.9; }

body.header-compact .catalogo-header::after { opacity: 0.9; transform: scale(0.9); }

/* LOADING BOTON */
.btn-whatsapp.loading {
  opacity: 0.8;
  cursor: not-allowed;
  position: relative;
}

.btn-whatsapp .spinner {
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top: 3px solid white;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  animation: girar 0.8s linear infinite;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}

/* ===== MODAL CATEGORÍAS ===== */
body.modal-categorias-open { overflow: hidden; }

.modal-categorias[aria-hidden="true"] { display: none; }

.modal-categorias { position: fixed; inset: 0; z-index: 2100; }

.modal-categorias__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(2px);
}

.modal-categorias__dialog {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0 auto;
  width: min(680px, 100%);
  background: #fff;
  border-radius: 18px 18px 0 0;
  overflow: hidden;
  box-shadow: 0 -22px 60px rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(0, 0, 0, 0.08);
  animation: sheetUp 0.18s ease-out;
}

.modal-categorias__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  background: linear-gradient(135deg, #ff5fa2, #ff2f7a);
  color: #fff;
}

.modal-categorias__title { font-weight: 900; font-size: 16px; }

.modal-categorias__close {
  border: none;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 18px;
  transition: 0.2s;
}

.modal-categorias__close:hover { background: rgba(255, 255, 255, 0.28); transform: scale(1.05); }

.modal-categorias__body { padding: 14px 16px calc(18px + env(safe-area-inset-bottom)); }

.modal-categorias__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.categoria-sheet-btn {
  border: 2px solid #ead3de;
  background: #fff;
  color: #5a3f4e;
  padding: 12px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 900;
  font-size: 14px;
  transition: 0.15s;
  box-shadow: 0 8px 18px rgba(255, 59, 111, 0.10);
}

.categoria-sheet-btn:hover { background: #fff3f8; transform: translateY(-1px); box-shadow: 0 12px 22px rgba(255, 59, 111, 0.14); }

.categoria-sheet-btn.is-active {
  background: var(--color-primario-oscuro);
  color: #fff;
  border-color: var(--color-primario-oscuro);
  box-shadow: 0 12px 24px rgba(255, 59, 111, 0.22);
}

/* PC: modal centrado */
@media (min-width: 769px) {
  .modal-categorias__dialog {
    top: 12vh;
    bottom: auto;
    width: min(760px, calc(100% - 28px));
    border-radius: 18px;
    box-shadow: 0 18px 55px rgba(0, 0, 0, 0.28);
    animation: popIn 0.16s ease-out;
  }
  .modal-categorias__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ===== MODAL OPCIONES (se mantiene) ===== */
body.modal-opciones-open { overflow: hidden; }

.opcion-seleccionada { margin: 6px 0; }

.opcion-seleccionada-text {
  display: inline-block;
  font-size: 12px;
  color: #5a3f4e;
  background: #fff5f9;
  border: 1px dashed #ffd0e1;
  padding: 6px 10px;
  border-radius: 12px;
}

.btn-ver-tonos {
  margin-top: 10px;
  width: 100%;
  border: 2px solid #ffd0e1;
  background: #fff;
  color: #7f2b52;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(255, 59, 111, .12);
  transition: .2s;
}

.btn-ver-tonos:hover { background: #fff3f8; transform: translateY(-1px); }

.modal-opciones[aria-hidden="true"] { display: none; }

.modal-opciones { position: fixed; inset: 0; z-index: 2000; }

.modal-opciones__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .45);
  backdrop-filter: blur(2px);
}

.modal-opciones__dialog {
  position: relative;
  margin: 8vh auto 0;
  width: min(560px, calc(100% - 28px));
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 18px 45px rgba(0, 0, 0, .25);
  border: 1px solid rgba(0, 0, 0, .08);
}

.modal-opciones__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  background: linear-gradient(135deg, #ff5fa2, #ff2f7a);
  color: #fff;
}

.modal-opciones__title { font-weight: 800; font-size: 16px; }

.modal-opciones__close {
  border: none;
  background: rgba(255, 255, 255, .18);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 18px;
  transition: .2s;
}

.modal-opciones__close:hover { background: rgba(255, 255, 255, .28); transform: scale(1.05); }

.modal-opciones__body { padding: 14px 16px 0; }

.modal-opciones__search {
  width: 100%;
  border: 1px solid #f0d5e2;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 14px;
  outline: none;
  margin-bottom: 12px;
}

.modal-opciones__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-height: min(46vh, 520px);
  overflow: auto;
  padding-bottom: 14px;
}

.modal-opciones__option {
  border: 2px solid #ead3de;
  background: #fff;
  color: #5a3f4e;
  padding: 10px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
  transition: .15s;
}

.modal-opciones__option:hover { background: #fff3f8; transform: translateY(-1px); box-shadow: 0 10px 18px rgba(255, 59, 111, .16); }

.modal-opciones__option.is-active { background: #ff2f7a; color: #fff; border-color: #ff2f7a; }

.modal-opciones__footer {
  display: flex;
  gap: 10px;
  padding: 14px 16px 16px;
  border-top: 1px solid #f2e4ec;
  background: #fff;
}

.modal-opciones__cancel {
  flex: 1;
  border: 2px solid #ead3de;
  background: #fff;
  color: #5a3f4e;
  padding: 12px 14px;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
  transition: .2s;
}

.modal-opciones__cancel:hover { background: #faf7f9; }

.modal-opciones__confirm {
  flex: 1;
  border: none;
  background: linear-gradient(135deg, #ff5fa2, #ff2f7a);
  color: #fff;
  padding: 12px 14px;
  border-radius: 999px;
  font-weight: 900;
  cursor: pointer;
  transition: .2s;
  box-shadow: 0 10px 18px rgba(255, 59, 111, .22);
}

.modal-opciones__confirm:disabled { opacity: .55; cursor: not-allowed; box-shadow: none; }

.modal-opciones__option.has-thumb { border-radius: 14px; padding: 8px; }

.modal-opciones__thumb {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 12px;
  display: block;
  margin-bottom: 6px;
}

.modal-opciones__caption { font-size: 12px; font-weight: 800; color: #5a3f4e; display: block; }

/* ====== AJUSTES MÓVIL IMPORTANTES (esto arregla simetría + imágenes) ====== */
@media (max-width: 768px) {
  .catalogo-grid { padding: 12px; }

  .catalogo-header {
    padding-top: 56px;
    padding-bottom: 14px;
    text-align: left;
  }

  .catalogo-header h1 {
    margin: 0;
    font-size: 2rem;
    padding-right: 120px;
    z-index: 4;
  }

  .catalogo-header p {
    margin-top: 10px;
    padding-right: 120px;
    z-index: 4;
  }

  .catalogo-header::after {
    right: 12px;
    top: 10px;
    width: 56px;
    height: 56px;
    z-index: 2;
  }

  .catalogo-header::before {
    top: 8px;
    width: 78px;
    height: 24px;
    opacity: 0.55;
  }

  .catalogo-header h1::after { display: none; }

  .catalogo-header .sun-glow {
    top: 6px;
    right: 8px;
    width: 76px;
    height: 76px;
  }

  .nube-kitty {
    top: 4px;
    width: 108px;
    z-index: 2;
  }

  /* Kitty vuelve a “asomarse” a la altura original */
  .mascota-peek {
    left: auto !important;
    right: 35px;
    width: 200px;
    bottom: -140px;
    z-index: 3;
    animation: asomarseKittyMobile 7s ease-in-out infinite;
  }

  /* Toolbar: alineada y simétrica */
  .catalogo-toolbar {
    justify-content: flex-start;
    gap: 8px;
    margin-top: 14px;
    padding: 0;
  }

  .btn-categorias__text { display: none; }

  .btn-categorias {
    padding: 10px 12px;
  }

  .btn-lupa {
    width: 42px;
    height: 42px;
  }

  .chip-categoria {
    max-width: 46vw;
    padding: 10px 12px;
  }

  /* Si abre búsqueda, ocultar chip para que TODO quede en 1 sola fila */
  body.search-open .chip-categoria { display: none; }

  .busqueda-wrap {
    min-width: 0;
    max-width: none;
    flex: 1 1 auto;
  }

  #busquedaInput {
    padding: 11px 12px;
    font-size: 14px;
  }

  /* Cat title + grid móvil */
  .category-title {
    font-size: 25px;
    margin-bottom: 16px;
  }

  /* Esto arregla el “4 columnas mini” que te rompió las imágenes */
  .productos-wrapper {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .producto {
    padding: 12px;
    border-radius: 16px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
  }

  .producto:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
  }

  .producto > img,
  .producto .carousel-images img {
    border-radius: 12px;
    background: #f5f5f5;
  }

  .carousel {
    aspect-ratio: 1 / 1;
  }

  .catalogo-grid .producto h3 {
    font-size: 21px;
    margin: 10px 0 4px;
    line-height: 1.3;
    min-height: auto;
    display: block;
  }

  .producto p {
    font-size: 17px;
    margin: 6px 0;
  }

  .btn-comprar {
    padding: 10px 16px;
    font-size: 14px;
    border-radius: 24px;
    margin-top: 10px;
  }

  .badge {
    top: 8px;
    left: 8px;
    padding: 4px 10px;
    font-size: 12px;
  }

  .selector-colores,
  .selector-aroma,
  .selector-opcion {
    margin: 8px 0;
    min-height: auto;
  }

  .label-color,
  .label-aroma,
  .label-opcion {
    font-size: 12px;
  }

  .colores,
  .aromas,
  .opciones {
    gap: 6px;
  }

  .color-opcion,
  .aroma-opcion {
    width: 26px;
    height: 26px;
  }

  .opcion-btn {
    padding: 10px 16px;
    font-size: 18px;
    min-width: 95px;
  }

  .carrito-flotante {
    width: 80px;
    height: 80px;
    font-size: 22px;
    bottom: 15px;
    right: 15px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
  }

  .carrito-flotante span {
    font-size: 18px;
    padding: 6px 9px;
  }

  .panel-carrito {
    width: 100%;
    max-width: 320px;
  }

  .precio-unitario {
    font-size: 14px;
    min-height: auto;
  }

  .precio-mayor,
  .promo-pack {
    font-size: 12px;
    min-height: auto;
  }
}

@media (max-width: 480px) {
  .modal-categorias__grid { grid-template-columns: 1fr; }
  .modal-opciones__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .catalogo-header h1 { font-size: 1.8rem; padding-right: 82px; }
  .catalogo-header p { font-size: 0.95rem; padding-right: 82px; }
  .catalogo-header::after { width: 56px; height: 56px; right: 10px; }

  .mascota-peek {
    width: 180px;
    right: 8px;
    left: auto;
    bottom: -80px;
    animation-duration: 7s;
  }
}

/* DESKTOP intermedio */
@media (min-width: 769px) and (max-width: 1180px) {
  .productos-wrapper { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .modal-categorias__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* KEYFRAMES */
@keyframes nubeCruza {
  from { left: -180px; }
  to { left: calc(100% + 180px); }
}

@keyframes nubeCruza2 {
  from { left: -140px; }
  to { left: calc(100% + 140px); }
}

@keyframes asomarseKitty {
  0%, 100% { transform: translateY(35px); }
  18% { transform: translateY(-80px); }
  45% { transform: translateY(-90px); }
  62% { transform: translateY(35px); }
}

@keyframes asomarseKittyMobile {
  0%, 100% { transform: translateY(23px); }
  20% { transform: translateY(-85px); }
  45% { transform: translateY(-85px); }
  62% { transform: translateY(23px); }
}

@keyframes nubeKittyCruza {
  from { left: -260px; }
  to { left: calc(100% + 260px); }
}

@keyframes solGlow {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 12px rgba(255, 120, 180, 0.9),
      0 0 28px rgba(255, 120, 180, 0.7),
      0 0 52px rgba(255, 120, 180, 0.45);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 16px rgba(255, 120, 180, 1),
      0 0 38px rgba(255, 120, 180, 0.85),
      0 0 70px rgba(255, 120, 180, 0.55);
  }
}

@keyframes solHalo {
  0%, 100% { opacity: 0.65; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}

@keyframes girar {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes sheetUp {
  from { transform: translateY(10px); opacity: 0.6; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes popIn {
  from { transform: translateY(-6px); opacity: 0.75; }
  to { transform: translateY(0); opacity: 1; }
}
