/* Plantilla "pasillos" v1 — tienda online de Zenit.
   Hogar y bazar: el inicio se recorre como el local. Franja de sectores con íconos, portada a sangre con
   canto de madera, y las categorías como PASILLOS (franjas que alternan fondo claro y madera, con el cartel
   del sector a la izquierda y sus productos a la derecha). Bricolage Grotesque + Nunito Sans.
   Variables estándar que pisa el núcleo con la paleta: --fondo --texto --acento --secundario --destacado
   y --sobre-*. html[data-paleta="oscura"] = Ébano. El checkout y el pedido los dibuja el núcleo con
   clases estándar: acá solo se estilan. Cada bloque de #vista se centra solo, salvo los .ancho-completo. */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body, h1, h2, h3, h4, p, figure, dl, dd, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: none; cursor: pointer; padding: 0; }

:root {
  --fondo: #F4EEE4;
  --texto: #2B241D;
  --acento: #2B241D;
  --secundario: #E6D6BD;
  --destacado: #E2AE5F;
  --sobre-acento: #fff;
  --sobre-secundario: #1a1a1a;
  --sobre-destacado: #1a1a1a;
  --suave: color-mix(in srgb, var(--texto) 64%, var(--fondo));
  --linea: color-mix(in srgb, var(--texto) 15%, var(--fondo));
  --tarjeta: color-mix(in srgb, #ffffff 60%, var(--fondo));
  /* "cartel": superficies oscuras (íconos de pasillo, portada sin foto, resumen, pie). */
  --oscuro: color-mix(in srgb, var(--texto) 92%, #000);
  --sobre-oscuro: var(--fondo);
  /* madera del canto (material fijo de la plantilla) */
  --madera: repeating-linear-gradient(90deg, #8C6B48 0 3px, #A07D57 3px 12px, #93714D 12px 14px, #A88661 14px 28px);
  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  --f: "Nunito Sans", "Segoe UI", system-ui, sans-serif;
  --ancho: 1280px;
  --margen: clamp(16px, 4vw, 32px);
  --radio: 18px;
  color-scheme: light;
}
:root[data-paleta="oscura"] { --oscuro: var(--secundario); --sobre-oscuro: var(--texto); --tarjeta: color-mix(in srgb, #ffffff 6%, var(--fondo)); }

body { background: var(--fondo); color: var(--texto); font-family: var(--f); font-size: 1rem; line-height: 1.55; -webkit-font-smoothing: antialiased; min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; }
h1, h2, h3, .titulo-pagina, .form legend { font-family: var(--display); font-weight: 800; letter-spacing: -0.025em; line-height: 1; text-wrap: balance; }
.precio { font-family: var(--display); font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.mono { font-variant-numeric: tabular-nums; letter-spacing: 0.04em; }
.rotulo { font-size: 0.78rem; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--suave); }
.wrap { width: 100%; max-width: var(--ancho); margin: 0 auto; padding: 0 var(--margen); }
.visualmente-oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.centro { text-align: center; }
:focus-visible { outline: 3px solid var(--destacado); outline-offset: 2px; }
::selection { background: var(--destacado); color: var(--sobre-destacado); }
[hidden] { display: none !important; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition-duration: 0.001ms !important; animation-duration: 0.001ms !important; } }

/* Cada bloque de #vista se centra con el ancho de la tienda (incluye lo que dibuja el núcleo). */
#vista > * { width: 100%; max-width: var(--ancho); margin-inline: auto; padding-inline: var(--margen); }
#vista > .ancho-completo { max-width: none; padding-inline: 0; }
#vista > .pedido { max-width: calc(680px + 2 * var(--margen)); }

/* ---------- cabecera: sectores · marca centrada · carrito ---------- */
.cabecera { position: sticky; top: 0; z-index: 30; background: var(--fondo); border-bottom: 1px solid var(--linea); }
.cabecera-fila { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; padding-block: 0.75rem; }
.btn-sectores { justify-self: start; display: inline-flex; align-items: center; gap: 0.6rem; border: 1.5px solid var(--linea); background: var(--tarjeta); border-radius: 999px; padding: 0.55rem 1rem; font-weight: 800; font-size: 0.9rem; }
.btn-sectores svg { width: 18px; height: 18px; }
.marca { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--display); font-weight: 800; font-size: clamp(1.35rem, 3vw, 1.85rem); letter-spacing: -0.03em; line-height: 1; max-width: 56vw; }
.marca span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.marca-techo { width: 30px; height: 22px; flex: none; color: var(--destacado); }
.bolsa { justify-self: end; position: relative; width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--linea); background: var(--tarjeta); display: grid; place-items: center; }
.bolsa svg { width: 21px; height: 21px; }
.contador { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--acento); color: var(--sobre-acento); font-size: 0.7rem; font-weight: 800; display: grid; place-items: center; font-variant-numeric: tabular-nums; }

/* ---------- botones y enlaces ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 50px; padding: 0 1.6rem; border-radius: 999px; border: 0; background: var(--secundario); color: var(--texto); font-weight: 800; font-size: 0.97rem; transition: transform 0.15s ease, filter 0.15s ease; }
.btn:hover:not(:disabled) { transform: translateY(-1px); filter: brightness(1.06); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primario { background: var(--acento); color: var(--sobre-acento); }
.btn-ambar { background: var(--destacado); color: var(--sobre-destacado); }
.btn-borde { background: transparent; box-shadow: inset 0 0 0 1.5px var(--linea); }
.btn-bloque { width: 100%; }
.enlace { font-weight: 800; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--destacado); }
.ver-todo { font-weight: 800; font-size: 0.95rem; border-bottom: 2.5px solid var(--destacado); padding-bottom: 2px; white-space: nowrap; }

/* ---------- franja de sectores ---------- */
.sectores { background: var(--tarjeta); border-bottom: 1px solid var(--linea); }
.sectores ul { display: flex; gap: 0.25rem; overflow-x: auto; scrollbar-width: none; padding-block: 0.7rem; }
.sectores ul::-webkit-scrollbar { display: none; }
.sectores li { flex: 1 0 96px; }
.sector-btn { width: 100%; display: grid; justify-items: center; gap: 0.4rem; padding: 0.35rem 0.4rem; border-radius: 12px; font-weight: 700; font-size: 0.82rem; text-align: center; }
.sector-ic { width: 48px; height: 48px; border-radius: 50%; background: var(--secundario); display: grid; place-items: center; transition: background-color 0.15s ease; }
.sector-ic svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.sector-btn:hover .sector-ic { background: var(--destacado); color: var(--sobre-destacado); }
.sector-nombre { line-height: 1.2; overflow-wrap: anywhere; }

/* ---------- secciones (ver tienda/plantillas/FORMATO.md) ---------- */
.sec { padding-block: clamp(2.2rem, 5vw, 3.4rem); }
.sec-cab { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1.3rem; flex-wrap: wrap; }
.sec-cab h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); }

