/* NesMa — tienda / pedidos por WhatsApp */
:root {
  --navy: #173a66;
  --blue: #1d5fb8;
  --blue-600: #174f9c;
  --sky: #e8f1fc;
  --sky-2: #f3f8fe;
  --ink: #142033;
  --ink-2: #4a5872;
  --ink-3: #7a879c;
  --line: #dfe6ef;
  --line-2: #eef2f7;
  --bg: #f6f8fb;
  --card: #ffffff;
  --wa: #1fa855;
  --wa-600: #178a45;
  --ok-bg: #e7f6ed;
  --danger: #c0392b;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20, 32, 51, .06), 0 4px 16px rgba(20, 32, 51, .06);
  --shadow-lg: 0 20px 60px rgba(20, 32, 51, .25);
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --header-h: 120px;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: var(--header-h); }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg);
  font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { -webkit-tap-highlight-color: transparent; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.015em; }
h1 { font-size: clamp(1.6rem, 1.1rem + 2vw, 2.6rem); font-weight: 800; }
h2 { font-size: clamp(1.25rem, 1.05rem + .8vw, 1.6rem); font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 700; }
.muted { color: var(--ink-2); }
.small { font-size: .85rem; }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.ic { width: 20px; height: 20px; flex: none; }
.ic--xl { width: 48px; height: 48px; color: var(--line); }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }
:focus-visible { outline: 3px solid rgba(29, 95, 184, .45); outline-offset: 2px; border-radius: 6px; }

