/* Jiumin Store — paleta coqueta rosa con acento dorado.
   Rosa fuerte: #e75480 · rosa medio: #f472a7 · rosa claro: #ffd6e8
   Fondo: #fff5f8 · dorado: #c9962e · texto: #5b2a3a */

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: #5b2a3a;
  background-color: #fff5f8;
  min-height: 100vh;
}

/* Fondo floral acuarela fijo, suave, detrás de todo el contenido. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url("/bg.jpg") top left / 320px repeat;
  opacity: 0.5;
  z-index: -1;
  pointer-events: none;
}

/* ---------- Encabezado ---------- */

.encabezado {
  text-align: center;
  padding: 0.5rem 1rem 1rem;
}

.barra-superior {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid #ffd6e8;
  border-radius: 999px;
  padding: 0.35rem 0.5rem;
  box-shadow: 0 2px 8px rgba(231, 84, 128, 0.12);
}

.boton-perfil,
.boton-carrito {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid #ffd6e8;
  border-radius: 999px;
  color: #b03060;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.45rem 0.9rem;
  cursor: pointer;
}

.boton-perfil {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.icono-perfil {
  width: 1.15rem;
  height: 1.15rem;
  fill: #b03060;
  flex-shrink: 0;
}

.boton-carrito {
  position: relative;
  font-size: 1.25rem;
  padding: 0.35rem 0.7rem;
}

.carrito-contador {
  position: absolute;
  top: -0.4rem;
  right: -0.4rem;
  min-width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: #d6336c;
  color: #fff;
  border: 2px solid #fff;
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.25rem;
}

.carrito-contador[hidden] { display: none; }

/* Logo con los botones de redes a los lados. */
.logo-fila {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0.6rem;
  max-width: 640px;
  margin: 0.75rem auto 0.25rem;
}

.redes-lado {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.boton-red {
  flex-shrink: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  background: #e75480;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(231, 84, 128, 0.35);
  text-decoration: none;
}

.boton-red svg {
  width: 1.35rem;
  height: 1.35rem;
  fill: #fff;
}

.logo {
  display: block;
  width: min(60vw, 280px);
  border-radius: 24px;
}

@media (max-width: 360px) {
  .logo { width: min(56vw, 220px); }
  .boton-red { width: 2.2rem; height: 2.2rem; }
  .boton-red svg { width: 1.15rem; height: 1.15rem; }
}

.eslogan {
  margin: 0.5rem 0 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: #b03060;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

/* ---------- Contenido ---------- */

.contenido {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
}

.buscador input {
  width: 100%;
  padding: 0.8rem 1rem;
  font-size: 1rem;
  border: 2px solid #f9a8c9;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #5b2a3a;
  outline: none;
}

.buscador input:focus { border-color: #e75480; }

.categorias {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin: 1rem 0;
}

.chip {
  border: 1px solid #f9a8c9;
  background: rgba(255, 255, 255, 0.9);
  color: #b03060;
  border-radius: 999px;
  padding: 0.45rem 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.chip.activo {
  background: #e75480;
  border-color: #e75480;
  color: #fff;
}

.estado { text-align: center; color: #8a4a63; }

.estado.error { color: #a31621; font-weight: 600; }

/* ---------- Rejilla de productos ---------- */

.rejilla {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
}

@media (min-width: 640px) {
  .rejilla { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 960px) {
  .rejilla { grid-template-columns: repeat(4, 1fr); }
}

.tarjeta {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(231, 84, 128, 0.15);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tarjeta:hover,
.tarjeta:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(231, 84, 128, 0.3);
}

/* Anillo dorado del primer toque (producto seleccionado). */
.tarjeta.seleccionado {
  outline: 3px solid #c9962e;
  outline-offset: 2px;
}

.tarjeta img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: #ffeef5;
}

.tarjeta-cuerpo { padding: 0.6rem 0.7rem 0.8rem; }

.tarjeta-nombre {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
}

.tarjeta-precio {
  margin: 0.35rem 0 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: #d6336c;
}

.sin-resultados {
  grid-column: 1 / -1;
  text-align: center;
  color: #8a4a63;
}

/* ---------- Tira: Ofertas Relámpago ---------- */
/* Solo las Ofertas Relámpago van hasta arriba, con su barrita dorada.
   Los destacados se quedan en la rejilla normal. La tira es una fila con
   deslizamiento horizontal, se esconde sola cuando no hay ofertas y tocar
   una tarjeta abre el detalle. */

.tira-ofertas { margin: 0.4rem 0 0.9rem; }

.tira-ofertas[hidden] { display: none; }

.tira-ofertas h2 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  color: #b03060;
}

/* Tal cual estaba en la app original: la barra de Ofertas Relámpago es
   amarilla (#ffc531) con letra oscura pequeña (#3d1524). */
#tira-relampago {
  background: #ffc531;
  border-radius: 16px;
  padding: 0.7rem 0.7rem 0.9rem;
}

#tira-relampago h2 {
  color: #3d1524;
  font-size: 0.9rem;
  margin-left: 0.2rem;
}

.tira-lista {
  display: flex;
  gap: 0.7rem;
  overflow-x: auto;
  padding-bottom: 0.35rem;
  scroll-snap-type: x mandatory;
}

.tira-tarjeta {
  flex: 0 0 132px;
  scroll-snap-align: start;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(231, 84, 128, 0.15);
  padding-bottom: 0.6rem;
}

.tira-tarjeta-foto img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: #ffeef5;
}

/* Sin foto: hueco rosa con "Sin foto" en la tarjeta (rejilla y tira). */
.tarjeta-sin-foto {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #ffeef5;
  color: #c98aa5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}

.tira-tarjeta-nombre {
  margin: 0.45rem 0.55rem 0;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tira-tarjeta .insignia-destacado { margin: 0.35rem 0.55rem 0; }

.tira-tarjeta-precio {
  margin: 0.35rem 0.55rem 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #d6336c;
}

/* Cuenta atrás por tarjeta en la tira (chip), como estaba en la app. */
.tira-tarjeta .flash-cuenta {
  display: inline-block;
  margin: 0.35rem 0.55rem 0;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  background: #ffe3ee;
  color: #b03060;
  font-size: 0.75rem;
}

.tira-tarjeta .etiqueta-off {
  margin: 0.35rem 0 0 0.55rem;
}

/* ---------- Botón de agregar al carrito (dos toques) ---------- */

.tarjeta-agregar,
.boton-agregar {
  width: 100%;
  margin-top: 0.6rem;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 0.8rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.tarjeta-agregar.seleccionado,
.boton-agregar.seleccionado {
  outline: 3px solid #c9962e;
  outline-offset: 2px;
}

.tarjeta-agregar.agregado,
.boton-agregar.agregado {
  background: #2e9e5b;
}

/* ---------- Selector de cantidad (primer toque) ---------- */

.cantidad-selector {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  margin-top: 0.5rem;
}

.cantidad-selector[hidden] { display: none; }

.cantidad-selector button {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: 1.5px solid #e75480;
  background: #fff;
  color: #e75480;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.cantidad-selector span {
  min-width: 1.5rem;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 700;
  color: #5b2a3a;
}

.detalle-acciones .cantidad-selector { margin-top: 0; }

/* ---------- Paginación ---------- */

.paginacion {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.paginacion button {
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.paginacion button:disabled {
  background: #f3b8cd;
  cursor: default;
}

.paginacion span { font-weight: 600; color: #8a4a63; }

/* Barra superior: mismo estilo que la de abajo; un poco de aire arriba
   para no pegarse a los chips de categoría y abajo antes de la rejilla. */
#paginacion-arriba { margin-top: 0.5rem; margin-bottom: 1rem; }

/* Botones numerados de página: más angostos que los de anterior/siguiente. */
.paginacion-numero { padding: 0.55rem 0.85rem; }

.paginacion-numero.activo {
  background: #b03060;
  outline: 2px solid #c9962e;
  outline-offset: 1px;
}

/* ---------- Modal de detalle ---------- */

.modal { position: fixed; inset: 0; z-index: 10; }

.modal[hidden] { display: none; }

.modal-fondo {
  position: absolute;
  inset: 0;
  background: rgba(60, 10, 30, 0.55);
}

.modal-contenido {
  position: relative;
  max-width: 520px;
  width: calc(100% - 2rem);
  margin: 4vh auto;
  background: #fff9fb;
  border-radius: 20px;
  padding: 1rem 1rem 1.25rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  max-height: 92vh;
  overflow-y: auto;
}

.modal-cerrar {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  z-index: 2;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  border: none;
  background: #e75480;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
}

.carrusel { position: relative; }

.carrusel img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
  display: block;
  background: #ffeef5;
}

.carrusel-flecha {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.9);
  color: #d6336c;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.carrusel-flecha.izquierda { left: 0.5rem; }
.carrusel-flecha.derecha { right: 0.5rem; }

.carrusel-puntos {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 0.6rem;
}

.carrusel-puntos button {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  border: none;
  background: #f3b8cd;
  padding: 0;
  cursor: pointer;
}

.carrusel-puntos button.activo { background: #e75480; }

.modal-contenido h2 {
  margin: 0.75rem 0 0.25rem;
  font-size: 1.25rem;
  color: #5b2a3a;
}

.detalle-precio {
  margin: 0;
  font-size: 1.3rem;
  font-weight: 700;
  color: #d6336c;
}

.detalle-categoria { margin: 0.4rem 0 0; color: #8a4a63; }

.detalle-modelos {
  margin: 0.4rem 0 0;
  font-weight: 600;
  color: #c9962e;
}

.detalle-descripcion { margin: 0.6rem 0 0; line-height: 1.5; }

.detalle-acciones { margin-top: 0.9rem; }

/* ---------- Panel del carrito ---------- */

.carrito-fondo {
  position: fixed;
  inset: 0;
  background: rgba(60, 10, 30, 0.5);
  z-index: 15;
}

.carrito-fondo[hidden] { display: none; }

.carrito-panel {
  position: fixed;
  top: 0;
  right: 0;
  height: 100dvh;
  width: min(92vw, 360px);
  background: #fff9fb;
  z-index: 20;
  box-shadow: -8px 0 30px rgba(0, 0, 0, 0.25);
  transform: translateX(105%);
  transition: transform 0.25s ease;
  display: flex;
  flex-direction: column;
}

.carrito-panel.abierto { transform: none; }

.carrito-panel[hidden] { display: none; }

.carrito-encabezado {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1rem 0.75rem;
  border-bottom: 1px solid #ffd6e8;
}

.carrito-encabezado h2 { margin: 0; font-size: 1.2rem; color: #5b2a3a; }

.carrito-cerrar {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  border: none;
  background: #e75480;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
}

.carrito-items {
  flex: 1;
  overflow-y: auto;
  padding: 0.5rem 1rem;
}

.carrito-vacio {
  text-align: center;
  color: #8a4a63;
  margin-top: 2rem;
}

.carrito-item {
  display: flex;
  gap: 0.7rem;
  align-items: center;
  padding: 0.7rem 0;
  border-bottom: 1px solid #ffe3ee;
}

.carrito-item img {
  width: 3.2rem;
  height: 3.2rem;
  object-fit: cover;
  border-radius: 10px;
  background: #ffeef5;
  flex-shrink: 0;
}

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

.carrito-item-nombre {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.25;
}

.carrito-item-precio {
  margin: 0.2rem 0 0;
  font-size: 0.85rem;
  color: #d6336c;
  font-weight: 700;
}

.carrito-item-cantidad {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.carrito-item-cantidad button {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  border: 1px solid #f9a8c9;
  background: #fff;
  color: #d6336c;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.carrito-item-cantidad span {
  min-width: 1.2rem;
  text-align: center;
  font-weight: 700;
}

.carrito-item-quitar {
  background: none;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.3rem;
  flex-shrink: 0;
}

.carrito-pie {
  padding: 1rem;
  border-top: 1px solid #ffd6e8;
}

.carrito-total {
  margin: 0;
  font-size: 1.15rem;
  text-align: right;
}

/* ---------- Botón Enviar pedido (pie del carrito) ---------- */

.boton-enviar-pedido {
  width: 100%;
  margin-top: 0.75rem;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.boton-enviar-pedido:disabled {
  background: #f3b8cd;
  cursor: default;
}

/* ---------- Checkout ---------- */

/* Lista detallada del pedido (maqueta aprobada 27 nov): un renglón por
   artículo con su costo, y el Total al final, antes de los datos y el pago. */
.checkout-articulos {
  margin: 0.25rem 0 0;
}

.checkout-articulo {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid #f0e0e7;
  color: #333;
}

.checkout-articulo-nombre {
  min-width: 0;
  font-size: 1rem;
}

.checkout-articulo-precio {
  white-space: nowrap;
  font-size: 0.9rem;
}

.checkout-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  border-top: 1px solid #ffd6e8;
  margin: 1.1rem 0 1rem;
  padding-top: 0.75rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: #5b2a3a;
}

.checkout-total strong {
  font-weight: 800;
}

/* Títulos del checkout como en la maqueta: grandes, mismo color. */
#checkout-titulo {
  font-size: 1.5rem;
}

.checkout-guardado-botones {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.boton-usar-guardado {
  background: #fff;
  border: 1px solid #f9a8c9;
  color: #b03060;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
}

/* Pastilla de dirección elegida en el checkout (modo guardado). */
.boton-usar-guardado.seleccionado {
  background: #e75480;
  border-color: #e75480;
  color: #fff;
}

/* Resumen solo lectura de los datos guardados (modo guardado del checkout). */
.checkout-datos-seleccionados {
  background: rgba(255, 214, 232, 0.6);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.75rem 0.9rem;
  margin-bottom: 1rem;
}

.checkout-datos-titulo {
  margin: 0 0 0.4rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: #b03060;
}

.checkout-datos-linea {
  margin: 0.15rem 0;
  color: #5b2a3a;
}

/* Banderita discreta para usar otra dirección guardada en este pedido:
   un renglón chico tipo enlace abajo del resumen; al tocarla despliega
   las pastillas de direcciones. */
.checkout-otra-direccion {
  display: block;
  margin: 0.6rem 0 0;
  padding: 0;
  background: none;
  border: 0;
  color: #b03060;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.checkout-otra-direccion-flecha {
  display: inline-block;
  margin-left: 0.15rem;
  transition: transform 0.2s ease;
}

.checkout-otra-direccion.abierto .checkout-otra-direccion-flecha {
  transform: rotate(90deg);
}

.checkout-otras-direcciones {
  margin-top: 0.6rem;
}

/* --- Checkout a pantalla completa en teléfono --- */
/* Como Mi perfil: el modal centrado quedaba más alto que la parte visible
   y el botón "Confirmar pedido" quedaba cortado a la mitad. En móvil el
   checkout ocupa toda la pantalla (100dvh con respaldo 100vh) y el
   contenido se desplaza por dentro; el botón ✕ queda fijo arriba. */
@media (max-width: 640px) {
  #modal-checkout .modal-contenido {
    width: 100%;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    margin: 0;
    border-radius: 0;
    overflow-y: auto;
    padding: 1rem 1rem calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }

  /* El ✕ es absoluto y se iría con el desplazamiento: fijo arriba. */
  #modal-checkout .modal-cerrar {
    position: fixed;
    top: 0.6rem;
    right: 0.6rem;
  }
}

.campo {
  display: block;
  margin-bottom: 0.85rem;
}

.campo > span {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: #b03060;
}

.campo > span em { font-weight: 400; color: #8a4a63; }

/* Botón "i" de información junto a una etiqueta (checkout: Ubicación en Maps). */
.campo-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25rem;
  height: 1.25rem;
  margin-left: 0.2rem;
  padding: 0;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1;
  color: #e75480;
  background: #fff0f5;
  border: 1.5px solid #e75480;
  border-radius: 50%;
  cursor: pointer;
  vertical-align: middle;
}

.campo-info[aria-expanded="true"] { background: #e75480; color: #fff; }

.campo input,
.campo select,
.campo textarea {
  width: 100%;
  padding: 0.7rem 0.9rem;
  font-size: 1rem;
  font-family: inherit;
  border: 2px solid #f9a8c9;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.95);
  color: #5b2a3a;
  outline: none;
}

.campo input:focus,
.campo select:focus,
.campo textarea:focus { border-color: #e75480; }

.campo textarea { resize: vertical; }

.checkout-pago {
  border-top: 1px solid #ffd6e8;
  margin-top: 1.1rem;
  padding-top: 0.75rem;
}

.checkout-pago h3 {
  margin: 0 0 0.3rem;
  font-size: 1.5rem;
  color: #5b2a3a;
}

/* Costos de envío: una línea corta según ubicación y total, sin botones.
   Dentro de la zona la línea va en caja verde; el "pero te faltan $X"
   va en letritas rojas y más chicas. */
.checkout-envio {
  border-top: 1px solid #ffd6e8;
  margin-top: 1.1rem;
  padding-top: 0.75rem;
}

.checkout-envio h3 {
  margin: 0 0 0.3rem;
  font-size: 1.5rem;
  color: #5b2a3a;
}

.envio-mensaje {
  margin: 0;
  color: #333;
  line-height: 1.5;
}

.envio-mensaje.envio-caja-verde {
  background: #e6f7ec;
  color: #1e7a3c;
  border: 1px solid #a8dcc0;
  border-radius: 0.6rem;
  padding: 0.6rem 0.8rem;
}

.envio-mensaje.envio-caja-amarilla {
  background: #fff3cd;
  color: #8a6d00;
  border: 1px solid #e8c96a;
  border-radius: 0.6rem;
  padding: 0.6rem 0.8rem;
}

.envio-pero {
  color: #c0392b;
  font-size: 0.85em;
}

.checkout-metodo {
  margin: 0 0 0.6rem;
  font-weight: 700;
  color: #d6336c;
}

.checkout-pestanas-pago {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.pestana-pago {
  flex: 1;
  background: #fff;
  border: 2px solid #ffd6e8;
  border-radius: 999px;
  padding: 0.55rem 0.5rem;
  font-size: 1rem;
  font-weight: 700;
  color: #8a4a63;
  cursor: pointer;
}

.pestana-pago-activa {
  background: #e75480;
  border-color: #e75480;
  color: #fff;
}

.boton-copiar-clabe {
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  margin-left: 0.3rem;
}

.checkout-efectivo-texto {
  margin: 0;
  color: #333;
  line-height: 1.5;
}

.confirmacion-whatsapp-respaldo {
  text-align: center;
  color: #8a4a63;
  line-height: 1.5;
}

.confirmacion-whatsapp-respaldo[hidden] { display: none; }

.checkout-datos-transferencia {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.7rem 0.9rem;
}

.checkout-datos-transferencia p { margin: 0.3rem 0; }
.checkout-datos-transferencia p span { color: #8a4a63; }

.checkout-nota-transferencia {
  margin: 0;
  color: #8a4a63;
  font-style: italic;
}

.checkout-cargando-transferencia { margin: 0; color: #8a4a63; }

.checkout-error,
.comprobante-error,
.feedback-error,
.perfil-error {
  color: #a31621;
  font-weight: 600;
}

.checkout-error[hidden],
.comprobante-error[hidden],
.feedback-error[hidden],
.perfil-error[hidden] { display: none; }

.boton-confirmar-pedido {
  width: 100%;
  margin-top: 0.6rem;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.75rem 0.8rem;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
}

.boton-confirmar-pedido:disabled {
  background: #f3b8cd;
  cursor: default;
}

/* ---------- Confirmación del pedido ---------- */

/* La confirmación queda centrada verticalmente en el modal. */
#checkout-confirmacion {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 60vh;
}

#checkout-confirmacion[hidden] { display: none; }

@media (max-width: 640px) {
  #checkout-confirmacion { min-height: calc(100dvh - 3rem); }
}

/* Celebración del pedido: confeti y cohetes. El contenedor no recibe
   toques, así que no tapa ni bloquea ningún botón de la confirmación. */
.celebracion-pedido {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 5;
}

.celebracion-confeti {
  position: absolute;
  top: -16px;
  border-radius: 2px;
  pointer-events: none;
  animation: caer-confeti linear forwards;
}

@keyframes caer-confeti {
  to { transform: translateY(108vh) rotate(720deg); }
}

.celebracion-destello {
  position: absolute;
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  pointer-events: none;
  animation: destello-cohete 0.55s ease-out forwards;
}

@keyframes destello-cohete {
  from { transform: scale(0.4); opacity: 1; }
  to { transform: scale(2.2); opacity: 0; }
}

.celebracion-cohete {
  position: absolute;
  width: 7px;
  height: 7px;
  margin: -3.5px 0 0 -3.5px;
  border-radius: 50%;
  pointer-events: none;
  animation: estallar-cohete 0.9s ease-out forwards;
}

@keyframes estallar-cohete {
  from { transform: translate(0, 0) scale(1); opacity: 1; }
  to { transform: translate(var(--dx, 0px), var(--dy, 0px)) scale(0.4); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .celebracion-pedido { display: none; }
}

#checkout-confirmacion h2 {
  color: #2e9e5b;
  text-align: center;
  font-size: 2rem;
  line-height: 1.2;
}

.confirmacion-numero,
.confirmacion-total {
  text-align: center;
  font-size: 1.15rem;
  margin: 0.4rem 0;
}

.confirmacion-texto {
  text-align: center;
  color: #8a4a63;
  line-height: 1.5;
}

.boton-whatsapp {
  display: block;
  text-align: center;
  background: #2e9e5b;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.75rem 0.8rem;
  margin: 1rem 0;
}

.comprobante {
  border-top: 1px solid #ffd6e8;
  padding-top: 0.75rem;
  margin-top: 1rem;
}

.comprobante h3 { margin: 0 0 0.3rem; font-size: 1.05rem; }
.comprobante p { margin: 0.3rem 0 0.7rem; color: #8a4a63; line-height: 1.5; }

.comprobante-archivo {
  display: block;
  text-align: center;
  background: #fff;
  border: 2px dashed #f9a8c9;
  border-radius: 14px;
  padding: 0.8rem;
  font-weight: 700;
  color: #b03060;
  cursor: pointer;
  margin-bottom: 0.6rem;
}

.boton-comprobante {
  width: 100%;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.65rem 0.8rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.boton-comprobante:disabled {
  background: #f3b8cd;
  cursor: default;
}

.comprobante-exito,
.feedback-exito {
  color: #2e9e5b;
  font-weight: 700;
}

.comprobante-exito[hidden],
.feedback-exito[hidden] { display: none; }

.boton-seguir-comprando {
  width: 100%;
  margin-top: 1.1rem;
  background: #fff;
  border: 2px solid #f9a8c9;
  color: #b03060;
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

/* ---------- Mi perfil ---------- */

.perfil-vacio,
.perfil-cargando {
  text-align: center;
  color: #8a4a63;
  line-height: 1.5;
}

.perfil-vacio[hidden],
.perfil-cargando[hidden] { display: none; }

.perfil-datos {
  background: rgba(255, 214, 232, 0.6);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.75rem 0.9rem;
  margin-bottom: 1rem;
}

.perfil-nombre { margin: 0; font-size: 1.15rem; font-weight: 800; }
.perfil-telefono { margin: 0.25rem 0 0.4rem; color: #8a4a63; }

/* Avatar de Mi perfil: cuadro con puntas redondeadas, como el logo de la tienda. */
.perfil-encabezado {
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

.perfil-avatar {
  position: relative;
  flex: 0 0 auto;
  width: 4rem;
  height: 4rem;
  border-radius: 1rem;
  background: #e75480;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  border: none;
  padding: 0;
  cursor: pointer;
  overflow: hidden;
}

.perfil-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Insignia del lápiz sobre el avatar (esquina inferior derecha): señala
   que el avatar se puede editar. El ✏️ va en ::before para no ensuciar
   el textContent del botón (la inicial sigue siendo solo la letra). */
.perfil-avatar-lapiz {
  position: absolute;
  right: 0.15rem;
  bottom: 0.15rem;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #e75480;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.perfil-avatar-lapiz::before {
  content: '✏️';
  font-size: 0.8rem;
  line-height: 1;
}

/* Selector de avatar (3 opciones: inicial, subir foto, avatar de la tienda). */
.avatar-selector {
  margin-top: 0.9rem;
  padding: 0.9rem;
  border: 1px solid #f3b8cd;
  border-radius: 1rem;
  background: #fff5f8;
}

.avatar-selector-titulo {
  margin: 0 0 0.6rem;
  font-weight: 700;
  color: #7a2b45;
}

.avatar-selector-subtitulo {
  margin: 0.8rem 0 0.5rem;
  color: #7a2b45;
}

.avatar-opciones {
  display: flex;
  gap: 0.7rem;
}

.avatar-opcion {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0.7rem 0.4rem;
  border: 1px solid #f3b8cd;
  border-radius: 0.8rem;
  background: #fff;
  color: #7a2b45;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
}

.avatar-opcion-muestra {
  width: 3rem;
  height: 3rem;
  border-radius: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 800;
}

.avatar-inicial-muestra {
  background: #e75480;
  color: #fff;
}

.avatar-subir-muestra {
  background: #fdeef3;
}

.avatar-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.5rem;
}

.avatar-grid-boton {
  aspect-ratio: 1;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 0.8rem;
  overflow: hidden;
  background: #fff;
  cursor: pointer;
}

.avatar-grid-boton img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar-grid-boton.elegido {
  border-color: #e75480;
  box-shadow: 0 0 0 2px #f9c6d4;
}

.avatar-error {
  margin: 0.6rem 0 0;
  color: #b3261e;
  font-size: 0.9rem;
}

.avatar-exito {
  margin: 0.6rem 0 0;
  color: #1e7d32;
  font-weight: 600;
  font-size: 0.9rem;
}

.perfil-identidad { min-width: 0; }

.perfil-corazones {
  margin: 0;
  font-size: 1.4rem;
  letter-spacing: 0.2rem;
}

.perfil-corazones .corazon-lleno { color: #e75480; }
.perfil-corazones .corazon-vacio { color: #f3b8cd; }

.perfil-direcciones h3,
.perfil-pedidos h3,
.perfil-feedback h3 {
  margin: 0 0 0.6rem;
  font-size: 1.05rem;
  color: #5b2a3a;
}

.perfil-direcciones ul {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.perfil-direcciones li {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #ffd6e8;
  border-radius: 12px;
  padding: 0.6rem 0.8rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.perfil-direcciones li strong { color: #b03060; }

.perfil-pedidos h4 {
  margin: 0.9rem 0 0.5rem;
  color: #b03060;
  font-size: 0.95rem;
}

.perfil-pedidos h4[hidden] { display: none; }

.pedido {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.7rem 0.85rem;
  margin-bottom: 0.6rem;
}

.pedido-encabezado {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-weight: 700;
}

.pedido-fecha { margin: 0.25rem 0 0.5rem; color: #8a4a63; font-size: 0.85rem; }

.pedido-items {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.92rem;
  line-height: 1.5;
}

.pedido-pie {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid #ffe3ee;
  font-size: 0.9rem;
}

.pedido-total { font-weight: 800; color: #d6336c; }

.pedido-pago { font-weight: 600; color: #8a4a63; }

/* Filas cebras en Mis pedidos: las tarjetas alternan el fondo para
   distinguir un pedido del siguiente (solo Mis pedidos, no las direcciones). */
.pedido-cebra { background: #ffeef5; }

/* Pastilla del estatus del pedido: en forma de botón SIN ser botón
   (solo visual, no se puede tocar ni hace nada). */
.pedido-estado {
  display: inline-block;
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.85rem;
  font-weight: 800;
  cursor: default;
}

.pedido-estado-nuevo { background: #ffd6e8; color: #b03060; }
.pedido-estado-atendido { background: #fff3d6; color: #8a6d1b; }
.pedido-estado-entregado { background: #e6f7ec; color: #1e7a3c; }
.pedido-estado-otro { background: #f0e6ea; color: #8a4a63; }

/* Pastilla del grupo en Pedidos del panel: igual que la pastilla del
   estatus, con su margen de encabezado de grupo. */
.admin-grupo-pastilla { margin: 1rem 0 0.6rem; }
.admin-grupo-pastilla:first-child { margin-top: 0; }

/* Barra "Pedidos anteriores": despliega los pedidos que no caben en los
   primeros 4 de Mis pedidos. */
.perfil-pedidos-anteriores { margin-top: 0.6rem; }

.perfil-pedidos-anteriores.abierto .feedback-flecha { transform: rotate(180deg); }

#perfil-pedidos-anteriores-lista { margin-top: 0.6rem; }
#perfil-pedidos-anteriores-lista[hidden] { display: none; }

.perfil-pedidos-vacio { color: #8a4a63; }
.perfil-pedidos-vacio[hidden] { display: none; }

.perfil-feedback {
  border-top: 1px solid #ffd6e8;
  margin-top: 1.2rem;
  padding-top: 0.9rem;
}

/* Botón discreto que desliza y abre un bloque (dudas y cambio de número). */
.boton-feedback-toggle {
  width: 100%;
  background: #fff;
  color: #b03060;
  border: 1.5px solid #e75480;
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.4rem;
}

.boton-feedback-toggle .feedback-flecha { transition: transform 0.35s ease; }

.perfil-feedback.abierto .boton-feedback-toggle .feedback-flecha,
.perfil-cambio-numero.abierto .boton-feedback-toggle .feedback-flecha { transform: rotate(180deg); }

/* Cuerpo que se desliza: cerrado 0fr, abierto 1fr. */
.feedback-cuerpo {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}

.feedback-cuerpo-interior {
  overflow: hidden;
  min-height: 0;
  visibility: hidden;
  transition: visibility 0s 0.35s;
}

.perfil-feedback.abierto .feedback-cuerpo,
.perfil-cambio-numero.abierto .feedback-cuerpo { grid-template-rows: 1fr; }

.perfil-feedback.abierto .feedback-cuerpo-interior,
.perfil-cambio-numero.abierto .feedback-cuerpo-interior {
  visibility: visible;
  transition-delay: 0s;
}

.feedback-cuerpo-interior .campo:first-child { margin-top: 0.8rem; }
.feedback-cuerpo-interior .cambio-numero-nota { margin-top: 0.8rem; }

.boton-feedback {
  width: 100%;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.boton-feedback:disabled {
  background: #f3b8cd;
  cursor: default;
}

/* ---------- Pie de página ---------- */

.pie {
  background: rgba(255, 255, 255, 0.88);
  border-top: 1px solid #ffd6e8;
  text-align: center;
  color: #8a4a63;
  font-size: 0.95rem;
  padding: 1.25rem 1rem 1.75rem;
  margin-top: 1rem;
}

.pie-nombre {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: #b03060;
}

.pie-eslogan { margin: 0.3rem 0 0.9rem; font-weight: 600; }

.pie-privacidad {
  display: inline-block;
  background: #e75480;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.55rem 1.2rem;
}

.pie-redes {
  margin-top: 0.9rem;
  display: flex;
  gap: 0.6rem;
  justify-content: center;
  align-items: center;
}

.pie-redes a {
  color: #d6336c;
  font-weight: 700;
  text-decoration: none;
}

.pie-ciudad { margin: 0.7rem 0 0; font-size: 0.85rem; }

/* ==========================================================================
   HITO 3 — Ofertas flash, cambio de número y panel de administradora.
   Todo lo de aquí es aditivo; la paleta rosa/floral existente no cambia.
   ========================================================================== */

/* ---------- Ofertas flash ---------- */

.precio-oferta {
  color: #d6336c;
  font-size: 1.25rem;
  font-weight: 800;
}

.precio-anterior {
  color: #8a4a63;
  font-size: 0.9rem;
  font-weight: 400;
  margin-left: 0.35rem;
}

.flash-cuenta {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #b03060;
}

.detalle-flash {
  margin: 0.35rem 0 0;
  font-weight: 700;
  color: #b03060;
}

.detalle-flash[hidden] { display: none; }

/* ---------- Logo: pista de que admite toques ---------- */

.logo { cursor: pointer; }

/* ---------- Modo admin: la vitrina y el pie quedan ocultos ---------- */

body.modo-admin .contenido,
body.modo-admin .pie,
body.modo-admin .barra-superior { display: none; }

/* ---------- Vista del panel ---------- */

.admin {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
}

.admin-encabezado {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #ffd6e8;
  border-radius: 16px;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 10px rgba(231, 84, 128, 0.15);
}

.admin-encabezado h2 {
  margin: 0;
  font-size: 1.35rem;
  color: #b03060;
}

.boton-salir-admin {
  background: #fff;
  border: 2px solid #f9a8c9;
  color: #b03060;
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

.admin-seccion {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 16px;
  margin-bottom: 0.9rem;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(231, 84, 128, 0.12);
}

.admin-seccion-encabezado {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffeef5;
  border: none;
  padding: 0.85rem 1rem;
  font-size: 1.1rem;
  font-weight: 800;
  color: #b03060;
  cursor: pointer;
  font-family: inherit;
}

.admin-seccion-encabezado:hover { background: #ffd6e8; }

.admin-flecha { font-size: 1rem; }

/* Insignia con la cantidad de acciones pendientes en el encabezado de la sección. */
.admin-insignia-pendientes {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  height: 1.5rem;
  padding: 0 0.35rem;
  margin-left: 0.4rem;
  border-radius: 999px;
  background: #e75480;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
  line-height: 1;
  vertical-align: middle;
}

.admin-insignia-pendientes[hidden] { display: none; }

.admin-cuerpo { padding: 1rem; }

.admin-cuerpo[hidden] { display: none; }

.admin-acciones { margin-bottom: 0.9rem; }

.admin-cargando,
.admin-vacio {
  text-align: center;
  color: #8a4a63;
  line-height: 1.5;
}

.admin-vacio-grupo {
  color: #8a4a63;
  font-size: 0.92rem;
  margin: 0.3rem 0 1rem;
}

.admin-grupo-titulo {
  margin: 1rem 0 0.6rem;
  font-size: 1.05rem;
  color: #b03060;
}

.admin-grupo-titulo:first-child { margin-top: 0; }

.admin-error {
  color: #a31621;
  font-weight: 600;
  line-height: 1.5;
}

.admin-error[hidden] { display: none; }

.admin-exito {
  color: #2e9e5b;
  font-weight: 700;
}

.admin-exito[hidden] { display: none; }

.admin-login-texto {
  color: #8a4a63;
  line-height: 1.5;
}

/* ---------- Botones del panel ---------- */

.boton-admin-primario {
  width: 100%;
  background: #e75480;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.boton-admin-primario:disabled {
  background: #f3b8cd;
  cursor: default;
}

.admin-botones {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.7rem;
}

.boton-admin {
  background: #fff;
  border: 1px solid #f9a8c9;
  color: #b03060;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}

.boton-admin:disabled {
  opacity: 0.55;
  cursor: default;
}

.boton-admin-verde {
  background: #2e9e5b;
  border-color: #2e9e5b;
  color: #fff;
}

.boton-admin-peligro {
  border-color: #f3b8cd;
  color: #a31621;
}

.boton-admin-chico {
  padding: 0.3rem 0.7rem;
  font-size: 0.85rem;
}

/* ---------- Insignias ---------- */

.insignia {
  display: inline-block;
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
  font-size: 0.8rem;
  font-weight: 800;
  margin-right: 0.35rem;
}

.insignia-destacado {
  background: #fff3d6;
  color: #8a6d1b;
  border: 1px solid #e8c96a;
}

.insignia-flash {
  background: #ffe3ee;
  color: #d6336c;
  border: 1px solid #f9a8c9;
}

.insignia-bloqueada {
  background: #fde8e8;
  color: #a31621;
  border: 1px solid #f5b5b5;
}

.insignia-duda { background: #e8f0fe; color: #2b4a8f; border: 1px solid #b9cdf5; }
.insignia-queja { background: #fde8e8; color: #a31621; border: 1px solid #f5b5b5; }
.insignia-sugerencia { background: #e6f7ec; color: #1e7a3c; border: 1px solid #a8dcc0; }

/* ---------- Pedidos (admin) ---------- */

.pedido-admin {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.8rem 0.9rem;
  margin-bottom: 0.7rem;
}

/* Filas cebras: las tarjetas alternan el fondo para distinguir un pedido del siguiente. */
.pedido-admin-cebra { background: #ffeef5; }

.pedido-admin-encabezado {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 0.8rem;
  align-items: baseline;
}

.pedido-admin-fecha {
  color: #8a4a63;
  font-size: 0.85rem;
}

.pedido-admin-numero {
  margin: 0.3rem 0 0;
  font-weight: 700;
  color: #b03060;
}

.pedido-admin-items {
  list-style: none;
  margin: 0.6rem 0 0;
  padding: 0;
}

.pedido-admin-items li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.3rem 0;
  font-size: 0.92rem;
  line-height: 1.4;
}

.pedido-admin-items img {
  width: 2.8rem;
  height: 2.8rem;
  object-fit: cover;
  border-radius: 8px;
  background: #ffeef5;
  flex-shrink: 0;
}

.pedido-admin-total {
  margin: 0.6rem 0 0;
  font-weight: 800;
  color: #d6336c;
  font-size: 1.05rem;
}

.pedido-admin-direccion {
  margin: 0.4rem 0 0;
  line-height: 1.5;
}

.pedido-admin-mapa {
  display: inline-block;
  margin-top: 0.35rem;
  color: #d6336c;
  font-weight: 700;
  text-decoration: none;
}

/* Botón Navegar en Pedidos: cajita propia con aire arriba y abajo. */
.pedido-admin-navegar { margin: 0.6rem 0 0.65rem; }

.pedido-admin-metodo { color: #8a4a63; }

.pedido-admin-envio {
  margin: 0.4rem 0 0;
  line-height: 1.5;
}

.pago-pildora {
  display: inline-block;
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.85rem;
  font-weight: 800;
}

.pago-pendiente { background: #fff3d6; color: #8a6d1b; }
.pago-reportado { background: #e8f0fe; color: #2b4a8f; }
.pago-confirmado { background: #e6f7ec; color: #1e7a3c; }

.comprobante-admin-img {
  width: 100%;
  border-radius: 14px;
  display: block;
  background: #ffeef5;
  margin-top: 0.5rem;
}

.comprobante-admin-img:not([src]) { display: none; }

/* ---------- Productos (admin) ---------- */

.producto-admin {
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.7rem 0.8rem;
  margin-bottom: 0.6rem;
  flex-wrap: wrap;
}

.producto-admin > img {
  width: 4rem;
  height: 4rem;
  object-fit: cover;
  border-radius: 10px;
  background: #ffeef5;
  flex-shrink: 0;
}

.producto-admin-sin-foto {
  width: 4rem;
  height: 4rem;
  border-radius: 10px;
  background: #ffeef5;
  color: #c98aa5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  text-align: center;
  flex-shrink: 0;
}

.producto-admin-info { flex: 1; min-width: 10rem; }

.producto-admin-info p { margin: 0.25rem 0 0; }

.producto-admin-stock { color: #8a4a63; font-size: 0.9rem; }

.producto-admin-insignias { margin-top: 0.4rem; }

.producto-admin .admin-botones { margin-top: 0.4rem; }

/* Buscador y "Cargar más" de Productos (admin) */

.admin-buscar-productos { margin-bottom: 0.7rem; }

.admin-buscar-productos input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #f9a8c9;
  border-radius: 999px;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  background: #fff;
  color: #5b2333;
}

.admin-buscar-productos input:focus {
  outline: 2px solid #e75480;
  outline-offset: 1px;
}

.admin-cargar-mas {
  display: block;
  margin: 0.2rem auto 0.6rem;
}

/* Formulario de producto: fotos */

.campo-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.campo-check input {
  width: auto;
  accent-color: #e75480;
}

.producto-fotos { margin-top: 1rem; border-top: 1px solid #ffd6e8; padding-top: 0.75rem; }

.producto-fotos h3 { margin: 0 0 0.6rem; font-size: 1.05rem; }

.producto-fotos-lista {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr));
  gap: 0.6rem;
  margin-bottom: 0.7rem;
}

.producto-foto-item {
  border: 1px solid #ffd6e8;
  border-radius: 12px;
  padding: 0.4rem;
  text-align: center;
  background: #fff;
}

.producto-foto-item img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  display: block;
  background: #ffeef5;
}

.producto-foto-item .insignia,
.producto-foto-item .boton-admin { margin-top: 0.4rem; }

/* ---------- Clientas (admin) ---------- */

.clienta-admin {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.8rem 0.9rem;
  margin-bottom: 0.7rem;
}

.clienta-admin-telefono { margin: 0.25rem 0 0; color: #8a4a63; }

.clienta-admin-corazones {
  margin: 0.4rem 0 0;
  font-size: 1.3rem;
  letter-spacing: 0.2rem;
}

.clienta-admin-corazones .corazon-lleno { color: #e75480; }
.clienta-admin-corazones .corazon-vacio { color: #f3b8cd; }

.clienta-admin-pedidos { margin: 0.35rem 0 0; font-size: 0.92rem; color: #8a4a63; }

.clienta-admin-direcciones {
  list-style: none;
  margin: 0.7rem 0 0;
  padding: 0;
}

.clienta-admin-direcciones[hidden] { display: none; }

.clienta-admin-direcciones li {
  background: rgba(255, 214, 232, 0.5);
  border: 1px solid #ffd6e8;
  border-radius: 10px;
  padding: 0.5rem 0.7rem;
  margin-bottom: 0.4rem;
  line-height: 1.4;
  font-size: 0.92rem;
}

.clienta-admin-direccion-texto { display: block; }

/* Botón Navegar en Clientas: en su propio renglón, con aire sobre el texto. */
.clienta-admin-navegar { display: inline-block; margin-top: 0.45rem; }

/* ---------- Dudas y cambios de número (admin) ---------- */

.duda-admin,
.cambio-admin {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #ffd6e8;
  border-radius: 14px;
  padding: 0.8rem 0.9rem;
  margin-bottom: 0.7rem;
}

.duda-admin-mensaje { margin: 0.6rem 0 0.3rem; line-height: 1.5; }

.duda-admin-quien,
.duda-admin-estado,
.cambio-admin-fecha,
.cambio-admin-estado {
  margin: 0.25rem 0 0;
  color: #8a4a63;
  font-size: 0.9rem;
}

.cambio-admin-numeros {
  margin: 0.4rem 0 0;
  font-weight: 700;
  font-size: 1.05rem;
}

/* ---------- Cambio de número (Mi perfil) ---------- */

.perfil-cambio-numero {
  border-top: 1px solid #ffd6e8;
  margin-top: 1.2rem;
  padding-top: 0.9rem;
}

.perfil-cambio-numero h3 {
  margin: 0 0 0.6rem;
  font-size: 1.05rem;
  color: #5b2a3a;
}

.cambio-numero-nota {
  margin: 0 0 0.8rem;
  color: #8a4a63;
  line-height: 1.5;
}

.cambio-numero-estado {
  color: #8a4a63;
  font-weight: 600;
  line-height: 1.5;
}

.cambio-numero-estado[hidden] { display: none; }

/* ==========================================================================
   HITO 4 — Colores, favoritos y editor de fotos.
   ========================================================================== */

/* --- Corazón de favorito en la tarjeta --- */
.tarjeta { position: relative; }

.tarjeta-favorito {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 2;
  width: 2.1rem;
  height: 2.1rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #8a4a63;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.2);
}

.tarjeta-favorito.activo { color: #e75480; }

/* --- Icono de compartir en la tarjeta (esquina inferior derecha de la foto) --- */
.tarjeta-foto { position: relative; }

.tarjeta-compartir-icono {
  position: absolute;
  right: 0.5rem;
  bottom: 0.5rem;
  z-index: 2;
  width: 2.1rem;
  height: 2.1rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #8a4a63;
  cursor: pointer;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tarjeta-compartir-icono svg { width: 1.15rem; height: 1.15rem; }

/* --- Puntitos de fotos en la tarjeta (se cambian con toque o deslizamiento) --- */
.tarjeta-puntos {
  position: absolute;
  left: 0.4rem;
  right: 3.1rem;
  bottom: 0.55rem;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 0.3rem;
}

.tarjeta-puntos:empty { display: none; }

.tarjeta-puntos button {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  padding: 0;
  cursor: pointer;
}

.tarjeta-puntos button.activo { background: #e75480; }

/* --- Muestras de color (tarjeta y detalle) --- */
.tarjeta-colores,
.detalle-colores {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.45rem 0 0.1rem;
}

.tarjeta-colores:empty,
.detalle-colores:empty { display: none; }

.color-chip {
  width: 1.5rem;
  height: 1.5rem;
  padding: 0;
  border: 2px solid rgba(0, 0, 0, 0.15);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: inset 0 0 0 2px #fff;
}

.color-chip.seleccionado {
  border-color: #c9962e;
  outline: 2px solid #c9962e;
  outline-offset: 1px;
}

.tarjeta-color-elegido,
.detalle-color-elegido {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #8a4a63;
}

.detalle-colores-bloque { margin: 0.8rem 0 0.2rem; }

.detalle-colores-titulo {
  margin: 0 0 0.2rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: #8a4a63;
}

.detalle-color-aviso {
  margin: 0.4rem 0 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: #c0392b;
}

/* --- Corazón en el detalle --- */
.detalle-acciones {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.detalle-acciones .boton-agregar { flex: 1; }

.detalle-favorito {
  flex: 0 0 auto;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid #ffd6e8;
  border-radius: 50%;
  background: #fff;
  color: #8a4a63;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.detalle-favorito.activo {
  color: #e75480;
  border-color: #e75480;
}

/* --- Icono de compartir en el detalle (junto al corazón) --- */
.detalle-compartir-icono {
  flex: 0 0 auto;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid #ffd6e8;
  border-radius: 50%;
  background: #fff;
  color: #8a4a63;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.detalle-compartir-icono svg { width: 1.25rem; height: 1.25rem; }

/* --- Color en el carrito --- */
.carrito-item-color {
  margin: 0.1rem 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #8a4a63;
}

/* --- Favoritos en "Mi perfil" --- */
.perfil-favoritos { margin: 1rem 0; }

.perfil-favoritos h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

#perfil-lista-favoritos {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.favorito-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.4rem 0.5rem;
  border: 1px solid #ffd6e8;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  text-align: left;
}

.favorito-item img {
  width: 3rem;
  height: 3rem;
  object-fit: cover;
  border-radius: 8px;
  background: #ffeef5;
}

.favorito-nombre {
  flex: 1;
  font-size: 0.95rem;
  font-weight: 600;
}

.favorito-precio {
  font-size: 0.9rem;
  color: #8a4a63;
}

.favorito-corazon { color: #e75480; }

/* --- Colores en el formulario de producto (admin) --- */
.campo-colores legend {
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0;
}

.producto-colores {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.4rem;
}

.color-check {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.55rem 0.3rem 0.35rem;
  border: 1px solid #ffd6e8;
  border-radius: 999px;
  background: #fff;
  font-size: 0.85rem;
  cursor: pointer;
}

.color-check input {
  width: 1.05rem;
  height: 1.05rem;
  accent-color: #e75480;
  cursor: pointer;
}

.color-check-muestra {
  width: 1rem;
  height: 1rem;
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 50%;
}

.campo-ayuda {
  margin: 0.4rem 0 0;
  font-size: 0.85rem;
  color: #8a4a63;
}

/* --- Editor de fotos (admin) --- */
.editor-foto-contenido { max-width: 560px; }

.editor-foto-ayuda {
  margin: 0.2rem 0 0.8rem;
  font-size: 0.9rem;
  color: #8a4a63;
}

.editor-foto-area {
  position: relative;
  display: inline-block;
  max-width: 100%;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.editor-foto-area canvas {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  background: #ffeef5;
}

.editor-foto-recorte {
  position: absolute;
  border: 2px dashed #e75480;
  background: rgba(231, 84, 128, 0.12);
  pointer-events: none;
}

/* --- Numeritos en el editor de fotos --- */
/* El botón es un circulito rosa con el siguiente número: se arrastra a la
   foto para colocarlo. Los números ya puestos son circulitos iguales sobre
   la foto; se arrastran para moverlos y al tocarlos se seleccionan. */
.editor-numero-boton {
  min-width: 2.4rem;
  height: 2.4rem;
  padding: 0 0.4rem;
  border-radius: 999px;
  border: 2px solid #fff;
  background: #e75480;
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  flex-shrink: 0;
}

.editor-numero-boton.arrastrando {
  opacity: 0.7;
  cursor: grabbing;
  transform: scale(1.1);
}

#editor-foto-numero-quitar {
  color: #c62828;
  border-color: #ef9a9a;
}

/* Botones − / + para el tamaño del numerito seleccionado: blancos grandes
   para tocarlos con el dedo; solo se ven cuando hay un número tocado. */
.editor-numero-tamano {
  min-width: 2.4rem;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
}

.editor-foto-numeros {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.editor-foto-numero-colocado {
  position: absolute;
  transform: translate(-50%, -50%);
  /* Chicos y discretos, como los circulitos de modelos de las tarjetas:
     que se lean bien pero sin tapar la pieza del producto. El tamaño se
     ajusta con los botones − / + (variable --num-t, 1 = tamaño chico). */
  min-width: calc(1.7rem * var(--num-t, 1));
  height: calc(1.7rem * var(--num-t, 1));
  padding: 0 0.35rem;
  border-radius: 999px;
  border: 2px solid #fff;
  background: #e75480;
  color: #fff;
  font-weight: 700;
  font-size: calc(0.9rem * var(--num-t, 1));
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
}

.editor-foto-numero-colocado.seleccionado {
  outline: 3px solid #ffd34d;
  outline-offset: 1px;
}

.editor-foto-numero-colocado.fuera-recorte { opacity: 0.35; }

.editor-numero-fantasma {
  position: fixed;
  z-index: 9999;
  transform: translate(-50%, -50%);
  /* Igual de chico que el número ya puesto: lo que se ve es lo que queda. */
  min-width: 1.7rem;
  height: 1.7rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  border: 2px solid #fff;
  background: #e75480;
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.editor-foto-botones {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.editor-foto-acciones {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.editor-foto-acciones .boton-admin-primario { flex: 1; }

/* --- Editor de fotos a pantalla completa en teléfono --- */
/* El modal centrado quedaba más alto que la parte visible (la barra del
   navegador recorta las unidades vh) y los botones Guardar/Cancelar
   quedaban cortados abajo: había que desplazar la ventana para llegar a
   ellos. En móvil el editor ocupa toda la pantalla (100dvh con respaldo
   100vh), la foto se achica sola al espacio que queda y los botones de
   acción quedan siempre visibles sin desplazar. */
@media (max-width: 640px) {
  .editor-foto-contenido {
    width: 100%;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    margin: 0;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 1rem 1rem calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }

  .editor-foto-contenido h2,
  .editor-foto-ayuda { flex-shrink: 0; }

  /* El área no crece más que la foto: así el rectángulo de recorte, que se
     posiciona en % del área, sigue calzando exacto con el lienzo. */
  .editor-foto-area {
    flex: 0 1 auto;
    min-height: 0;
    align-self: center;
    overflow: hidden;
  }

  .editor-foto-area canvas {
    max-height: calc(100vh - 19.5rem);
    max-height: calc(100dvh - 19.5rem);
  }

  .editor-foto-botones { flex-shrink: 0; }

  .editor-foto-acciones {
    flex-shrink: 0;
    margin-top: auto;
    padding-top: 0.8rem;
    background: #fff9fb;
  }
}

/* __VERIF26__ stock, destacado, % OFF, modelos, compartir y visor. */
.tarjeta-stock {
  margin: 0.2rem 0 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #2e7d32;
}
.tarjeta-stock.agotado { color: #c62828; }
.tarjeta-agregar:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.insignia-destacado {
  display: inline-block;
  margin: 0.2rem 0;
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  background: #fff3cd;
  color: #8a6d00;
  border: 1px solid #c9962e;
  font-size: 0.8rem;
  font-weight: 700;
}
.etiqueta-off {
  display: inline-block;
  margin-left: 0.3rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  /* Amarillo tenue (Jose, 27 nov 07:55): antes era rosa #e75480. */
  background: #fff3cd;
  color: #8a6d00;
  font-size: 0.8rem;
  font-weight: 700;
}

/* Descuento en vivo en el formulario de producto (misma etiqueta amarilla
   tenue de las tarjetas; se oculta cuando no hay descuento válido). */
.campo-descuento { margin: 0 0 0.85rem; }

.campo-descuento .etiqueta-off {
  margin-left: 0;
  font-size: 0.95rem;
  padding: 0.25rem 0.65rem;
}
.precio-anterior { color: #8a4a63; }
.modelos-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  align-items: center;
  margin: 0.3rem 0 0.5rem;
}
.modelos-etiqueta { font-size: 0.85rem; font-weight: 600; color: #5b2a3a; }
.modelo-boton {
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  border: 1.5px solid #e75480;
  background: #fff;
  color: #e75480;
  font-weight: 700;
  cursor: pointer;
}
.modelo-boton.activo { background: #e75480; color: #fff; }
.modelo-boton.modelo-todos { padding: 0 0.8rem; background: #fff0f5; }
.modelo-boton.agotado,
.modelo-boton:disabled { background: #f0ecee; color: #b8adb2; border-color: #e2d9dd; cursor: not-allowed; }

/* --- Indicador de modelos en la tarjeta (solo muestra, no elige) --- */
.modelos-indicador {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  align-items: center;
  margin: 0.3rem 0 0.5rem;
}
.modelo-indicador {
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  border: 1.5px solid #e75480;
  background: #fff;
  color: #e75480;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}
.modelo-indicador.activo { background: #e75480; color: #fff; }
.modelos-texto { font-size: 0.9rem; font-weight: 600; color: #5b2a3a; }
.modelo-aviso {
  margin: 0.2rem 0 0.4rem;
  color: #c62828;
  font-size: 0.85rem;
  font-weight: 600;
}
.modelo-aviso[hidden] { display: none; }
.tarjeta-compartir, .boton-compartir {
  margin-top: 0.4rem;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  border: 1.5px solid #25d366;
  background: #fff;
  color: #128c4a;
  font-weight: 700;
  cursor: pointer;
}
.tarjeta-compartir { width: 100%; }
.detalle-stock { margin: 0.3rem 0; }
.detalle-stock .tarjeta-stock { margin: 0; }
.detalle-destacado {
  margin: 0.3rem 0;
  font-weight: 700;
  color: #8a6d00;
}
.detalle-modelos-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.4rem 0;
}
.detalle-modelos-picker[hidden] { display: none; }
.visor[hidden] { display: none; }
.visor {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
}
.visor-fondo {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
}
.visor-foto {
  position: relative;
  max-width: 94vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 8px;
}
.visor-cerrar {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  border: none;
  background: #fff;
  color: #5b2a3a;
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
}
.visor-flecha {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.9);
  color: #5b2a3a;
  font-size: 1.5rem;
  font-weight: 700;
  cursor: pointer;
}
.visor-anterior { left: 0.6rem; }
.visor-siguiente { right: 0.6rem; }
.visor-contador {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  margin: 0;
  color: #fff;
  font-weight: 600;
}

/* ---------- Formulario de producto (igual que la app original) ---------- */

#formulario-producto {
  margin-top: 0.2rem;
  /* Que el final del formulario no quede pegado a la lista de productos:
     espacio generoso + línea divisoria rosa sutil. */
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid #f9d3e2;
}

#formulario-producto h2 {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.45rem;
  color: #4a2525;
  margin: 0 0 1rem;
}

#formulario-producto .campo > span { color: #4a2525; }

#formulario-producto .campo input,
#formulario-producto .campo select,
#formulario-producto .campo textarea {
  background: #fdf6f3;
  border: 1px solid #e7cbc4;
}

#formulario-producto .campo input::placeholder,
#formulario-producto .campo textarea::placeholder { color: #b08d94; }

#formulario-producto .campo input:focus,
#formulario-producto .campo select:focus,
#formulario-producto .campo textarea:focus { border-color: #e75480; }

#formulario-producto .campo-ayuda { margin-bottom: 0.85rem; color: #8a6d6d; }

.campo-fila-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 0.7rem; }

/* Stock por modelo en el formulario: campos chicos, dos por renglón. */
.stock-modelos-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.7rem; }
.stock-modelos-grid .campo { margin-bottom: 0; }

/* "Cantidad que hay" cuando muestra el total (suma) de los modelos:
   solo lectura, se suma solo. */
.campo input.solo-lectura { background: #f7f0f3; color: #8a6a78; }

.campo-corto input { width: 9rem; max-width: 100%; }

/* Pestañas del formulario de producto: Disponible, Destacado, Oferta
   relámpago (igual que las pestañas de pago del checkout). */
.producto-pestanas { display: flex; gap: 0.5rem; margin: 0.4rem 0 0.6rem; }
.producto-pestana {
  flex: 1;
  background: #fff;
  border: 2px solid #ffd6e8;
  border-radius: 999px;
  padding: 0.55rem 0.4rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #8a4a63;
  cursor: pointer;
}
.producto-pestana-activa { background: #e75480; border-color: #e75480; color: #fff; }

#producto-oferta-campos {
  border: 1.5px solid #d4a017;
  border-radius: 16px;
  background: #fdf8ee;
  padding: 0.8rem 0.9rem;
  margin-top: 0.2rem;
}
#producto-oferta-campos .campo { margin-bottom: 0.6rem; }
#producto-oferta-campos .campo:last-child { margin-bottom: 0; }

.formulario-botones { display: flex; gap: 0.7rem; margin-top: 0.9rem; }
.formulario-botones .boton-admin-primario { flex: 1; width: auto; background: #d81b60; padding: 0.85rem 0.8rem; font-size: 1.05rem; }
#boton-cancelar-producto {
  background: #fff; border: 1px solid #d8c2bc; color: #4a2525;
  border-radius: 999px; padding: 0.85rem 1.4rem;
  font-size: 1rem; font-weight: 700; cursor: pointer;
}

.producto-fotos-zona { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: stretch; }
.producto-fotos-lista { display: contents; }
.producto-foto-vacia {
  width: 96px; height: 96px; flex: 0 0 96px;
  border-radius: 16px; background: #fbe3de;
  display: flex; align-items: center; justify-content: center;
}
.elegir-fotos {
  width: 96px; min-height: 96px; flex: 0 0 96px;
  border: 1.5px dashed #d8a7a0; border-radius: 16px; background: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.1rem;
  cursor: pointer; color: #d81b60; font-weight: 700; font-size: 0.85rem; text-align: center;
  padding: 0.4rem;
}
.elegir-fotos-mas { font-size: 2rem; line-height: 1; color: #5b2a3a; font-weight: 400; }
.producto-fotos-zona .producto-foto-item { flex: 0 0 110px; }

/* Colores: píldoras con muestra, sin casilla visible */
.color-check { padding: 0.45rem 0.85rem 0.45rem 0.55rem; gap: 0.5rem; border: 1px solid #eccfc9; font-size: 0.92rem; font-weight: 600; color: #4a2525; }
.color-check input { position: absolute; opacity: 0; width: 0; height: 0; margin: 0; }
.color-check-muestra { width: 1.15rem; height: 1.15rem; }
.color-check.seleccionado { background: #fdeef3; border-color: #e75480; }
.producto-colores { gap: 0.5rem; }

.insignia-no-disponible { background: #ececec; color: #666; }

/* --- Mi perfil a pantalla completa en teléfono --- */
/* Como el editor de fotos: el modal centrado quedaba más alto que la parte
   visible y el botón de abajo ("Solicitar cambio") quedaba cortado. En
   móvil Mi perfil ocupa toda la pantalla (100dvh con respaldo 100vh) y el
   contenido se desplaza por dentro; el botón ✕ queda fijo arriba. */
@media (max-width: 640px) {
  #modal-perfil .modal-contenido {
    width: 100%;
    max-width: none;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    margin: 0;
    border-radius: 0;
    overflow-y: auto;
    padding: 1rem 1rem calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }

  /* El ✕ es absoluto y se iría con el desplazamiento: fijo arriba. */
  #modal-perfil .modal-cerrar {
    position: fixed;
    top: 0.6rem;
    right: 0.6rem;
  }
}

/* Corazones redondos (SVG) en Mi perfil y en Clientas del panel. */
.perfil-corazones svg,
.clienta-admin-corazones svg {
  width: 1.5rem;
  height: 1.5rem;
  vertical-align: -0.35rem;
}

.perfil-corazones .corazon-lleno svg { fill: #e75480; }
.perfil-corazones .corazon-vacio svg { fill: #f3b8cd; }
.clienta-admin-corazones .corazon-lleno svg { fill: #e75480; }
.clienta-admin-corazones .corazon-vacio svg { fill: #f3b8cd; }

/* Explicación de los corazones en Mi perfil. */
.perfil-corazones-ayuda {
  margin: 0.45rem 0 0;
  font-size: 0.85rem;
  line-height: 1.45;
  color: #8a4a63;
}