.sec-portada { position: relative; min-height: clamp(380px, 52vw, 560px); display: grid; align-items: end; background: var(--oscuro); color: var(--sobre-oscuro); overflow: hidden; }
.portada-foto { position: absolute; inset: 0; }
.portada-foto img { width: 100%; height: 100%; object-fit: cover; }
.sec-portada::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(20, 15, 10, .82) 0%, rgba(20, 15, 10, .35) 60%, rgba(20, 15, 10, 0) 100%); pointer-events: none; }
.portada-texto { position: relative; z-index: 1; display: grid; gap: 1.1rem; justify-items: start; padding-block: clamp(2.5rem, 7vw, 5rem) calc(clamp(2.5rem, 7vw, 5rem) + 22px); }
.portada-texto h1 { font-size: clamp(2.6rem, 6vw, 4.8rem); max-width: 14ch; }
.portada-texto .descripcion { font-size: 1.1rem; max-width: 44ch; color: inherit; opacity: 0.9; }
.con-imagen .portada-texto { color: #F6F1E9; }
.portada-canto { position: absolute; left: 0; right: 0; bottom: 0; height: 22px; background: var(--madera); z-index: 1; }

.sec-anuncio { padding: 0.55rem var(--margen); background: var(--destacado); color: var(--sobre-destacado); text-align: center; font-weight: 800; font-size: 0.88rem; }

/* el núcleo la dibuja: acá solo el tono de la plantilla */
.sec-beneficios { background: none; border-radius: 0; border-bottom: 1px solid var(--linea); padding: 1.3rem 0; margin: 0; }
.beneficio-icono { border-radius: 12px; background: var(--secundario); color: var(--texto); }
.beneficio-texto b { font-weight: 800; }

.carrusel { display: grid; grid-auto-flow: column; grid-auto-columns: min(88%, 760px); gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 0.5rem; }
.diapositiva { position: relative; display: block; aspect-ratio: 16 / 9; scroll-snap-align: start; overflow: hidden; border-radius: var(--radio); background: var(--oscuro); }
.diapositiva img { width: 100%; height: 100%; object-fit: cover; }
.carrusel-titulo { position: absolute; left: 1rem; bottom: 1rem; padding: 0.45rem 0.95rem; border-radius: 999px; background: var(--destacado); color: var(--sobre-destacado); font-weight: 800; }

/* ---------- PASILLOS (sección categorías) ---------- */
.pasillo { padding-block: clamp(2rem, 5vw, 3.4rem); }
.pasillo:nth-child(even) { background: var(--secundario); }
.pasillo-fila { display: grid; grid-template-columns: minmax(0, 290px) minmax(0, 1fr); gap: clamp(1.25rem, 3.5vw, 2.75rem); align-items: start; }
.cartel { position: sticky; top: 6.5rem; display: grid; gap: 0.85rem; justify-items: start; }
.cartel-num { font-size: 0.78rem; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--suave); }
.cartel-ic { width: 64px; height: 64px; border-radius: 18px; background: var(--oscuro); color: var(--destacado); display: grid; place-items: center; }
.cartel-ic svg { width: 34px; height: 34px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.cartel h2 { font-size: clamp(2rem, 3.8vw, 3rem); overflow-wrap: anywhere; }
.cartel-ver { font-weight: 800; border-bottom: 2.5px solid var(--destacado); padding-bottom: 2px; text-align: left; }
.fila { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }

.estrella { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: var(--oscuro); color: var(--sobre-oscuro); border-radius: var(--radio); overflow: hidden; }
.estrella-foto { min-height: 420px; }
.estrella-foto .foto { height: 100%; aspect-ratio: auto; border-radius: 0; }
.estrella-texto { padding: clamp(1.75rem, 5vw, 3.5rem); display: grid; align-content: center; gap: 1rem; justify-items: start; }
.estrella-texto .rotulo { color: var(--destacado); }
.estrella-texto h2 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); }
.estrella-texto .descripcion { color: inherit; opacity: 0.82; max-width: 42ch; }
.estrella-precio { font-size: 1.5rem; display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }

