﻿/* =====================================================================
   Traza Láser — estilos (pensado primero para celular)
   Los colores salen de css/tema.css
   ===================================================================== */
:root {
  --tinta: var(--carbon);
  --papel: var(--crema);
  --borde: color-mix(in srgb, var(--algarrobo) 28%, transparent);
  --sombra: 0 10px 30px -12px rgba(43, 29, 20, .35);
  --radio: 18px;
  --f-titulo: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Book Antiqua", serif;
  --f-texto: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ancho: 1160px;
  --barra-alto: 62px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--barra-alto) + 10px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--f-texto); color: var(--tinta); line-height: 1.55; font-size: 16px;
  background: var(--papel);
  background-image:
    radial-gradient(circle at 20% 0%, color-mix(in srgb, var(--pino) 22%, transparent), transparent 45%),
    repeating-linear-gradient(92deg, transparent 0 22px, color-mix(in srgb, var(--pino) 7%, transparent) 22px 23px);
  padding-bottom: env(safe-area-inset-bottom);
}
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--f-titulo); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.3rem, 9vw, 4.2rem); }
h2 { font-size: clamp(1.7rem, 6.5vw, 2.7rem); }
h3 { font-size: 1.2rem; }
em { font-style: italic; color: var(--algarrobo); }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--laser); outline-offset: 3px; border-radius: 6px; }
.saltar { position: absolute; left: -999px; }
.saltar:focus { left: 10px; top: 10px; z-index: 99; background: #fff; padding: 8px 12px; }
[hidden] { display: none !important; }

/* ---------------------------------------------------------- botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: .75em 1.4em; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; text-decoration: none; transition: transform .15s, box-shadow .2s, background .2s;
}
.btn:active { transform: scale(.97); }
.btn-laser { background: var(--laser); color: #fff; box-shadow: 0 8px 22px -8px color-mix(in srgb, var(--laser) 80%, transparent); }
.btn-laser:hover { box-shadow: 0 0 0 4px color-mix(in srgb, var(--laser) 25%, transparent), 0 8px 22px -8px var(--laser); }
.btn-linea { border-color: var(--tinta); color: var(--tinta); background: transparent; }
.btn-linea:hover { background: var(--tinta); color: var(--papel); }
.btn-ancho { width: 100%; }
.btn-grande { font-size: 1.1rem; min-height: 56px; }
.btn-chico { min-height: 38px; padding: .4em 1em; font-size: .9rem; }
.ico-wa { width: 22px; height: 22px; fill: currentColor; }

/* ---------------------------------------------------------- barra */
.barra {
  position: sticky; top: 0; z-index: 40; height: var(--barra-alto);
  display: flex; align-items: center; gap: 10px; padding: 0 14px;
  padding-top: env(safe-area-inset-top);
  background: color-mix(in srgb, var(--carbon) 94%, transparent); color: var(--crema);
  backdrop-filter: blur(8px);
  border-bottom: 1px dashed color-mix(in srgb, var(--pino) 45%, transparent);
}
.marca { display: flex; align-items: center; gap: 8px; text-decoration: none; margin-right: auto; }
.marca-ico { width: 38px; height: 38px; }
.marca-ico .corte { fill: none; stroke: var(--pino); stroke-width: 1.6; stroke-dasharray: 3 2.4; }
.marca-ico .t { stroke: var(--crema); stroke-width: 3.4; stroke-linecap: round; fill: none; }
.marca-ico .haz { stroke: var(--laser); stroke-width: 1.6; }
.marca-ico .chispa { fill: var(--laser); filter: drop-shadow(0 0 3px var(--laser)); animation: chispa 1.6s infinite; }
.marca-txt { display: flex; flex-direction: column; line-height: 1; }
.marca-txt b { font-weight: 400; letter-spacing: .28em; font-size: 1.05rem; }
.marca-txt small { letter-spacing: .52em; font-size: .62rem; color: var(--pino); margin-top: 3px; }
@keyframes chispa { 50% { opacity: .35; } }

.menu {
  position: fixed; inset: var(--barra-alto) 0 auto 0; background: var(--carbon);
  display: flex; flex-direction: column; padding: 8px 18px 20px;
  transform: translateY(-120%); transition: transform .3s ease; z-index: -1;
  border-bottom: 2px dashed var(--laser);
}
.menu.abierto { transform: none; }
.menu a { padding: 14px 4px; text-decoration: none; border-bottom: 1px dashed color-mix(in srgb, var(--pino) 30%, transparent); font-size: 1.1rem; }
.btn-menu, .btn-carrito {
  width: 44px; height: 44px; border: 0; background: transparent; color: var(--crema);
  display: grid; place-items: center; position: relative; border-radius: 12px;
}
.btn-menu { gap: 5px; align-content: center; }
.btn-menu span { display: block; width: 22px; height: 2px; background: currentColor; transition: .25s; }
.btn-menu[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.btn-menu[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.btn-menu[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.btn-carrito svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.contador {
  position: absolute; top: 2px; right: 0; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px;
  background: var(--laser); color: #fff; font-size: .75rem; font-weight: 800; display: grid; place-items: center;
}
.contador.salto { animation: salto .4s; }
@keyframes salto { 40% { transform: scale(1.4); } }

/* ---------------------------------------------------------- hero */
.hero { padding: 34px 20px 30px; max-width: var(--ancho); margin: 0 auto; display: grid; gap: 26px; }
.sobretitulo {
  text-transform: uppercase; letter-spacing: .2em; font-size: .75rem; font-weight: 700; color: var(--algarrobo);
  margin: 0 0 12px; display: flex; align-items: center; gap: 8px;
}
.punto-laser { width: 9px; height: 9px; border-radius: 50%; background: var(--laser); box-shadow: 0 0 0 4px color-mix(in srgb, var(--laser) 22%, transparent), 0 0 12px var(--laser); animation: chispa 1.6s infinite; }
.hero h1 em { display: inline-block; position: relative; }
.hero h1 em::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -.04em; height: 3px;
  background: repeating-linear-gradient(90deg, var(--laser) 0 10px, transparent 10px 16px);
  transform-origin: left; animation: trazar 1.6s .3s ease-out both;
}
@keyframes trazar { from { transform: scaleX(0); } }
.bajada { font-size: 1.1rem; max-width: 34em; }
.hero-acciones { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0; }
.hero-acciones .btn { flex: 1 1 auto; }
.sellos { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: .95rem; }
.sellos li { padding-left: 26px; position: relative; }
.sellos li::before { content: ""; position: absolute; left: 0; top: .35em; width: 14px; height: 14px; border: 2px dashed var(--algarrobo); border-radius: 50%; }

.hero-arte { position: relative; aspect-ratio: 1 / .9; max-width: 460px; width: 100%; margin: 0 auto; }
.trazo-circulo { position: absolute; inset: 0; width: 100%; height: 100%; }
.trazo-circulo circle {
  fill: color-mix(in srgb, var(--pino) 28%, transparent); stroke: var(--algarrobo); stroke-width: 2;
  stroke-dasharray: 8 7; animation: girar 60s linear infinite; transform-origin: center;
}
@keyframes girar { to { transform: rotate(360deg); } }
.pieza { position: absolute; filter: drop-shadow(0 16px 18px rgba(43, 29, 20, .35)); }
.p1 { width: 44%; left: 30%; bottom: 4%; z-index: 3; }
.p2 { width: 46%; left: 2%; bottom: 14%; z-index: 1; transform: rotate(-8deg); }
.p3 { width: 38%; right: 2%; bottom: 12%; z-index: 2; transform: rotate(6deg); }
.haz-laser {
  position: absolute; left: 52%; top: -4%; width: 2px; height: 32%; z-index: 4;
  background: linear-gradient(var(--laser), transparent); box-shadow: 0 0 10px var(--laser);
  animation: barrer 5s ease-in-out infinite;
}
.haz-laser::after { content: ""; position: absolute; bottom: -4px; left: -4px; width: 10px; height: 10px; border-radius: 50%; background: #fff; box-shadow: 0 0 12px 4px var(--laser); }
@keyframes barrer { 0%, 100% { transform: translateX(-60px); } 50% { transform: translateX(60px); } }

.linea-corte { height: 2px; margin: 10px 20px; background: repeating-linear-gradient(90deg, var(--algarrobo) 0 12px, transparent 12px 20px); opacity: .5; }

/* ---------------------------------------------------------- secciones */
.seccion { padding: 46px 20px; max-width: var(--ancho); margin: 0 auto; }
.seccion-cab { margin-bottom: 22px; }
.seccion-madera, .seccion-oscura { max-width: none; }
.seccion-madera > *, .seccion-oscura > * { max-width: var(--ancho); margin-left: auto; margin-right: auto; }
.seccion-madera { background: color-mix(in srgb, var(--pino) 30%, var(--crema)); border-block: 2px dashed color-mix(in srgb, var(--algarrobo) 40%, transparent); }
.seccion-oscura { background: var(--carbon); color: var(--crema); }
.seccion-oscura em, .seccion-oscura .sobretitulo { color: var(--pino); }

/* ---------------------------------------------------------- catálogo */
.filtros {
  display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 14px; margin: 0 -20px; padding-left: 20px; padding-right: 20px;
  scrollbar-width: none; position: sticky; top: var(--barra-alto); z-index: 5;
  background: linear-gradient(var(--papel) 75%, transparent);
}
.filtros::-webkit-scrollbar { display: none; }
.chip {
  flex: none; border: 1.5px dashed var(--algarrobo); background: transparent; color: var(--tinta);
  padding: 9px 16px; border-radius: 999px; font-weight: 600; min-height: 42px;
}
.chip[aria-selected="true"] { background: var(--carbon); color: var(--crema); border-style: solid; border-color: var(--carbon); }
.grilla { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.cargando, .vacio { grid-column: 1 / -1; text-align: center; padding: 30px; opacity: .7; }
.tarjeta {
  position: relative; background: #fffaf3; border-radius: var(--radio); overflow: hidden; text-decoration: none;
  box-shadow: var(--sombra); display: flex; flex-direction: column; transition: transform .2s;
  outline: 1.5px dashed transparent; outline-offset: -7px;
}
.tarjeta:hover { transform: translateY(-3px); outline-color: color-mix(in srgb, var(--laser) 70%, transparent); }
.tarjeta-foto { aspect-ratio: 1; background: var(--pino); overflow: hidden; }
.tarjeta-foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.tarjeta:hover .tarjeta-foto img { transform: scale(1.05); }
.tarjeta-txt { padding: 10px 12px 14px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.tarjeta h3 { font-size: 1rem; margin: 0; }
.tarjeta .resumen { font-size: .82rem; opacity: .75; margin: 0; display: none; }
.precio { font-weight: 800; color: var(--algarrobo); margin-top: auto; }
.precio small { font-weight: 600; font-size: .72rem; opacity: .8; text-transform: uppercase; letter-spacing: .05em; }
.etiqueta { position: absolute; top: 10px; left: 10px; background: var(--laser); color: #fff; font-size: .68rem; font-weight: 800; padding: 4px 9px; border-radius: 999px; letter-spacing: .05em; text-transform: uppercase; }

/* ---------------------------------------------------------- pasos */
.pasos { list-style: none; padding: 0; margin: 0 auto 24px; display: grid; gap: 14px; counter-reset: p; }
.pasos li { background: var(--crema); border-radius: var(--radio); padding: 18px 18px 16px 74px; position: relative; border: 1.5px dashed var(--borde); }
.pasos h3 { margin-bottom: 4px; }
.pasos p { margin: 0; }
.num {
  position: absolute; left: 16px; top: 16px; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; font-family: var(--f-titulo); font-size: 1.4rem; font-weight: 700;
  color: var(--laser); border: 2px dashed var(--laser);
}
.consejos { background: var(--carbon); color: var(--crema); border-radius: var(--radio); padding: 20px; }
.consejos ul { margin: 0; padding-left: 1.2em; }
.consejos li { margin: 6px 0; }

/* ---------------------------------------------------------- empresas */
.empresas { display: grid; gap: 26px; }
.lista-check { list-style: none; padding: 0; margin: 16px 0 22px; display: grid; gap: 10px; }
.lista-check li { padding-left: 30px; position: relative; }
.lista-check li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--laser); color: #fff; font-size: .8rem; display: grid; place-items: center; font-weight: 800; }
.empresas-fotos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.empresas-fotos img { aspect-ratio: 1; object-fit: cover; border-radius: 12px; width: 100%; }
.empresas-fotos img:nth-child(2) { transform: translateY(14px); }
.empresas-fotos img:nth-child(5) { transform: translateY(14px); }

/* ---------------------------------------------------------- faq */
.faq { display: grid; gap: 10px; max-width: 820px; }
.faq details { background: #fffaf3; border-radius: 14px; border: 1.5px dashed var(--borde); }
.faq summary { padding: 16px 48px 16px 18px; font-weight: 700; cursor: pointer; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-size: 1.5rem; color: var(--laser); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { margin: 0; padding: 0 18px 18px; }

/* ---------------------------------------------------------- contacto */
.contacto { display: grid; gap: 24px; align-items: center; }
.datos { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 8px; }
.datos a { color: var(--crema); }
.datos li { display: flex; gap: 10px; }
.datos li span:first-child { color: var(--pino); min-width: 92px; font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; padding-top: 2px; }
.logo-grande { border-radius: 50%; max-width: 340px; width: 80%; margin: 0 auto; box-shadow: 0 0 0 6px var(--carbon), 0 0 0 8px color-mix(in srgb, var(--pino) 60%, transparent); }

.pie { text-align: center; padding: 26px 20px 100px; font-size: .9rem; }
.pie p { margin: 4px 0; }
.pie-chico { opacity: .7; font-size: .8rem; }
.pie .btn { margin-top: 12px; }

/* ---------------------------------------------------------- WhatsApp flotante */
.wa-flotante {
  position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 30;
  width: 58px; height: 58px; border-radius: 50%; background: #25D366; display: grid; place-items: center;
  box-shadow: 0 10px 24px -6px rgba(0,0,0,.4);
}
.wa-flotante svg { width: 32px; height: 32px; fill: #fff; }
body.en-ficha .wa-flotante { display: none; }

/* ---------------------------------------------------------- ficha de producto */
.ficha { max-width: var(--ancho); margin: 0 auto; padding: 0 0 110px; min-height: 80vh; }
.volver { display: inline-flex; align-items: center; gap: 6px; margin: 14px 16px; background: none; border: 0; color: var(--algarrobo); font-weight: 700; padding: 8px 0; }
.galeria { position: relative; }
.galeria-pista {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; background: color-mix(in srgb, var(--pino) 35%, var(--crema));
}
.galeria-pista::-webkit-scrollbar { display: none; }
.galeria-pista img { flex: 0 0 100%; width: 100%; aspect-ratio: 1; object-fit: contain; scroll-snap-align: center; }
.galeria-puntos { display: flex; gap: 6px; justify-content: center; padding: 10px; }
.galeria-puntos button { width: 9px; height: 9px; border-radius: 50%; border: 0; padding: 0; background: color-mix(in srgb, var(--algarrobo) 35%, transparent); }
.galeria-puntos button.activo { background: var(--laser); width: 22px; border-radius: 6px; }
.miniaturas { display: none; }
.galeria-flecha {
  position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 0;
  background: color-mix(in srgb, var(--crema) 85%, transparent); color: var(--tinta); font-size: 1.4rem; box-shadow: var(--sombra); display: none;
}
.galeria-flecha.izq { left: 10px; } .galeria-flecha.der { right: 10px; }

.ficha-info { padding: 6px 20px 0; }
.ficha-info h1 { font-size: clamp(1.8rem, 7vw, 2.6rem); }
.ficha-precio { font-size: 1.6rem; font-weight: 800; color: var(--algarrobo); margin: 0 0 10px; }
.ficha-precio small { font-size: .85rem; font-weight: 600; opacity: .8; }
.ficha-desc p { margin: 0 0 .7em; }
.ficha-desc p.nota { background: color-mix(in srgb, var(--laser) 12%, transparent); border-left: 3px solid var(--laser); padding: 8px 12px; border-radius: 0 8px 8px 0; }

.form-pedido { margin: 22px 0; display: grid; gap: 18px; }
.grupo { border: 0; padding: 0; margin: 0; }
.grupo legend, .campo > span { font-weight: 800; margin-bottom: 8px; display: block; font-size: .95rem; }
.opciones { display: grid; gap: 8px; }
.opcion { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1.5px dashed var(--borde); background: #fffaf3; cursor: pointer; }
.opcion input { accent-color: var(--laser); width: 20px; height: 20px; flex: none; }
.opcion .op-txt { flex: 1; font-size: .93rem; }
.opcion .op-txt small { display: block; opacity: .7; font-size: .8rem; }
.opcion .op-precio { font-weight: 800; color: var(--algarrobo); white-space: nowrap; }
.opcion:has(input:checked) { border-style: solid; border-color: var(--laser); background: color-mix(in srgb, var(--laser) 7%, #fffaf3); }
.colores { display: flex; flex-wrap: wrap; gap: 8px; }
.colores label { cursor: pointer; }
.colores input { position: absolute; opacity: 0; }
.colores span { display: inline-block; padding: 9px 14px; border-radius: 999px; border: 1.5px dashed var(--borde); background: #fffaf3; font-weight: 600; font-size: .9rem; }
.colores input:checked + span { border: 1.5px solid var(--laser); background: color-mix(in srgb, var(--laser) 10%, #fffaf3); }
.colores input:focus-visible + span { outline: 3px solid var(--laser); }
.campo { display: block; }
.campo input[type=text], .campo textarea, .carrito-pie input:not([type=radio]):not([type=checkbox]) {
  width: 100%; font: inherit; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--borde); background: #fff; color: var(--tinta); font-size: 16px;
}
.campo textarea { min-height: 76px; resize: vertical; }
.campo input:focus, .campo textarea:focus, .carrito-pie input:not([type=radio]):not([type=checkbox]):focus { outline: none; border-color: var(--laser); box-shadow: 0 0 0 3px color-mix(in srgb, var(--laser) 20%, transparent); }
.ayuda { font-size: .8rem; opacity: .7; margin-top: 4px; display: block; }
.vista-previa {
  margin-top: 8px; padding: 14px; border-radius: 14px; text-align: center; color: var(--carbon);
  background: linear-gradient(135deg, var(--pino), color-mix(in srgb, var(--algarrobo) 60%, var(--pino)));
  font-family: var(--f-titulo); font-size: 1.3rem; min-height: 56px; text-shadow: 0 1px 0 rgba(255,255,255,.25);
  border: 2px dashed color-mix(in srgb, var(--carbon) 30%, transparent);
}
.vista-previa:empty { display: none; }
.foto-sel { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1.5px dashed var(--borde); background: #fffaf3; cursor: pointer; }
.foto-sel input[type=checkbox] { accent-color: var(--laser); width: 20px; height: 20px; }
.foto-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.foto-preview img { width: 70px; height: 70px; object-fit: cover; border-radius: 10px; border: 2px solid var(--pino); }
.cantidad { display: inline-flex; align-items: center; border: 1.5px solid var(--borde); border-radius: 999px; background: #fff; }
.cantidad button { width: 44px; height: 44px; border: 0; background: none; font-size: 1.3rem; color: var(--algarrobo); }
.cantidad output { min-width: 34px; text-align: center; font-weight: 800; }

.ficha-extra { margin-top: 26px; display: grid; gap: 12px; }
.caja { background: #fffaf3; border-radius: var(--radio); padding: 16px 18px; border: 1.5px dashed var(--borde); }
.caja h3 { font-size: 1.05rem; }
.caja p { margin: 0 0 .5em; font-size: .93rem; }
.relacionados { margin-top: 30px; }
.relacionados .grilla { grid-template-columns: repeat(2, minmax(0,1fr)); }

.barra-pedido {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 35; display: flex; gap: 8px; align-items: center;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--carbon);
  border-top: 2px dashed var(--laser);
}
.barra-pedido .total-ficha { color: var(--crema); font-weight: 800; font-size: 1.05rem; line-height: 1.1; margin-right: auto; }
.barra-pedido .total-ficha small { display: block; font-weight: 500; font-size: .7rem; color: var(--pino); }
.barra-pedido .btn { min-height: 46px; padding: .6em 1em; font-size: .9rem; }
.btn-agregar { background: transparent; border-color: var(--pino); color: var(--crema); }

/* ---------------------------------------------------------- carrito */
.velo { position: fixed; inset: 0; background: rgba(20, 12, 6, .55); z-index: 50; }
.carrito {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(420px, 100%); z-index: 60; background: var(--crema);
  display: flex; flex-direction: column; transform: translateX(105%); transition: transform .3s ease;
  border-left: 2px dashed var(--laser);
}
.carrito.abierto { transform: none; }
.carrito-cab { display: flex; align-items: center; justify-content: space-between; padding: calc(14px + env(safe-area-inset-top)) 18px 10px; border-bottom: 1px dashed var(--borde); }
.carrito-cab h2 { margin: 0; font-size: 1.5rem; }
.cerrar { width: 44px; height: 44px; border: 0; background: none; font-size: 2rem; line-height: 1; color: var(--tinta); }
.carrito-items { flex: 1; overflow-y: auto; padding: 12px 18px; display: grid; gap: 12px; align-content: start; }
.item { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: start; background: #fffaf3; padding: 10px; border-radius: 14px; }
.item img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; }
.item h4 { margin: 0 0 2px; font-size: .95rem; }
.item p { margin: 0; font-size: .78rem; opacity: .8; }
.item .item-precio { font-weight: 800; color: var(--algarrobo); font-size: .95rem; }
.item .quitar { border: 0; background: none; color: var(--laser); font-size: .8rem; font-weight: 700; padding: 6px 0 0; }
.item .cantidad { transform: scale(.85); transform-origin: left; margin-top: 4px; }
.item .cantidad button { width: 36px; height: 36px; }
.carrito-vacio { text-align: center; padding: 40px 10px; opacity: .8; }
.carrito-pie { padding: 14px 18px calc(16px + env(safe-area-inset-bottom)); border-top: 1px dashed var(--borde); display: grid; gap: 10px; background: color-mix(in srgb, var(--pino) 18%, var(--crema)); }
.carrito-pie label { font-size: .85rem; font-weight: 700; display: grid; gap: 4px; }
.total { display: flex; justify-content: space-between; align-items: baseline; font-size: 1.1rem; }
.total b { font-size: 1.4rem; color: var(--algarrobo); }
.aviso-chico { font-size: .75rem; opacity: .7; margin: 0; text-align: center; }

.toast {
  position: fixed; left: 50%; bottom: 90px; transform: translate(-50%, 30px); opacity: 0; z-index: 70;
  background: var(--carbon); color: var(--crema); padding: 12px 18px; border-radius: 999px; font-weight: 600;
  transition: .3s; pointer-events: none; border: 1px dashed var(--laser); max-width: 90vw; text-align: center;
}
.toast.visible { transform: translate(-50%, 0); opacity: 1; }

/* ---------------------------------------------------------- tablet / escritorio */
@media (min-width: 640px) {
  .grilla { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
  .tarjeta .resumen { display: block; }
  .pasos { grid-template-columns: repeat(2, 1fr); }
  .relacionados .grilla { grid-template-columns: repeat(4, minmax(0,1fr)); }
}
@media (min-width: 920px) {
  :root { --barra-alto: 72px; }
  .btn-menu { display: none; }
  .menu { position: static; transform: none; flex-direction: row; background: none; padding: 0; gap: 4px; border: 0; z-index: auto; margin-right: 8px; }
  .menu a { border: 0; font-size: .95rem; padding: 8px 12px; border-radius: 999px; }
  .menu a:hover { background: color-mix(in srgb, var(--pino) 20%, transparent); }
  .hero { grid-template-columns: 1.05fr 1fr; align-items: center; padding: 60px 24px; }
  .hero-acciones .btn { flex: 0 0 auto; }
  .seccion { padding: 70px 24px; }
  .grilla { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .pasos { grid-template-columns: repeat(4, 1fr); }
  .pasos li { padding: 70px 18px 18px; }
  .empresas { grid-template-columns: 1fr 1fr; align-items: center; }
  .contacto { grid-template-columns: 1.2fr 1fr; }
  .filtros { margin: 0; padding-left: 0; padding-right: 0; }
  .ficha { padding: 0 24px 140px; }
  .ficha-cuerpo { display: grid; grid-template-columns: 1.1fr 1fr; gap: 10px 36px; align-items: start; }
  .volver { margin-left: 0; }
  .galeria { position: sticky; top: calc(var(--barra-alto) + 16px); border-radius: var(--radio); overflow: hidden; }
  .galeria-flecha { display: block; }
  .miniaturas { display: flex; gap: 8px; padding: 8px 0; overflow-x: auto; }
  .miniaturas button { flex: none; border: 2px solid transparent; padding: 0; border-radius: 10px; overflow: hidden; background: none; }
  .miniaturas button.activo { border-color: var(--laser); }
  .miniaturas img { width: 66px; height: 66px; object-fit: cover; }
  .ficha-info { padding: 0; }
  .relacionados { margin-top: 56px; position: relative; z-index: 1; }
  .barra-pedido { left: auto; right: 24px; bottom: 20px; border-radius: 999px; border: 2px dashed var(--laser); padding: 8px 8px 8px 22px; box-shadow: var(--sombra); min-width: 520px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* =====================================================================
   v2: Instagram, logo reemplazable, checkout con envío y Mercado Pago
   ===================================================================== */
.btn-ig { width: 44px; height: 44px; display: grid; place-items: center; color: var(--crema); border-radius: 12px; }
.btn-ig:hover { color: var(--laser); }
.btn-ig svg, .pie-redes svg, .btn-ig-grande svg, .dato-ig svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; }
svg .relleno { fill: currentColor; stroke: none; }
.marca-logo { height: 42px; width: auto; max-width: 150px; object-fit: contain; }
.marca.con-logo .marca-ico, .marca.con-logo .marca-txt { display: none; }
.btn-ig-grande { margin-top: 10px; border-color: var(--pino); color: var(--crema); background: transparent; }
.btn-ig-grande:hover { background: linear-gradient(45deg, #f09433, #dc2743 50%, #bc1888); border-color: transparent; }
.dato-ig { display: inline-flex; align-items: center; gap: 6px; }
.dato-ig svg { width: 18px; height: 18px; }
.contacto .btn { margin-right: 8px; }
.pie-redes { display: flex; justify-content: center; gap: 18px; margin: 12px 0 !important; }
.pie-redes a { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; font-weight: 700; color: var(--algarrobo); padding: 6px 4px; }
.pie-redes .ico-wa { width: 22px; height: 22px; }

.btn-wa { background: #25D366; color: #fff; }
.btn-wa:hover { background: #1ebe5a; }
.a-medida { margin: 6px 0 10px; padding: 16px 18px; border-radius: var(--radio); background: color-mix(in srgb, #25D366 9%, #fffaf3); border: 1.5px dashed color-mix(in srgb, #25D366 50%, transparent); }
.a-medida p { margin: 0 0 12px; font-size: .93rem; }

/* carrito con formulario: todo el panel se desplaza */
.carrito { overflow-y: auto; overscroll-behavior: contain; }
.carrito-cab { position: sticky; top: 0; background: var(--crema); z-index: 2; }
.carrito-items { flex: none; overflow: visible; }
.carrito-pie legend { font-weight: 800; margin-bottom: 8px; }
.carrito-pie .opcion { padding: 10px 12px; }
.campos-cliente { display: grid; gap: 10px; }
.campos-cliente small { font-weight: 400; opacity: .7; }
#camposDireccion { display: grid; gap: 10px; }
#camposDireccion[hidden] { display: none !important; }
.fila-2 { display: grid; grid-template-columns: 1fr 96px; gap: 10px; }
.carrito-pie input.invalido { border-color: #c62828; box-shadow: 0 0 0 3px rgba(198, 40, 40, .15); }
.resumen-total { display: grid; gap: 4px; padding: 10px 0; border-top: 1px dashed var(--borde); font-size: .95rem; }
.resumen-total > div { display: flex; justify-content: space-between; }
.aviso-error { margin: 0; padding: 10px 12px; border-radius: 10px; background: #fde8e4; color: #8a1c0c; font-size: .88rem; font-weight: 600; }
.btn-mp { background: #009EE3; color: #fff; box-shadow: 0 8px 22px -10px #009EE3; }
.btn-mp:hover { background: #0087c2; }
.btn-mp:disabled { opacity: .45; cursor: not-allowed; }
.mp-logo { display: inline-grid; place-items: center; width: 28px; height: 20px; border-radius: 10px; background: #fff; color: #009EE3; font-size: .7rem; font-weight: 900; }
.medios-pago { margin: -2px 0 2px; text-align: center; font-size: .78rem; opacity: .8; }

/* resultado del pago */
.modal { position: fixed; inset: 0; z-index: 80; background: rgba(20, 12, 6, .6); display: grid; place-items: center; padding: 20px; }
.modal-caja { background: var(--crema); border-radius: 22px; padding: 28px 22px 22px; max-width: 420px; width: 100%; text-align: center; border: 2px dashed var(--laser); box-shadow: var(--sombra); }
.modal-ico { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; font-size: 2rem; font-weight: 800; color: #fff; }
.modal-ico.ok { background: #2e9d57; }
.modal-ico.espera { background: var(--pino); }
.modal-ico.error { background: #c62828; }
.modal-caja h2 { font-size: 1.6rem; }
.modal-ref { font-size: .82rem; opacity: .7; }
.modal-acciones { display: grid; gap: 10px; margin-top: 16px; }

/* logo nuevo de Marca */
.marca-logo { height: 46px; max-width: 170px; }
.logo-grande.logo-nuevo { border-radius: 0; box-shadow: none; max-width: 320px; aspect-ratio: auto; }

.carrito-pie label.opcion { display: flex; font-weight: 600; font-size: .92rem; gap: 12px; }
.carrito-pie .op-txt small { font-weight: 400; }

/* arreglo: botones de opción del carrito con tamaño normal */
.carrito-pie input[type=radio] { accent-color: var(--laser); width: 20px; height: 20px; flex: none; margin: 0; }
.carrito-pie .op-txt { min-width: 0; }
.carrito { overflow-x: hidden; }
/* =====================================================================
   v3: Previsualizador 3D "Probá tu diseño"
   ===================================================================== */
.btn-visor {
  width: 100%; margin: 4px 0 6px; background: var(--carbon); color: var(--crema);
  border: 2px dashed var(--laser); min-height: 54px; font-size: 1.02rem;
}
.btn-visor:hover { background: color-mix(in srgb, var(--carbon) 85%, var(--laser)); }
.btn-visor .cubo { width: 24px; height: 24px; fill: none; stroke: var(--laser); stroke-width: 1.8; stroke-linejoin: round; }
.btn-visor small { font-weight: 500; opacity: .75; font-size: .78rem; }

.visor { position: fixed; inset: 0; z-index: 90; background: rgba(20, 12, 6, .72); display: flex; align-items: stretch; justify-content: center; }
.visor-caja {
  background: var(--crema); width: 100%; height: 100%; display: flex; flex-direction: column; overflow: hidden;
}
.visor-cab { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: calc(10px + env(safe-area-inset-top)) 14px 8px 18px; border-bottom: 1px dashed var(--borde); }
.visor-cab h2 { font-size: 1.15rem; margin: 0; }
.visor-sobre { margin: 0; font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; color: var(--laser); font-weight: 700; }
.visor-cerrar { width: 44px; height: 44px; border: 0; background: none; font-size: 2rem; line-height: 1; color: var(--tinta); flex: none; }
.visor-escena {
  position: relative; flex: 1 1 52%; min-height: 240px; overflow: hidden;
  background: radial-gradient(circle at 50% 40%, #fffaf2, color-mix(in srgb, var(--pino) 45%, var(--crema)) 75%);
}
.visor-lienzo { position: absolute; inset: 0; width: 100% !important; height: 100% !important; touch-action: none; cursor: grab; display: block; }
.visor-lienzo:active { cursor: grabbing; }
.visor-lienzo-2d { object-fit: contain; cursor: default; }
.visor-cargando { position: absolute; inset: 0; display: grid; place-content: center; grid-auto-flow: column; gap: 10px; align-items: center; font-weight: 600; color: var(--algarrobo); }
.visor-pista {
  position: absolute; left: 50%; top: 12px; transform: translateX(-50%); margin: 0; pointer-events: none;
  background: rgba(43, 29, 20, .78); color: var(--crema); padding: 6px 12px; border-radius: 999px; font-size: .8rem; white-space: nowrap;
  max-width: calc(100% - 20px);
}
@media (max-width: 560px) { .visor-pista { white-space: normal; text-align: center; border-radius: 14px; width: max-content; line-height: 1.3; } }
.es-2d .visor-pista { display: none; }
.visor-aviso {
  position: absolute; left: 10px; right: 10px; bottom: 10px; margin: 0; pointer-events: none; text-align: center;
  background: rgba(255, 250, 243, .92); color: var(--carbon); border: 1.5px dashed var(--laser);
  padding: 6px 10px; border-radius: 10px; font-size: .78rem; font-weight: 600;
}
.visor-panel { flex: 0 1 auto; max-height: 48%; overflow-y: auto; padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); display: grid; gap: 10px; border-top: 2px dashed var(--laser); }
.visor-subir { cursor: pointer; }
.visor-privado { margin: -2px 0 0; font-size: .76rem; text-align: center; color: var(--ceniza, #6E5D50); }
.visor-estado { margin: 0; font-size: .82rem; font-weight: 600; color: var(--algarrobo); text-align: center; }
.visor-estado:empty { display: none; }
.visor-sliders { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
.visor-sliders label { display: grid; gap: 2px; font-size: .78rem; font-weight: 700; }
.visor-sliders input { width: 100%; accent-color: var(--laser); height: 28px; }
.visor-botones { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.visor-botones .btn { min-height: 42px; padding: .5em .6em; font-size: .88rem; }
.item img.con-preview { border: 2px dashed var(--laser); }

@media (min-width: 920px) {
  .visor { align-items: center; padding: 24px; }
  .visor-caja {
    max-width: 1120px; height: min(86vh, 760px); border-radius: 22px; border: 2px dashed var(--laser);
    display: grid; grid-template-columns: 1.45fr 1fr; grid-template-rows: auto 1fr;
  }
  .visor-cab { grid-column: 1 / -1; }
  .visor-escena { min-height: 0; }
  .visor-panel { max-height: none; border-top: 0; border-left: 2px dashed var(--laser); align-content: start; padding: 18px 20px; }
  .visor-sliders { grid-template-columns: 1fr; gap: 10px; }
}

/* visor: ajuste celular (escena más grande, aviso compacto, botón de agregar siempre visible) */
@media (max-width: 919px) {
  .visor-escena { flex: 1 1 auto; min-height: 50vh; }
  .visor-panel { max-height: 46vh; padding-top: 10px; gap: 8px; }
  .visor-aviso { bottom: 6px; left: 6px; right: 6px; font-size: .7rem; padding: 4px 8px; }
  .visor-pista { top: 8px; font-size: .74rem; }
  .visor-privado { font-size: .7rem; }
  .visor-subir { min-height: 44px; }
  .visor-sliders { gap: 2px 14px; }
  .visor-sliders input { height: 24px; }
}
.visor-panel [data-accion="agregar"] { position: sticky; bottom: 0; box-shadow: 0 -10px 18px 4px var(--crema); }

/* visor: pie fijo con el botón de agregar */
.visor-panel [data-accion="agregar"] { position: static; box-shadow: none; }
.visor-pie { flex: none; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); border-top: 1px dashed var(--borde); background: var(--crema); }
@media (max-width: 919px) {
  .visor-caja { height: 100dvh; }
  .visor-escena { flex: 1 1 auto; min-height: 40vh; }
  .visor-panel { flex: 0 1 auto; min-height: 0; max-height: 40vh; padding-bottom: 10px; }
}
@media (min-width: 920px) {
  .visor-caja { grid-template-rows: auto 1fr auto; }
  .visor-escena { grid-row: 2 / 4; }
  .visor-panel { grid-column: 2; grid-row: 2; overflow-y: auto; }
  .visor-pie { grid-column: 2; grid-row: 3; border-left: 2px dashed var(--laser); padding: 14px 20px; }
}

.es-2d::before { content: 'Vista 2D sobre la foto'; position: absolute; top: 10px; left: 10px; z-index: 2; background: rgba(43,29,20,.8); color: var(--crema); font-size: .72rem; padding: 4px 10px; border-radius: 999px; }

/* ---------- v4: capas del visor ---------- */
.visor-agregar { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.visor-agregar .btn { min-height: 44px; padding: .5em .6em; font-size: .9rem; }
.visor-capas { display: grid; gap: 6px; }
.visor-capas-tit { margin: 0; font-size: .8rem; font-weight: 800; }
.visor-capas-tit small { font-weight: 500; color: var(--ceniza, #6E5D50); }
.visor-lista { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: thin; }
.visor-lista li { flex: 0 0 auto; }
.visor-lista button { display: flex; align-items: center; gap: 6px; max-width: 170px; min-height: 44px; padding: 4px 10px 4px 4px; border: 2px solid rgba(43,29,20,.18); border-radius: 10px; background: #fff; font: inherit; font-size: .8rem; cursor: pointer; color: var(--tinta, #2B1D14); }
.visor-lista button.activa { border-color: var(--laser); box-shadow: 0 0 0 2px rgba(228,87,46,.18); }
.visor-mini { flex: 0 0 34px; width: 34px; height: 34px; border-radius: 6px; display: grid; place-items: center; background: #f3e9dc; font-weight: 800; overflow: hidden; }
.visor-mini canvas { width: 34px; height: 34px; }
.visor-nombre { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.visor-vacio { font-size: .8rem; color: var(--ceniza, #6E5D50); padding: 6px 2px; }
.visor-herr { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.visor-herr .btn { min-height: 40px; padding: .35em .2em; font-size: .78rem; }
.visor-herr .visor-borrar { color: #b3261e; }
.visor-herr.deshabilitado, .visor-sliders.deshabilitado { opacity: .45; }
.visor-texto { display: grid; gap: 2px; font-size: .78rem; font-weight: 700; }
.visor-texto[hidden] { display: none; }
.visor-texto input { font: inherit; font-size: 1rem; padding: .45em .6em; border: 2px solid rgba(43,29,20,.2); border-radius: 8px; }
.visor-lienzo { touch-action: none; }
@media (min-width: 920px) {
  .visor-lista { flex-direction: column; overflow-x: visible; max-height: 220px; overflow-y: auto; }
  .visor-lista button { max-width: none; width: 100%; }
}
@media (max-width: 919px) {
  .visor-pista { font-size: .72rem; }
}
.visor-panel { grid-template-columns: minmax(0, 1fr); } .visor-panel > *, .visor-capas > * { min-width: 0; }
