:root {
  --bg: #0f1024;
  --bg2: #17183a;
  --panel: #1d1f47;
  --line: #2f3270;
  --text: #f2f2ff;
  --muted: #a3a6d6;
  --accent: #ffcb3d;
  --accent-ink: #14152e;
  --hot: #ff4d6d;
  --ok: #3ddc97;
  --pk: #ffcb3d; --mtg: #e8894a; --op: #e5484d; --bg-game: #3ddc97; --acc: #9d7bff;
  --radius: 14px;
  --font: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --display: 'Archivo Black', 'Inter', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.5 var(--font); }
a { color: var(--accent); }
button { font: inherit; color: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }
.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.wrap.narrow { width: min(680px, 100% - 32px); padding-block: 32px 64px; }
.small { font-size: 13px; color: var(--muted); }

/* Botones */
.btn { border: 0; border-radius: 10px; padding: 10px 16px; font-weight: 700; background: var(--panel); text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.primary:disabled { opacity: .6; cursor: wait; }
.btn.big { width: 100%; padding: 14px 18px; font-size: 16px; }
.btn.add { background: transparent; border: 2px solid var(--accent); color: var(--accent); padding: 6px 12px; font-size: 13px; }
.btn.add:hover { background: var(--accent); color: var(--accent-ink); }

/* Barra superior */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(15,16,36,.92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; gap: 16px; height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-family: var(--display); font-size: 20px; letter-spacing: .3px; white-space: nowrap; }
.logo b { color: var(--accent); font-weight: 400; }
/* Logo de Jako's Games (el d20 con el schnauzer): se pinta con el color de cada tema */
.logo-mark { flex: none; display: block; width: 38px; height: 42px; background: var(--logo, var(--accent));
  -webkit-mask: url('/img/logo-jakos.svg') center / contain no-repeat; mask: url('/img/logo-jakos.svg') center / contain no-repeat; }
.search { flex: 1; }
.search input { width: 100%; background: var(--bg2); border: 1px solid var(--line); color: var(--text); border-radius: 999px; padding: 10px 18px; font: inherit; }
.search input:focus { outline: 2px solid var(--accent); border-color: transparent; }
.track-link { color: var(--muted); text-decoration: none; font-weight: 600; white-space: nowrap; margin-left: auto; }
.track-link:hover { color: var(--text); }
.cart-btn { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; width: 46px; height: 42px; display: grid; place-items: center; }
.badge { position: absolute; top: -6px; right: -6px; background: var(--hot); color: #fff; font-size: 11px; font-weight: 700; border-radius: 999px; min-width: 20px; height: 20px; display: none; place-items: center; padding: 0 5px; }
.badge.show { display: grid; }

/* Hero */
.hero { background: radial-gradient(900px 400px at 85% 10%, rgba(157,123,255,.25), transparent 60%), radial-gradient(700px 300px at 10% 100%, rgba(255,203,61,.15), transparent 60%), var(--bg); border-bottom: 1px solid var(--line); overflow: hidden; }
.hero-inner { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: 24px; padding-block: 48px; }
.eyebrow { text-transform: uppercase; letter-spacing: 2px; font-size: 12px; color: var(--accent); font-weight: 700; margin: 0 0 8px; }
.hero .hero-title { font-family: var(--display); font-weight: 400; font-size: clamp(32px, 5vw, 54px); line-height: 1.05; margin: 0 0 16px; }
.hero .hero-title span { color: var(--accent); }
h1.eyebrow { font-family: inherit; line-height: 1.4; }
.lead { color: var(--muted); font-size: 17px; max-width: 46ch; margin: 0; }
.hero-cards { position: relative; height: 260px; }
.fcard { position: absolute; width: 150px; height: 210px; border-radius: 12px; border: 3px solid #fff2; box-shadow: 0 20px 40px #0008; left: 50%; top: 20px; }
.fcard.c1 { background: linear-gradient(150deg, var(--mtg), #6b3412); transform: translateX(-130%) rotate(-14deg); }
.fcard.c2 { background: linear-gradient(150deg, var(--pk), #d9541e); transform: translateX(-50%) rotate(0); z-index: 2; top: 0; }
.fcard.c3 { background: linear-gradient(150deg, var(--op), #5e1020); transform: translateX(30%) rotate(14deg); }
.fcard::after { content: ''; position: absolute; inset: 14px; border-radius: 8px; border: 2px solid #fff5; background: radial-gradient(circle at 50% 40%, #fff6 0 22%, transparent 23%); }

/* Categorías */
.cats { display: flex; gap: 10px; overflow-x: auto; padding: 24px 0 8px; scrollbar-width: none; }
.cat { flex: none; display: flex; align-items: center; gap: 8px; border: 2px solid var(--line); background: var(--bg2); border-radius: 12px; padding: 10px 16px; font-weight: 700; --c: var(--accent); }
.cat small { background: var(--line); border-radius: 999px; padding: 1px 8px; font-size: 12px; color: var(--muted); }
.cat.pk { --c: var(--pk); } .cat.mtg { --c: var(--mtg); } .cat.op { --c: var(--op); } .cat.bg { --c: var(--bg-game); } .cat.acc { --c: var(--acc); }
.cat::before { content: ''; width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
.cat.on { border-color: var(--c); background: color-mix(in srgb, var(--c) 15%, var(--bg2)); }

.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; flex-wrap: wrap; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chips button { border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 6px 14px; color: var(--muted); font-weight: 600; }
.chips button.on { background: var(--text); color: var(--bg); border-color: var(--text); }
select { background: var(--bg2); color: var(--text); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; font: inherit; }
.results-info { color: var(--muted); font-size: 13px; margin: 4px 0 12px; }

/* Grid de productos */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; min-height: 200px; transition: opacity .2s; }
.grid.loading { opacity: .5; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: transform .15s, border-color .15s; }
.card:hover { transform: translateY(-3px); border-color: var(--accent); }
.card-img { position: relative; border: 0; padding: 0; background: var(--bg2); aspect-ratio: 1; overflow: hidden; }
.card-img img, .card-img .ph { width: 100%; height: 100%; object-fit: contain; }
.tag { position: absolute; top: 10px; left: 10px; font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 6px; }
.tag.low { background: var(--hot); color: #fff; }
.tag.cond { left: auto; right: 10px; background: #000a; color: #fff; }
.card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; flex: 1; }
.meta { color: var(--muted); font-size: 12px; margin: 0 0 4px; }
.card h3 { font-size: 15px; margin: 0 0 10px; line-height: 1.3; flex: 1; }
.card h3 button { background: none; border: 0; padding: 0; text-align: left; font-weight: 700; }
.card-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.price { font-family: var(--display); font-size: 18px; color: var(--accent); }
.empty { color: var(--muted); grid-column: 1 / -1; text-align: center; padding: 48px 0; }

/* Imagen genérica cuando no hay foto */
.ph { display: grid; place-items: center; background: linear-gradient(150deg, var(--c, var(--acc)), color-mix(in srgb, var(--c, var(--acc)) 30%, #000)); --c: var(--acc); }
.ph span { font-family: var(--display); font-size: 22px; color: #fff; text-shadow: 0 2px 10px #0006; padding: 0 10px; text-align: center; }
.ph.pk { --c: var(--pk); } .ph.mtg { --c: var(--mtg); } .ph.op { --c: var(--op); } .ph.bg { --c: var(--bg-game); } .ph.acc { --c: var(--acc); }

.pager { display: flex; justify-content: center; gap: 6px; padding: 28px 0; }
.pager button { min-width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg2); }
.pager button.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 800; }

/* Diálogos */
.dlg { border: 1px solid var(--line); background: var(--bg2); color: var(--text); border-radius: 18px; padding: 28px; width: min(820px, 100% - 24px); max-height: calc(100dvh - 24px); }
.dlg.wide { width: min(640px, 100% - 24px); }
.dlg::backdrop { background: #05061acc; backdrop-filter: blur(3px); }
.dlg-close { position: absolute; top: 12px; right: 12px; z-index: 5; border: 0; background: var(--panel); width: 36px; height: 36px; border-radius: 10px; }
.dlg-close.static { position: static; }
.pd { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.pd-img { background: var(--panel); border-radius: var(--radius); overflow: hidden; aspect-ratio: 1; }
.pd-img img, .pd-img .ph { width: 100%; height: 100%; object-fit: contain; }
.pd h2 { font-family: var(--display); font-weight: 400; font-size: 26px; line-height: 1.15; margin: 4px 0 10px; }
.pd-price { font-family: var(--display); font-size: 30px; color: var(--accent); margin: 8px 0; }
.pd-desc { color: var(--muted); }
.stock-line { font-weight: 600; color: var(--ok); }

/* Carrito */
.drawer { position: fixed; inset: 0; z-index: 50; background: #05061a99; opacity: 0; pointer-events: none; transition: opacity .2s; }
.drawer.open { opacity: 1; pointer-events: auto; }
.drawer-panel { position: absolute; right: 0; top: 0; bottom: 0; width: min(420px, 100%); background: var(--bg2); border-left: 1px solid var(--line); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .25s ease; }
.drawer.open .drawer-panel { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 20px; }
.drawer-items { flex: 1; overflow-y: auto; padding: 8px 20px; }
.drawer-foot { padding: 16px 20px 20px; border-top: 1px solid var(--line); }
.ci { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); align-items: center; }
.ci-img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; }
.ci .ph span { font-size: 10px; }
.ci-name { margin: 0; font-weight: 600; font-size: 14px; }
.ci-price { margin: 2px 0 6px; color: var(--accent); font-weight: 700; font-size: 14px; }
.ci-del { background: none; border: 0; color: var(--muted); }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 8px; }
.qty button { background: none; border: 0; width: 30px; height: 28px; }
.qty button:disabled { opacity: .3; }
.qty span { min-width: 24px; text-align: center; font-weight: 700; }
.empty-cart { text-align: center; padding: 60px 0; color: var(--muted); }
.free-hint { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); border-radius: 8px; padding: 8px 12px; font-size: 13px; margin: 0 0 10px; }
.row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.row.total { font-weight: 800; font-size: 18px; border-top: 1px solid var(--line); margin: 6px 0 14px; padding-top: 10px; }

/* Checkout */
.checkout h2 { font-family: var(--display); font-weight: 400; margin: 0 0 16px; }
.checkout label { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 12px; }
.checkout input, .checkout textarea { display: block; width: 100%; margin-top: 4px; background: var(--panel); border: 1px solid var(--line); color: var(--text); border-radius: 10px; padding: 10px 12px; font: inherit; }
.checkout input:focus, .checkout textarea:focus { outline: 2px solid var(--accent); border-color: transparent; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pay { border: 0; padding: 0; margin: 8px 0; }
.pay legend { font-weight: 700; margin-bottom: 8px; }
.pay-opt { display: flex !important; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 8px !important; cursor: pointer; color: var(--text) !important; }
.pay-opt input { width: auto !important; margin: 3px 0 0 !important; accent-color: var(--accent); }
.pay-opt:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.pay-opt small { display: block; color: var(--muted); font-weight: 400; }
.bank { display: block; background: var(--panel); border-left: 4px solid var(--accent); padding: 10px 14px; border-radius: 8px; margin: 8px 0; color: var(--text); }
.summary { background: var(--panel); border-radius: 12px; padding: 12px 16px 2px; margin: 12px 0; font-size: 14px; }
.error { color: var(--hot); font-weight: 600; min-height: 1em; }

/* Seguimiento */
.track { display: flex; gap: 10px; align-items: flex-end; margin-bottom: 24px; }
.track label { flex: 1; font-size: 13px; font-weight: 600; color: var(--muted); }
.track input { display: block; width: 100%; margin-top: 4px; background: var(--bg2); border: 1px solid var(--line); color: var(--text); border-radius: 10px; padding: 11px 14px; font: inherit; text-transform: uppercase; }
.panel { background: var(--bg2); border: 1px solid var(--line); border-radius: 18px; padding: 28px; }
.h-thanks { font-family: var(--display); font-weight: 400; margin: 0 0 8px; }
.steps { display: flex; list-style: none; padding: 0; margin: 20px 0; gap: 4px; }
.steps li { flex: 1; text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); padding-top: 12px; border-top: 4px solid var(--line); }
.steps li.done { color: var(--ok); border-color: var(--ok); }
.wa-btn { background: #25d366; color: #062; margin-top: 8px; }

.footer { border-top: 1px solid var(--line); margin-top: 32px; padding: 32px 0; color: var(--muted); }
.footer-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.footer strong { color: var(--text); font-family: var(--display); font-weight: 400; }
.footer .small { grid-column: 1 / -1; }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 20px); background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 10px; font-weight: 700; opacity: 0; transition: .2s; pointer-events: none; z-index: 100; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.warn { background: var(--hot); color: #fff; }

@media (max-width: 760px) {
  .topbar-inner { flex-wrap: wrap; height: auto; padding: 10px 0; gap: 10px; }
  .search { order: 5; flex-basis: 100%; }
  .hero-inner { grid-template-columns: 1fr; padding-block: 28px; }
  .hero-cards { display: none; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-foot { flex-direction: column; align-items: stretch; }
  .pd { grid-template-columns: 1fr; }
  .two { grid-template-columns: 1fr; gap: 0; }
  .dlg { padding: 20px; }
  .footer-inner { grid-template-columns: 1fr; }
}

/* Reservas */
.card.soldout .card-img { filter: grayscale(.55); }
.tag.out { background: #4a4d7a; color: #fff; }
.price.tbd, .pd-price.tbd { font-family: var(--font); font-size: 13px; font-weight: 700; color: var(--muted); }
.pd-price.tbd { font-size: 18px; }
.btn.add.reserve { border-color: var(--acc); color: #cdbcff; }
.btn.add.reserve:hover { background: var(--acc); color: #fff; }
.stock-line.out { color: var(--hot); }
.reserve-help { background: color-mix(in srgb, var(--acc) 14%, transparent); border-radius: 10px; padding: 10px 12px; font-size: 14px; color: var(--text); }
.reserve-product { font-size: 17px; margin: 0 0 8px; }
.reserve-ok .code { font-family: var(--display); font-weight: 400; color: var(--accent); font-size: 20px; letter-spacing: 1px; }

/* Vista 3D */
.pd-img { position: relative; }
.pd-img .visor3d { position: absolute; inset: 0; cursor: grab; background: radial-gradient(circle at 50% 40%, #2b2d6e55, transparent 70%); }
.pd-img .visor3d:active { cursor: grabbing; }
.pd-img.is3d > img, .pd-img.is3d > .ph { visibility: hidden; }
.visor3d-canvas { width: 100%; height: 100%; display: block; touch-action: none; }
.v3d-btn { position: absolute; left: 10px; bottom: 10px; z-index: 2; background: #000b; color: #fff; border: 1px solid #fff3; border-radius: 999px; padding: 7px 14px; font-weight: 700; font-size: 13px; backdrop-filter: blur(4px); }
.v3d-btn:hover { border-color: var(--accent); color: var(--accent); }
.v3d-hint { display: none; position: absolute; right: 12px; bottom: 16px; z-index: 2; font-size: 12px; color: var(--muted); pointer-events: none; }
.pd-img.is3d:not(.loading3d) .v3d-hint { display: block; }
.pd-img.loading3d::after { content: 'Cargando 3D…'; position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-weight: 600; }
.tag.v3d { top: auto; bottom: 10px; background: var(--accent); color: var(--accent-ink); }

/* Juegos que se pueden jugar en la tienda */
.play-toggle { margin-right: auto; border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 6px 14px; color: var(--muted); font-weight: 700; }
.play-toggle:hover { border-color: var(--accent); color: var(--accent); }
.play-toggle.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.tag.play { top: auto; bottom: 10px; background: #1f9d68; color: #fff; }
.tag.v3d { left: auto; right: 10px; }
.price.play { font-family: inherit; font-size: 14px; font-weight: 800; color: #3fd492; }
.play-help { background: color-mix(in srgb, #1f9d68 16%, transparent); border: 1px solid color-mix(in srgb, #1f9d68 45%, transparent); border-radius: 12px; padding: 10px 12px; margin: 10px 0; font-size: 14px; }
.ship-note { display: block; font-size: 11px; color: var(--muted); font-weight: 500; }
.checkout select { display: block; width: 100%; margin-top: 4px; background: var(--panel); border: 1px solid var(--line); color: var(--text); border-radius: 10px; padding: 10px 12px; font: inherit; }
.checkout select:focus { outline: 2px solid var(--accent); border-color: transparent; }

/* Símbolos de maná en la descripción de las cartas */
.pd-desc .mana { font-size: .92em; margin: 0 .08em; vertical-align: .05em; }

/* Cuenta y puntos */
.acct { margin-bottom: 18px; }
.acct h2 { font-family: var(--display); font-weight: 400; font-size: 20px; margin: 0 0 12px; }
.tabs { display: flex; gap: 6px; margin: 16px 0; }
.tabs button { flex: 1; border: 1px solid var(--line); background: transparent; color: var(--muted); border-radius: 10px; padding: 9px; font-weight: 700; }
.tabs button.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.points-card { display: grid; background: linear-gradient(135deg, #2b2d6e, #14152e); border: 1px solid var(--accent); border-radius: 16px; padding: 18px 20px; margin: 14px 0; }
.points-card span { color: var(--muted); font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.points-card b { font-family: var(--display); font-weight: 400; font-size: 40px; color: var(--accent); line-height: 1.1; }
.points-card small { color: var(--text); }
table.mini { width: 100%; border-collapse: collapse; font-size: 14px; }
table.mini td { padding: 8px 4px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.mini td.num { text-align: right; white-space: nowrap; }
.up { color: #3fd492; } .down { color: #ff7b7b; }
.link-out { margin-top: 12px; }
.acct-link { color: var(--accent); text-decoration: none; font-weight: 700; white-space: nowrap; }
.points-box { background: color-mix(in srgb, var(--accent) 8%, transparent); border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); border-radius: 12px; padding: 10px 14px; margin: 10px 0; font-size: 14px; }
.points-box label { display: flex; align-items: center; gap: 8px; margin: 6px 0 0; }
.points-box input[type=number] { width: 110px !important; margin: 0 !important; }
.points-box input[type=checkbox] { width: auto !important; margin: 0 !important; }
.earn-note { margin: 8px 0 4px; color: var(--muted); }
.earn-note b { color: var(--accent); }
@media (max-width: 560px) {
  .acct-link { font-size: 13px; }
  .topbar-inner .lbl { display: none; }
  .topbar-inner { gap: 8px; }
  .logo span { font-size: 17px; }
}

/* SEO: enlaces de producto, páginas de producto y categoría */
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a:hover { color: var(--accent); }
.seo-links { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; }
.seo-links a { color: var(--muted); }
.seo-about { color: var(--muted); max-width: 70ch; }
.seo-page { padding-block: 22px 56px; }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.crumbs a { color: var(--muted); }
.seo-h1 { font-family: var(--display); font-weight: 400; font-size: clamp(26px, 4vw, 38px); margin: 0 0 8px; }
.seo-product h1 { font-family: var(--display); font-weight: 400; font-size: 28px; line-height: 1.15; margin: 4px 0 10px; }
.seo-product .btn { margin: 6px 6px 6px 0; }
.seo-grid { margin-top: 18px; }
.seo-card-title { font-size: 15px; margin: 4px 0 8px; }
.seo-card-title a { color: var(--text); text-decoration: none; }
a.card-img { text-decoration: none; display: block; }

/* App instalable y página sin conexión */
[hidden] { display: none !important; }
.install-btn { margin-top: 4px; }
.offline-page { min-height: 100dvh; display: grid; place-items: center; }
.offline { text-align: center; max-width: 420px; padding: 24px 16px; }
.offline img { margin: 0 auto; }
.offline h1 { font-family: var(--display); font-weight: 400; margin: 12px 0 6px; }
.offline p { color: var(--muted); margin: 0 0 18px; }

/* Mercadería en camino */
.tag.soon { background: #2f6fe0; color: #fff; }
.stock-line.soon { color: #7fb0ff; }

/* SEO: relacionados, página de la tienda y preguntas */
.seo-h2 { font-family: var(--display); font-weight: 400; font-size: 22px; margin: 28px 0 14px; }
.related { margin-top: 12px; }
.visit { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 20px; margin: 16px 0; }
.visit p { margin: 0 0 10px; }
.visit-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px !important; }
.visit-cats ul { margin: 0; padding-left: 18px; }
.visit-cats li { margin-bottom: 6px; }
.visit-cats .seo-h2 { margin-top: 0; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; margin-bottom: 8px; }
.faq summary { cursor: pointer; font-weight: 700; }
.faq details p { margin: 8px 0 0; color: var(--muted); }
@media (max-width: 760px) { .visit { grid-template-columns: 1fr; } }

/* Cancelar pedido (cliente) */
.cancel-order { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 12px; }
.cancel-order summary { cursor: pointer; font-weight: 700; color: var(--muted); }
.cancel-order[open] summary { color: var(--text); margin-bottom: 8px; }
.cancel-order form { margin-top: 8px; }
.btn.danger { background: var(--hot); color: #fff; }

/* Iconos de texto (los temas los pueden ocultar o cambiar) y aviso de vista previa de tema */
.ico { width: 1.15em; height: 1.15em; flex: none; display: inline-block; vertical-align: -0.2em; overflow: visible; }  /* el trazo o relleno lo trae cada estilo (src/iconos.js) */
.dlg-close .ico, .ci-del .ico { width: 18px; height: 18px; vertical-align: middle; }
.dlg-close, .ci-del { display: inline-grid; place-items: center; color: var(--text); }
.track-link, .acct-link { display: inline-flex; align-items: center; gap: 6px; }
.track-link .ico, .acct-link .ico { width: 20px; height: 20px; }
.bell-btn .bell-ico { width: 22px; height: 22px; vertical-align: middle; }
.bell-dlg h3 { display: flex; align-items: center; gap: 8px; }
.bell-list { list-style: none; padding-left: 0 !important; }
.bell-list li { display: flex; gap: 10px; align-items: flex-start; margin: 6px 0; }
.bell-list .ico { margin-top: .2em; color: var(--accent); }
.btn .ico { margin-right: 2px; }
.tema-preview { position: fixed; left: 12px; bottom: 12px; z-index: 200; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
  max-width: calc(100% - 24px); padding: 10px 14px; border-radius: 10px; background: #111; color: #fff; font: 600 13px/1.3 system-ui, sans-serif; box-shadow: 0 6px 20px #0006; }
.tema-preview a { color: #ffd76a; }
@media (max-width: 400px) { .topbar-inner > .track-link:last-child { font-size: 13px; } }

/* ---------- Eventos y torneos ---------- */
.ev-strip { padding-top: 26px; }
.ev-strip-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.ev-strip-head h2 { font-family: var(--display); font-weight: 400; font-size: 22px; margin: 0; }
.ev-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.ev-cards-list { grid-template-columns: 1fr; max-width: 820px; }
.ev-card { display: flex; gap: 14px; align-items: center; padding: 12px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius, 14px);
  color: var(--text); text-decoration: none; }
.ev-card:hover { border-color: var(--accent); }
.ev-card.cancelado { opacity: .6; }
.ev-date { flex: none; display: grid; justify-items: center; align-content: center; width: 62px; min-height: 66px; padding: 4px 0; border-radius: 10px;
  background: var(--accent); color: var(--accent-ink); line-height: 1.05; text-transform: uppercase; }
.ev-date i { font-style: normal; font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.ev-date b { font-size: 26px; font-family: var(--display); font-weight: 400; }
.ev-date small { font-size: 12px; font-weight: 700; }
.ev-info { display: grid; gap: 2px; min-width: 0; }
.ev-meta { font-size: 12px; color: var(--muted); }
.ev-title { font-size: 16px; line-height: 1.25; }
.ev-sub { font-size: 13px; color: var(--muted); }
.ev-filtros { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 16px; }
.ev-filtros a { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--text); text-decoration: none; font-size: 14px; }
.ev-filtros a.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.ev-vacio p { margin: 0 0 8px; }
.ev-page { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 28px; align-items: start; }
.ev-page.sin-img { grid-template-columns: 1fr; }
.ev-img img { width: 100%; border-radius: var(--radius, 14px); border: 1px solid var(--line); }
.ev-head .seo-h1 { margin-bottom: 12px; }
.ev-when { display: flex; align-items: center; gap: 14px; font-size: 17px; font-weight: 600; margin: 0 0 12px; }
.ev-line { margin: 0 0 6px; }
.ev-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ev-aviso { padding: 10px 14px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); }
.ev-aviso.bad { border-color: var(--hot); color: var(--hot); }
.ev-body { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 28px; align-items: start; margin-top: 8px; }
.ev-text p { white-space: normal; }
.ev-signup { margin-top: 28px; }
.ev-signup .seo-h2 { margin-top: 0; }
.ev-ok-t { font-size: 18px; font-weight: 700; color: var(--ok); }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 760px) {
  .ev-page, .ev-body { grid-template-columns: 1fr; gap: 16px; }
  .ev-signup { margin-top: 0; }
  .ev-when { font-size: 16px; }
}

/* ---------- Compartir ---------- */
.share-btn { border: 1px solid var(--line); margin-top: 8px; }
.pd-info .share-btn { width: 100%; }
.share-dlg { width: min(420px, 100% - 24px); }
.share-what { color: var(--muted); margin: 0 0 14px; }
.share-opts { display: grid; gap: 8px; }
.share-opts .btn { width: 100%; justify-content: center; border: 1px solid var(--line); }
.share-wa { background: #25d366 !important; color: #052e12 !important; border-color: #25d366 !important; }
.share-fb { background: #1877f2 !important; color: #fff !important; border-color: #1877f2 !important; }

/* Páginas por tipo y reseñas */
.subcats { margin: 6px 0 14px; font-size: 14px; }
.review-box { margin: 14px 0; padding: 14px 16px; border: 1px dashed var(--accent); border-radius: 12px; }
.review-box p { margin: 0 0 10px; }

/* ---------- Inicio: solo las grandes categorías, con su imagen ---------- */
#grid.home { display: block; min-height: 0; }
body.en-inicio #cats, body.en-inicio .toolbar { display: none; }   /* en el inicio solo se ven las categorías */
.home-title { margin: 6px 0 16px; font-size: 24px; }
.home-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; margin: 0 0 30px; }
.tile { --c: var(--accent); display: flex; flex-direction: column; overflow: hidden; border-radius: 16px; background: var(--panel);
  border: 2px solid var(--c); text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s; }
.tile:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0, 0, 0, .25); }
.tile-img { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden;
  background: linear-gradient(135deg, color-mix(in srgb, var(--c) 55%, var(--panel)), color-mix(in srgb, var(--c) 15%, var(--panel))); }
.tile-img img { display: block; width: 100%; height: 100%; transition: transform .3s; }
.tile-img img.tile-full { object-fit: cover; }
.tile-img img.tile-bg { position: absolute; inset: 0; object-fit: cover; filter: blur(16px) saturate(1.3); transform: scale(1.25); opacity: .75; }
.tile-img img.tile-fg { position: relative; object-fit: contain; padding: 10px; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .35)); }
.tile:hover .tile-img img.tile-full, .tile:hover .tile-img img.tile-fg { transform: scale(1.04); }
.tile-txt { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px 14px; border-top: 3px solid var(--c); }
.tile-txt b { font-size: 19px; line-height: 1.2; }
.tile-txt small { color: var(--muted); font-size: 13px; }
.tile.pk { --c: var(--pk); } .tile.mtg { --c: var(--mtg); } .tile.op { --c: var(--op); } .tile.bg { --c: var(--bg-game); } .tile.acc { --c: var(--acc); } .tile.snk { --c: #e8590c; }
@media (max-width: 520px) {
  .home-tiles { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .tile-txt { padding: 9px 10px 11px; } .tile-txt b { font-size: 15px; } .home-title { font-size: 20px; }
}
/* Botón Avísame (notificaciones para clientes) */
.av-btn { border: 2px solid var(--accent); background: transparent; color: var(--accent); }
.av-btn.on { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.av-btn .av-x { opacity: .7; font-weight: 400; }
.panel .av-btn { display: flex; width: 100%; margin: 10px 0; }
.av-btn[hidden] { display: none !important; }

/* 🔔 Campanita de avisos en el encabezado */
.bell-btn { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; width: 46px; height: 42px; display: grid; place-items: center; color: var(--muted); cursor: pointer; flex: none; }
.bell-btn:hover { color: var(--text); }
.bell-btn.on { color: var(--accent); border-color: var(--accent); }
.bell-dot { position: absolute; top: 7px; right: 9px; width: 9px; height: 9px; border-radius: 50%; background: var(--hot); box-shadow: 0 0 0 2px var(--panel); animation: bellPulse 2s ease-in-out infinite; }
.bell-btn.on .bell-dot { display: none; }
@keyframes bellPulse { 50% { transform: scale(1.35); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .bell-dot { animation: none; } }
.bell-dlg { width: min(420px, 100% - 24px); }
.bell-dlg h3 { margin: 0 0 8px; }
.bell-dlg ul { padding-left: 18px; margin: 8px 0 12px; line-height: 1.6; }
.bell-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; margin-top: 14px; }
@media (max-width: 560px) { .bell-btn { width: 40px; height: 38px; } }
/* Celular angosto: la barra en una sola línea (logo, mi pedido, cuenta, campanita y carrito) */
@media (max-width: 430px) {
  .topbar .acct-link { font-size: 0; gap: 0; }
  .topbar .acct-link .ico { width: 22px; height: 22px; }
  .topbar-inner { gap: 6px; }
  .bell-btn, .cart-btn { width: 40px; height: 38px; }
}
/* Precio aproximado de reservas */
.price.est, .pd-price .est { color: var(--accent); }
.price.est small, .pd-price .est small { font-size: .72em; font-weight: 600; opacity: .8; margin-right: 2px; }
.est-note { display: block; font-size: 13px; font-weight: 500; color: var(--muted); margin-top: 2px; }
.reserve-product .est { color: var(--accent); font-weight: 700; }
/* Guías de las categorías y páginas temáticas (texto para clientes y Google) */
.guia { max-width: 820px; margin-top: 28px; }
.guia p { color: var(--muted); line-height: 1.65; }
.guia p b { color: var(--text); }
.guia .table-wrap { overflow-x: auto; }
.tcg-tabla { width: 100%; border-collapse: collapse; font-size: 14px; margin: 8px 0 4px; }
.tcg-tabla th, .tcg-tabla td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tcg-tabla th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.hub-links { margin-top: 18px; color: var(--muted); }
/* Páginas sin buscador (producto, categorías, eventos…): la barra en una sola línea también en el celular */
@media (max-width: 760px) {
  .topbar-inner:not(:has(.search)) { flex-wrap: nowrap; }
  .topbar-inner:not(:has(.search)) .track-link { font-size: 13px; white-space: nowrap; }
}

/* Recoger en la tienda / envío a domicilio */
.entrega .pay-opt small a { color: var(--accent); }
.cart-foot .muted-row, .muted-row { color: var(--muted); font-size: 14px; }

/* 🔥 Ofertas y combos */
.of-strip { padding-top: 26px; }
.of-strip .ev-strip-head h2 { font-family: var(--display); font-weight: 400; font-size: 22px; margin: 0; }
.of-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.of-card { display: flex; gap: 12px; padding: 10px; background: var(--panel); border: 1px solid var(--accent); border-radius: var(--radius, 14px); align-items: stretch; }
.of-card.soldout { opacity: .65; border-color: var(--line); }
.of-img { position: relative; flex: none; width: 96px; height: 96px; border-radius: 10px; overflow: hidden; background: var(--bg); display: grid; place-items: center; }
.of-img img { width: 100%; height: 100%; object-fit: contain; }
.of-img .tag { position: absolute; top: 4px; left: 4px; }
.of-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.of-body h3 { margin: 0; font-size: 15px; line-height: 1.25; }
.of-body h3 a { color: inherit; text-decoration: none; }
.of-inc { margin: 0; font-size: 12px; color: var(--muted); }
.of-price { margin: 0; font-size: 18px; }
.of-save { font-size: 12px; color: var(--ok, #2e9d5b); font-weight: 600; }
.of-foot { margin: auto 0 0; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.of-foot .btn.add { padding: 6px 12px; }
s.was, .was { color: var(--muted); font-weight: 400; font-size: .8em; margin-right: 2px; }
.tag.deal { background: #e0453a; color: #fff; }
.deal-line { margin: 0 0 4px; font-size: 14px; }
.deal-save { margin: -4px 0 8px; color: var(--ok, #2e9d5b); font-weight: 600; }
.incluye { margin: 8px 0; padding: 10px 12px; border: 1px dashed var(--accent); border-radius: 10px; }
.incluye ul { margin: 4px 0 0; padding-left: 18px; }
.card .tag.deal { top: auto; bottom: 10px; left: 10px; }
.deal-line .tag.deal, .incluye .tag.deal { position: static; display: inline-block; }
.of-cards { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.of-img, .of-img:hover { text-decoration: none; }
.of-img .ph { width: 100%; height: 100%; display: grid; place-items: center; padding: 6px; font-size: 12px; line-height: 1.2; text-align: center; color: var(--muted); }
.of-img .ph span { font-size: 12px; }
.of-foot { flex-wrap: wrap; }
.of-foot .muted { white-space: nowrap; }

/* 📝 Bajo pedido */
.ci-bp { margin: 2px 0 4px; font-size: 12px; color: #2f6fe0; font-weight: 600; }
.bp-note { margin: 8px 0 0; padding: 8px 10px; border-radius: 10px; background: color-mix(in srgb, #2f6fe0 10%, transparent); }
.of-img .tag.of-bp { top: auto; bottom: 4px; font-size: 10px; }

/* 🔁 «Se nos acabó · Pídelo» */
.cat.pide, .tile.pide { --c: #ff8a3d; }
.tag.pide { background: #d9480f; color: #fff; }
.acab-intro { grid-column: 1 / -1; display: grid; gap: 4px; border: 2px solid #ff8a3d; border-radius: 14px; padding: 14px 16px; background: color-mix(in srgb, #ff8a3d 12%, var(--bg2)); color: var(--text); font-size: 15px; line-height: 1.45; }
.acab-intro b:first-child { font-size: 16px; }

/* 📷 Ver precio con el código de barras */
.search { display: flex; gap: 8px; align-items: center; }
.search input { flex: 1; min-width: 0; }
.scan-btn { flex: none; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--bg2); color: var(--text); border-radius: 999px; padding: 9px 14px; font: inherit; font-weight: 700; white-space: nowrap; }
.scan-btn .ico { width: 18px; height: 18px; }
.scan-btn:hover { border-color: var(--accent); }
.pz-dlg h2 { margin-top: 0; }
.pz-stage { position: relative; width: 100%; aspect-ratio: 4 / 3; max-height: 46dvh; background: #000; border-radius: 14px; overflow: hidden; margin: 8px 0; }
.pz-stage video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pz-guide { position: absolute; left: 8%; right: 8%; top: 30%; height: 40%; border: 3px solid #fffd; border-radius: 12px; box-shadow: 0 0 0 999px #0005; }
.pz-guide i { position: absolute; left: 5%; right: 5%; top: 50%; height: 2px; background: #ff4040; box-shadow: 0 0 8px #ff4040; animation: pzLaser 1.4s ease-in-out infinite alternate; }
.pz-guide.hit { animation: pzHit .6s; }
@keyframes pzLaser { from { transform: translateY(-34px); } to { transform: translateY(34px); } }
@keyframes pzHit { 0% { border-color: #3ddc97; } 100% { border-color: #fffd; } }
@media (prefers-reduced-motion: reduce) { .pz-guide i { animation: none; } }
.pz-tip { position: absolute; left: 0; right: 0; bottom: 0; margin: 0; padding: 8px 12px; color: #fff; font-weight: 600; text-align: center; background: linear-gradient(transparent, #000c); font-size: 13px; }
.pz-stage.off { display: grid; place-items: center; aspect-ratio: auto; min-height: 90px; }
.pz-stage.off video, .pz-stage.off .pz-guide { display: none; }
.pz-stage.off .pz-tip { position: static; background: none; padding: 16px; }
.pz-stage[hidden] { display: none; }
.pz-manual { display: flex; gap: 8px; margin: 8px 0; }
.pz-manual input { flex: 1; min-width: 0; background: var(--bg); border: 1px solid var(--line); color: var(--text); border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 17px; letter-spacing: .04em; }
.pz-luz { margin-top: 4px; }
.pz-luz.on { border-color: var(--accent); }
.pz-card { display: grid; grid-template-columns: 140px 1fr; gap: 16px; align-items: start; margin: 8px 0 12px; }
.pz-img { aspect-ratio: 1; border-radius: 12px; background: var(--panel); overflow: hidden; display: grid; place-items: center; color: var(--muted); font-size: 13px; text-align: center; padding: 6px; }
.pz-img img { width: 100%; height: 100%; object-fit: contain; }
.pz-info h3 { margin: 2px 0 6px; font-size: 20px; line-height: 1.25; }
.pz-info .meta { margin: 0; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
.pz-precio { margin: 6px 0; font-size: 26px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.pz-precio .was { font-size: 16px; color: var(--muted); }
.pz-precio .tag { position: static; font-size: 12px; }
.pz-precio .tbd { font-size: 17px; color: var(--muted); }
.pz-estado { margin: 4px 0; font-weight: 600; }
.pz-estado.agotado { color: var(--muted); }
.pz-acc { display: flex; flex-wrap: wrap; gap: 8px; }
.pz-acc .btn { flex: 1 1 160px; }
.pz-nada { padding: 8px 0 4px; }
@media (max-width: 520px) {
  .pz-card { grid-template-columns: 96px 1fr; gap: 12px; }
  .pz-precio { font-size: 22px; }
  .scan-btn { padding: 9px 12px; }
}
.topbar-inner .scan-btn .lbl { display: inline; }

/* ===== Vitrina: menú lateral de categorías y tarjetas con luz =====
   Todo usa las variables de color de cada tema (--c por categoría, --bg, --line, --muted…),
   así que se ve igual de bien en los 14 temas. El resplandor va con filter: drop-shadow en capas
   (no con box-shadow) para no pisar los marcos y sombras propios de cada tema. */
.side-title { display: none; }
.card { --c: var(--accent); }
.card.c-pk { --c: var(--pk); } .card.c-mtg { --c: var(--mtg); } .card.c-op { --c: var(--op); } .card.c-bg { --c: var(--bg-game); }
.card.c-acc { --c: var(--acc); } .card.c-snk { --c: #e8590c; } .card.c-pide { --c: #ff8a3d; }

/* Celular y tableta: la fila de categorías se desliza y se queda pegada bajo el encabezado */
@media (max-width: 1023.98px) {
  .shop-side { display: contents; }
  #cats { position: sticky; top: var(--top-h, 0px); z-index: 15; margin-inline: -16px; padding: 10px 16px;
    background: color-mix(in srgb, var(--bg) 92%, transparent); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
    scroll-snap-type: x proximity; overscroll-behavior-x: contain; }
  #cats .cat { scroll-snap-align: start; }
}

/* Computadora: barra lateral fija a la izquierda del catálogo */
@media (min-width: 1024px) {
  .shop { display: grid; grid-template-columns: 232px minmax(0, 1fr); grid-template-rows: auto auto auto 1fr; column-gap: 28px; align-items: start; }
  .shop > .shop-side { grid-column: 1; grid-row: 1 / -1; position: sticky; top: calc(var(--top-h, 64px) + 16px);
    max-height: calc(100vh - var(--top-h, 64px) - 32px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin;
    margin-top: 24px; padding: 14px 12px 16px 12px; background: color-mix(in srgb, var(--panel) 70%, transparent);
    border: 1px solid var(--line); border-radius: var(--radius, 14px); }
  .shop > :not(.shop-side) { grid-column: 2; }
  .shop > .results-info { margin-top: 24px; }
  .side-title { display: block; margin: 2px 6px 10px; font-size: 12px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); }
  body.en-inicio .shop-side #cats { display: flex; }   /* en el inicio el menú también se ve */
  body.en-inicio .shop-side .toolbar { display: none; }
  .shop-side .cats { flex-direction: column; justify-content: flex-start; overflow: visible; padding: 0; gap: 4px; }
  /* Cada tema conserva sus colores de botón; el menú solo cambia la forma y suma una barra y un brillo con el color de la categoría */
  .shop-side .cat { position: relative; width: 100%; justify-content: flex-start; text-align: left; margin: 0; }
  .shop-side .cat small { margin-left: auto; }
  .shop-side .cat.on { filter: drop-shadow(0 0 8px color-mix(in srgb, var(--c) 55%, transparent)); }
  .shop-side .cat.on::after { content: ''; position: absolute; left: -12px; top: 18%; bottom: 18%; width: 4px; border-radius: 0 4px 4px 0; background: var(--c); }
  .shop-side .toolbar { flex-direction: column; align-items: stretch; gap: 12px; margin-top: 14px; padding: 14px 0 0; border-top: 1px solid var(--line); }
  .shop-side .chips { gap: 6px; }
  .shop-side .play-toggle, .shop-side #sort { width: 100%; }
}

/* Tarjetas (categorías del inicio y productos) iluminadas como vitrina */
.tile, .card { filter: drop-shadow(0 0 7px color-mix(in srgb, var(--c) 22%, transparent)); }
.grid .card, .home-tiles .tile { transition: transform .2s ease, filter .25s ease, border-color .15s; }
.card.soldout { filter: none; }
.card-img::before, .tile-img::before { content: ''; position: absolute; inset: auto 0 0 0; height: 42%; z-index: 1; pointer-events: none; opacity: .55;
  background: linear-gradient(90deg, transparent 8%, color-mix(in srgb, var(--c) 80%, #fff) 50%, transparent 92%) bottom / 100% 2px no-repeat,
    radial-gradient(ellipse 65% 75% at 50% 100%, color-mix(in srgb, var(--c) 45%, transparent), transparent 72%);
  transition: opacity .25s; }
.card-img::after, .tile-img::after { content: ''; position: absolute; inset: 0; z-index: 2; pointer-events: none; transform: translateX(-130%);
  background: linear-gradient(115deg, transparent 32%, rgba(255, 255, 255, .42) 48%, rgba(255, 255, 255, .12) 54%, transparent 66%); }
.card-img .tag { z-index: 3; }
.card-img img { transition: transform .35s ease; }
:is(.card:hover, .card:has(:focus-visible), .card:active, .tile:hover, .tile:focus-visible, .tile:active) {
  transform: translateY(-4px);
  filter: drop-shadow(0 0 1.5px color-mix(in srgb, var(--c) 75%, transparent)) drop-shadow(0 8px 16px color-mix(in srgb, var(--c) 40%, transparent))
    drop-shadow(0 0 30px color-mix(in srgb, var(--c) 28%, transparent));
}
.tile:focus-visible { outline: 3px solid var(--c); outline-offset: 3px; }
:is(.card:hover, .card:has(:focus-visible), .card:active) .card-img::before,
:is(.tile:hover, .tile:focus-visible, .tile:active) .tile-img::before { opacity: 1; }
:is(.card:hover, .card:has(:focus-visible), .card:active) .card-img::after,
:is(.tile:hover, .tile:focus-visible, .tile:active) .tile-img::after { animation: vitrina-brillo .85s ease-out 1; }
:is(.card:hover, .card:has(:focus-visible), .card:active) .card-img img { transform: scale(1.06); }
:is(.tile:focus-visible, .tile:active) .tile-img img.tile-full, :is(.tile:focus-visible, .tile:active) .tile-img img.tile-fg { transform: scale(1.04); }
@keyframes vitrina-brillo { from { transform: translateX(-130%); } to { transform: translateX(130%); } }
@media (prefers-reduced-motion: reduce) {
  .grid .card, .home-tiles .tile, .card-img img, .tile-img img, .card-img::before, .tile-img::before { transition: none; }
  :is(.card, .tile):is(:hover, :focus-visible, :active, :has(:focus-visible)) { transform: none; }
  :is(.card, .tile) :is(.card-img, .tile-img)::after { display: none; }
  :is(.card, .tile) img { transform: none !important; }
  .tile-img img.tile-bg { transform: scale(1.25) !important; }
}

/* Fichas de categorías: mismo ancho siempre y la última fila centrada, con cualquier cantidad (1, 5, 7, 12…) */
.home-tiles { --cols: 3; --gap: 18px; display: flex; flex-wrap: wrap; justify-content: center; gap: var(--gap); }
.home-tiles > .tile { flex: 0 0 calc((100% - (var(--cols) - 1) * var(--gap)) / var(--cols)); min-width: 0; }
@media (max-width: 520px) { .home-tiles { --cols: 2; --gap: 12px; } }

/* 📷 Guía «¿Cuánto cuesta?» antes de abrir la cámara de Ver precio */
.pz-guia { width: min(480px, 100% - 24px); }
.pz-guia h2 { margin: 0 40px 6px 0; }
.pz-guia-intro { margin: 0 0 14px; }
.pz-pasos { list-style: none; counter-reset: paso; margin: 0 0 14px; padding: 0; display: grid; gap: 10px; }
.pz-pasos li { counter-increment: paso; display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: center; padding: 10px 12px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius, 14px); line-height: 1.4; }
.pz-ico { position: relative; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; font-size: 22px;
  background: color-mix(in srgb, var(--accent) 18%, var(--bg2)); }
.pz-ico::after { content: counter(paso); position: absolute; right: -4px; bottom: -4px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center;
  font: 800 12px/1 var(--font); background: var(--text); color: var(--bg); }   /* texto y fondo del tema: buen contraste en todos */
.pz-permiso { margin: 0 0 12px; padding: 10px 12px; border-left: 4px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); border-radius: 8px; font-size: 14px; }
.pz-nomas { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; font-size: 15px; cursor: pointer; min-height: 44px; }
.pz-nomas input { width: 22px; height: 22px; margin: 0; accent-color: var(--accent); flex: none; }
.pz-guia .pz-acc .btn { min-height: 46px; }
.pz-como { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.pz-encender { margin: 0 auto 14px; display: block; }
.pz-stage:not(.off) .pz-encender { display: none; }
.pz-stage.off { grid-template-rows: auto auto; }
@media (max-width: 420px) { .pz-guia { padding: 22px 16px; } .pz-pasos li { grid-template-columns: 40px 1fr; padding: 9px 10px; } .pz-ico { width: 40px; height: 40px; font-size: 20px; } }

/* 🚚 Ficha: envío, recoger, pagos y WhatsApp junto al botón de agregar */
.pd-compra { list-style: none; margin: 14px 0 10px; padding: 10px 12px; display: grid; gap: 6px; font-size: 14.5px; line-height: 1.4;
  border: 1px solid var(--line); border-radius: var(--radius, 14px); background: color-mix(in srgb, var(--panel) 70%, transparent); }
.pd-compra li { display: grid; grid-template-columns: 22px 1fr; gap: 8px; align-items: start; }
.pd-wa { font-weight: 700; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
/* "También te puede interesar" en la ficha */
.pd-rel { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
.pd-rel h3 { margin: 0 0 10px; font-size: 17px; }
.pd-rel-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.pd-rel-item { display: flex; flex-direction: column; gap: 4px; padding: 0 0 8px; text-align: left; background: var(--panel); border: 1px solid var(--line);
  border-radius: 12px; overflow: hidden; color: var(--text); cursor: pointer; }
.pd-rel-item:hover, .pd-rel-item:focus-visible { border-color: var(--accent); }
.pd-rel-img { display: block; aspect-ratio: 1; background: var(--bg2); }
.pd-rel-img img, .pd-rel-img .ph { width: 100%; height: 100%; object-fit: contain; }
.pd-rel-img .ph span { font-size: 14px; }
.pd-rel-nom { padding: 0 8px; font-size: 13px; font-weight: 600; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pd-rel-precio { padding: 0 8px; font-size: 13.5px; font-weight: 800; color: var(--accent); }
@media (max-width: 560px) { .pd-rel-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* 🛒 Carrito: barra de envío gratis y sugerencia de accesorios */
.free-bar { margin: 6px 0 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; }
.free-bar p { margin: 0 0 6px; font-size: 14px; }
.free-bar progress { display: block; width: 100%; height: 8px; border: 0; border-radius: 99px; overflow: hidden; background: var(--line); appearance: none; -webkit-appearance: none; }
.free-bar progress::-webkit-progress-bar { background: var(--line); border-radius: 99px; }
.free-bar progress::-webkit-progress-value { background: var(--accent); border-radius: 99px; transition: width .3s; }
.free-bar progress::-moz-progress-bar { background: var(--accent); border-radius: 99px; }
.free-bar.ok { border-color: var(--ok); }
.free-bar.ok progress::-webkit-progress-value { background: var(--ok); }
.free-bar.ok progress::-moz-progress-bar { background: var(--ok); }
.cart-sug { margin: 12px 0 4px; padding: 10px 12px; border: 1px dashed var(--line); border-radius: 12px; }
.cart-sug-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
.cart-sug-head p { margin: 0; font-size: 14px; }
.link-btn { background: none; border: 0; padding: 6px 2px; font: inherit; font-size: 13px; color: var(--muted); text-decoration: underline; cursor: pointer; }
.cart-sug-item { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; padding: 6px 0; }
.cart-sug-item .ci-img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; }
.cart-sug-nom { font-size: 13.5px; font-weight: 600; line-height: 1.25; }
.cart-sug-nom small { display: block; font-weight: 700; color: var(--accent); }
.cart-sug .btn.add { padding: 8px 10px; font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .free-bar progress::-webkit-progress-value { transition: none; } }
.cart-sug-item .ph { overflow: hidden; }
.cart-sug-item .ph span, .pd-rel-img .ph span { font-size: 9px; padding: 1px 3px; letter-spacing: 0; }
.pd-rel-img .ph span { font-size: 12px; }

/* 🖼️ Imagen propia de la portada (en lugar del adorno del tema): se adapta sin empujar demasiado el contenido */
.hero-img { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; min-width: 0; }
.hero-img img { display: block; width: 100%; height: auto; max-height: 420px; object-fit: contain; filter: drop-shadow(0 16px 28px rgba(0, 0, 0, .3)); }
@media (max-width: 760px) {
  .hero-img { margin-top: -6px; }
  .hero-img img { width: auto; max-width: 100%; max-height: 210px; }
}
