/* VOREAL
   Layout: portada clara con el logo animado al costado, después la pared para probar la foto.
   Color: rosa, carbón y gris del logo sobre blanco.
   Tipografía: Newsreader (títulos) e Instrument Sans (texto). */
:root {
  --paper: #FFFFFF; --paper-2: #F8EFEE; --paper-3: #F0E0DE;
  --ink: #241F21; --ink-2: #4F4447; --line: #DCCBC9;
  --rose: #D99E9B; --rose-deep: #8B3F47; --rose-wash: #F6E1DF; --rose-field: #F2DEDB; --grey: #8D8A88;
  --wa: #17683F; --wa-dark: #0F4E2E; --danger: #A12F36;
  --f-display: 'Newsreader', Georgia, 'Times New Roman', serif;
  --f-body: 'Instrument Sans', system-ui, 'Segoe UI', Roboto, Arial, sans-serif;
  --f-mono: var(--f-body);
  --r: 6px; --gutter: 20px; --header-h: 68px; --bar-h: 76px;
}
@media (min-width: 720px) { :root { --gutter: 36px; } }
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
html.scroll-lock { overflow: hidden; }
body { margin: 0; font: 400 1.0625rem/1.55 var(--f-body); color: var(--ink); background: var(--paper); overflow-x: clip; font-variant-numeric: tabular-nums; }
img, svg, video, canvas { max-width: 100%; }
img { height: auto; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--rose-deep); outline-offset: 3px; }
.stage-wall[data-wall="carbon"] .print-group:focus-visible { outline-color: #fff; }
.icon { width: 20px; height: 20px; flex: none; }
.icon-lg { width: 28px; height: 28px; }
.sr-only, .sr-only-input { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; }
.skip-link:focus { top: 8px; }
.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 var(--gutter); }

