/* =========================================================
   COMPONENTS — piezas reutilizables en todas las páginas
   ========================================================= */
@layer components {
  /* ---------- Botones (estilo sereno, 28/10): píldoras redondeadas, sin mayúsculas. Negro relleno para comprar y lo
     principal, con borde para lo secundario, blancos sobre fondos oscuros. 44 px o más de alto ---------- */
  .btn {
    --btn-fg: var(--on-dark); --btn-bg: var(--brand); --btn-bd: var(--brand); --btn-hover: var(--brand-hover); --btn-hover-fg: var(--btn-fg);
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 46px; padding: 0 28px;
    border: 1px solid var(--btn-bd); border-radius: var(--btn-radius);
    background: var(--btn-bg); color: var(--btn-fg);
    font-size: 0.9375rem; font-weight: 500; letter-spacing: 0.02em; text-decoration: none; white-space: nowrap;
    transition: background var(--fast), border-color var(--fast), color var(--fast), box-shadow var(--fast);
  }
  .btn:hover { background: var(--btn-hover); border-color: var(--btn-hover); color: var(--btn-hover-fg); }
  .btn:active { scale: 0.98; }
  .btn .icon { width: 18px; height: 18px; }
  /* Principal: negro relleno (valores por defecto) */
  .btn--primary { /* valores por defecto */ }
  /* Píldora chica (02/11): encabezados de sección (óxido) y categoría en el escenario de estrellas (con borde). */
  .pill { display: inline-flex; align-items: center; min-height: 26px; padding: 3px 12px; border-radius: var(--pill); font-size: 0.75rem; font-weight: 600;
    letter-spacing: 0.06em; line-height: 1.2; text-transform: uppercase; background: var(--sand); color: var(--ink-2); }
  .pill--rust { background: var(--rust); color: #fff; }          /* 6,3:1 */
  .pill--line { border: 1px solid var(--line-strong); background: var(--paper); color: var(--ink-2); }
  .pill--light { border: 1px solid rgb(255 255 255 / 40%); background: rgb(255 255 255 / 12%); color: #fff; }
  /* Píldora + título de las filas y de los encabezados con enlace al costado. */
  .rail__head, .section__titles { display: grid; justify-items: start; gap: 10px; min-width: 0; }
  /* «Miralo en acción» del escenario de estrellas: chip con ícono de play. */
  .play-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 0 14px; border-radius: var(--pill); background: var(--sand);
    color: var(--ink); font-size: var(--fs-sm); font-weight: 500; text-decoration: none; transition: background var(--fast) var(--ease); }
  .play-chip:hover { background: var(--sand-2); }
  .play-chip .icon { width: 14px; height: 14px; }
  /* Negro: «Calcular», aceptar/rechazar cookies, avisarme */
  .btn--dark { --btn-bg: var(--espresso); --btn-bd: var(--espresso); --btn-hover: #000000; }
  /* Secundario y contorno: borde negro fino y texto negro; al pasar, se rellena de negro */
  .btn--secondary, .btn--outline { --btn-fg: var(--ink); --btn-bg: transparent; --btn-bd: var(--ink); --btn-hover: var(--ink); --btn-hover-fg: #fff; }
  /* Sobre fondos oscuros: blanco relleno o con borde blanco */
  .btn--light { --btn-fg: var(--ink); --btn-bg: #fff; --btn-bd: #fff; --btn-hover: var(--sand-2); --btn-hover-fg: var(--ink); }
  .btn--ghost { --btn-fg: #fff; --btn-bg: transparent; --btn-bd: #fff; --btn-hover: #fff; --btn-hover-fg: var(--ink); }
  /* Píldora (compatibilidad con plantillas anteriores): igual que el botón principal */
  .btn--pill { padding-inline: 28px; }
  /* Enlace subrayado (mismo alto táctil) */
  .btn--text { --btn-fg: var(--ink); --btn-bg: transparent; --btn-bd: transparent; --btn-hover: transparent; --btn-hover-fg: var(--ink); padding-inline: 6px; letter-spacing: 0; font-size: var(--fs-sm); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
  .btn--text:hover { text-decoration-thickness: 2px; }
  .btn--lg { min-height: 52px; padding-inline: 34px; font-size: var(--fs-base); }
  .btn--xl { min-height: 56px; font-size: var(--fs-base); }
  .btn--sm { min-height: var(--tap); padding-inline: 18px; font-size: var(--fs-sm); }
  .btn--block { display: flex; width: 100%; }
  .btn[disabled], .btn[aria-disabled="true"], .btn[aria-busy="true"] { opacity: 0.45; pointer-events: none; }
  .btn[aria-busy="true"]::after { content: ""; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin 0.7s linear infinite; }

  .link-arrow { display: inline-flex; align-items: center; gap: 8px; min-height: var(--tap); font-size: var(--fs-sm); font-weight: 500; text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
  .link-arrow:hover { text-decoration-thickness: 2px; }
  .link-back { display: inline-flex; align-items: center; gap: 8px; min-height: var(--tap); font-size: var(--fs-sm); color: var(--muted); text-decoration: none; }
  .link-back:hover { color: var(--ink); }
  .view-all { display: inline-flex; align-items: center; min-height: var(--tap); font-size: var(--fs-sm); font-weight: 500; text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
  .view-all:hover { text-decoration-thickness: 2px; }
  /* Botones del pie de atención al consumidor: el texto largo baja de renglón en el celular */
  .footer__consumer .btn { white-space: normal; height: auto; padding-block: 10px; }

  /* ---------- Formularios ---------- */
  .field { display: grid; gap: 6px; margin-bottom: 16px; }
  .field label { font-size: var(--fs-sm); font-weight: 500; }
  .field label small { font-weight: 400; color: var(--muted); }
  .field-row { display: grid; gap: 0 14px; grid-template-columns: 1fr; }
  @media (min-width: 560px) { .field-row { grid-template-columns: 1fr 1fr; } .field-row--street { grid-template-columns: 2.2fr 1fr; } }
  .input, .select {
    width: 100%; min-height: 50px; padding: 12px 14px;
    background: var(--paper); border: 1px solid var(--field); border-radius: var(--radius);
    font-size: 16px; transition: border-color var(--fast), box-shadow var(--fast);
    appearance: none; -webkit-appearance: none;
  }
  textarea.input { resize: vertical; min-height: 110px; line-height: 1.5; }
  .input:hover, .select:hover { border-color: var(--ink-2); }
  .input:focus, .select:focus { outline: 2px solid var(--focus); outline-offset: 1px; border-color: var(--focus); }
  .input[aria-invalid="true"], .select[aria-invalid="true"] { border-color: var(--err); background: var(--err-soft); }
  .input.is-valid { border-color: var(--ok); }
  .input--sm, .select--sm { min-height: 44px; padding: 8px 12px; }
  .field__error { font-size: var(--fs-sm); color: var(--err); font-weight: 500; }
  .field__error:empty { display: none; }
  /* «¿Quisiste decir …?» debajo del email (20/10) */
  .field__hint { display: flex; flex-wrap: wrap; align-items: center; gap: 0 4px; font-size: var(--fs-sm); color: var(--ink-2); }
  .field__hint[hidden] { display: none; }
  .field__hint .btn--text { min-height: 32px; padding-inline: 2px; font-weight: 600; }
  .form-msg { margin-top: 10px; font-size: var(--fs-sm); }
  .form-msg:empty { display: none; }
  .form-msg.is-ok { color: var(--ok); font-weight: 600; }
  .form-msg.is-error { color: var(--err); font-weight: 600; }
  .form-hint { font-size: var(--fs-sm); color: var(--muted); margin-bottom: 14px; }
  .select-wrap { position: relative; display: inline-block; }
  .select-wrap--field { display: block; }
  .select-wrap .icon { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); pointer-events: none; width: 18px; height: 18px; }
  .select { padding-right: 40px; cursor: pointer; }

  .check { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-sm); cursor: pointer; }
  .check input { appearance: none; -webkit-appearance: none; flex: none; width: 22px; height: 22px; margin: 0; border: 1.5px solid var(--field); border-radius: 4px; background: var(--paper); display: grid; place-items: center; cursor: pointer; }
  .check input::after { content: ""; width: 10px; height: 6px; border-left: 2px solid var(--on-dark); border-bottom: 2px solid var(--on-dark); transform: rotate(-45deg) scale(0); margin-top: -2px; transition: transform var(--fast) var(--ease); }
  .check input:checked { background: var(--brand); border-color: var(--brand); }
  .check input:checked::after { transform: rotate(-45deg) scale(1); }
  .check input:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
  .check--sm { font-size: var(--fs-xs); color: var(--ink-2); }
  .check--dark { color: var(--on-dark-muted); }
  .check--dark a { color: var(--on-dark); }
  .check--dark input { border-color: var(--on-dark-muted); background: transparent; }
  .check--dark input:checked { border-color: #fff; background: #fff; }
  .check--dark input::after { border-color: var(--ink); }
  .check--dark input:focus-visible { outline-color: #fff; }

  .alert { padding: 14px 16px; font-size: var(--fs-sm); margin-bottom: 18px; border-radius: var(--radius); }
  .alert--error { background: var(--err-soft); color: var(--err); }
  .alert--ok { background: var(--ok-soft); color: var(--ok); }
  .alert--warn { background: var(--warn-soft); color: var(--warn); }

  .panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(18px, 3vw, 28px); margin: 0 0 16px; min-width: 0; }
  .panel--plain { background: none; border: 0; padding: 0; }
  .panel legend, .panel__title { display: flex; align-items: center; gap: 12px; font-family: var(--font-display); font-weight: 500; font-size: var(--fs-xl); padding: 0; float: left; width: 100%; margin-bottom: 16px; }
  .panel legend + * { clear: both; }
  .panel__n { width: 30px; height: 30px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--espresso); color: var(--on-dark); font-family: var(--font); font-size: var(--fs-xs); font-weight: 600; }

  /* ---------- Chips y barra de herramientas ---------- */
  .chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 6px; -webkit-overflow-scrolling: touch; }
  .chips::-webkit-scrollbar { display: none; }
  /* Filtros en píldora gris; el elegido, negro */
  .chip-btn { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px; border: 0; border-radius: var(--pill); background: var(--sand); color: var(--ink); font-size: var(--fs-sm); font-weight: 400; text-decoration: none; transition: background var(--fast), color var(--fast); }
  .chip-btn:hover { background: var(--sand-2); }
  .chip-btn[aria-current="page"], .chip-btn[aria-selected="true"], .chip-btn[aria-pressed="true"], .chip-btn.is-active { background: var(--brand); color: var(--on-dark); }
  /* «Ofertas» en la fila de categorías de la tienda (solo si hay productos con descuento) */
  .chip-btn--offers { background: var(--rust-soft); color: var(--rust); }
  .chip-btn--offers:hover { background: var(--beige); }
  .chip-btn--offers .icon { width: 15px; height: 15px; }
  .chip-btn--offers[aria-current="page"] { background: var(--rust); color: #fff; }
  .toolbar { display: grid; gap: 14px; margin-bottom: 18px; }
  .toolbar__controls { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
  .search { position: relative; flex: 1 1 220px; }
  .search .icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--muted); }
  .search__input { width: 100%; min-height: 48px; padding: 0 18px 0 46px; border: 1px solid transparent; border-radius: var(--pill); background: var(--sand); font-size: 16px; }
  .search__input:hover { border-color: var(--line-strong); }
  .search__input:focus { outline: 0; border-color: var(--ink); background: var(--paper); }
  @media (min-width: 1000px) { .toolbar { grid-template-columns: 1fr auto; align-items: center; } }
  .results-count { color: var(--muted); font-size: var(--fs-sm); margin-bottom: 16px; }
  .empty { text-align: center; padding: 56px 20px; display: grid; gap: 12px; justify-items: center; }
  .empty h2 { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 500; }

  /* ---------- Tarjeta de producto (estilo sereno, 28/10) ----------
     Sin caja ni sombra: la foto sobre gris claro (4:5) y debajo, a la izquierda, estrellas, nombre, frase corta y precio.
     Sobre la foto: las etiquetas arriba a la izquierda y el botón redondo para agregar abajo a la derecha (o la cantidad
     si ya está en el carrito, o «Avisame» sin stock). Al pasar el mouse se ve la segunda foto. */
  .product-grid { display: grid; gap: 32px 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  @media (min-width: 760px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 20px; } }
  @media (min-width: 1100px) { .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 48px 30px; } }

  .card { position: relative; display: flex; flex-direction: column; min-width: 0; background: transparent; }
  /* Cuadrada (29/10, pedido del dueño): las fotos son cuadradas y así se ven enteras, sin cortes a los costados. */
  .card__media { position: relative; aspect-ratio: 1; background: var(--tile); }
  .card__visual { position: absolute; inset: 0; display: grid; place-items: center; overflow: hidden; isolation: isolate; background: var(--tile); }
  /* <picture> no arma caja; sus <source> tampoco (si no, cuentan como filas de la grilla y achican la foto). */
  .card__visual picture { display: contents; }
  .card__visual source { display: none; }
  .card__visual img { position: relative; z-index: 1; grid-area: 1 / 1; width: 82%; height: 82%; object-fit: contain; mix-blend-mode: multiply;
    transition: opacity var(--slow) var(--ease), transform 0.8s cubic-bezier(0.22, 1, 0.36, 1); }
  .photo--ambientada .card__visual img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
  .photo--ambientada .card__visual .card__img-alt { width: 82%; height: 82%; object-fit: contain; mix-blend-mode: multiply; }
  /* Segunda foto (al pasar el mouse): si es una escena de uso ocupa todo el cuadro; si es el producto solo, va sobre gris. */
  .card__visual .card__img-alt.is-scene { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
  .card__visual .card__img-alt { opacity: 0; }
  @media (hover: hover) and (pointer: fine) {
    /* La primera foto se oculta del todo (28/10: con «img:first-child» la que está dentro de <picture>, después de los
       <source>, seguía visible y se veían las dos fotos mezcladas). */
    .card:hover .card__visual:has(.card__img-alt) img:not(.card__img-alt) { opacity: 0; }
    .card:hover .card__visual .card__img-alt { opacity: 1; }
    .card:hover .card__visual:not(:has(.card__img-alt)) img { transform: scale(1.04); }
  }
  /* Etiquetas sobre la foto (arriba a la izquierda), 02/11: una sola etiqueta comercial en píldora (mismo alto en todas,
     colores por tipo) y «Envío gratis». El stock va debajo del precio (.card__stock). Contrastes AA anotados al lado. */
  .card__flags { position: absolute; z-index: 2; top: 10px; left: 10px; right: 10px; display: flex; flex-wrap: wrap; gap: 6px; pointer-events: none; }
  .card__badge, .card__ship { display: inline-flex; align-items: center; gap: 5px; min-height: 24px; padding: 3px 10px; border: 1px solid transparent;
    border-radius: var(--pill); background: var(--ink); color: #fff; font-size: 0.6875rem; font-weight: 600; line-height: 1.2; letter-spacing: 0.02em; }
  .card__badge .icon { width: 12px; height: 12px; }
  .card__ship { background: var(--paper); color: var(--ink); font-weight: 500; }
  .card__ship .icon { width: 14px; height: 14px; }
  .card__badge--sale { background: var(--rust); }                                                  /* blanco sobre óxido 6,3:1 */
  .card__badge--star { background: var(--ink); }                                                   /* blanco sobre negro 16,9:1 */
  .card__badge--star .icon { color: #f4c84a; }
  /* Etiquetas que elige el dueño (F4) */
  .card__badge--tendencia { background: var(--rust-soft); color: var(--rust); }                    /* 5,4:1 */
  .card__badge--nuevo { border-color: var(--ink); background: var(--paper); color: var(--ink); }   /* 16,9:1, borde fino */
  .card__badge--mas-pedido { background: var(--ink); }                                             /* 16,9:1 */
  .card__badge--edicion-limitada { border-color: var(--rust); background: var(--paper); color: var(--rust); } /* 6,3:1 */
  /* «Tiene video»: ícono chico abajo a la izquierda */
  .card__video { position: absolute; z-index: 2; bottom: 10px; left: 10px; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--night); color: #fff; pointer-events: none; }
  .card__video .icon { width: 14px; height: 14px; margin-left: 2px; }

  .card__body { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding-top: 14px; text-align: left; }
  .card__title { font-family: var(--font); font-size: 0.9375rem; font-weight: 400; line-height: 1.35; color: var(--ink);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .card__link { text-decoration: none; }
  .card__link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
  .card__link:hover { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
  .card__link:focus-visible { outline: none; }
  .card__link:focus-visible::after { outline: 2px solid var(--focus); outline-offset: 3px; }
  .card__tag { font-size: var(--fs-xs); line-height: 1.4; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
  .card__stars { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 2px; font-size: var(--fs-xs); color: var(--ink-2); }
  .card__soldout { font-size: var(--fs-sm); color: var(--muted); }
  /* Precio: el actual; rebajado en terracota con el anterior tachado y «-10% OFF» al lado. Debajo, en letra chica, el
     precio sin impuestos nacionales. */
  .card__price { display: grid; justify-items: start; gap: 2px; margin-top: 4px; }
  .card__now { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
  .card__amount { display: inline-flex; align-items: baseline; gap: 0.2em; font-size: 0.9375rem; font-weight: 500; line-height: 1.3; color: var(--ink); font-variant-numeric: tabular-nums; }
  .card__now.is-sale .card__amount { color: var(--rust); }
  .card__cur { font-size: 1em; }
  .card__was { font-size: var(--fs-xs); color: var(--muted); font-variant-numeric: tabular-nums; }
  /* «-15% OFF» en una pastilla óxido chiquita (blanco encima 6,3:1) */
  .card__off { padding: 1px 8px; border-radius: var(--pill); background: var(--rust); color: #fff; font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.02em; line-height: 1.5; align-self: center; }
  .card .installments { font-size: var(--fs-xs); color: var(--ink-2); }
  .card__transfer { font-size: var(--fs-xs); line-height: 1.35; color: var(--ink); }
  .card__transfer span { color: var(--rust); }
  /* Res. 4/2025: el precio sin impuestos nacionales, en letra más chica y liviana que el precio (02/11: más suave, sin
     perder el contraste AA del gris apagado). */
  .card__notax { font-size: 0.6875rem; line-height: 1.3; font-weight: 400; letter-spacing: 0.01em; color: var(--muted); }
  /* Estado del stock (02/11): fuera de la foto, una línea chica con un punto. 16/11: en bloque y el punto en línea (antes
     era flex y en tarjetas angostas «Sin stock» y «· te avisamos…» quedaban como dos columnas partidas). */
  .card__stock { display: block; margin-top: 3px; font-size: var(--fs-xs); line-height: 1.3; color: var(--muted); }
  .card__stock::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 6px; vertical-align: 0.1em; border-radius: 50%; background: var(--line-strong); }
  .card__stock.is-low { color: var(--rust); }
  .card__stock.is-low::before { background: var(--rust); }
  @media (max-width: 599px) { .card__stock-more { display: none; } }
  /* Acciones sobre la foto (abajo a la derecha), encima del enlace de la tarjeta. */
  .card__actions { position: absolute; z-index: 3; right: 10px; bottom: 10px; display: flex; justify-content: flex-end; max-width: calc(100% - 20px); }
  .card__buy { display: grid; place-items: center; width: var(--tap); height: var(--tap); border-radius: 50%; background: var(--paper); color: var(--ink);
    box-shadow: 0 2px 10px rgb(0 0 0 / 12%); transition: background var(--fast), color var(--fast), transform var(--fast); }
  .card__buy:hover { background: var(--ink); color: #fff; }
  .card__buy .icon { width: 21px; height: 21px; }
  .card__buy--text { display: inline-flex; align-items: center; justify-content: center; gap: 6px; width: auto; height: auto; min-height: var(--tap); padding: 0 16px;
    border-radius: var(--pill); background: var(--paper); color: var(--ink); box-shadow: 0 2px 10px rgb(0 0 0 / 12%); font-size: var(--fs-xs); font-weight: 500; text-decoration: none; }
  /* Sin stock (02/11): la campanita redonda también en la compu, en lugar del botón grande «Avisame» sobre la foto. El
     lector de pantalla sigue diciendo «Avisame cuando vuelva …». */
  .card__notify { position: relative; display: grid; place-items: center; width: var(--tap); height: var(--tap); min-height: var(--tap); padding: 0;
    border-radius: 50%; background: var(--paper); color: var(--ink); box-shadow: 0 2px 10px rgb(0 0 0 / 12%); text-decoration: none; }
  .card__notify span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .card__notify:hover { background: var(--ink); color: #fff; }
  .card__notify .icon { width: 18px; height: 18px; }
  /* Tarjetas en el celular (01/11): la foto despejada («Avisame» pasa a una campanita redonda del tamaño del botón de
     agregar; el nombre accesible sigue siendo «Avisame cuando vuelva …»), el nombre en hasta dos líneas parejas, el precio
     más marcado y sin la frase corta (sigue en la ficha y en la compu). */
  @media (max-width: 599px) {
    .card__flags { top: 8px; left: 8px; right: 8px; }
    .card__actions { right: 8px; bottom: 8px; }
    .card__buy:not(.card__buy--text) { width: 40px; height: 40px; }
    .card__notify { width: 40px; height: 40px; min-height: 40px; padding: 0; border-radius: 50%; }
    .card__notify span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    .card__notify .icon { width: 17px; height: 17px; }
    .card__body { gap: 2px; padding-top: 10px; }
    .card__title { font-size: 0.875rem; line-height: 1.3; min-height: 2.6em; }
    .card__tag { display: none; }
    .card__price { margin-top: 2px; }
    .card__amount { font-size: 1.0625rem; font-weight: 600; }
  }
  /* Recién agregado: un saltito del botón (sin animación si se pidió reducir movimiento). */
  @media (prefers-reduced-motion: no-preference) { .card__buy:active { transform: scale(0.92); } }
  .card__quantity { display: grid; grid-template-columns: 40px minmax(2.4ch, auto) 40px; align-items: center; height: var(--tap); border-radius: var(--pill); background: var(--paper); color: var(--ink); box-shadow: 0 2px 10px rgb(0 0 0 / 12%); overflow: hidden; }
  .card__quantity button { display: grid; place-items: center; height: var(--tap); }
  .card__quantity button:hover:not(:disabled) { background: var(--sand); }
  .card__quantity button:disabled { opacity: 0.3; cursor: not-allowed; }
  .card__quantity .icon { width: 14px; height: 14px; }
  .card__quantity output { text-align: center; font-size: var(--fs-sm); font-weight: 600; font-variant-numeric: tabular-nums; }
  .card__actions [hidden] { display: none; }
  .cart-line__stock-warning { display: block; color: var(--err); font-size: var(--fs-sm); }
  /* Colores de la tarjeta: puntitos debajo del nombre */
  .swatches--card { margin-top: 4px; }

  /* ---------- Filas que se deslizan (estilo sereno, 28/10): inicio, «Categorías» de la tienda y «También te puede
     interesar» de la ficha ----------
     Arriba el título y «Ver todo»; las tarjetas se deslizan con el dedo o con las flechas; los puntos dicen en qué parte de
     la fila estás. En el celular las flechas y los puntos van debajo; en la compu, arriba a la derecha (como la referencia).
     Las de productos del inicio avanzan solas y se frenan al tocarlas (components/rail.js). */
  .rail { padding-top: clamp(40px, 5vw, 64px); }
  .rail__grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 22px 16px; }
  .rail__title { font-family: var(--font-display); font-size: clamp(1.5rem, 1.25rem + 0.9vw, 1.875rem); font-weight: 500; line-height: 1.15; letter-spacing: -0.015em; }
  .rail__all { justify-self: end; }
  .rail__body { grid-column: 1 / -1; display: grid; gap: 12px; min-width: 0; }
  .rail__track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 16px) / 2.15); gap: 0 16px; min-width: 0;
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .rail__track::-webkit-scrollbar { display: none; }
  .rail__track > * { scroll-snap-align: start; }
  .rail__track.product-grid { grid-template-columns: none; }
  .rail__track > .card { animation: none; }
  .cat-rail { grid-auto-columns: 72%; }
  .rail__nav { display: flex; align-items: center; gap: 14px; }
  .rail__nav:not(:has(button:not([hidden]))) { display: none; }
  .rail__arrow { display: grid; place-items: center; width: var(--tap); height: var(--tap); margin-inline: -10px; color: var(--ink); }
  .rail__arrow[hidden] { display: none; }
  .rail__arrow:disabled { color: var(--line-strong); cursor: default; }
  .rail__arrow .icon { width: 22px; height: 22px; }
  .rail__dots { display: flex; align-items: center; gap: 8px; }
  .rail__dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--line-strong); transition: background-color var(--base) var(--ease), transform var(--base) var(--ease); }
  .rail__dots i.is-on { background: var(--ink); transform: scale(1.25); }
  @media (min-width: 600px) { .rail__track { grid-auto-columns: calc((100% - 2 * 20px) / 3); gap: 0 20px; } .cat-rail { grid-auto-columns: calc((100% - 20px) / 2.4); } }
  @media (min-width: 900px) {
    .rail__grid { grid-template-columns: minmax(0, 1fr) auto auto; gap: 28px 36px; }
    .rail__body { display: contents; }
    .rail__nav { grid-area: 1 / 2; }
    .rail__all { grid-area: 1 / 3; }
    .rail__track { grid-row: 2; grid-column: 1 / -1; grid-auto-columns: calc((100% - 3 * 30px) / 4); gap: 0 30px; }
  }
  .rail__track > .skeleton--card { min-height: 0; }

  /* Tarjeta de categoría: la foto sobre gris, el nombre y la cantidad. */
  .cat-tile { display: grid; gap: 4px; color: var(--ink); text-decoration: none; }
  .cat-tile__img { display: grid; place-items: center; aspect-ratio: 1; margin-bottom: 10px; overflow: hidden; background: var(--tile); }
  .cat-tile__img img { width: 100%; height: 100%; padding: 9%; object-fit: contain; mix-blend-mode: multiply; transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1); }
  .cat-tile__img.photo--ambientada img { padding: 0; object-fit: cover; mix-blend-mode: normal; }
  .cat-tile__img .icon { width: 30%; height: 30%; color: var(--ink-2); }
  .cat-tile__name { font-size: var(--fs-lg); line-height: 1.25; }
  .cat-tile__count { font-size: var(--fs-sm); color: var(--muted); }
  .cat-tile__go { display: none; }
  @media (hover: hover) and (pointer: fine) {
    .cat-tile:hover img { transform: scale(1.04); }
    .cat-tile:hover .cat-tile__name { text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
  }

  /* ---------- Precio y cuotas ---------- */
  .price { font-size: var(--fs-base); font-weight: 500; font-variant-numeric: tabular-nums; }
  .price.has-discount { display: inline-flex; flex-wrap: wrap; align-items: baseline; column-gap: 8px; }
  .price__now { color: var(--accent); }
  .price.has-discount .price__now { color: var(--rust); }
  .price__was { font-size: 0.8em; font-weight: 400; color: var(--muted); }
  .installments { font-size: var(--fs-sm); color: var(--ink-2); }
  /* «Precio sin impuestos nacionales» (Res. 4/2025, Ley 27.743): en letra más chica que el precio */
  .price-notax { display: block; font-size: var(--fs-xs, 0.8125rem); color: var(--ink-2); }
  .installments:empty { display: none; }
  .installments--transfer { color: var(--ink); font-weight: 500; }
  /* «¿Tenés un cupón?» (carrito y checkout) */
  .coupon { display: grid; gap: 6px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
  .coupon__form { display: grid; gap: 6px; }
  .coupon__label { font-size: var(--fs-sm); font-weight: 500; }
  .coupon__row { display: flex; gap: 8px; }
  .coupon__row .input { flex: 1 1 auto; min-width: 0; min-height: var(--tap); text-transform: uppercase; }
  .coupon__row .btn { min-height: var(--tap); }
  .coupon > .btn--text { justify-self: start; min-height: var(--tap); }
  .coupon__msg { font-size: var(--fs-sm); color: var(--ok); }
  .coupon__msg:empty { display: none; }
  .coupon__msg.is-error { color: var(--err); }
  .discount-badge { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: var(--radius-sm); background: var(--rust); color: #fff; font-size: var(--fs-xs); font-weight: 500; line-height: 1.4; }

  /* ---------- Estrellas (solo con reseñas reales aprobadas) ---------- */
  .stars { --pct: 0%; position: relative; display: inline-block; width: 5.4em; height: 1em; font-size: 14px; line-height: 1; background: linear-gradient(90deg, var(--ink) var(--pct), var(--line-strong) var(--pct)); -webkit-mask: var(--stars-mask) repeat-x left center / 1.08em 1em; mask: var(--stars-mask) repeat-x left center / 1.08em 1em; }
  :root { --stars-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5l2.9 6 6.6.8-4.9 4.5 1.3 6.5L12 17l-5.9 3.3 1.3-6.5L2.5 9.3l6.6-.8z'/%3E%3C/svg%3E"); }

  /* ---------- Cantidad (píldora) ---------- */
  .qty { display: inline-flex; align-items: center; width: max-content; overflow: hidden; border: 1px solid var(--line-strong); border-radius: var(--pill); background: var(--paper); }
  .qty button { display: grid; place-items: center; width: var(--tap); height: 46px; transition: background var(--fast); }
  .qty button:hover:not([disabled]) { background: var(--sand); }
  .qty button[disabled] { opacity: 0.3; pointer-events: none; }
  .qty .icon { width: 16px; height: 16px; }
  .qty output { min-width: 28px; text-align: center; font-weight: 500; font-variant-numeric: tabular-nums; }

  /* ---------- Carrito (panel lateral) ---------- */
  .overlay { position: fixed; inset: 0; z-index: 90; background: rgb(0 0 0 / 45%); opacity: 0; visibility: hidden; transition: opacity var(--base), visibility var(--base); }
  .overlay.is-visible { opacity: 1; visibility: visible; }
  .drawer { position: fixed; z-index: 100; top: 0; right: 0; bottom: 0; width: min(480px, 100%); display: flex; flex-direction: column; background: var(--paper); box-shadow: -24px 0 60px -30px rgb(0 0 0 / 40%); transform: translateX(105%); visibility: hidden; transition: transform 0.42s var(--ease), visibility 0.42s; outline: none; }
  .drawer.is-open { transform: none; visibility: visible; }
  .drawer__head { display: flex; align-items: center; justify-content: space-between; min-height: 64px; padding: 0 12px 0 20px; border-bottom: 1px solid var(--line); background: var(--paper); }
  .drawer__head h2 { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 500; }
  .drawer__count { color: var(--muted); font-family: var(--font); font-weight: 400; font-size: var(--fs-sm); }
  .drawer__body { flex: 1; overflow-y: auto; padding: 4px 20px 16px; overscroll-behavior: contain; }
  .drawer__foot { padding: 14px 20px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--paper); display: grid; gap: 10px; }
  .drawer__totals { display: grid; gap: 6px; margin: 0; }
  .drawer__totals div { display: flex; justify-content: space-between; gap: 16px; font-size: var(--fs-sm); }
  .drawer__totals dt { color: var(--ink-2); }
  .drawer__totals dd { margin: 0; text-align: right; font-weight: 500; }
  .drawer__total { padding-top: 8px; border-top: 1px solid var(--line); font-size: var(--fs-lg) !important; }
  .drawer__total dt { color: var(--ink) !important; font-weight: 600; }
  .drawer__secure { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: var(--fs-xs); color: var(--muted); }
  .drawer__secure .icon { width: 14px; height: 14px; }
  .drawer__suggest { padding-top: 18px; margin-top: 8px; border-top: 1px solid var(--line); }
  .drawer__suggest h3 { font-family: var(--font-display); font-size: var(--fs-lg); font-weight: 500; margin-bottom: 10px; }
  .mini-list { display: grid; gap: 10px; }
  .mini { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
  .mini__img { width: 64px; height: 64px; border-radius: 0; background: var(--tile); display: grid; place-items: center; overflow: hidden; }
  .mini__img img { width: 86%; height: 86%; object-fit: contain; mix-blend-mode: multiply; }
  .mini__name { display: block; font-size: var(--fs-sm); font-weight: 500; line-height: 1.3; text-decoration: none; }
  .mini__name:hover { text-decoration: underline; }
  .mini .price { font-size: var(--fs-sm); }
  .mini__add { width: var(--tap); height: var(--tap); display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--paper); }
  .mini__add:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
  /* «¿Querés sumar…?» (F7): una sola sugerencia, con su motivo */
  .mini__why { display: flex; flex-wrap: wrap; gap: 2px 8px; font-size: var(--fs-xs); color: var(--muted); margin: 2px 0; }
  .mini__why a { color: var(--ink-2); }
  .mini__add-btn { gap: 4px; white-space: nowrap; }
  .mini__add-btn .icon { width: 16px; height: 16px; }
  .mini__img.photo--ambientada img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
  .cart-empty { display: grid; justify-items: center; gap: 12px; text-align: center; padding: 56px 10px; color: var(--ink-2); }
  .cart-empty .icon { width: 40px; height: 40px; color: var(--muted); }

  .ship-progress { padding: 12px 16px; margin: 12px 0 0; border-radius: 0; background: var(--sand); border: 0; }
  .drawer .ship-progress { margin: 12px 20px 0; }
  .ship-progress__text { font-size: var(--fs-sm); margin-bottom: 8px; }
  .ship-progress__bar { height: 6px; border-radius: var(--pill); background: var(--paper); overflow: hidden; }
  .ship-progress__bar span { display: block; height: 100%; width: 100%; background: var(--ink); transform-origin: left; transform: scaleX(var(--p, 0)); transition: transform 0.5s var(--ease); border-radius: inherit; }
  .ship-progress.is-complete .ship-progress__bar span { background: var(--ok); }

  .cart-line { display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); }
  .cart-line:last-child { border-bottom: 0; }
  /* Miniatura de una línea del carrito: mismo criterio de fotos parejas que las tarjetas. */
  .line-photo { display: grid; place-items: center; width: 76px; height: 76px; border-radius: 0; background: var(--tile); overflow: hidden; isolation: isolate; }
  .line-photo img { width: 84%; height: 84%; object-fit: contain; mix-blend-mode: multiply; }
  .line-photo.photo--ambientada img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
  .cart-line__info { min-width: 0; display: grid; gap: 4px; align-content: start; }
  .cart-line__name { font-weight: 500; font-size: var(--fs-sm); line-height: 1.3; text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .cart-line__name:hover { text-decoration: underline; }
  .cart-line__kit { font-size: var(--fs-xs); color: var(--muted); }
  .cart-line__price { font-size: var(--fs-sm); color: var(--muted); display: flex; gap: 6px; align-items: baseline; }
  .cart-line__side { display: grid; justify-items: end; align-content: space-between; gap: 8px; }
  .cart-line__total { font-weight: 500; font-size: var(--fs-sm); }
  .cart-line__remove { min-height: 36px; color: var(--muted); font-size: var(--fs-sm); text-decoration: underline; }
  .cart-line__remove:hover { color: var(--err); }
  /* Saltito del número del carrito al agregar algo (20/10) */
  [data-cart-count].is-bump { animation: cart-bump 420ms var(--ease); }
  @keyframes cart-bump { 0% { transform: scale(1); } 35% { transform: scale(1.35); } 100% { transform: scale(1); } }
  @media (prefers-reduced-motion: reduce) { [data-cart-count].is-bump { animation: none; } }
  /* Collage del combo en el carrito (20/10): 2 o 3 fotos en el mismo lugar que ocupa la foto de un producto. */
  .kit-thumb { display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: 1fr; gap: 2px; width: 76px; height: 76px; padding: 0; border-radius: 0; background: var(--paper); }
  .kit-thumb img { width: 100%; height: 100%; min-height: 0; object-fit: contain; border-radius: 0; background: var(--tile); padding: 2px; mix-blend-mode: multiply; }
  .kit-thumb--3 img:first-child { grid-row: span 2; }
  .cart-line__save { display: block; font-size: var(--fs-xs); font-weight: 500; color: var(--rust); }
  .cart-line .qty button { width: 38px; height: 38px; }

  /* ---------- Avisos breves ---------- */
  .toasts { position: fixed; z-index: 130; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%); display: grid; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
  .toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; padding: 10px 16px 10px 12px; border-radius: var(--radius); background: var(--espresso); color: var(--on-dark); font-size: var(--fs-sm); box-shadow: 0 18px 40px -16px rgb(0 0 0 / 45%); animation: fadeUp var(--base) var(--ease); }
  .toast.is-out { opacity: 0; transition: opacity 0.3s; }
  .toast .icon { color: #bfe3c8; }
  .toast--error .icon { color: #ffc2b5; }
  .toast button { margin-left: auto; font-weight: 600; text-decoration: underline; white-space: nowrap; min-height: 36px; }
  .toast__img { width: 40px; height: 40px; flex: none; border-radius: var(--radius-sm); object-fit: contain; background: var(--linen); }

  /* ---------- Aviso de cookies: aceptar y rechazar con el mismo peso ---------- */
  /* 16/11 (Hommy): tarjeta chica flotante abajo, con aire a los costados (como Zara, Aesop y Our Place). Celular: unos
     90 px (antes ~125 px de lado a lado); compu: abajo a la izquierda, 400 px de ancho. Con «Configurar» abierto crece
     hasta 75 % del alto y se desplaza adentro. Mientras se ve, la barra de compra, «Volver arriba» y WhatsApp se corren
     hacia arriba (--cookie-h, lo mide consent.js). */
  .cookie { position: fixed; z-index: 110; left: max(10px, env(safe-area-inset-left)); right: max(10px, env(safe-area-inset-right));
    bottom: calc(10px + env(safe-area-inset-bottom)); padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 16px;
    background: var(--paper); box-shadow: 0 18px 50px -18px rgb(0 0 0 / 45%);
    max-height: 40dvh; overflow-y: auto; overscroll-behavior: contain; animation: cookie-in 0.45s var(--ease-out, ease) both; }
  @keyframes cookie-in { from { opacity: 0; transform: translateY(16px); } }
  .cookie.is-open { max-height: 75dvh; }
  .cookie__main { display: grid; gap: 8px; }
  .cookie__text p { margin: 0; font-size: 0.8125rem; line-height: 1.5; color: var(--ink-2); }
  .cookie p a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }
  .cookie__actions { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 8px; }
  .cookie__actions .btn { min-height: 40px; padding: 0 10px; font-size: 0.875rem; font-weight: 700; letter-spacing: 0; text-transform: none; line-height: 1.1; white-space: nowrap; }
  /* «Configurar» va en el renglón del texto, como «Más info»: área de toque de 24 px de alto como mínimo (WCAG 2.5.8). */
  .cookie__customize { display: inline-block; min-height: 24px; padding: 0; border: 0; background: none; color: var(--ink); font: inherit; font-weight: 600;
    text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
  @media (min-width: 700px) { .cookie { right: auto; width: 400px; left: max(20px, env(safe-area-inset-left)); bottom: 20px; padding: 16px 18px; } }
  @media (prefers-reduced-motion: reduce) { .cookie { animation: none; } }
  /* Mientras el aviso está abierto, la página suma abajo un espacio de su mismo alto: el final (el pie, el botón de
     arrepentimiento) nunca queda tapado. */
  html.has-cookie-bar body { padding-bottom: var(--cookie-h, 0px); }
  .cookie__prefs { max-width: 1200px; margin: 12px auto 0; padding-top: 10px; border-top: 1px solid var(--line); }
  .cookie__prefs .cookie__actions { grid-template-columns: 1fr; max-width: 360px; }
  .cookie__list li { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--line); }
  .cookie__list strong { display: block; font-size: var(--fs-sm); font-weight: 600; }
  .cookie__list span { font-size: var(--fs-xs); color: var(--muted); }
  /* WhatsApp flotante (F12): abajo a la derecha; se corre hacia arriba con el aviso de cookies y con la barra de compra. */
  .wa-float { position: fixed; z-index: 54; right: 16px; bottom: calc(16px + var(--cookie-h, 0px) + env(safe-area-inset-bottom)); display: inline-flex; align-items: center; gap: 8px;
    min-height: 48px; min-width: 48px; padding: 0 16px 0 12px; border-radius: var(--pill); background: #187a41; color: var(--on-dark); font-size: var(--fs-sm); font-weight: 600;
    text-decoration: none; box-shadow: 0 16px 32px -14px rgb(0 0 0 / 45%); transition: bottom var(--base) var(--ease), background var(--fast); }
  .wa-float:hover { background: #135f33; color: #fff; }
  .wa-float .icon { width: 22px; height: 22px; }
  @media (max-width: 899px) {
    .wa-float { padding: 0; justify-content: center; width: 52px; height: 52px; }
    .wa-float__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    body:has(.buybar.is-visible) .wa-float { bottom: calc(84px + var(--cookie-h, 0px) + env(safe-area-inset-bottom)); }
  }
  /* Que nada quede tapado por la barra (WCAG 2.4.11): lo que recibe el foco se desplaza por encima. */
  html.has-cookie-bar { scroll-padding-bottom: calc(var(--cookie-h, 0px) + 16px); }
  .switch { position: relative; flex: none; width: 48px; height: 28px; display: inline-block; }
  .switch input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
  .switch i { position: absolute; inset: 0; border-radius: 14px; background: var(--field); transition: background var(--fast); }
  .switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--paper); transition: transform var(--base) var(--ease); }
  .switch input:checked + i { background: var(--brand); }
  .switch input:checked + i::after { transform: translateX(20px); }
  .switch input:disabled + i { opacity: 0.55; }
  .switch input:focus-visible + i { outline: 2px solid var(--focus); outline-offset: 3px; }

  /* ---------- Acordeones (ficha y preguntas frecuentes) ---------- */
  .acc { border-top: 1px solid var(--line); }
  .acc details { border-bottom: 1px solid var(--line); }
  .acc summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; padding: 14px 0; cursor: pointer; font-weight: 500; list-style: none; }
  .acc summary::-webkit-details-marker { display: none; }
  .acc summary .icon { transition: transform var(--base) var(--ease); }
  .acc details[open] summary .icon { transform: rotate(180deg); }
  .acc__body { padding: 0 0 20px; color: var(--ink-2); max-width: 68ch; display: grid; gap: 10px; }
  .acc__body ul { display: grid; gap: 6px; padding-left: 1.2em; list-style: disc; }
  .faq details p { padding: 0 0 20px; color: var(--ink-2); max-width: 68ch; }

  /* ---------- Texto largo y tablas ---------- */
  .prose { font-size: var(--fs-base); color: var(--ink-2); line-height: 1.7; }
  .prose > * + * { margin-top: 1em; }
  .prose h2 { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 500; color: var(--ink); margin-top: 2em; }
  .prose h3 { color: var(--ink); margin-top: 1.5em; }
  .prose ul { list-style: disc; padding-left: 1.3em; display: grid; gap: 6px; }
  .prose ol { list-style: decimal; padding-left: 1.3em; display: grid; gap: 6px; }
  .prose a { color: var(--ink); font-weight: 500; }
  .prose .lead { font-size: var(--fs-lg); color: var(--ink); }
  .prose code, .table code { background: var(--sand); padding: 2px 6px; border-radius: 4px; font-size: 0.85em; }
  .table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
  .table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
  .table th, .table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
  .table th { background: var(--sand); font-size: var(--fs-sm); color: var(--ink); }
  .table tr:last-child td { border-bottom: 0; }

  /* ---------- Etiquetas de estado ---------- */
  .tag { display: inline-block; padding: 3px 10px; border-radius: var(--pill); font-size: var(--fs-xs); font-weight: 600; background: var(--sand); }
  .tag--paid, .tag--delivered, .tag--approved { background: var(--ok-soft); color: var(--ok); }
  .tag--pending_payment, .tag--pending { background: var(--warn-soft); color: var(--warn); }
  .tag--cancelled, .tag--refunded, .tag--hidden { background: var(--err-soft); color: var(--err); }
  .tag--shipped, .tag--processing { background: #dde6ef; color: var(--cobalt); }

  /* ---------- Toques ---------- */
  @media (pointer: coarse) {
    .btn--sm { min-height: var(--tap); }
    .cart-line .qty button { width: var(--tap); height: var(--tap); }
    .cart-line__remove { min-height: var(--tap); }
    .check--sm { padding-block: 4px; }
  }
}
@layer components {
  /* Recuadro anti-bots (Turnstile), solo si la tienda lo activa */
  .turnstile { min-height: 65px; margin: 4px 0 8px; }
}
@layer components {
  /* Lugar de foto o video que llena su marco (portada, estrella, banda, banner de categoría, ficha).
     Sin z-index propio: así las fotos con fondo blanco se funden (multiply) con el color del marco. */
  .vslot { position: absolute; inset: 0; }
  .vslot__photo { border-radius: var(--radius); }

  /* Con video: portada fija debajo; el video aparece encima recién cuando empieza (si no, queda la portada). */
  .vslot.has-video { overflow: hidden; border-radius: inherit; }
  .vslot__video, .vslot__gif { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
  /* Videos «para mirar»: no reciben clics (sin controles, sin menú, sin pantalla completa). */
  .vslot__video { pointer-events: none; }
  .vslot__video::-webkit-media-controls { display: none !important; }
  .vslot__video::-webkit-media-controls-start-playback-button { display: none !important; -webkit-appearance: none; }

  /* Caja de muestra (solo en la vista previa): tamaño y proporción reales del lugar del video */
  .vslot.is-placeholder { display: grid; place-items: center; padding: 12px; border: 2px dashed var(--line-strong); border-radius: inherit;
    background: repeating-linear-gradient(135deg, rgb(22 25 31 / 5%) 0 12px, transparent 12px 24px), var(--room, var(--sand)); }
  .vbox { display: grid; justify-items: center; gap: 8px; max-width: 36ch; padding: 16px 18px; border-radius: var(--radius); background: rgb(255 255 255 / 90%); text-align: center; box-shadow: 0 10px 30px -20px rgb(22 25 31 / 60%); }
  .vbox__icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: var(--brand); color: var(--on-dark); }
  .vbox__what { font-size: var(--fs-sm); line-height: 1.45; color: var(--ink); }
  .vbox__meta { font-size: var(--fs-xs); line-height: 1.45; color: var(--ink-2); }
}

/* Variantes de color: muestras redondas en la tarjeta (solo informan) y en la ficha (se eligen). */
@layer components {
  .swatches { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
  .swatch { --swatch: #ccc; width: 18px; height: 18px; border-radius: 50%; background: var(--swatch); box-shadow: inset 0 0 0 1px rgb(0 0 0 / 18%); }
  .swatches--card { gap: 6px; margin-block: 2px 4px; }
  .swatches--card .swatch { width: 14px; height: 14px; }
  .pdp__colors { display: grid; gap: 8px; margin-block: 4px 12px; }
  .swatches__label { margin: 0; font-size: var(--fs-sm); color: var(--ink-2); }
  .swatches--pdp .swatch { width: 34px; height: 34px; border: 0; padding: 0; cursor: pointer; outline-offset: 3px; }
  .swatches--pdp .swatch[aria-checked="true"] { box-shadow: inset 0 0 0 1px rgb(0 0 0 / 18%), 0 0 0 2px var(--surface, #fff), 0 0 0 4px var(--ink); }
  .swatches--pdp .swatch:focus-visible { outline: 2px solid var(--brand); }

  /* Ventana del cupón de primera compra (22/10): <dialog> nativo en el centro de la pantalla, una vez por visitante.
     Estilo sereno (28/10): en dos mitades, una foto real de un producto a la izquierda (en la compu) y a la derecha el logo,
     «10% OFF» grande, el código en una caja punteada y el botón negro. En el celular, sin la foto. */
  .welcome { width: min(420px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); margin: auto; padding: 0; border: 0; border-radius: 0; background: var(--paper); color: var(--ink); box-shadow: 0 30px 60px -20px rgb(0 0 0 / 45%); overflow: auto; }
  .welcome::backdrop { background: rgb(0 0 0 / 55%); }
  .welcome[open] { display: grid; animation: welcome-in var(--base, 0.25s) var(--ease, ease) both; }
  @keyframes welcome-in { from { opacity: 0; transform: translateY(12px) scale(0.98); } }
  .welcome__media { display: none; background: var(--tile); }
  .welcome__media img { width: 100%; height: 100%; object-fit: cover; }
  .welcome__main { display: grid; align-content: start; gap: 14px; padding: 0 24px 22px; text-align: left; }
  @media (min-width: 700px) {
    .welcome:has(.welcome__media) { width: min(800px, calc(100vw - 32px)); grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .welcome__media { display: block; min-height: 520px; }
    .welcome__main { padding: 0 28px 28px; }
  }
  .welcome__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; margin: 0 -14px 0 0; padding-top: 8px; }
  .welcome__close { flex: none; display: grid; place-items: center; width: var(--tap); height: var(--tap); border: 0; border-radius: 50%; background: transparent; color: var(--ink); }
  .welcome__close:hover { background: var(--sand); }
  .welcome__close .icon { width: 22px; height: 22px; }
  .welcome__eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-sm); color: var(--ink-2); }
  .welcome__eyebrow .icon { width: 16px; height: 16px; color: var(--rust); }
  .welcome__title { display: grid; gap: 6px; font-family: var(--font-display); font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem); font-weight: 400; line-height: 1.25; }
  .welcome__pct { display: block; font-size: clamp(3rem, 2.4rem + 2.6vw, 4.25rem); font-weight: 500; line-height: 1; letter-spacing: -0.03em; color: var(--ink); }
  .welcome__text { font-size: var(--fs-sm); color: var(--ink-2); }
  .welcome__code { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 8px 8px 16px; border: 1.5px dashed var(--ink); background: var(--sand); }
  .welcome__code code { font-family: var(--font); font-size: var(--fs-lg); font-weight: 600; letter-spacing: 0.06em; color: var(--ink); }
  .welcome__status { min-height: 1.2em; font-size: var(--fs-xs); color: var(--ok); }
  .welcome__later { justify-self: center; color: var(--muted); }
  @media (prefers-reduced-motion: reduce) { .welcome[open] { animation: none; } }

  /* Círculo de luz que sigue al mouse (25/10, traído de la portada del diseño anterior). Va en los bloques oscuros con
     [data-glow]; glow.js escribe --gx/--gy (posición del mouse dentro del bloque) y la clase is-glowing mientras el
     mouse está encima. El círculo se mueve con translate (no repinta el bloque) y sigue al cursor casi pegado (16/11:
     más chico, luz caramelo que aclara la foto con «screen», aparece creciendo y respira suave mientras está quieto).
     Queda debajo del texto y no recibe clics. Color y tamaño en tokens.css. */
  [data-glow] { position: relative; isolation: isolate; overflow: hidden; overflow: clip; }
  [data-glow]::after { content: ""; position: absolute; z-index: -1; left: 0; top: 0; width: var(--glow-size); aspect-ratio: 1; border-radius: 50%;
    background: radial-gradient(circle closest-side, var(--glow-color), var(--glow-halo) 55%, transparent); mix-blend-mode: screen; pointer-events: none; opacity: 0;
    translate: calc(var(--gx, 50%) - 50%) calc(var(--gy, 50%) - 50%); scale: 0.4;
    transition: opacity 0.25s var(--ease, ease), scale 0.3s var(--ease, ease); }
  [data-glow].is-glowing::after { opacity: 1; scale: 1; animation: glow-breathe 2.4s ease-in-out 0.3s infinite alternate;
    transition: opacity 0.25s var(--ease, ease), scale 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), translate 0.12s cubic-bezier(0.22, 1, 0.36, 1); }
  @keyframes glow-breathe { to { scale: 1.12; } }
  @media (prefers-reduced-motion: reduce), (hover: none), (pointer: coarse) { [data-glow]::after { display: none; } }
}

/* ---------- «¡Agregado al carrito!» (26/10; estilo sereno desde el 28/10) ----------
   Ventana nativa (<dialog>): en la compu al centro; en el celular sube desde abajo y ocupa hasta el 88 % del alto.
   Arriba el producto que sumaste, el total y «Ver carrito»; abajo «Sumá a tu compra» con hasta 4 productos. */
@layer components {
  .added { width: 100%; max-width: 100%; max-height: 88vh; max-height: 88dvh; margin: auto 0 0; padding: 0; border: 0; border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    background: var(--paper); color: var(--ink); box-shadow: 0 -20px 60px -20px rgb(0 0 0 / 40%); overflow: hidden; }
  .added[open] { display: flex; }
  .added::backdrop { background: rgb(0 0 0 / 50%); }
  .added__box { display: flex; flex-direction: column; width: 100%; min-height: 0; }
  .added__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; padding: 0 8px 0 20px; border-bottom: 1px solid var(--line); background: var(--paper); }
  .added__title { font-family: var(--font-display); font-size: 1.25rem; font-weight: 500; }
  .added__body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; display: grid; gap: 20px; align-content: start; padding: 16px 16px calc(20px + env(safe-area-inset-bottom)); }
  .added__card { display: grid; gap: 12px; padding: 16px; background: var(--sand); }
  .added__item { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 14px; align-items: center; }
  .added__item .line-photo, .added__item .kit-thumb { width: 72px; height: 72px; }
  .added__info { display: grid; gap: 4px; min-width: 0; }
  .added__name { font-size: var(--fs-sm); font-weight: 500; line-height: 1.35; color: var(--ink); text-decoration: none; }
  .added__name:hover { text-decoration: underline; }
  .added__qty { font-size: var(--fs-sm); color: var(--ink-2); font-variant-numeric: tabular-nums; }
  .added__total { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-top: 4px; font-size: var(--fs-sm); font-weight: 500; }
  .added__total strong { font-size: var(--fs-lg); font-weight: 600; font-variant-numeric: tabular-nums; }
  .added__card .btn--primary { min-height: 48px; }
  .added__card .btn--text { min-height: 40px; }
  .added__more { display: grid; gap: 12px; }
  .added__more-title { font-family: var(--font-display); font-size: var(--fs-lg); font-weight: 500; }
  .added__list { display: grid; grid-auto-flow: column; grid-auto-columns: 44%; gap: 12px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 2px 2px 6px; }
  .added__list::-webkit-scrollbar { display: none; }
  .added-pick { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding-bottom: 4px; scroll-snap-align: start; background: transparent; overflow: hidden; }
  .added-pick__img { display: grid; place-items: center; aspect-ratio: 4 / 5; background: var(--tile); }
  .added-pick__img img { width: 86%; height: 86%; object-fit: contain; mix-blend-mode: multiply; }
  .added-pick__img.photo--ambientada img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
  .added-pick__name { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; min-height: 2.7em; padding: 0;
    font-size: var(--fs-sm); line-height: 1.35; color: var(--ink); text-decoration: none; }
  .added-pick__name:hover { color: var(--ink); text-decoration: underline; }
  .added-pick__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; padding: 0; font-size: var(--fs-sm); font-weight: 500; }
  .added-pick__price .price__was { font-size: var(--fs-xs); font-weight: 400; }
  .added-pick .btn { width: auto; min-height: var(--tap); margin: auto 0 0; }
  @media (prefers-reduced-motion: no-preference) { .added[open] { animation: addedUp 0.32s var(--ease); } .added[open]::backdrop { animation: fadeIn 0.2s ease; } }
  @keyframes addedUp { from { translate: 0 40px; opacity: 0.4; } }
  @media (min-width: 700px) {
    .added { width: min(720px, calc(100vw - 48px)); max-height: min(720px, calc(100vh - 48px)); margin: auto; border-radius: 0; box-shadow: 0 30px 80px -30px rgb(0 0 0 / 50%); }
    .added__body { padding: 20px 22px 24px; }
    .added__list { grid-auto-flow: row; grid-template-columns: repeat(4, minmax(0, 1fr)); overflow: visible; }
    @media (prefers-reduced-motion: no-preference) { .added[open] { animation: addedIn 0.24s var(--ease); } }
  }
  @keyframes addedIn { from { opacity: 0; scale: 0.96; } }
}