.sec-nosotros { display: grid; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; }
.sec-nosotros.con-imagen { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.sec-nosotros img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radio); }
.nosotros-texto { display: grid; gap: 0.9rem; max-width: 60ch; }
.nosotros-texto h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); }
.nosotros-texto .descripcion { color: var(--texto); font-size: 1.06rem; }

.pasos { counter-reset: paso; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.pasos li { counter-increment: paso; display: grid; gap: 0.35rem; align-content: start; padding: 1.5rem; border-radius: var(--radio); background: var(--tarjeta); }
.pasos li::before { content: counter(paso); width: 40px; height: 40px; border-radius: 12px; background: var(--oscuro); color: var(--destacado); display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 1.2rem; margin-bottom: 0.4rem; }
.pasos b { font-size: 1.1rem; font-weight: 800; }
.pasos span { color: var(--suave); }

.testimonios { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.testimonio { padding: 1.5rem; border-radius: var(--radio); background: var(--tarjeta); display: grid; gap: 0.9rem; align-content: space-between; }
.testimonio blockquote { font-size: 1.12rem; font-weight: 600; line-height: 1.4; }
.testimonio figcaption { color: var(--suave); font-size: 0.88rem; font-weight: 800; }

.sec-ubicacion { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; padding: clamp(1.4rem, 4vw, 2rem); border-radius: var(--radio); background: var(--secundario); }
.ubicacion-dir { font-family: var(--display); font-size: 1.4rem; font-weight: 800; margin-top: 0.25rem; }

/* ---------- catálogo ---------- */
.herramientas { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-bottom: 0.9rem; }
.buscador-caja { flex: 1 1 260px; display: flex; align-items: center; gap: 0.6rem; padding: 0 1.1rem; min-height: 50px; border-radius: 999px; border: 1.5px solid var(--linea); background: var(--tarjeta); color: var(--suave); }
.buscador-caja svg { width: 18px; height: 18px; flex: none; }
.buscador { width: 100%; padding: 0.7rem 0; border: 0; background: transparent; outline: 0; color: var(--texto); }
.buscador::placeholder { color: var(--suave); }
.orden select { min-height: 50px; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--linea); background: var(--tarjeta); color: var(--texto); font-weight: 700; }
.chips { display: flex; gap: 0.45rem; overflow-x: auto; scrollbar-width: thin; padding-bottom: 0.4rem; margin-bottom: 1.3rem; }
.chip { flex: none; padding: 0.55rem 1.05rem; border-radius: 999px; background: var(--tarjeta); font-weight: 700; font-size: 0.92rem; }
.chip[aria-pressed="true"] { background: var(--acento); color: var(--sobre-acento); }

/* ---------- tarjetas ---------- */
.grilla { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.75rem 1rem; }
.tarjeta { display: grid; gap: 0.35rem; align-content: start; min-width: 0; }
.tarjeta-foto { position: relative; margin-bottom: 0.45rem; }
.foto { aspect-ratio: 4 / 5; display: grid; place-items: center; background: var(--c, var(--secundario)); color: var(--texto); overflow: hidden; max-width: 100%; border-radius: var(--radio); }
.pasillo:nth-child(even) .foto { background: var(--tarjeta); }
.foto img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.tarjeta:hover .foto img { transform: scale(1.04); }
.foto .inicial { font-family: var(--display); font-weight: 800; font-size: 3.4rem; color: color-mix(in srgb, var(--texto) 25%, var(--secundario)); }
.etiqueta { position: absolute; top: 0.75rem; left: 0.75rem; padding: 0.25rem 0.7rem; border-radius: 999px; font-size: 0.75rem; font-weight: 800; }
.etiqueta-alerta { background: var(--oscuro); color: var(--sobre-oscuro); }
.etiqueta-gris { background: var(--fondo); color: var(--suave); }
.rapido { position: absolute; right: 0.75rem; bottom: 0.75rem; width: 42px; height: 42px; border-radius: 50%; background: var(--acento); color: var(--sobre-acento); display: grid; place-items: center; font-size: 1.35rem; font-weight: 700; box-shadow: 0 6px 14px -6px rgba(0, 0, 0, .5); transition: transform 0.15s ease; }
.rapido:hover { transform: scale(1.08); }
.rapido-ok { display: none; font-size: 1.05rem; }
.rapido[data-agregado] { background: var(--destacado); color: var(--sobre-destacado); }
.rapido[data-agregado] .rapido-mas { display: none; }
.rapido[data-agregado] .rapido-ok { display: block; }
.tarjeta-nombre { font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.tarjeta-nombre:hover { text-decoration: underline; text-decoration-color: var(--destacado); text-underline-offset: 3px; }
.tarjeta .precio { font-size: 1.15rem; }
.estado { font-size: 0.82rem; font-weight: 800; }
.estado-ultimas { color: color-mix(in srgb, var(--destacado) 45%, var(--texto)); }
.estado-agotado { color: var(--suave); }
.vacio { padding: 3rem 0; color: var(--suave); }
.cargando { padding: 4rem 0; color: var(--suave); text-align: center; }

/* ---------- producto ---------- */
.migas { padding-block: 1.3rem 1rem; color: var(--suave); font-size: 0.92rem; }
.migas a:hover { color: var(--texto); }
.producto { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(1.5rem, 4.5vw, 3.5rem); padding-bottom: 3rem; align-items: start; }
.galeria { display: grid; gap: 0.75rem; min-width: 0; }
.galeria.con-miniaturas { grid-template-columns: 84px minmax(0, 1fr); }
.galeria.con-miniaturas .foto-grande { grid-column: 2; grid-row: 1; }
.galeria.con-miniaturas .miniaturas { grid-column: 1; grid-row: 1; grid-template-columns: minmax(0, 1fr); align-content: start; }
.galeria > .foto { aspect-ratio: 4 / 5; border-radius: 22px; }
/* Página del producto: la foto principal se ve COMPLETA (sin recortar); el fondo madera completa lo que sobre. */
.foto-grande img { object-fit: contain; }
.galeria .inicial { font-size: 6rem; }
.miniaturas { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0.6rem; }
.miniatura { aspect-ratio: 1; overflow: hidden; border-radius: 12px; background: var(--secundario); border: 2px solid transparent; }
.miniatura img { width: 100%; height: 100%; object-fit: cover; }
.miniatura[aria-pressed="true"] { border-color: var(--texto); }
.ficha { display: grid; gap: 1.1rem; position: sticky; top: 6rem; }
.pasillo-tag { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 800; font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--suave); }
.pasillo-tag span { width: 34px; height: 34px; border-radius: 10px; background: var(--oscuro); color: var(--destacado); display: grid; place-items: center; }
.pasillo-tag svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ficha h1 { font-size: clamp(2rem, 3.8vw, 2.9rem); }
.ficha-precio { display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap; }
.ficha-precio .precio { font-size: 2rem; }
.descripcion { white-space: pre-line; color: var(--suave); max-width: 60ch; }
.grupo { display: grid; gap: 0.55rem; }
.grupo-titulo { font-weight: 800; font-size: 0.9rem; }
.opciones { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.opcion { min-height: 46px; padding: 0.4rem 1.1rem; border-radius: 999px; background: var(--tarjeta); font-weight: 700; }
.opcion:hover:not(:disabled) { box-shadow: inset 0 0 0 1.5px var(--texto); }
.opcion[aria-pressed="true"] { background: var(--acento); color: var(--sobre-acento); }
.opcion:disabled { color: color-mix(in srgb, var(--texto) 35%, var(--fondo)); text-decoration: line-through; cursor: not-allowed; }
.fila-compra { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.6rem; }
.cantidad { display: inline-flex; align-items: center; border-radius: 999px; background: var(--tarjeta); }
.cantidad button { width: 44px; height: 50px; font-size: 1.2rem; }
.cantidad output { min-width: 2rem; text-align: center; font-weight: 800; font-variant-numeric: tabular-nums; }
.cantidad-chica button { width: 34px; height: 36px; font-size: 1.05rem; }
.entrega { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.6rem; }
.entrega-item { display: grid; gap: 0.2rem; padding: 0.9rem 1rem; border-radius: 16px; background: var(--tarjeta); font-size: 0.92rem; }
.entrega-item svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 0.2rem; }
.entrega-item span { color: var(--suave); }
.aviso { padding: 0.8rem 1rem; border-radius: 12px; background: var(--secundario); font-weight: 700; font-size: 0.95rem; }
.aviso-ok { background: color-mix(in srgb, var(--destacado) 35%, var(--fondo)); }

/* ---------- carrito (página y panel) ---------- */
.titulo-pagina { font-size: clamp(2.2rem, 4.4vw, 3.2rem); margin-block: 1.6rem 1.2rem; }
.carrito { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 2rem; padding-bottom: 3.5rem; align-items: start; }
.lineas { display: grid; gap: 0.75rem; align-content: start; }
.linea { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 0.9rem; padding: 0.75rem; border-radius: var(--radio); background: var(--tarjeta); }
.linea-foto { display: block; width: 92px; aspect-ratio: 1; border-radius: 12px; background: var(--secundario); overflow: hidden; }
.linea-foto .foto { width: 100%; height: 100%; aspect-ratio: 1; border-radius: 12px; }
.linea-foto .foto .inicial { font-size: 2rem; }
.linea-info { display: grid; gap: 0.2rem; align-content: start; min-width: 0; }
.linea-detalle { color: var(--suave); font-size: 0.9rem; }
.linea-pie { display: flex; justify-content: space-between; align-items: center; gap: 0.6rem; margin-top: 0.4rem; }
.linea .cantidad { background: var(--fondo); }
.quitar { color: var(--suave); font-size: 0.85rem; text-decoration: underline; text-underline-offset: 3px; justify-self: start; margin-top: 0.2rem; }
.resumen { display: grid; gap: 0.9rem; padding: 1.5rem; border-radius: 22px; background: var(--oscuro); color: var(--sobre-oscuro); position: sticky; top: 6rem; }
.resumen .linea-detalle { color: inherit; opacity: 0.72; }
.resumen-titulo { font-size: 1.5rem; }
.totales { display: grid; gap: 0.45rem; font-variant-numeric: tabular-nums; }
.totales div { display: flex; justify-content: space-between; gap: 1rem; font-weight: 600; }
.totales .total { padding-top: 0.7rem; border-top: 1px solid color-mix(in srgb, var(--sobre-oscuro) 18%, transparent); font-size: 1.2rem; font-weight: 800; }
.resumen .envio-gratis-barra { background: color-mix(in srgb, var(--sobre-oscuro) 18%, transparent); }
.resumen .envio-gratis-barra span { background: var(--destacado); }

.panel-carrito { position: fixed; inset: 0; z-index: 50; }
.panel-velo { position: absolute; inset: 0; background: color-mix(in srgb, #000 45%, transparent); }
.panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(460px, 100%); display: flex; flex-direction: column; background: var(--fondo); padding-bottom: env(safe-area-inset-bottom, 0px); animation: entra-panel 0.24s ease-out; }
@keyframes entra-panel { from { transform: translateX(30px); opacity: 0.5; } to { transform: none; opacity: 1; } }
.panel-cab { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.2rem; border-bottom: 1px solid var(--linea); }
.panel-cab h2 { font-size: 1.7rem; }
.panel-cerrar { width: 42px; height: 42px; border-radius: 50%; background: var(--tarjeta); font-size: 1.5rem; line-height: 1; }
.panel-cuerpo { flex: 1; overflow-y: auto; padding: 0.9rem 1.2rem; }
.panel-pie { margin: 0 0.9rem 0.9rem; position: static; }
.panel-pie .resumen-titulo { display: none; }
body.con-panel-carrito { overflow: hidden; }

/* ---------- checkout (lo dibuja el núcleo) ---------- */
.checkout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(1.5rem, 4vw, 3rem); padding-bottom: 4rem; align-items: start; }
.form { display: grid; gap: 1.4rem; }
.form fieldset { border: 0; padding: 1.3rem; border-radius: var(--radio); background: var(--tarjeta); display: grid; gap: 0.95rem; margin: 0; min-width: 0; }
.form legend { float: left; width: 100%; padding: 0 0 0.4rem; font-size: 1.45rem; }
.campo { display: grid; gap: 0.35rem; }
.campo label { font-size: 0.92rem; font-weight: 700; }
.campo input, .campo select, .campo textarea { width: 100%; padding: 0.75rem 0.95rem; min-height: 50px; border: 1.5px solid var(--linea); border-radius: 12px; background: var(--fondo); color: var(--texto); }
.campo input:focus, .campo select:focus, .campo textarea:focus { border-color: var(--texto); outline: none; }
.campo textarea { min-height: 88px; resize: vertical; }
.campo .ayuda { font-size: 0.8rem; font-weight: 500; color: var(--suave); }
.dos { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.9rem; }
.radios { display: grid; gap: 0.5rem; }
.radio { display: flex; align-items: center; gap: 0.6rem; padding: 0.85rem 1rem; border: 1.5px solid var(--linea); border-radius: 12px; background: var(--fondo); cursor: pointer; }
.radio:has(input:checked) { border-color: var(--texto); box-shadow: inset 0 0 0 1px var(--texto); }
.radio input { accent-color: var(--acento); width: 18px; height: 18px; }

/* ---------- estado del pedido (lo dibuja el núcleo) ---------- */
.pedido { max-width: 680px; padding-block: 2.25rem 4rem; display: grid; gap: 1.2rem; }
.pedido .titulo-pagina { margin: 0; }
.sello { justify-self: start; padding: 0.35rem 0.95rem; border-radius: 999px; font-weight: 800; font-size: 0.85rem; }
.sello-ok { background: var(--destacado); color: var(--sobre-destacado); }
.sello-espera { background: var(--secundario); color: var(--texto); }
.sello-mal { background: var(--oscuro); color: var(--sobre-oscuro); }

/* ---------- pie + whatsapp ---------- */
.pie { margin-top: 2.5rem; background: var(--oscuro); color: var(--sobre-oscuro); }
.pie-canto { height: 12px; background: var(--madera); }
.pie-fila { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 1rem; padding-block: 2.5rem 3.2rem; }
.pie-marca { font-family: var(--display); font-weight: 800; font-size: 1.9rem; letter-spacing: -0.03em; }
.pie p { opacity: 0.75; font-size: 0.92rem; margin-top: 0.4rem; }
.pie-legal { font-size: 0.85rem; }
.wsp { position: fixed; right: 1.1rem; bottom: 1.1rem; z-index: 40; width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; background: var(--acento); color: var(--sobre-acento); box-shadow: 0 6px 20px color-mix(in srgb, #000 25%, transparent); }
.wsp svg { width: 26px; height: 26px; }

/* ---------- celular y tablet ---------- */
@media (max-width: 960px) {
  .pasillo-fila { grid-template-columns: minmax(0, 1fr); }
  .cartel { position: static; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 1rem; row-gap: 0.4rem; }
  .cartel-num, .cartel-ver { grid-column: 1 / -1; }
  .cartel-ic { width: 52px; height: 52px; border-radius: 14px; }
  .cartel-ic svg { width: 28px; height: 28px; }
  .fila { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 46%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 0.4rem; scrollbar-width: thin; }
  .fila .tarjeta { scroll-snap-align: start; }
  .grilla { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 0.75rem; }
  .pasos { grid-template-columns: minmax(0, 1fr); }
  .estrella, .producto, .carrito, .checkout, .sec-nosotros.con-imagen { grid-template-columns: minmax(0, 1fr); }
  .estrella-foto { min-height: 300px; }
  .ficha, .resumen { position: static; }
}
@media (max-width: 640px) {
  .ocultar-movil { display: none; }
  .btn-sectores { padding: 0; width: 46px; height: 46px; justify-content: center; }
  .cabecera-fila { grid-template-columns: auto 1fr auto; }
  .marca { justify-self: center; }
  .fila { grid-auto-columns: 62%; }
  .galeria.con-miniaturas { grid-template-columns: minmax(0, 1fr); }
  .galeria.con-miniaturas .foto-grande { grid-column: 1; }
  .galeria.con-miniaturas .miniaturas { grid-column: 1; grid-row: 2; grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .dos { grid-template-columns: minmax(0, 1fr); }
  .linea { grid-template-columns: 76px minmax(0, 1fr); }
  .linea-foto { width: 76px; }
}

/* La barra de "Vista previa" la dibuja y la estila el núcleo: no va acá. */

/* Cuadro de foto: la imagen LLENA siempre el cuadro (así funcionan la foto completa y el encuadre). */
.foto { position: relative; }
.foto > img { position: absolute; inset: 0; width: 100%; height: 100%; }
.estrella-foto { position: relative; }
.estrella-foto .foto { position: absolute; inset: 0; height: auto; }