h1, h2 { font-family: var(--f-display); font-weight: 400; text-wrap: balance; }
h1 { font-size: clamp(2.7rem, 5.6vw, 4.9rem); line-height: 1.02; letter-spacing: -.025em; }
h2 { font-size: clamp(2rem, 3.8vw, 3.1rem); line-height: 1.06; letter-spacing: -.02em; }
.lede { font-size: clamp(1.08rem, 1.6vw, 1.25rem); color: var(--ink-2); max-width: 52ch; }
.sec-head { display: grid; gap: 16px; max-width: 800px; margin-bottom: clamp(28px, 4vw, 48px); }
.mini-title { font-size: 1rem; font-weight: 700; margin-bottom: 12px; }
main section { padding: clamp(64px, 9vw, 120px) 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 24px;
  border: 1px solid var(--ink); border-radius: var(--r); background: transparent;
  font-weight: 600; line-height: 1.2; text-decoration: none; text-align: center; cursor: pointer; transition: background-color .15s, color .15s;
}
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: var(--rose-deep); border-color: var(--rose-deep); }
.btn-wa { background: var(--wa); border-color: var(--wa); color: #fff; }
.btn-wa:hover { background: var(--wa-dark); }
.btn-mp { background: #0B5FA5; border-color: #0B5FA5; color: #fff; }
.btn-mp:hover { background: #084A82; }
.btn:disabled { opacity: .6; }
.mp { display: grid; gap: 10px; }
.btn-quiet { border-color: var(--ink-2); background: #fff; }
.btn-quiet:hover { background: var(--paper-2); }
.btn-quiet[aria-pressed="true"] { background: var(--ink); color: #fff; }
.btn-sm { min-height: 44px; padding: 0 16px; font-size: .95rem; }
.btn-block { width: 100%; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex: none; border: 0; background: transparent; border-radius: var(--r); cursor: pointer; }
.icon-btn:hover { background: var(--paper-3); }
.icon-btn-solid { background: var(--ink); color: #fff; }
.icon-btn-solid:hover { background: var(--rose-deep); }

/* ---------- Encabezado ---------- */
.top-banner { background: var(--rose-field); padding: 9px 0; font-size: .9rem; font-weight: 500; line-height: 1.35; }
.top-banner p { max-width: 1320px; margin: 0 auto; padding: 0 var(--gutter); }
.site-header { position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: var(--header-h); }
.brand { line-height: 0; }
.brand-logo { width: 56px; height: 56px; border-radius: 50%; display: block; }
.main-nav { display: none; gap: 8px; }
.main-nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; text-decoration: none; font-weight: 500; }
.main-nav a:hover { text-decoration: underline; text-decoration-color: var(--rose); text-decoration-thickness: 3px; text-underline-offset: 8px; }
@media (min-width: 900px) { .main-nav { display: flex; } }
.cart-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid var(--ink-2); background: #fff; border-radius: var(--r); font-weight: 600; cursor: pointer; }
.cart-btn:hover { background: var(--paper-2); }
.cart-count { min-width: 24px; height: 24px; padding: 0 6px; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px; font-size: .82rem; background: var(--rose-deep); color: #fff; }
.cart-count[data-n="0"] { background: var(--paper-3); color: var(--ink-2); }
@media (max-width: 420px) { .cart-label { display: none; } }

/* ---------- Portada: el logo animado ---------- */
main .hero { position: relative; overflow: hidden; background: var(--paper-2); padding: 24px 0 44px; }
.hero-grid { display: flex; flex-direction: column-reverse; gap: 28px; }
.hero-copy { display: grid; gap: 20px; }
.hero h1 { max-width: 11ch; }
.hero .lede { max-width: 40ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 4px; }
.hero-logo { width: min(62vw, 34svh); margin: 0 auto; }
.logo-pila { position: relative; aspect-ratio: 640 / 641; }
.logo-pila img { position: absolute; inset: 0; width: 100%; height: 100%; }
.anim-toggle { position: absolute; right: var(--gutter); top: 16px; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%; background: #fff; color: var(--ink); cursor: pointer; }
@media (min-width: 760px) {
  main .hero { display: flex; align-items: center; min-height: clamp(440px, calc(100svh - 110px), 720px); padding: 32px 0; }
  .hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 40px; }
  .hero-copy { gap: 24px; }
  .hero-logo { width: min(34vw, 58svh, 460px); }
}

/* ---------- Entrada ---------- */
.intro { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; overflow: hidden; animation: intro-fin 0s 6s forwards; }
.sin-intro .intro { display: none; }
.puerta { position: absolute; top: 0; bottom: 0; width: 50.2%; background: var(--rose-field); }
.puerta-izq { left: 0; }
.puerta-der { right: 0; }
.intro .logo-pila { width: min(64vw, 56svh, 420px); }
.anim .intro .logo-pila img { opacity: 0; }
@keyframes intro-fin { to { visibility: hidden; } }
@keyframes juntar { from { opacity: 0; transform: translate(var(--x, 0), var(--y, 0)) rotate(var(--g, 0deg)) scale(var(--e, 1)); } 60% { opacity: 1; } to { opacity: 1; transform: none; } }
@keyframes abrir-izq { to { transform: translateX(-101%); } }
@keyframes abrir-der { to { transform: translateX(101%); } }
@keyframes irse { to { opacity: 0; transform: scale(1.25); } }
.p-anillo { --e: 2.6; --g: -90deg; }
.p-marco { --x: -70vw; --g: -120deg; }
.p-v { --y: -80vh; --g: 60deg; }
.p-trazo { --x: 70vw; --y: 30vh; --g: 200deg; }
.p-nombre { --x: 80vw; }
.p-lema { --y: 70vh; --g: -40deg; }
.anim .intro.go .logo-pila img { animation: juntar 1.15s cubic-bezier(.2, .85, .25, 1) both; }
.anim .intro.go .p-marco { animation-delay: .12s !important; }
.anim .intro.go .p-v { animation-delay: .26s !important; }
.anim .intro.go .p-trazo { animation-delay: .38s !important; }
.anim .intro.go .p-nombre { animation-delay: .46s !important; }
.anim .intro.go .p-lema { animation-delay: .56s !important; }
.anim .intro.go .logo-pila { animation: irse .55s 2s ease-in forwards; }
.anim .intro.go .puerta-izq { animation: abrir-izq .95s 2s cubic-bezier(.75, 0, .2, 1) forwards; }
.anim .intro.go .puerta-der { animation: abrir-der .95s 2s cubic-bezier(.75, 0, .2, 1) forwards; }
html:not(.anim) .intro.go { opacity: 0; transition: opacity .5s .4s; }

/* ---------- Movimiento de la portada y de la página ---------- */
@keyframes flotar { from { transform: translateY(-8px); } to { transform: translateY(8px); } }
@keyframes pintar { 0%, 72%, 100% { clip-path: inset(0); } 73% { clip-path: inset(0 100% 0 0); } 88% { clip-path: inset(0); } }
@keyframes entrar { from { opacity: 0; transform: translateY(40px); } }
@keyframes avance { from { transform: scaleX(0); } }
.anim .hero-logo { animation: flotar 3.6s ease-in-out infinite alternate; }
.anim .hero-logo .p-v, .anim .hero-logo .p-trazo { animation: pintar 8s 3s ease-in-out infinite; }
.anim .hero-logo img { transition: translate .35s ease-out; }
.anim.abierta .hero-copy > * { animation: entrar .8s cubic-bezier(.2, .8, .2, 1) backwards; }
.anim.abierta .hero-copy > :nth-child(2) { animation-delay: .12s; }
.anim.abierta .hero-copy > :nth-child(3) { animation-delay: .24s; }
.anim .btn { transition: background-color .15s, color .15s, transform .2s; }
.anim .btn:hover { transform: translateY(-3px); }
.anim .btn .icon { transition: transform .2s; }
.anim .btn:hover .icon { transform: translateX(4px); }
.anim .mosaic img { transition: transform .5s cubic-bezier(.2, .8, .2, 1); transform-origin: 50% 0; }
.anim .mosaic li:hover img { transform: rotate(-1.6deg) scale(1.02); }
.anim .brand-logo { transition: transform .6s; }
.anim .brand:hover .brand-logo { transform: rotate(360deg); }
.anim .chat-launcher { transition: transform .2s; }
.anim .chat-launcher:hover { transform: scale(1.1); }
@supports (animation-timeline: scroll()) {
  .anim .site-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 3px; background: var(--rose); transform-origin: 0 0; animation: avance linear both; animation-timeline: scroll(root); }
}

/* ---------- Visualizador ---------- */
.viz { background: var(--rose-field); }
.viz .sec-head .lede { color: var(--ink); }
.viz-grid { display: grid; gap: 28px; }
@media (min-width: 960px) {
  .viz-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 32px; align-items: start; }
  .viz-stage-col { position: sticky; top: calc(var(--header-h) + 16px); }
}

.stage { width: 100%; }
.stage-wall {
  --wall: #F1ECE6; --wall-shade: #E3DCD3; --dim: #3A3633;
  --sofa: #85807B; --sofa-light: #9C9792; --sofa-dark: #6C6864;
  position: relative; width: 100%; height: 380px; overflow: hidden;
  background: var(--wall);
  border: 1px solid var(--line);
  contain: layout paint;
}
.stage-wall[data-wall="rosa"]   { --wall: #E6CFCB; --wall-shade: #D7BCB7; --dim: #4A3233; }
.stage-wall[data-wall="gris"]   { --wall: #BDBAB6; --wall-shade: #A9A5A0; --dim: #2E2B2A; }
.stage-wall[data-wall="carbon"] { --wall: #3A3736; --wall-shade: #2C2A29; --dim: #F1ECE6; --sofa: #9A958F; --sofa-light: #ADA8A2; --sofa-dark: #837E79; }
.stage-wall.is-dragover { outline: 3px dashed var(--rose-deep); outline-offset: -8px; }

.room-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.r-wall { fill: var(--wall); }
.r-shade { fill: var(--wall-shade); }
.r-sofa { fill: var(--sofa); }
.r-sofa-l { fill: var(--sofa-light); }
.r-sofa-d { fill: var(--sofa-dark); }
.r-pillow { fill: var(--rose); }
.r-floor { fill: #B79F83; }

.ruler { position: absolute; left: 0; top: 0; bottom: 0; width: 30px; color: var(--dim); pointer-events: none; }
.tick { position: absolute; left: 0; height: 0; border-top: 1px solid currentColor; opacity: 0.55; width: 7px; }
.tick.major { width: 13px; opacity: 0.85; }
.tick-label { position: absolute; left: 15px; transform: translateY(-50%); font-family: var(--f-mono); font-size: 10px; opacity: 0.85; line-height: 1; }

.print-group {
  position: absolute; display: flex; cursor: grab; touch-action: pan-y pinch-zoom;
  -webkit-user-select: none; user-select: none;
}
.print-group.is-editing { touch-action: none; }
.print-group.is-dragging { cursor: grabbing; }
.print-group canvas {
  display: block; flex: none;
  box-shadow: 0 0 0 1px rgba(0,0,0,.28), 2px 2px 0 1px #CDB48F, 8px 12px 18px -3px rgba(0,0,0,.4);
}
.print-group.is-editing canvas { outline: 2px dashed var(--rose-deep); outline-offset: 3px; }
.stage-wall[data-wall="carbon"] .print-group.is-editing canvas { outline-color: #fff; }

.dim { position: absolute; display: flex; align-items: center; gap: 6px; color: var(--dim); font-family: var(--f-mono); font-size: 11px; line-height: 1; pointer-events: none; }
.dim b { font-weight: 500; white-space: nowrap; }
.dim-w { left: 0; right: 0; top: -22px; height: 14px; }
.dim-w::before, .dim-w::after {
  content: ""; flex: 1; height: 8px;
  background: linear-gradient(currentColor, currentColor) center / 100% 1px no-repeat;
}
.dim-w::before { border-left: 1px solid currentColor; }
.dim-w::after { border-right: 1px solid currentColor; }
.dim-h { top: 0; bottom: 0; right: -24px; width: 14px; flex-direction: column; }
.dim-h::before, .dim-h::after {
  content: ""; flex: 1; width: 8px;
  background: linear-gradient(currentColor, currentColor) center / 1px 100% no-repeat;
}
.dim-h::before { border-top: 1px solid currentColor; }
.dim-h::after { border-bottom: 1px solid currentColor; }
.dim-h b { writing-mode: vertical-rl; transform: rotate(180deg); }

.stage-caption { margin-top: 10px; font-weight: 600; color: var(--ink); min-height: 1.5em; }
.photo-warning {
  margin-top: 10px; padding: 12px 14px; font-size: 0.92rem;
  background: var(--rose-wash); border-radius: var(--r);
}

/* ---------- Controles ---------- */
.viz-controls { min-width: 0; background: #fff; border-radius: 10px; padding: var(--panel); --panel: clamp(18px, 2.4vw, 30px); }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.ctl { padding: 20px 0; border-top: 1px solid var(--line); }
.ctl:first-child { border-top: 0; padding-top: 0; }
.ctl legend, .ctl-title {
  padding: 0; margin: 0 0 12px; display: flex; align-items: center; gap: 10px;
  font-family: var(--f-display); font-size: 1.15rem; font-weight: 400; letter-spacing: -0.01em;
}
.ctl legend { float: left; width: 100%; }
.ctl legend + * { clear: both; }
.step {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 26px; height: 26px; background: var(--ink); color: var(--paper);
  font-family: var(--f-mono); font-size: 0.8rem; font-weight: 500;
}
.ctl-hint { margin-top: 10px; font-size: 0.88rem; color: var(--ink-2); max-width: 60ch; }

/* Tamaños */
.size-list {
  display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x proximity;
  margin: 0 calc(var(--panel) * -1); padding: 4px var(--panel) 12px;
  scrollbar-width: thin;
}
.size-group { display: none; }
.size-opt { flex: none; scroll-snap-align: start; position: relative; }
.size-opt input { position: absolute; opacity: 0; width: 100%; height: 100%; inset: 0; margin: 0; cursor: pointer; }
.size-opt label {
  display: grid; gap: 2px; width: 146px; min-height: 148px; padding: 12px;
  background: var(--paper); border: 1.5px solid var(--line); cursor: pointer;
  align-content: start;
}
.so-mini { display: flex; align-items: flex-end; justify-content: flex-start; gap: 3px; height: 46px; margin-bottom: 6px; }
.so-mini i { display: block; background: var(--rose); border: 1px solid var(--ink-2); }
.so-name { font-family: var(--f-display); font-weight: 400; font-size: 1.05rem; line-height: 1.15; }
.so-cm { font-family: var(--f-mono); font-size: 0.78rem; color: var(--ink-2); }
.so-price { font-weight: 700; margin-top: 4px; }
.so-promo { font-size: 0.8rem; color: var(--rose-deep); font-weight: 600; line-height: 1.25; }
.size-opt input:checked + label { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); background: var(--rose-wash); }
.size-opt input:checked + label .so-mini i { background: var(--ink); }
.size-opt input:focus-visible + label { outline: 3px solid var(--rose-deep); outline-offset: 3px; }
@media (min-width: 960px) {
  .size-list { display: grid; overflow: visible; margin: 0; padding: 0; gap: 8px; }
  .size-group { display: block; font-family: var(--f-mono); font-size: 0.72rem; letter-spacing: 0.09em;  color: var(--ink-2); margin: 10px 0 0; }
  .size-opt label {
    width: auto; min-height: 64px; padding: 10px 14px;
    grid-template-columns: 64px 1fr auto; grid-template-areas: "mini name price" "mini cm promo"; align-items: center; column-gap: 14px;
  }
  .so-mini { grid-area: mini; height: 44px; margin: 0; align-items: flex-end; justify-content: center; }
  .so-name { grid-area: name; }
  .so-cm { grid-area: cm; }
  .so-price { grid-area: price; margin: 0; text-align: right; }
  .so-promo { grid-area: promo; text-align: right; }
}

/* Orientación */
.seg { position: relative; display: grid; grid-template-columns: 1fr 1fr; max-width: 360px; border: 1px solid var(--ink-2); }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg label {
  display: flex; align-items: center; justify-content: center; min-height: 48px; cursor: pointer;
  font-weight: 650; background: var(--paper);
}
.seg label + input + label { border-left: 1px solid var(--ink-2); }
.seg input:checked + label { background: var(--ink); color: var(--paper); }
.seg input:focus-visible + label { outline: 3px solid var(--rose-deep); outline-offset: 2px; }

/* Foto */
.drop {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 18px 18px 18px 20px; min-height: 104px; cursor: pointer;
  background: var(--paper); border: 2px dashed var(--ink-2);
}
.drop .icon-lg { margin-bottom: 4px; color: var(--rose-deep); }
.drop-main { font-weight: 700; font-size: 1.05rem; }
.drop-sub { font-size: 0.9rem; color: var(--ink-2); }
.drop:hover, .drop.dragover { border-color: var(--rose-deep); background: var(--rose-wash); }
.drop:focus-within { outline: 3px solid var(--rose-deep); outline-offset: 3px; }
.photo-status { margin-top: 10px; font-size: 0.92rem; font-weight: 600; overflow-wrap: anywhere; }
.photo-actions { margin-top: 6px; }
.samples { margin-top: 14px; }
.samples-label { display: block; font-family: var(--f-mono); font-size: 0.74rem;  letter-spacing: 0.08em; color: var(--ink-2); margin-bottom: 8px; }
.samples-row { display: flex; gap: 10px; flex-wrap: wrap; }
.sample-btn { width: 64px; height: 64px; padding: 0; border: 1.5px solid var(--line); background: var(--paper); cursor: pointer; overflow: hidden; }
.sample-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sample-btn[aria-pressed="true"] { border-color: var(--ink); box-shadow: 0 0 0 2px var(--ink); }

.crop-row { display: flex; gap: 10px; flex-wrap: wrap; }
.zoom-row { display: grid; grid-template-columns: auto 1fr 3.4em; gap: 12px; align-items: center; margin-top: 10px; }
.zoom-row label { font-weight: 600; }
.zoom-row output { font-family: var(--f-mono); font-size: 0.85rem; text-align: right; }
input[type="range"] { width: 100%; min-height: 44px; margin: 0; accent-color: var(--ink); background: transparent; }

/* Pared */
.swatches { position: relative; display: flex; gap: 10px; flex-wrap: wrap; }
.swatches input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.swatches label {
  display: flex; align-items: flex-end; min-width: 72px; min-height: 52px; padding: 6px 8px; cursor: pointer;
  background: var(--sw); border: 1.5px solid var(--ink-2);
  font-size: 0.82rem; font-weight: 650; color: #2E2B2A;
}
.swatches input[data-dark] + label, #wall-carbon + label { color: #F6F0EC; }
.swatches input:checked + label { box-shadow: 0 0 0 3px var(--paper), 0 0 0 5px var(--ink); }
.swatches input:focus-visible + label { outline: 3px solid var(--rose-deep); outline-offset: 5px; }

/* Compra */
.buy { margin-top: 8px; padding: 22px 0 0; border-top: 1px solid var(--line); display: grid; gap: 12px; }
.buy-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; }
.buy-size { font-family: var(--f-display); font-weight: 400; font-size: 1.2rem; line-height: 1.2; }
.buy-promo { font-size: 0.9rem; color: var(--rose-deep); font-weight: 600; }
.buy-price { font-family: var(--f-display); font-weight: 400; font-size: 2.1rem; letter-spacing: -0.03em; line-height: 1; white-space: nowrap; }
.buy-note { font-size: 0.88rem; color: var(--ink-2); }

/* Precios con números parejos y fáciles de leer */
.buy-price, .sum-total, .buy-bar .buy-bar-price { font-family: var(--f-body); font-weight: 700; }

/* ---------- Pasos ---------- */
.steps-list { counter-reset: paso; display: grid; gap: 28px 36px; margin-top: clamp(28px, 4vw, 52px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.steps-list li { counter-increment: paso; display: grid; grid-template-columns: 48px minmax(0, 1fr); align-content: start; }
.steps-list li::before { content: counter(paso); grid-row: 1 / 3; font: 400 2.6rem/1 var(--f-display); color: var(--rose-deep); }
.steps-list h3 { font-size: 1.2rem; line-height: 1.3; margin-bottom: 6px; }
.steps-list p { color: var(--ink-2); }

/* ---------- Galería: filas de igual altura, como una pared ---------- */
main .gallery { padding-top: 0; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.filter-btn { min-height: 44px; padding: 0 16px; background: #fff; border: 1px solid var(--ink-2); border-radius: 22px; font-weight: 500; cursor: pointer; }
.filter-btn:hover { background: var(--paper-2); }
.filter-btn[aria-pressed="true"] { background: var(--ink); color: #fff; }
.filter-btn small { margin-left: 6px; }
.mosaic { --alto: 190px; display: flex; flex-wrap: wrap; gap: 18px 10px; }
.mosaic::after { content: ""; flex: 100 1 0; }
.mosaic li { flex: var(--ratio) 1 calc(var(--ratio) * var(--alto)); min-width: 0; max-width: calc(var(--ratio) * var(--alto) * 1.7); }
.mosaic img { display: block; width: 100%; aspect-ratio: var(--ratio); object-fit: cover; background: var(--paper-3); }
.mosaic figcaption { padding-top: 6px; font-size: .86rem; color: var(--ink-2); }
@media (min-width: 760px) { .mosaic { --alto: 330px; gap: 26px 18px; } }

/* ---------- Cómo son ---------- */
.spec { background: var(--ink); color: #fff; }
.spec-grid, .faq-grid { display: grid; gap: 12px 72px; }
.spec-list { display: grid; gap: 32px 48px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.spec-row dt { font-size: 1.2rem; font-weight: 600; margin-bottom: 6px; color: var(--rose-field); }
.spec-row dd { max-width: 40ch; }
.delivery-grid, .delivery-cols { display: grid; gap: 32px 72px; align-items: start; }
.delivery .lede strong { color: var(--ink); }
.plain-list { display: grid; gap: 12px; }
@media (min-width: 900px) {
  .spec-grid, .faq-grid { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); align-items: start; }
  .delivery-grid { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); }
  .delivery-cols { grid-template-columns: 1.2fr 1fr; gap: 40px; }
}

/* ---------- Opiniones (solo si se activan en config.js) ---------- */
.reviews { background: var(--paper-2); }
.reviews-list { display: grid; gap: 32px 48px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.review blockquote { margin: 0 0 10px; font: 400 1.2rem/1.45 var(--f-display); }
.review cite { font-style: normal; color: var(--ink-2); }

/* ---------- Preguntas ---------- */
main .faq { padding-top: 0; }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { position: relative; display: flex; align-items: center; min-height: 64px; padding: 14px 44px 14px 0; list-style: none; font-size: 1.12rem; font-weight: 600; cursor: pointer; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; position: absolute; right: 6px; font-size: 1.6rem; font-weight: 400; }
.faq-list details[open] summary::after { content: "\2013"; }
.faq-list details p { padding-bottom: 22px; color: var(--ink-2); max-width: 62ch; }

/* ---------- Contacto y pie ---------- */
main .contact { background: var(--rose-field); padding: clamp(48px, 7vw, 88px) 0; }
.contact-box { display: flex; flex-wrap: wrap; gap: 28px 48px; align-items: center; justify-content: space-between; }
.contact-box h2 { margin-bottom: 12px; }
.contact-box .lede { color: var(--ink); }
.site-footer { padding: 56px 0 28px; }
.footer-grid { display: grid; gap: 36px; }
.footer-brand { display: flex; gap: 18px; align-items: center; max-width: 400px; }
.footer-logo { width: 96px; height: 96px; border-radius: 50%; flex: none; }
.site-footer .plain-list { gap: 0; }
.site-footer li a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-bottom { margin-top: 32px; font-size: .9rem; color: var(--ink-2); }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } .site-footer li { min-height: 44px; } }
@media (max-width: 899px) { .site-footer { padding-bottom: calc(var(--bar-h) + 28px); } }

/* ---------- Barra de compra (celular) ---------- */
.buy-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; align-items: center; gap: 12px;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: var(--paper); border-top: 1px solid var(--line);
  min-height: var(--bar-h);
}
.buy-bar-info { flex: 1; min-width: 0; display: grid; line-height: 1.2; }
.buy-bar-label { font-size: 0.85rem; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.buy-bar-price { font-family: var(--f-display); font-weight: 400; font-size: 1.35rem; }
.buy-bar .btn { flex: none; padding: 0 16px; }
@media (min-width: 900px) { .buy-bar { display: none !important; } }

/* ---------- Backdrop + carrito ---------- */
.backdrop { position: fixed; inset: 0; z-index: 55; background: rgba(46, 43, 42, 0.55); }

.cart {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 60;
  width: min(460px, 100%); display: flex; flex-direction: column;
  background: var(--paper); border-left: 1px solid var(--line);
  box-shadow: -20px 0 40px rgba(46, 43, 42, 0.25);
  animation: slide-in 0.25s ease-out;
}
@keyframes slide-in { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.cart-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 10px 20px; border-bottom: 1px solid var(--line); }
.cart-head h2 { font-size: 1.5rem; }
.cart-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 8px 20px 32px; }
.cart-empty { padding: 36px 0; display: grid; gap: 18px; justify-items: start; color: var(--ink-2); }

.cart-items > li { display: grid; grid-template-columns: 56px minmax(0, 1fr) 44px; gap: 4px 12px; padding: 16px 0; border-bottom: 1px solid var(--line); align-items: start; }
.ci-thumb { width: 56px; height: 56px; object-fit: cover; background: var(--paper-3); border: 1px solid var(--ink-2); display: block; }
.ci-thumb-empty { display: flex; align-items: center; justify-content: center; font-family: var(--f-mono); font-size: 0.65rem; color: var(--ink-2); text-align: center; padding: 2px; }
.ci-info { min-width: 0; }
.ci-name { font-family: var(--f-display); font-weight: 400; font-size: 1.05rem; line-height: 1.2; }
.ci-meta { font-size: 0.85rem; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ci-bottom { grid-column: 2 / 4; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--ink-2); }
.qty button { width: 44px; height: 44px; border: 0; background: var(--paper); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.qty button:hover { background: var(--paper-3); }
.qty output { min-width: 36px; text-align: center; font-family: var(--f-mono); font-weight: 500; }
.ci-price { font-weight: 700; }

.cart-summary { margin: 20px 0 8px; padding: 16px; background: var(--paper-2); border: 1px solid var(--ink-2); }
.cart-promos li { font-size: 0.9rem; color: var(--rose-deep); font-weight: 650; padding: 2px 0; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; color: var(--ink-2); }
.strike { text-decoration: line-through; }
.sum-total { font-family: var(--f-display); font-weight: 400; font-size: 1.6rem; color: var(--ink); padding-top: 8px; margin-top: 6px; border-top: 1px solid var(--line); }

.checkout { margin-top: 24px; display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 650; font-size: 0.95rem; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 10px 12px; font-size: 1rem;
  background: #fff; border: 1.5px solid var(--ink-2); border-radius: var(--r);
}
.field textarea { min-height: 76px; resize: vertical; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--rose-deep); outline-offset: 1px; border-color: var(--ink); }
.was-validated .field :invalid { border-color: var(--danger); border-width: 2px; }
.field-hint { font-size: 0.85rem; color: var(--ink-2); }
.field-hint:empty { display: none; }
.form-error { padding: 10px 12px; border-left: 4px solid var(--danger); background: #FBE9EA; color: #7D1F26; font-weight: 600; font-size: 0.92rem; }
.checkout-note { font-size: 0.88rem; color: var(--ink-2); }
.checkout-note strong { color: var(--ink); }
.sent-panel { margin-top: 24px; padding: 16px; display: grid; gap: 10px; background: var(--rose-wash); border: 1px solid var(--ink-2); justify-items: start; }
.sent-panel a { font-weight: 650; }

/* ---------- Asistente virtual ---------- */
.chat { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 50; }
html.has-bar .chat { bottom: calc(var(--bar-h) + 14px + env(safe-area-inset-bottom)); }
.chat-launcher {
  position: relative; width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--paper);
  background: var(--wa); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(23, 104, 63, 0.4);
}
.chat-launcher:hover { background: var(--wa-dark); }
.backdrop-chat { z-index: 0; background: transparent; }
.chat-panel {
  position: absolute; right: 0; bottom: 68px; z-index: 1;
  width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100dvh - 180px));
  display: flex; flex-direction: column; padding: 0; background: var(--paper);
  border: 1px solid var(--line); border-radius: 10px; overflow: hidden; box-shadow: 0 18px 50px rgb(36 31 33 / .28);
  animation: slide-up 0.2s ease-out;
}
@keyframes slide-up { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
.chat-head { display: flex; gap: 12px; align-items: center; padding: 10px 8px 10px 14px; background: var(--paper-2); border-bottom: 1px solid var(--line); }
.chat-head > div { flex: 1; min-width: 0; }
.chat-head h2 { font-family: var(--f-display); font-size: 1.02rem; letter-spacing: -0.01em; line-height: 1.2; }
.chat-head p { font-size: 0.8rem; color: var(--ink-2); }
.chat-avatar { width: 40px; height: 40px; border-radius: 50%; flex: none; object-fit: cover; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; overscroll-behavior: contain; }
.msg { max-width: 88%; padding: 10px 12px; font-size: 0.95rem; white-space: pre-line; overflow-wrap: anywhere; }
.msg-bot { align-self: flex-start; background: var(--paper-2); border-radius: 10px; }
.msg-user { align-self: flex-end; background: var(--ink); color: var(--paper); border-radius: 10px; }
.msg a { color: var(--wa-dark); font-weight: 700; }
.msg-typing { color: var(--ink-2); font-family: var(--f-mono); font-size: 0.8rem; }
.msg-typing i { display: inline-block; width: 5px; height: 5px; margin-right: 3px; background: var(--ink-2); border-radius: 50%; animation: blink 1s infinite; }
.msg-typing i:nth-child(2) { animation-delay: 0.15s; }
.msg-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes blink { 0%, 80%, 100% { opacity: 0.25; } 40% { opacity: 1; } }
.chat-options { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 14px 12px; max-height: 38%; overflow-y: auto; }
.chat-opt { display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; background: var(--paper); border: 1px solid var(--ink-2); border-radius: var(--r); font-weight: 600; font-size: 0.9rem; cursor: pointer; }
.chat-opt:hover { background: var(--rose-wash); }
.chat-opt-human { background: var(--wa); color: #fff; border-color: var(--wa); }
.chat-opt-human:hover { background: var(--wa-dark); }
.chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); background: var(--paper-2); }
.chat-form input { flex: 1; min-width: 0; min-height: 44px; padding: 8px 12px; background: #fff; border: 1.5px solid var(--ink-2); border-radius: var(--r); font-size: 1rem; }
@media (max-width: 560px) {
  .backdrop-chat { background: rgba(46, 43, 42, 0.45); }
  .chat-panel { position: fixed; left: 0; right: 0; bottom: 0; width: auto; height: min(82dvh, 640px); border-width: 2px 0 0; box-shadow: none; }
}

/* ---------- Sin animaciones (preferencia del dispositivo o botón) ---------- */
html:not(.anim) { scroll-behavior: auto; }
html:not(.anim) body *, html:not(.anim) body *::before, html:not(.anim) body *::after { animation: none !important; }
html:not(.anim) .intro { animation: intro-fin 0s 6s forwards !important; }
.sum-total { font-family: var(--f-body); font-weight: 700; }

/* ---------- Puntero de peluche (solo con mouse) ---------- */
@media (hover: hover) and (pointer: fine) {
  html {
    cursor: url("assets/cursor-flecha.png") 5 4, auto;
    cursor: image-set(url("assets/cursor-flecha.png") 1x, url("assets/cursor-flecha-2x.png") 2x) 5 4, auto;
  }
  a, button, select, summary, label, input[type="radio"], input[type="range"], .size-opt input, .drop, .intro {
    cursor: url("assets/cursor-corazon.png") 24 22, pointer !important;
    cursor: image-set(url("assets/cursor-corazon.png") 1x, url("assets/cursor-corazon-2x.png") 2x) 24 22, pointer !important;
  }
  .field label { cursor: inherit !important; }
  button:disabled { cursor: not-allowed !important; }
}