/* ── Topbar ───────────────────────── */
.topbar { background: var(--navy); color: #d5e2f5; font-size: .82rem; }
.topbar__in { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 36px; }
.topbar strong { color: #fff; }
.iva-switch { display: inline-flex; background: rgba(255, 255, 255, .1); border-radius: 999px; padding: 2px; }
.iva-switch button {
  border: 0; background: transparent; color: #c5d5ec; font-size: .78rem; font-weight: 600; padding: 4px 12px; border-radius: 999px; cursor: pointer;
}
.iva-switch button[aria-pressed="true"] { background: #fff; color: var(--navy); }

/* ── Header ───────────────────────── */
.header {
  position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .97); backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line); transition: transform .25s ease;
}
.header__in { display: flex; align-items: center; gap: 16px; padding-top: 10px; padding-bottom: 10px; }
.brand { flex: none; }
.brand img { height: 50px; width: auto; }
.search { flex: 1; position: relative; max-width: 600px; margin-left: auto; }
.search__ic { position: absolute; left: 14px; top: 12px; color: var(--ink-2); pointer-events: none; }
.search input {
  width: 100%; height: 44px; border-radius: 12px; border: 1.5px solid var(--line);
  background: var(--sky-2); padding: 0 40px 0 42px; outline: none; transition: border-color .15s, background .15s, box-shadow .15s;
}
.search input::-webkit-search-cancel-button { cursor: pointer; }
.search input:focus { border-color: var(--blue); background: #fff; box-shadow: 0 0 0 4px rgba(29, 95, 184, .12); }
.search__kbd {
  position: absolute; right: 12px; top: 11px; font: 600 .75rem var(--font); color: var(--ink-3); border: 1px solid var(--line);
  border-radius: 6px; padding: 1px 7px; background: #fff; pointer-events: none;
}
.search input:focus ~ .search__kbd, .search input:not(:placeholder-shown) ~ .search__kbd { display: none; }

.suggest {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 50; background: #fff; border: 1px solid var(--line);
  border-radius: 14px; box-shadow: var(--shadow-lg); overflow: hidden; max-height: min(70vh, 520px); overflow-y: auto;
}
.suggest__label { font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); padding: 10px 14px 4px; }
.sg {
  display: grid; grid-template-columns: 40px 1fr auto auto; gap: 10px; align-items: center; padding: 8px 14px; cursor: pointer;
  border-top: 1px solid var(--line-2);
}
.sg:first-of-type { border-top: 0; }
.sg.is-active, .sg:hover { background: var(--sky-2); }
.sg img { width: 40px; height: 40px; object-fit: contain; border-radius: 8px; border: 1px solid var(--line-2); background: #fff; }
.sg__name { font-weight: 600; font-size: .9rem; line-height: 1.25; }
.sg__name mark { background: #fff3bf; color: inherit; border-radius: 3px; padding: 0 1px; }
.sg__sub { font-size: .76rem; color: var(--ink-2); }
.hide-lg { display: none; }
.sg__price { font-weight: 800; font-size: .9rem; white-space: nowrap; text-align: right; }
.sg__price small { display: block; font-weight: 600; font-size: .68rem; color: var(--ink-3); }
.sg__add {
  width: 34px; height: 34px; border-radius: 10px; border: 1.5px solid var(--blue); color: var(--blue); background: #fff;
  display: grid; place-items: center; cursor: pointer; font-weight: 800; font-size: .85rem;
}
.sg__add:hover { background: var(--blue); color: #fff; }
.sg__add.is-in { background: var(--ok-bg); border-color: var(--wa); color: var(--wa-600); }
.suggest__all {
  display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 12px 14px; border: 0; border-top: 1px solid var(--line);
  background: var(--sky-2); color: var(--blue); font-weight: 700; cursor: pointer; text-align: left;
}
.suggest__all.is-active, .suggest__all:hover { background: var(--sky); }
.suggest__empty { padding: 16px 14px; color: var(--ink-2); font-size: .9rem; }
.suggest__empty a { font-weight: 700; }

.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 16px; flex: none;
  border-radius: 12px; border: 0; background: var(--blue); color: #fff; font-weight: 700; cursor: pointer;
}
.cart-btn:hover { background: var(--blue-600); }
.badge {
  min-width: 22px; height: 22px; border-radius: 999px; background: #fff; color: var(--blue);
  font-size: .78rem; font-weight: 800; display: inline-grid; place-items: center; padding: 0 6px;
}
.pop { animation: pop .35s ease; }
@keyframes pop { 50% { transform: scale(1.3); } }

.catnav { border-top: 1px solid var(--line-2); position: relative; }
.catnav__in {
  display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding-top: 6px; padding-bottom: 6px;
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent);
}
.catnav__in::-webkit-scrollbar { display: none; }
.catnav a {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; padding: 6px 12px; border-radius: 999px;
  color: var(--ink-2); font-size: .88rem; font-weight: 600;
}
.catnav a .ic { width: 17px; height: 17px; }
.catnav a:hover { background: var(--sky); color: var(--blue); }
.catnav a.is-active { background: var(--blue); color: #fff; }

/* ── Botones ───────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px;
  border-radius: 12px; font-weight: 700; border: 1.5px solid transparent; cursor: pointer; transition: background .15s, border-color .15s, color .15s, transform .05s;
  white-space: nowrap; text-align: center;
}
.btn:active { transform: translateY(1px); }
.btn--lg { height: 50px; padding: 0 22px; font-size: 1.02rem; }
.btn--sm { height: 38px; padding: 0 12px; font-size: .88rem; border-radius: 10px; }
.btn--primary { background: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-600); }
.btn--ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn--light { background: #fff; color: var(--navy); }
.btn--light:hover { background: var(--sky); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { background: var(--wa-600); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.icon-btn { width: 40px; height: 40px; display: inline-grid; place-items: center; border-radius: 10px; border: 0; background: transparent; cursor: pointer; color: var(--ink-2); flex: none; }
.icon-btn:hover { background: var(--sky); color: var(--ink); }
.link { font-weight: 600; }
.link-btn { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--ink-2); cursor: pointer; font-size: .88rem; font-weight: 600; padding: 6px 8px; border-radius: 8px; }
.link-btn:hover { color: var(--blue); background: var(--sky-2); }
.link-btn .ic { width: 17px; height: 17px; }

/* Selector de cantidad */
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--blue); border-radius: 10px; background: #fff; overflow: hidden; flex: none; }
.qty button { width: 36px; height: 36px; border: 0; background: transparent; cursor: pointer; display: grid; place-items: center; color: var(--blue); }
.qty button:hover { background: var(--sky); }
.qty .ic { width: 16px; height: 16px; }
.qty input { width: 44px; height: 36px; border: 0; text-align: center; font-weight: 800; -moz-appearance: textfield; background: transparent; font-variant-numeric: tabular-nums; padding: 0; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty--wide input { width: 58px; }
.qty--block { display: flex; width: 100%; }
.qty--block input { flex: 1; }
.add-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 39px; min-width: 116px; padding: 0 14px;
  border-radius: 10px; border: 1.5px solid var(--blue); background: #fff; color: var(--blue); font-weight: 700; font-size: .9rem; cursor: pointer; flex: none;
}
.add-btn:hover { background: var(--blue); color: #fff; }
.add-btn .ic { width: 16px; height: 16px; }
.add-btn--solid { background: var(--blue); color: #fff; }
.add-btn--solid:hover { background: var(--blue-600); }
.add-btn--block { width: 100%; }

/* Segmentado */
.seg { display: inline-flex; background: #fff; border: 1.5px solid var(--line); border-radius: 10px; padding: 2px; }
.seg button {
  display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; padding: 0 12px; height: 34px; border-radius: 8px;
  font-weight: 600; font-size: .88rem; color: var(--ink-2); cursor: pointer;
}
.seg button .ic { width: 18px; height: 18px; }
.seg button[aria-pressed="true"] { background: var(--blue); color: #fff; }

/* ── Hero ───────────────────────── */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: radial-gradient(1200px 500px at 85% -10%, rgba(110, 168, 255, .35), transparent 60%), linear-gradient(135deg, var(--navy) 0%, #1a4a8c 55%, var(--blue) 100%);
}
/* hexágono del logo como marca de agua */
.hero::before {
  content: ""; position: absolute; width: 620px; height: 620px; left: -180px; bottom: -260px; opacity: .08; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cpath d='M100 12 L176 56 L176 144 L100 188 L24 144 L24 56 Z M100 104 L48 82 M100 104 L152 82 M100 104 L100 172' fill='none' stroke='white' stroke-width='6' stroke-linejoin='round' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center / contain;
}
.hero__in { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; padding-top: 48px; padding-bottom: 72px; }
.hero h1 { color: #fff; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .76rem; font-weight: 700; color: var(--blue); margin: 0 0 10px; }
.hero .eyebrow { color: #9cc6ff; }
.lead { font-size: 1.08rem; color: var(--ink-2); max-width: 50ch; margin: 0; }
.hero .lead { color: #dbe7f7; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.hero .btn--primary { background: #fff; color: var(--navy); box-shadow: 0 6px 20px rgba(0, 0, 0, .18); }
.hero .btn--primary:hover { background: var(--sky); }
.hero .btn--ghost { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .45); }
.hero .btn--ghost:hover { background: rgba(255, 255, 255, .16); border-color: #fff; color: #fff; }
.hero__note { font-size: .88rem; color: #b9cde8; margin: 18px 0 0; max-width: 52ch; }
.hero__note strong { color: #fff; }
.showcase { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.sc {
  display: grid; grid-template-rows: 1fr auto; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 12px; color: var(--ink);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18); transition: transform .15s, box-shadow .15s, border-color .15s; min-width: 0;
}
.sc:hover { transform: translateY(-3px); border-color: #9cc6ff; box-shadow: 0 12px 30px rgba(0, 0, 0, .25); }
.sc img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: contain; }
.sc__name { display: block; font-weight: 700; font-size: .95rem; margin-top: 6px; }
.sc__price { display: block; font-size: .82rem; color: var(--ink-2); }
.sc__price b { color: var(--ink); font-size: 1rem; }

.perks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: -30px; position: relative; }
.perk { display: flex; gap: 12px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; box-shadow: var(--shadow); }
.perk .ic { width: 24px; height: 24px; color: var(--blue); margin-top: 2px; }
.perk strong { display: block; font-size: .93rem; }
.perk span { font-size: .83rem; color: var(--ink-2); }

.block { padding-top: 44px; }
.block__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.block__head h2 { margin: 0; }

/* ── Categorías ───────────────────────── */
.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.cat-card {
  display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 10px 14px 10px 10px; color: var(--ink); transition: border-color .15s, box-shadow .15s, transform .15s;
}
.cat-card:hover { border-color: var(--blue); box-shadow: var(--shadow); transform: translateY(-2px); }
.cat-card__img { width: 60px; height: 60px; flex: none; border-radius: 12px; background: #fff; border: 1px solid var(--line-2); display: grid; place-items: center; overflow: hidden; }
.cat-card__img img { width: 100%; height: 100%; object-fit: contain; }
.cat-card__txt { flex: 1; min-width: 0; }
.cat-card strong { display: block; font-size: .96rem; line-height: 1.25; }
.cat-card__txt span { font-size: .8rem; color: var(--ink-2); }
.cat-card > .ic { color: var(--ink-3); width: 18px; }

/* ── Tarjetas de producto ───────────────────────── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.card {
  display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: box-shadow .15s, border-color .15s; position: relative;
}
.card:hover { box-shadow: var(--shadow); border-color: #c8d5e6; }
.card.in-cart { border-color: var(--blue); box-shadow: 0 0 0 1px var(--blue); }
.card__media { aspect-ratio: 1; background: #fff; display: grid; place-items: center; padding: 14px; }
.card__media img { width: 100%; height: 100%; object-fit: contain; transition: transform .25s; }
.card:hover .card__media img { transform: scale(1.04); }
.card__chip {
  position: absolute; top: 10px; left: 10px; font-size: .72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px;
  background: var(--sky); color: var(--blue); z-index: 1;
}
.card__chip--in { background: var(--blue); color: #fff; left: auto; right: 10px; display: inline-flex; align-items: center; gap: 4px; }
.card__chip--in .ic { width: 13px; height: 13px; }
.card__body { padding: 0 14px 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card__title { font-size: .95rem; font-weight: 700; line-height: 1.3; margin: 0; color: var(--ink); }
.card__title a { color: inherit; }
.card__title a::after { content: ""; position: absolute; inset: 0; z-index: 0; }
.card__meta { font-size: .8rem; color: var(--ink-2); margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card__price { margin-top: auto; padding-top: 6px; }
.price { font-weight: 800; font-size: 1.18rem; color: var(--ink); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.price small { font-weight: 600; font-size: .72rem; color: var(--ink-2); letter-spacing: 0; }
.ivatag { display: inline-block; vertical-align: .12em; margin-left: .3em; padding: .12em .45em; border-radius: 6px; background: #e3edfb; color: var(--blue); font-size: .72rem; font-weight: 800; letter-spacing: .01em; line-height: 1.25; white-space: nowrap; font-variant-numeric: normal; }
.ivatag--in { background: #e4f5ea; color: #157a3c; }
.price__from { display: block; font-size: .7rem; color: var(--ink-3); font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.card__foot { padding: 0 14px 14px; position: relative; z-index: 1; }
.card__foot .qty { display: flex; width: 100%; }
.card__foot .qty input { flex: 1; }

/* ── Catálogo ───────────────────────── */
#view-catalog { padding-top: 18px; padding-bottom: 40px; min-height: 70vh; }
.crumbs { font-size: .84rem; color: var(--ink-2); margin-bottom: 6px; }
.crumbs a { color: var(--ink-2); }
.crumbs a:hover { color: var(--blue); }
.cat-head h1 { margin-bottom: 2px; font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.2rem); }
.cat-head p { margin: 0; }
.toolbar {
  display: flex; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; margin: 14px 0;
  padding: 10px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.toolbar__ctrls { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.result-count { font-size: .88rem; color: var(--ink-2); margin: 0; }
.select select {
  height: 40px; border-radius: 10px; border: 1.5px solid var(--line); background: #fff; padding: 0 34px 0 12px; appearance: none; cursor: pointer; font-weight: 600; font-size: .88rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%234a5872' stroke-width='2' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.empty { text-align: center; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); padding: 40px 16px; }
.empty__actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }

/* Lista rápida */
.plist { display: grid; gap: 12px; }
.pgroup { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.pgroup__head {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: var(--sky-2); border-bottom: 1px solid var(--line); color: var(--ink);
}
.pgroup__head img { width: 40px; height: 40px; object-fit: contain; background: #fff; border-radius: 8px; border: 1px solid var(--line-2); flex: none; }
.pgroup__title { font-weight: 700; font-size: .95rem; flex: 1; min-width: 0; }
.pgroup__title small { display: block; font-weight: 500; color: var(--ink-2); font-size: .78rem; }
.pgroup__more { font-size: .84rem; font-weight: 700; white-space: nowrap; }
.prow {
  display: grid; grid-template-columns: minmax(0, 1fr) 100px 110px 132px; gap: 12px; align-items: center; padding: 8px 14px;
  border-top: 1px solid var(--line-2);
}
.prow:first-of-type { border-top: 0; }
.prow.in-cart { background: #f2f8ff; }
.prow__name { font-weight: 600; font-size: .9rem; line-height: 1.3; }
.prow__specs { font-size: .76rem; color: var(--ink-2); }
.prow__code { font-size: .8rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.prow__price { font-weight: 800; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.prow__price small { display: block; font-weight: 600; font-size: .7rem; color: var(--ink-3); }
.prow__ctrl { display: flex; justify-content: flex-end; }
.prow__ctrl .add-btn { min-width: 0; width: 100%; }
.prow__ctrl .qty { width: 100%; }
.prow__ctrl .qty input { flex: 1; width: 0; }

/* ── Bloques varios ───────────────────────── */
.pro-band {
  display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; padding: 28px;
  border-radius: 20px; color: #fff; background: linear-gradient(120deg, var(--navy), var(--blue));
}
.pro-band h2 { color: #fff; margin-bottom: 6px; }
.pro-band p { margin: 0; color: #d5e2f5; max-width: 60ch; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.steps li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.steps span { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--sky); color: var(--blue); font-weight: 800; margin-bottom: 8px; }
.steps strong { display: block; margin-bottom: 4px; }
.steps p { margin: 0; color: var(--ink-2); font-size: .92rem; }
.faq { padding-bottom: 56px; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 16px; margin-bottom: 8px; }
.faq summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 700; color: var(--blue); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 14px; color: var(--ink-2); }

/* ── Footer ───────────────────────── */
.footer { background: #fff; border-top: 1px solid var(--line); padding: 40px 0 24px; }
.footer__in { display: grid; grid-template-columns: 1fr 1.2fr 1.2fr; gap: 32px; }
.footer__logo { height: 56px; width: auto; margin-bottom: 8px; }
.footer__legal { border-top: 1px solid var(--line); margin-top: 28px; padding-top: 16px; }
.contact { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.contact li { display: flex; gap: 10px; align-items: flex-start; }
.contact .ic { color: var(--blue); margin-top: 2px; }
.contact a { color: var(--ink); }
.contact a:hover { color: var(--blue); }

/* ── WhatsApp flotante + barra mobile ───────────────────────── */
.fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 40; width: 56px; height: 56px; border-radius: 50%; background: var(--wa); color: #fff;
  display: grid; place-items: center; box-shadow: 0 8px 24px rgba(31, 168, 85, .4); transition: transform .15s, bottom .2s;
}
.fab:hover { transform: scale(1.06); }
.fab .ic { width: 28px; height: 28px; }
.cartbar { display: none; }

/* ── Modal de producto ───────────────────────── */
.modal, .drawer { position: fixed; inset: 0; z-index: 60; }
.modal__backdrop, .drawer__backdrop { position: absolute; inset: 0; background: rgba(14, 24, 40, .5); animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } }
.modal__panel {
  position: relative; margin: 3vh auto; width: min(1040px, calc(100% - 32px)); height: 94vh; max-height: 900px; background: #fff;
  border-radius: 20px; box-shadow: var(--shadow-lg); animation: rise .22s ease; overflow: hidden;
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
.pd { display: flex; flex-direction: column; height: 100%; }
.pd__bar { display: flex; align-items: center; gap: 8px; padding: 8px 10px 8px 16px; border-bottom: 1px solid var(--line-2); flex: none; }
.pd__bar .crumbs { margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pd__bar-title { display: none; font-weight: 700; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pd__scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.pd__grid { display: grid; grid-template-columns: 320px 1fr; gap: 28px; padding: 24px 24px 8px; align-items: start; }
.pd__media { position: sticky; top: 0; }
.pd__media img { width: 100%; aspect-ratio: 1; object-fit: contain; border: 1px solid var(--line-2); border-radius: 16px; padding: 16px; background: #fff; }
.pd__info h2 { font-size: 1.45rem; margin-bottom: 6px; }
.pd__lead { color: var(--ink-2); margin: 0 0 12px; }
.pd__from { font-size: .9rem; color: var(--ink-2); margin: 0 0 14px; }
.pd__from b { font-size: 1.3rem; color: var(--ink); }
.pd__features { margin: 0 0 12px; padding: 0; list-style: none; display: grid; gap: 4px; }
.pd__features li { display: flex; gap: 8px; font-size: .9rem; }
.pd__features .ic { color: var(--wa); width: 18px; height: 18px; margin-top: 2px; }
.pd__more { font-size: .88rem; }
.pd__more summary { cursor: pointer; font-weight: 700; color: var(--blue); list-style: none; padding: 4px 0; }
.pd__more summary::-webkit-details-marker { display: none; }
.pd__more[open] summary { margin-bottom: 6px; }
.pd__notes { font-size: .82rem; color: var(--ink-2); background: var(--sky-2); border-radius: 10px; padding: 10px 12px; margin: 10px 0 0; }
.pd__notes p { margin: 2px 0; }
.pd__label { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-weight: 700; font-size: .95rem; margin: 18px 0 8px; }
.pd__label span { font-weight: 500; font-size: .8rem; color: var(--ink-2); }
.vlist { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.vrow { display: grid; grid-template-columns: minmax(0, 1fr) auto 132px; gap: 6px 14px; align-items: center; padding: 10px 12px; border-top: 1px solid var(--line-2); }
.vrow:first-child { border-top: 0; }
.vrow.in-cart { background: #f2f8ff; }
.vrow__name { font-weight: 700; font-size: .92rem; line-height: 1.3; }
.vrow__meta { font-size: .76rem; color: var(--ink-2); line-height: 1.4; }
.vrow__meta b { color: var(--ink); font-weight: 600; }
.vrow__price { font-weight: 800; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.vrow__price small { display: block; font-weight: 600; font-size: .7rem; color: var(--ink-3); }
.vrow__ctrl { display: flex; }
.vrow__ctrl > * { width: 100%; }
.vrow__ctrl .qty input { flex: 1; width: 0; }
.related { padding: 8px 24px 24px; }
.related h3 { font-size: 1rem; margin: 10px 0 10px; }
.related__row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(180px, 1fr); gap: 10px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.rel { display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 12px; padding: 8px; color: var(--ink); background: #fff; }
.rel:hover { border-color: var(--blue); }
.rel img { width: 48px; height: 48px; object-fit: contain; flex: none; }
.rel strong { display: block; font-size: .82rem; line-height: 1.25; }
.rel span { font-size: .76rem; color: var(--ink-2); }
.pd__foot {
  flex: none; display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); background: #fff;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
}
.pd__sum { flex: 1; min-width: 0; font-size: .85rem; color: var(--ink-2); line-height: 1.3; }
.pd__sum strong { display: block; color: var(--ink); font-size: 1.05rem; }
.pd__foot-actions { display: flex; gap: 8px; align-items: center; }

/* ── Pedido (drawer) ───────────────────────── */
.drawer__panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(480px, 100%); background: #fff; display: flex; flex-direction: column;
  box-shadow: var(--shadow-lg); animation: slide .22s ease;
}
@keyframes slide { from { transform: translateX(30px); opacity: 0; } }
.drawer__head { display: flex; justify-content: space-between; align-items: center; padding: 10px 10px 10px 18px; border-bottom: 1px solid var(--line); }
.drawer__head h2 { margin: 0; font-size: 1.2rem; }
.drawer__body { flex: 1; overflow: auto; padding: 4px 18px 18px; overscroll-behavior: contain; }
.drawer__foot { border-top: 1px solid var(--line); padding: 12px 18px; padding-bottom: max(12px, env(safe-area-inset-bottom)); display: grid; gap: 6px; }
.drawer__foot-links { display: flex; justify-content: center; gap: 8px; }
.send__total { margin-left: auto; font-weight: 800; background: rgba(255, 255, 255, .18); padding: 4px 10px; border-radius: 8px; font-size: .92rem; }
#send-order { justify-content: flex-start; }
.cart-empty, .cart-sent { text-align: center; padding: 48px 8px; display: grid; justify-items: center; gap: 4px; }
.cart-empty p, .cart-sent p { margin: 0; }
.cart-empty__actions, .cart-sent__actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 12px; }
.cart-sent__ic { width: 56px; height: 56px; border-radius: 50%; background: var(--ok-bg); color: var(--wa-600); display: grid; place-items: center; margin-bottom: 8px; }
.cart-sent__ic .ic { width: 30px; height: 30px; }
.cart-sent hr { width: 100%; border: 0; border-top: 1px solid var(--line); margin: 20px 0 8px; }
.cart-list { list-style: none; margin: 0; padding: 0; }
.cart-item { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--line-2); align-items: start; }
.cart-item img { width: 52px; height: 52px; object-fit: contain; border: 1px solid var(--line-2); border-radius: 10px; padding: 3px; background: #fff; grid-row: span 2; }
.cart-item__name { font-weight: 700; font-size: .9rem; line-height: 1.3; color: var(--ink); }
.cart-item__name:hover { color: var(--blue); }
.cart-item__sub { font-size: .76rem; color: var(--ink-2); }
.cart-item__total { font-weight: 800; white-space: nowrap; text-align: right; font-variant-numeric: tabular-nums; }
.cart-item__ctrl { grid-column: 2 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.cart-item__ctrl .qty { border-color: var(--line); }
.cart-item .icon-btn { width: 36px; height: 36px; color: var(--ink-3); }
.cart-item .icon-btn:hover { color: var(--danger); background: #fdecea; }
.cart-totals { padding: 12px 0 14px; display: grid; gap: 4px; font-size: .9rem; font-variant-numeric: tabular-nums; }
.cart-totals div { display: flex; justify-content: space-between; }
.cart-totals .grand { font-size: 1.1rem; font-weight: 800; border-top: 1px dashed var(--line); padding-top: 8px; margin-top: 4px; }
.cart-totals .hint { font-size: .78rem; color: var(--ink-2); display: block; margin-top: 4px; }

.who { background: var(--sky-2); border-radius: 14px; padding: 14px; }
.who h3 { margin: 0 0 10px; font-size: .98rem; display: flex; justify-content: space-between; align-items: center; }
.who__summary { display: flex; gap: 12px; align-items: center; }
.who__avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; font-weight: 800; flex: none; }
.who__summary div { flex: 1; min-width: 0; font-size: .88rem; color: var(--ink-2); line-height: 1.35; }
.who__summary strong { display: block; color: var(--ink); font-size: .95rem; }
.who form { display: grid; gap: 10px; }
.field { display: grid; gap: 4px; font-size: .84rem; font-weight: 600; }
.field input, .field textarea {
  width: 100%; border: 1.5px solid var(--line); border-radius: 10px; padding: 10px 12px; background: #fff; font-weight: 400; outline: none; font-size: 1rem;
}
.field input:focus, .field textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(29, 95, 184, .12); }
.field .is-invalid { border-color: var(--danger); }
.field__row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; border: 0; padding: 0; margin: 0; }
.chips legend { font-size: .84rem; font-weight: 600; margin-bottom: 4px; padding: 0; width: 100%; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips label span {
  display: inline-block; padding: 7px 12px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; font-size: .84rem; font-weight: 600; cursor: pointer; color: var(--ink-2);
}
.chips input:checked + span { border-color: var(--blue); background: var(--blue); color: #fff; }
.chips input:focus-visible + span { outline: 3px solid rgba(29, 95, 184, .45); outline-offset: 2px; }
.form-error { color: var(--danger); font-size: .85rem; margin: 0; text-align: center; font-weight: 600; }

/* ── Toast ───────────────────────── */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 80; background: var(--ink); color: #fff;
  padding: 10px 10px 10px 16px; border-radius: 12px; box-shadow: var(--shadow-lg); font-weight: 600; font-size: .9rem; display: flex; gap: 12px; align-items: center;
  animation: rise .2s ease; max-width: calc(100% - 24px); min-width: 280px;
}
.toast span { flex: 1; }
.toast button, .toast a {
  border: 0; background: rgba(255, 255, 255, .12); color: #9cc6ff; font-weight: 700; padding: 6px 10px; border-radius: 8px; cursor: pointer; white-space: nowrap; font-size: .88rem;
}
.toast button:hover, .toast a:hover { background: rgba(255, 255, 255, .2); }

body.lock { overflow: hidden; }

/* ── Responsive ───────────────────────── */
@media (max-width: 960px) {
  .hero__in { grid-template-columns: 1fr; padding-top: 26px; padding-bottom: 46px; gap: 22px; }
  .showcase { grid-template-columns: repeat(4, minmax(150px, 1fr)); overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
  .showcase::-webkit-scrollbar { display: none; }
  .perks { grid-template-columns: repeat(2, 1fr); }
  .pd__grid { grid-template-columns: 1fr; gap: 14px; padding: 16px; }
  .pd__media { position: static; display: flex; gap: 14px; align-items: center; }
  .pd__media img { width: 120px; flex: none; padding: 8px; }
  .related { padding: 8px 16px 20px; }
  .footer__in { grid-template-columns: 1fr; gap: 24px; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .prow { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name price" "code ctrl"; gap: 4px 12px; padding: 10px 12px; }
  .prow__info { grid-area: name; }
  .prow__code { grid-area: code; align-self: center; }
  .prow__price { grid-area: price; }
  .prow__ctrl { grid-area: ctrl; width: 132px; justify-self: end; }
}
@media (max-width: 640px) {
  :root { --header-h: 116px; }
  .hide-sm { display: none !important; }
  .topbar__in { min-height: 34px; }
  .header__in { flex-wrap: wrap; gap: 8px 10px; padding-top: 8px; padding-bottom: 8px; }
  .header.is-hidden { transform: translateY(-100%); }
  .brand img { height: 40px; }
  .search { order: 3; flex-basis: 100%; max-width: none; }
  .search input { font-size: 16px; }
  .suggest { position: fixed; left: 8px; right: 8px; top: auto; max-height: 60vh; }
  .sg { grid-template-columns: 36px 1fr auto; }
  .sg .sg__price { display: none; }
  .sg__sub b { color: var(--ink); }
  .sg__sub .hide-lg { display: inline; }
  .cart-btn { margin-left: auto; padding: 0 12px; height: 40px; }
  .cart-btn__label { display: none; }
  .catnav__in { padding-top: 4px; padding-bottom: 6px; }
  h1 { font-size: 1.7rem; }
  .lead { font-size: 1rem; }
  .hero__cta .btn { flex: 1; }
  .hero__note { display: none; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card__media { padding: 10px; }
  .card__body { padding: 0 10px 8px; }
  .card__title { font-size: .86rem; }
  .card__meta { display: none; }
  .price { font-size: 1.02rem; }
  .card__foot { padding: 0 10px 10px; }
  .card__foot .add-btn { min-width: 0; width: 100%; height: 38px; font-size: .85rem; }
  .card__foot .qty button { width: 34px; }
  .perks { grid-template-columns: 1fr 1fr; margin-top: -26px; gap: 8px; }
  .perk { padding: 10px; flex-direction: column; gap: 4px; }
  .perk span { font-size: .78rem; }
  .cats { grid-template-columns: 1fr; }
  .toolbar { position: sticky; top: 0; z-index: 20; background: var(--bg); margin: 10px -16px; padding: 8px 16px; transition: top .25s ease; }
  body:not(.header-hidden) .toolbar { top: var(--header-h); }
  .toolbar__ctrls { width: 100%; flex-wrap: nowrap; }
  .toolbar .select { flex: 1; min-width: 0; }
  .toolbar select { width: 100%; padding-right: 26px; background-position: right 8px center; font-size: .82rem; }
  .result-count { width: 100%; font-size: .8rem; }
  .pro-band { padding: 22px; }
  .pro-band .btn { width: 100%; }
  .modal__panel { margin: 0; width: 100%; height: 100%; max-height: none; border-radius: 0; animation: up .22s ease; }
  @keyframes up { from { transform: translateY(24px); opacity: 0; } }
  .pd__bar { padding: 6px 8px; }
  .pd__bar .crumbs { display: none; }
  .pd__bar-title { display: block; }
  .pd__info h2 { font-size: 1.2rem; }
  .vrow { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name price" "meta ctrl"; padding: 10px; gap: 4px 10px; }
  .vrow__info { display: contents; }
  .vrow__name { grid-area: name; }
  .vrow__meta { grid-area: meta; align-self: center; }
  .vrow__price { grid-area: price; }
  .vrow__ctrl { grid-area: ctrl; width: 124px; justify-self: end; }
  .pd__foot { flex-wrap: wrap; gap: 8px; }
  .pd__sum { flex-basis: 100%; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
  .pd__sum strong { display: inline; }
  .pd__foot-actions { flex-basis: 100%; }
  .pd__foot-actions .btn { flex: 1; height: 44px; }
  .cartbar {
    display: flex; position: fixed; left: 10px; right: 10px; bottom: max(10px, env(safe-area-inset-bottom)); z-index: 41; justify-content: space-between; align-items: center; gap: 8px;
    background: var(--blue); color: #fff; border-radius: 14px; padding: 12px 14px; box-shadow: var(--shadow-lg); font-size: .9rem; animation: rise .2s ease;
  }
  .cartbar__info { display: flex; flex-direction: column; line-height: 1.2; }
  .cartbar__info span { font-size: .8rem; color: #d5e2f5; }
  .cartbar__go { font-weight: 700; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; background: rgba(255, 255, 255, .16); padding: 8px 12px; border-radius: 10px; }
  .cartbar__go .ic { width: 16px; height: 16px; }
  body.has-cartbar .fab { bottom: 86px; }
  body.has-cartbar .toast { bottom: 86px; }
  body.has-cartbar .footer { padding-bottom: 100px; }
  .fab { width: 50px; height: 50px; right: 14px; }
  .toast { left: 10px; right: 10px; transform: none; max-width: none; min-width: 0; }
  .field__row { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  .header, .fab, .cartbar, .topbar { display: none; }
}
