/* =====================================================================================================
   Vitrina — storefront theme ("oscuro ciencia").
   Everything here applies only to the customer-facing store: every rule is scoped to
   body:not(.admin-mode), so the admin panel keeps its own look (app.css) untouched.
   ===================================================================================================== */

/* ---------- design tokens (shared with the admin panel, see admin.css) ---------- */
body{
  --bg:#050b18;
  --surface:#0c1628; --surface-2:#111f38; --surface-glass: rgba(9,18,36,0.72);
  --card: linear-gradient(180deg, rgba(18,33,60,0.86) 0%, rgba(10,19,37,0.9) 100%);
  --line: rgba(140,180,255,0.12); --line-strong: rgba(140,180,255,0.26);
  --text:#eaf1ff; --text-dim:#a6b7d4; --text-faint:#7589ab;
  --teal:#38bdf8; --teal-soft: rgba(56,189,248,0.14); --on-teal:#03111f;
  --amber:#fbbf24; --amber-soft: rgba(251,191,36,0.14); --on-amber:#1c1302;
  --red:#fb7185; --red-soft: rgba(251,113,133,0.14);
  --blue:#60a5fa; --blue-soft: rgba(96,165,250,0.14);
  --accent:#3b82f6; --accent-2:#22d3ee;
  --accent-grad: linear-gradient(135deg, #2563eb 0%, #3b82f6 45%, #22d3ee 100%);
  --text-grad: linear-gradient(100deg, #ffffff 10%, #bfe3ff 45%, #60a5fa 100%);
  --glow: 0 10px 34px -10px rgba(37,99,235,0.75);
  --shadow: 0 20px 50px -24px rgba(0,0,0,0.9);
  --shadow-hover: 0 30px 70px -26px rgba(0,0,0,0.95), 0 0 0 1px rgba(96,165,250,0.28);
  --shadow-win: 0 60px 140px -30px rgba(0,0,0,0.95), 0 0 0 1px rgba(140,180,255,0.14);
  --scrim: rgba(2,6,15,0.66);
  --radius-lg:22px; --radius-md:14px; --radius-sm:10px;
  --header-h: 68px;
  color-scheme: dark;
  background: var(--bg);
  color: var(--text);
  overflow-x: clip;
}
body:not(.admin-mode)::before{
  background:
    radial-gradient(900px 620px at 8% -8%, rgba(37,99,235,0.30), transparent 62%),
    radial-gradient(760px 520px at 102% 8%, rgba(34,211,238,0.13), transparent 60%),
    radial-gradient(900px 700px at 50% 118%, rgba(59,130,246,0.18), transparent 62%),
    linear-gradient(rgba(140,180,255,0.04) 1px, transparent 1px) 0 0 / 46px 46px,
    linear-gradient(90deg, rgba(140,180,255,0.04) 1px, transparent 1px) 0 0 / 46px 46px,
    var(--bg);
}
body:not(.admin-mode) ::selection{ background: rgba(59,130,246,0.45); color:#fff; }
body:not(.admin-mode) :focus-visible{ outline: 2px solid var(--accent-2); outline-offset: 2px; }

/* animated light orbs + molecule canvas behind everything */
.fx-bg{ display:none; }
body:not(.admin-mode) .fx-bg{ display:block; position:fixed; inset:0; z-index:-1; pointer-events:none; overflow:hidden; }
.fx-bg canvas{ position:absolute; inset:0; width:100%; height:100%; }
.fx-bg .orb{ position:absolute; border-radius:50%; filter: blur(60px); opacity:.5; will-change: transform; }
.fx-bg .orb-1{ width:42vmax; height:42vmax; left:-12vmax; top:-14vmax; background: radial-gradient(circle, rgba(37,99,235,0.55), transparent 65%); animation: orbA 22s ease-in-out infinite alternate; }
.fx-bg .orb-2{ width:34vmax; height:34vmax; right:-10vmax; top:18vh; background: radial-gradient(circle, rgba(34,211,238,0.32), transparent 65%); animation: orbB 26s ease-in-out infinite alternate; }
.fx-bg .orb-3{ width:38vmax; height:38vmax; left:28vw; bottom:-22vmax; background: radial-gradient(circle, rgba(99,102,241,0.30), transparent 65%); animation: orbA 30s ease-in-out infinite alternate-reverse; }
@keyframes orbA{ from{ transform: translate(0,0) scale(1); } to{ transform: translate(8vw, 6vh) scale(1.12); } }
@keyframes orbB{ from{ transform: translate(0,0) scale(1.05); } to{ transform: translate(-7vw, 10vh) scale(0.92); } }

/* ---------- header: fixed glass bar with logo, page tabs, search and cart ---------- */
body:not(.admin-mode) .brand-hero{ display:none; }
body:not(.admin-mode) .wrap{ padding-top: calc(var(--header-h) + 22px + env(safe-area-inset-top, 0px)); }
body:not(.admin-mode) .topbar{
  position: fixed; left:0; right:0; top:0; z-index: 250; margin:0;
  min-height: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  padding: env(safe-area-inset-top, 0px) max(18px, calc((100vw - 1180px) / 2 + 18px)) 0;
  display:flex; align-items:center; gap:18px; flex-wrap:nowrap;
  background: linear-gradient(180deg, rgba(5,11,24,0.78), rgba(5,11,24,0.55));
  -webkit-backdrop-filter: blur(18px) saturate(150%); backdrop-filter: blur(18px) saturate(150%);
  border-bottom: 1px solid transparent;
  transition: background .3s, border-color .3s, box-shadow .3s;
}
body.scrolled:not(.admin-mode) .topbar{ background: rgba(5,11,24,0.86); border-bottom-color: var(--line); box-shadow: 0 12px 40px -18px rgba(0,0,0,0.9); }
body:not(.admin-mode) .topbar .brand{
  display:flex; align-items:center; gap:10px; flex: 0 1 auto; min-width:0;
  background:none; border:0; padding:4px 6px 4px 0; color:inherit; text-align:left; border-radius:12px;
}
body:not(.admin-mode) .brand-mark{ width:auto; height:38px; background:none; border-radius:0; overflow:visible; filter: drop-shadow(0 0 14px rgba(59,130,246,0.45)); }
body:not(.admin-mode) .brand-mark img{ height:38px; width:auto; }
body:not(.admin-mode) .brand-text{ display:flex; flex-direction:column; min-width:0; }
body:not(.admin-mode) .brand-name{
  font-size:17px; letter-spacing:-0.01em;
  background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent;
}
body:not(.admin-mode) .brand-tag{ font-size:11.5px; color: var(--text-faint); }
body.admin-mode #storeTabs, body.admin-mode #searchBtn, body.admin-mode #hdrCartBtn{ display:none !important; }
.hdr-cart{ display:none; }
.kbd{ display:none; }

body:not(.admin-mode) .topbar .store-tabs{
  margin:0 auto; display:flex; gap:4px; padding:4px; border-radius:999px; width:auto;
  background: rgba(255,255,255,0.04); border:1px solid var(--line);
}
body:not(.admin-mode) .store-tabs button{ position:relative; padding:8px 18px; font-size:14px; color: var(--text-dim); transition: color .2s, background .25s; }
body:not(.admin-mode) .store-tabs button:hover{ color: var(--text); }
body:not(.admin-mode) .store-tabs button.on{ color:#fff; background: var(--accent-grad); box-shadow: var(--glow); }
body:not(.admin-mode) .topbar-actions{ margin-left:0; gap:8px; flex-wrap:nowrap; }
body:not(.admin-mode) .hdr-btn{
  background: rgba(255,255,255,0.04); border:1px solid var(--line); color: var(--text-dim);
  border-radius: 999px; padding: 9px 14px; height:40px;
}
body:not(.admin-mode) .hdr-btn:hover{ color: var(--text); border-color: var(--line-strong); background: rgba(255,255,255,0.07); }
body:not(.admin-mode) .hdr-search{ min-width: 180px; justify-content:flex-start; color: var(--text-faint); }
body:not(.admin-mode) .hdr-search .lbl{ flex:1; text-align:left; }
body:not(.admin-mode) .kbd{
  display:inline-flex; align-items:center; justify-content:center; min-width:22px; height:22px; padding:0 6px;
  border-radius:6px; border:1px solid var(--line-strong); background: rgba(255,255,255,0.05);
  font: 600 11.5px/1 var(--font-body); color: var(--text-dim);
}
body:not(.admin-mode) .hdr-cart{
  position:relative; display:inline-flex; align-items:center; justify-content:center; width:44px; height:44px; flex-shrink:0;
  border-radius:999px; border:0; color:#fff; background: var(--accent-grad); box-shadow: var(--glow);
  transition: transform .2s ease;
}
body:not(.admin-mode) .hdr-cart[hidden]{ display:none; }
body:not(.admin-mode) .hdr-cart:hover{ transform: translateY(-1px) scale(1.04); }
body:not(.admin-mode) .hdr-cart svg{ width:20px; height:20px; }
.hdr-cart-count{
  position:absolute; top:-4px; right:-4px; min-width:20px; height:20px; padding:0 5px; border-radius:99px;
  background:#fff; color:#0b1a33; font: 700 11.5px/20px var(--font-body); text-align:center; box-shadow: 0 0 0 2px var(--bg);
}
.hdr-cart.bump, .store-nav button.bump{ animation: fabBump .42s ease; }
body:not(.admin-mode) .segmented{ background: rgba(255,255,255,0.05); border-color: var(--line); }
body:not(.admin-mode) .segmented button[aria-pressed="true"]{ background: var(--accent-grad); color:#fff; box-shadow: var(--glow); }

/* ---------- common surfaces & controls ---------- */
body:not(.admin-mode) .btn-primary{ background: var(--accent-grad); color:#fff; box-shadow: var(--glow); }
body:not(.admin-mode) .btn-primary:hover{ filter: brightness(1.1); }
body:not(.admin-mode) .btn-teal{ background: var(--accent-grad); color:#fff; box-shadow: var(--glow); }
body:not(.admin-mode) .btn-ghost{ background: rgba(255,255,255,0.04); color: var(--text-dim); border:1px solid var(--line); }
body:not(.admin-mode) .btn-ghost:hover{ background: rgba(255,255,255,0.08); color: var(--text); }
body:not(.admin-mode) .btn{ border-radius: 12px; text-decoration:none; }
body:not(.admin-mode) .btn-block.btn-primary, body:not(.admin-mode) .win-foot .btn-primary{ border-radius: 14px; padding: 13px 18px; font-size:15px; }
body:not(.admin-mode) .link-btn{ color: var(--blue); text-decoration:none; }
body:not(.admin-mode) .link-btn:hover{ color: #93c5fd; text-decoration: underline; }
body:not(.admin-mode) .panel-card{
  background: var(--card); border:1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
body:not(.admin-mode) .field input, body:not(.admin-mode) .field textarea, body:not(.admin-mode) .field select,
body:not(.admin-mode) .coupon-row input, body:not(.admin-mode) .dc-inputs input, body:not(.admin-mode) .dc-inputs select{
  background: rgba(3,9,20,0.55); border:1px solid var(--line-strong); color: var(--text); border-radius: 12px;
}
body:not(.admin-mode) .field input:focus, body:not(.admin-mode) .field textarea:focus, body:not(.admin-mode) .field select:focus,
body:not(.admin-mode) .dc-inputs input:focus, body:not(.admin-mode) .dc-inputs select:focus, body:not(.admin-mode) .coupon-row input:focus{
  outline:none; border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(34,211,238,0.16);
}
body:not(.admin-mode) select option{ background:#0c1628; color: var(--text); }
body:not(.admin-mode) .muted{ color: var(--text-faint); }
body:not(.admin-mode) .banner{ background: var(--amber-soft); color: var(--amber); border-color: rgba(251,191,36,0.35); border-radius: 14px; }
body:not(.admin-mode) .eyebrow, .eyebrow{
  display:inline-flex; align-items:center; gap:8px; font: 600 11.5px/1 var(--font-body); letter-spacing: .14em; text-transform: uppercase; color: var(--accent-2);
}

/* ---------- page transition & scroll reveal ---------- */
.page-in{ animation: pageIn .45s cubic-bezier(.2,.8,.2,1) both; }
@keyframes pageIn{ from{ opacity:0; transform: translateY(14px); } to{ opacity:1; transform:none; } }
body:not(.admin-mode) .rv{ opacity:0; transform: translateY(26px); transition: opacity .8s cubic-bezier(.2,.8,.2,1), transform .8s cubic-bezier(.2,.8,.2,1); }
body:not(.admin-mode) .rv.in{ opacity:1; transform:none; }
body:not(.admin-mode) .rv .hscroll > *, body:not(.admin-mode) .rv .grid > *, body:not(.admin-mode) .rv .cat-tiles > *{ opacity:0; transform: translateY(18px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1); }
body:not(.admin-mode) .rv.in .hscroll > *, body:not(.admin-mode) .rv.in .grid > *, body:not(.admin-mode) .rv.in .cat-tiles > *{ opacity:1; transform:none; }
.rv.in .hscroll > :nth-child(2), .rv.in .grid > :nth-child(2), .rv.in .cat-tiles > :nth-child(2){ transition-delay: .06s; }
.rv.in .hscroll > :nth-child(3), .rv.in .grid > :nth-child(3), .rv.in .cat-tiles > :nth-child(3){ transition-delay: .12s; }
.rv.in .hscroll > :nth-child(4), .rv.in .grid > :nth-child(4), .rv.in .cat-tiles > :nth-child(4){ transition-delay: .18s; }
.rv.in .hscroll > :nth-child(n+5), .rv.in .grid > :nth-child(n+5), .rv.in .cat-tiles > :nth-child(n+5){ transition-delay: .24s; }

/* ---------- home: hero ---------- */
body:not(.admin-mode) .hero-card{
  display:grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items:center; gap: 10px;
  min-height: 440px; margin-bottom: 28px; padding: 0; border-radius: 30px; overflow:hidden; isolation:isolate;
  background:
    radial-gradient(700px 420px at 85% 30%, rgba(34,211,238,0.16), transparent 60%),
    radial-gradient(600px 460px at 0% 100%, rgba(37,99,235,0.28), transparent 60%),
    linear-gradient(160deg, rgba(16,32,64,0.9) 0%, rgba(7,14,30,0.92) 60%);
  border: 1px solid var(--line-strong);
  box-shadow: 0 40px 100px -40px rgba(0,0,0,0.95), inset 0 1px 0 rgba(255,255,255,0.06);
}
body:not(.admin-mode) .hero-card::after{
  content:""; position:absolute; inset:0; z-index:-1; pointer-events:none; opacity:.5;
  background: linear-gradient(rgba(140,180,255,0.06) 1px, transparent 1px) 0 0/34px 34px, linear-gradient(90deg, rgba(140,180,255,0.06) 1px, transparent 1px) 0 0/34px 34px;
  -webkit-mask-image: radial-gradient(ellipse at 70% 50%, #000 0%, transparent 70%); mask-image: radial-gradient(ellipse at 70% 50%, #000 0%, transparent 70%);
}
body:not(.admin-mode) .hero-inner{ padding: 52px 20px 44px 48px; max-width: 620px; position:relative; z-index:1; }
.hero-eyebrow{
  display:inline-flex; align-items:center; gap:9px; padding:7px 14px 7px 10px; border-radius:999px; margin-bottom:18px;
  background: rgba(56,189,248,0.1); border:1px solid rgba(56,189,248,0.28); color:#bfe8ff; font-size:12.5px; font-weight:600; letter-spacing:.02em;
}
.hero-eyebrow i{ width:8px; height:8px; border-radius:50%; background: var(--accent-2, #22d3ee); box-shadow: 0 0 0 0 rgba(34,211,238,0.7); animation: ping 2.2s ease-out infinite; }
@keyframes ping{ 0%{ box-shadow: 0 0 0 0 rgba(34,211,238,0.6); } 80%,100%{ box-shadow: 0 0 0 10px rgba(34,211,238,0); } }
body:not(.admin-mode) .hero-card h1{
  font-size: clamp(34px, 5.6vw, 62px); line-height:1.02; letter-spacing:-0.035em; font-weight:700; margin:0;
  background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent;
}
body:not(.admin-mode) .hero-card p{ font-size: 16.5px; line-height:1.6; color: var(--text-dim); margin-top:16px; max-width: 520px; }
body:not(.admin-mode) .hero-actions{ margin-top: 28px; gap:12px; }
body:not(.admin-mode) .hero-btn{
  text-decoration:none;
  background: var(--accent-grad); color:#fff; padding: 14px 24px; border-radius: 14px; font-weight:700; font-size:15px;
  box-shadow: var(--glow), inset 0 1px 0 rgba(255,255,255,0.25); position:relative; overflow:hidden;
}
body:not(.admin-mode) .hero-btn::after{
  content:""; position:absolute; top:0; bottom:0; width:40%; left:-60%; transform: skewX(-20deg);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent); transition: left .7s ease;
}
body:not(.admin-mode) .hero-btn:hover::after{ left:130%; }
body:not(.admin-mode) .hero-btn:hover{ transform: translateY(-2px); }
body:not(.admin-mode) .hero-btn-ghost{
  background: rgba(255,255,255,0.05); color: var(--text); border:1px solid var(--line-strong); padding: 14px 20px; border-radius:14px;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
body:not(.admin-mode) .hero-btn-ghost:hover{ background: rgba(255,255,255,0.1); }
body:not(.admin-mode) .hero-card .highlights{
  display:flex; flex-wrap:wrap; gap:0; margin: 34px 0 0; background:none; border:0; border-radius:0; overflow:visible;
}
body:not(.admin-mode) .hero-card .highlights > div{ text-align:left; padding: 0 26px 0 0; margin-right:26px; border-right:1px solid var(--line); }
body:not(.admin-mode) .hero-card .highlights > div:last-child{ border-right:0; margin-right:0; }
body:not(.admin-mode) .hero-card .highlights > div + div{ border-left:0; }
body:not(.admin-mode) .hero-card .highlights b{
  font-size: 26px; letter-spacing:-0.02em; background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent;
}
body:not(.admin-mode) .hero-card .highlights span{ font-size:12.5px; color: var(--text-faint); }
.hero-art{ position:relative; height:100%; min-height: 380px; }
.hero-art .helix{ position:absolute; inset: 0; width:100%; height:100%; }
.float-chip{
  position:absolute; z-index:2; display:flex; align-items:center; gap:10px; padding:8px 14px 8px 8px; max-width: 250px;
  border-radius:16px; border:1px solid var(--line-strong); color: var(--text); text-align:left;
  background: rgba(10,20,40,0.72); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 20px 50px -20px rgba(0,0,0,0.9); animation: floaty 6s ease-in-out infinite; transition: border-color .2s, transform .2s;
}
.float-chip:hover{ border-color: rgba(56,189,248,0.6); }
.float-chip.fc-0{ top: 16%; right: 8%; }
.float-chip.fc-1{ bottom: 14%; left: 4%; animation-delay: -3s; }
.fc-img{ width:44px; height:44px; border-radius:11px; overflow:hidden; flex-shrink:0; background:#e9eef6; }
.fc-img .pimg{ width:100%; height:100%; object-fit:cover; }
.fc-img .ph span{ font-size:18px; }
.fc-txt{ display:flex; flex-direction:column; min-width:0; }
.fc-txt b{ font-size:13px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.fc-txt small{ font-size:12px; color: var(--accent-2); font-weight:600; }
@keyframes floaty{ 0%,100%{ transform: translateY(0); } 50%{ transform: translateY(-10px); } }

/* ---------- home: sections ---------- */
body:not(.admin-mode) .home-sec{ margin: 44px 0; }
body:not(.admin-mode) .sec-head{ margin-bottom: 18px; align-items:flex-end; }
body:not(.admin-mode) .sec-head h2{ font-size: clamp(22px, 3vw, 30px); letter-spacing:-0.025em; margin-top:8px; }
body:not(.admin-mode) .sec-head p{ color: var(--text-faint); }
body:not(.admin-mode) .ann-row{ border-radius: 24px; }
body:not(.admin-mode) .ann-card{
  position:relative; overflow:hidden; min-height: 150px; padding: 28px 30px; border-radius: 24px; isolation:isolate;
  border:1px solid var(--line-strong); background: linear-gradient(120deg, rgba(20,40,80,0.95), rgba(8,16,34,0.95));
}
body:not(.admin-mode) .ann-card::before{
  content:""; position:absolute; z-index:-1; width: 340px; height:340px; right:-80px; top:-120px; border-radius:50%; filter: blur(20px); opacity:.75;
  background: radial-gradient(circle, var(--ann-c, rgba(59,130,246,0.6)), transparent 65%);
}
body:not(.admin-mode) .ann-card::after{
  content:""; position:absolute; inset:0; z-index:-1; pointer-events:none;
  background: radial-gradient(420px circle at var(--mx, 80%) var(--my, 0%), rgba(255,255,255,0.08), transparent 45%);
}
body:not(.admin-mode) .ann-0{ --ann-c: rgba(34,211,238,0.55); }
body:not(.admin-mode) .ann-1{ --ann-c: rgba(59,130,246,0.65); }
body:not(.admin-mode) .ann-2{ --ann-c: rgba(251,146,60,0.45); }
body:not(.admin-mode) .ann-3{ --ann-c: rgba(139,92,246,0.55); }
body:not(.admin-mode) .ann-card h3{ font-size: 22px; letter-spacing:-0.02em; }
body:not(.admin-mode) .ann-card p{ color: var(--text-dim); max-width: 560px; }
body:not(.admin-mode) .ann-btn{ background: rgba(255,255,255,0.08); border-color: var(--line-strong); border-radius: 12px; padding: 9px 16px; }
body:not(.admin-mode) .ann-btn:hover{ background: rgba(255,255,255,0.14); }
body:not(.admin-mode) .ann-dots i{ background: rgba(255,255,255,0.18); }
body:not(.admin-mode) .ann-dots i.on{ background: var(--accent-grad); width:22px; }

/* ---------- product cards (home rail, grid) ---------- */
body:not(.admin-mode) .pcard, body:not(.admin-mode) .hcard{
  position:relative; isolation:isolate; background: var(--card); border:1px solid var(--line); border-radius: 22px;
  box-shadow: var(--shadow); overflow:hidden; color: var(--text);
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s, border-color .35s;
}
body:not(.admin-mode) .pcard::before, body:not(.admin-mode) .hcard::before, body:not(.admin-mode) .cat-tile::before{
  content:""; position:absolute; inset:0; z-index:2; pointer-events:none; opacity:0; transition: opacity .35s;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 0%), rgba(96,165,250,0.16), transparent 50%);
}
body:not(.admin-mode) .pcard:hover, body:not(.admin-mode) .hcard:hover{ transform: translateY(-6px); box-shadow: var(--shadow-hover); border-color: rgba(96,165,250,0.35); }
body:not(.admin-mode) .pcard:hover::before, body:not(.admin-mode) .hcard:hover::before, body:not(.admin-mode) .cat-tile:hover::before{ opacity:1; }
body:not(.admin-mode) .pcard.out, body:not(.admin-mode) .hcard.out{ opacity:.6; }
body:not(.admin-mode) .pcard-media, body:not(.admin-mode) .hcard-media{
  margin: 8px 8px 0; width: calc(100% - 16px); border-radius: 16px; overflow:hidden; aspect-ratio: 4/5; background:#e8edf5;
}
body:not(.admin-mode) .hcard-media{ aspect-ratio: 4/4.2; }
body:not(.admin-mode) .pcard-media::after, body:not(.admin-mode) .hcard-media::after{
  content:""; position:absolute; inset:0; pointer-events:none; border-radius:inherit;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08), inset 0 -60px 60px -40px rgba(5,11,24,0.35);
}
body:not(.admin-mode) .pcard:hover .pcard-media .pimg, body:not(.admin-mode) .hcard:hover .hcard-media .pimg{ transform: scale(1.06); }
body:not(.admin-mode) .hcard-media .pimg{ transition: transform .5s ease; }
body:not(.admin-mode) .ph{
  background:
    radial-gradient(80% 70% at 30% 20%, hsl(var(--h) 85% 62% / .5), transparent 60%),
    radial-gradient(90% 80% at 90% 100%, hsl(calc(var(--h) + 60) 85% 55% / .35), transparent 60%),
    linear-gradient(160deg, #13264a, #0a1428);
}
body:not(.admin-mode) .ph span{ color: rgba(255,255,255,0.9); text-shadow: 0 0 30px hsl(var(--h) 90% 60% / .8); }
body:not(.admin-mode) .media-badge{ top:10px; left:10px; border-radius: 999px; font-size:11px; padding:5px 10px; letter-spacing:.01em; }
body:not(.admin-mode) .media-badge.opts{ background: rgba(5,11,24,0.72); color:#dbeafe; border:1px solid rgba(147,197,253,0.35); }
body:not(.admin-mode) .media-badge.low{ background: rgba(251,191,36,0.92); color:#1c1302; }
body:not(.admin-mode) .media-badge.out{ background: rgba(5,11,24,0.82); color:#fff; }
body:not(.admin-mode) .pcard-body{ padding: 12px 14px 14px; }
body:not(.admin-mode) .pcard-cat{ font-size:11px; letter-spacing:.1em; text-transform:uppercase; color: var(--accent-2); font-weight:600; }
body:not(.admin-mode) .pcard-name, body:not(.admin-mode) .hcard-name{ font-size:15.5px; color: var(--text); }
body:not(.admin-mode) .pcard-opts, body:not(.admin-mode) .hcard-opts{ color: var(--text-faint); }
body:not(.admin-mode) .price{ color: var(--text); font-size: 18px; letter-spacing:-0.01em; }
body:not(.admin-mode) .price small{ color: var(--text-faint); }
body:not(.admin-mode) .add-btn{
  width:42px; height:42px; border-radius: 13px; background: var(--accent-grad); color:#fff; box-shadow: var(--glow);
  transition: transform .2s ease, box-shadow .2s;
}
body:not(.admin-mode) .add-btn:hover{ transform: scale(1.08) rotate(90deg); }
body:not(.admin-mode) .add-btn svg{ transition: transform .3s; }
body:not(.admin-mode) .add-btn:disabled{ background: rgba(255,255,255,0.06); color: var(--text-faint); box-shadow:none; }
body:not(.admin-mode) .add-btn:disabled:hover{ transform:none; }
body:not(.admin-mode) .add-btn .in-cart{ background:#fff; color:#0b1a33; border-color: #0c1628; }
body:not(.admin-mode) .stock-dot.ok{ color: #34d399; }
body:not(.admin-mode) .hscroll{ grid-auto-columns: minmax(220px, 260px); gap:16px; padding: 4px 4px 16px; margin: 0 -4px; }
body:not(.admin-mode) .hcard-body{ padding: 12px 14px 14px; }
body:not(.admin-mode) .grid{ gap: 18px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
body:not(.admin-mode) .skeleton{ background: var(--card); border-color: var(--line); border-radius: 22px; }
body:not(.admin-mode) .skeleton::after{ background: linear-gradient(100deg, transparent 30%, rgba(96,165,250,0.08) 50%, transparent 70%); }
body:not(.admin-mode) .empty{ border-color: var(--line-strong); color: var(--text-dim); border-radius: 22px; background: rgba(255,255,255,0.02); }

/* categories */
body:not(.admin-mode) .cat-tiles{ grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap:12px; }
body:not(.admin-mode) .cat-tile{
  position:relative; isolation:isolate; overflow:hidden; padding: 12px; gap: 2px 14px; grid-template-columns: 56px 1fr;
  background: var(--card); border:1px solid var(--line); border-radius: 18px; transition: transform .3s, border-color .3s;
}
body:not(.admin-mode) .cat-tile:hover{ transform: translateY(-3px); border-color: rgba(96,165,250,0.35); }
body:not(.admin-mode) .cat-tile-media{ width:56px; height:56px; border-radius:14px; background:#e8edf5; }
body:not(.admin-mode) .cat-tile-name{ font-family: var(--font-display); font-size:15px; }
body:not(.admin-mode) .cat-tile-n{ color: var(--text-faint); }

/* WhatsApp call to action */
.home-cta{
  display:flex; align-items:center; justify-content:space-between; gap:20px; flex-wrap:wrap; margin: 50px 0 20px; padding: 30px 34px;
  border-radius: 26px; border:1px solid var(--line-strong); position:relative; overflow:hidden; isolation:isolate;
  background: linear-gradient(120deg, rgba(37,99,235,0.35), rgba(8,16,34,0.9) 55%, rgba(34,211,238,0.18));
}
.home-cta h2{ margin:0; font-family: var(--font-display); font-size: clamp(20px, 2.6vw, 26px); letter-spacing:-0.02em; }
.home-cta p{ margin:6px 0 0; color: var(--text-dim); }

/* ---------- shop page: search, sort, category chips ---------- */
body:not(.admin-mode) .store-controls{
  position: sticky; top: calc(var(--header-h) + env(safe-area-inset-top, 0px) + 8px); z-index: 20; margin-bottom: 22px; padding: 12px;
  border-radius: 20px; background: rgba(8,16,32,0.75); border:1px solid var(--line);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
}
body:not(.admin-mode) .search-field input, body:not(.admin-mode) .select{
  background: rgba(3,9,20,0.55); border:1px solid var(--line-strong); color: var(--text); border-radius: 12px; height:44px;
}
body:not(.admin-mode) .search-field input:focus{ border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(34,211,238,0.16); }
body:not(.admin-mode) .chip{
  background: rgba(255,255,255,0.04); border:1px solid var(--line); color: var(--text-dim); padding: 8px 15px; transition: all .2s;
}
body:not(.admin-mode) .chip:hover{ color: var(--text); border-color: var(--line-strong); background: rgba(255,255,255,0.08); }
body:not(.admin-mode) .chip[aria-pressed="true"]{ background: var(--accent-grad); color:#fff; border-color: transparent; box-shadow: var(--glow); }
body:not(.admin-mode) .chip .n{ opacity:.65; }

/* ---------- floating windows ---------- */
body:not(.admin-mode) .overlay{ background: var(--scrim); -webkit-backdrop-filter: blur(10px) saturate(120%); backdrop-filter: blur(10px) saturate(120%); }
body:not(.admin-mode) .win{
  background: linear-gradient(180deg, rgba(17,31,58,0.97), rgba(9,17,34,0.98));
  border:1px solid var(--line-strong); border-radius: 26px; box-shadow: var(--shadow-win);
  animation: winPop .42s cubic-bezier(.2,.9,.25,1.1) both;
}
@keyframes winPop{ from{ opacity:0; transform: translateY(18px) scale(.96); filter: blur(4px); } to{ opacity:1; transform:none; filter:none; } }
body:not(.admin-mode) .win-bar{ border-bottom-color: var(--line); padding: 16px 18px 14px 22px; }
body:not(.admin-mode) .win-title{ font-size:15px; color: var(--text-dim); font-weight:600; }
body:not(.admin-mode) .win-foot{ background: rgba(8,16,32,0.9); border-top-color: var(--line); }
body:not(.admin-mode) .icon-btn{ color: var(--text-dim); border-radius: 12px; width:36px; height:36px; background: rgba(255,255,255,0.04); }
body:not(.admin-mode) .icon-btn:hover{ color: var(--text); background: rgba(255,255,255,0.1); }
body:not(.admin-mode) .grabber{ background: rgba(255,255,255,0.22); }

/* product window: large, two columns on desktop */
body:not(.admin-mode) #win-detail .win{ max-width: 1020px; }
.pd{ display:grid; gap:18px; }
.pd-media{ position:relative; }
body:not(.admin-mode) .pd .detail-media{
  position:relative; border-radius: 22px; aspect-ratio: 1/1; background:#e8edf5;
  box-shadow: 0 30px 60px -30px rgba(0,0,0,0.9), 0 0 0 1px rgba(255,255,255,0.08);
}
body:not(.admin-mode) .pd .detail-media::after{ content:""; position:absolute; inset:0; border-radius:inherit; pointer-events:none; box-shadow: inset 0 0 0 1px rgba(255,255,255,0.1); }
.pd-mg-strip{ display:flex; gap:6px; flex-wrap:wrap; margin-top:12px; }
.pd-mg-strip span{ font-size:12px; font-weight:600; padding:5px 10px; border-radius:99px; border:1px solid var(--line); color: var(--text-faint); }
.pd-mg-strip span.on{ color:#fff; border-color: transparent; background: var(--accent-grad); }
.pd-info{ display:flex; flex-direction:column; gap:16px; min-width:0; }
body:not(.admin-mode) .detail-name{ font-size: clamp(24px, 3vw, 34px); letter-spacing:-0.03em; line-height:1.1; margin-top:8px; }
.pd-price{ display:flex; align-items:baseline; gap:8px; margin-top:10px; flex-wrap:wrap; }
body:not(.admin-mode) .pd-price .price{
  font-size: 32px; font-weight:700; letter-spacing:-0.02em; background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent;
}
.pd-unit{ font-size:14px; color: var(--text-faint); }
.pd-variant{ font-size:12.5px; font-weight:600; color: var(--accent-2, #22d3ee); padding:4px 10px; border-radius:99px; background: rgba(34,211,238,0.1); border:1px solid rgba(34,211,238,0.25); }
body:not(.admin-mode) .variant-chips{ gap:8px; }
body:not(.admin-mode) .variant-chips .chip{ padding: 10px 16px; border-radius: 14px; font-weight:600; font-size:14px; }
body:not(.admin-mode) .variant-chips .chip .n{ display:block; font-size:11.5px; font-weight:500; margin:2px 0 0; opacity:.8; }
body:not(.admin-mode) .stock-line.ok{ color:#34d399; } body:not(.admin-mode) .dot.ok{ background:#34d399; box-shadow: 0 0 10px #34d399; }
.pd-jump{
  position: sticky; top: -18px; z-index: 5; display:flex; gap:6px; overflow-x:auto; scrollbar-width:none; margin: 0 -6px; padding: 10px 6px;
  background: rgba(14,27,51,0.94); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-radius: 0 0 16px 16px;
}
.pd-jump::-webkit-scrollbar{ display:none; }
.pd-jump button{
  flex-shrink:0; border:1px solid var(--line); background: rgba(255,255,255,0.04); color: var(--text-dim);
  padding: 7px 14px; border-radius: 999px; font-size:13px; font-weight:600; transition: all .2s;
}
.pd-jump button:hover{ color: var(--text); }
.pd-jump button.on{ color:#fff; background: var(--accent-grad); border-color: transparent; box-shadow: var(--glow); }
body:not(.admin-mode) .detail-info{ gap:12px; }
body:not(.admin-mode) .detail-info section{
  padding: 16px 18px; border-radius: 18px; background: rgba(255,255,255,0.03); border:1px solid var(--line); scroll-margin-top: 60px;
}
body:not(.admin-mode) .detail-info section + section{ border-top:1px solid var(--line); padding-top:16px; }
body:not(.admin-mode) .detail-info h3{ font-size:13px; letter-spacing:.12em; text-transform:uppercase; color: var(--accent-2); margin-bottom:6px; }
body:not(.admin-mode) .detail-desc{ color: var(--text-dim); font-size:15px; line-height:1.65; }
body:not(.admin-mode) .dose-calc{
  scroll-margin-top: 60px; padding: 18px; border-radius: 20px; gap:14px;
  background: radial-gradient(420px 220px at 100% 0%, rgba(34,211,238,0.14), transparent 60%), rgba(37,99,235,0.08);
  border:1px solid rgba(96,165,250,0.3);
}
body:not(.admin-mode) .dose-calc h3{ font-size:16px; }
body:not(.admin-mode) .dc-inputs label{ color: var(--text-dim); }
body:not(.admin-mode) .dc-stat{ background: rgba(3,9,20,0.5); border-color: var(--line); border-radius: 14px; padding: 12px 14px; }
body:not(.admin-mode) .dc-stat b{ font-size: 28px; background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent; }
body:not(.admin-mode) .dc-note{ color: var(--text-faint); }
body:not(.admin-mode) .related-item{ background: rgba(255,255,255,0.03); border-color: var(--line); border-radius: 16px; padding:8px; transition: transform .2s, border-color .2s; }
body:not(.admin-mode) .related-item:hover{ transform: translateY(-3px); border-color: rgba(96,165,250,0.35); }
body:not(.admin-mode) .related-item .pimg{ background:#e8edf5; border-radius: 11px; }
body:not(.admin-mode) .stepper{ background: rgba(3,9,20,0.55); border-color: var(--line-strong); border-radius: 14px; }
body:not(.admin-mode) .stepper button:hover{ background: rgba(255,255,255,0.08); }
body:not(.admin-mode) #detailFoot{ align-items:center; }
@media (min-width: 860px){
  .pd{ grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); gap: 30px; align-items:start; }
  .pd-media{ position: sticky; top: 0; }
  body:not(.admin-mode) #detailBody{ padding: 24px 28px 28px; }
  .pd-jump{ top: -24px; }
  body:not(.admin-mode) #win-detail .win-foot{ padding-left: 28px; padding-right: 28px; }
  body:not(.admin-mode) #detailFoot .btn-primary{ flex: 0 1 380px; margin-left:auto; }
  body:not(.admin-mode) #detailFoot .stepper{ margin-left: calc(47.5% + 15px - 28px); }
}

/* syringe (dose calculator) */
.syringe{ grid-column: 1 / -1; display:flex; align-items:center; height:46px; margin: 4px 0 6px; --fill:0%; }
.syr-needle{ width:34px; height:2px; background: linear-gradient(90deg, rgba(200,215,240,0.2), #cbd5e1); border-radius:2px; }
.syr-barrel{
  position:relative; flex:1; height:30px; border-radius:6px; overflow:hidden;
  background: linear-gradient(180deg, rgba(255,255,255,0.14), rgba(255,255,255,0.04)); border:1.5px solid rgba(203,213,225,0.55);
}
.syr-liquid{
  position:absolute; left:0; top:0; bottom:0; width: var(--fill);
  background: linear-gradient(180deg, rgba(56,189,248,0.95), rgba(37,99,235,0.95)); box-shadow: 0 0 18px rgba(56,189,248,0.7);
  transition: width .6s cubic-bezier(.2,.8,.2,1);
}
.syr-plunger{ position:absolute; top:-2px; bottom:-2px; left: var(--fill); width:6px; margin-left:-3px; background:#e2e8f0; border-radius:2px; transition: left .6s cubic-bezier(.2,.8,.2,1); }
.syr-ticks span{ position:absolute; bottom:0; width:1px; height:9px; background: rgba(255,255,255,0.55); }
.syr-ticks span[data-n]{ height:14px; }
.syr-ticks span[data-n]::after{ content: attr(data-n); position:absolute; top:-15px; left:-8px; width:16px; text-align:center; font: 600 9px/1 var(--font-body); color: rgba(255,255,255,0.7); }
.syr-ticks span[data-n="100"]::after{ left:-22px; }
.syr-rod{ width: 22px; height:6px; background: linear-gradient(90deg, #94a3b8, #cbd5e1); }
.syr-cap{ width:6px; height:30px; border-radius:3px; background:#cbd5e1; }
.syringe.over .syr-liquid{ background: linear-gradient(180deg, #fb7185, #e11d48); box-shadow: 0 0 18px rgba(251,113,133,0.7); }
.syringe .syr-ticks{ position:absolute; inset:0; }

/* cart: a drawer from the right on desktop, bottom sheet on phones */
@media (min-width: 641px){
  body:not(.admin-mode) #win-cart{ justify-content:flex-end; align-items:stretch; padding: 12px; }
  body:not(.admin-mode) #win-cart .win{ max-width: 460px; height: 100%; animation: drawerIn .45s cubic-bezier(.2,.9,.25,1) both; }
  body:not(.admin-mode) #win-cart .win-body{ flex:1; }
}
@keyframes drawerIn{ from{ transform: translateX(105%); } to{ transform:none; } }
.ck-steps{ display:none; }
body:not(.admin-mode) .ck-steps{ display:flex; list-style:none; margin:0 0 4px; padding:0; gap:6px; counter-reset: s; }
body:not(.admin-mode) .ck-steps[hidden]{ display:none; }
.ck-steps li{ flex:1; display:flex; align-items:center; gap:7px; white-space:nowrap; font-size:12.5px; font-weight:600; color: var(--text-faint); }
.ck-steps li i{
  font-style:normal; width:24px; height:24px; border-radius:50%; display:inline-flex; align-items:center; justify-content:center; flex-shrink:0;
  border:1px solid var(--line-strong); font-size:12px;
}
.ck-steps li + li::before{ content:""; flex: 0 0 14px; height:1px; background: var(--line-strong); margin-right:2px; }
.ck-steps li.now{ color: var(--text); }
.ck-steps li.now i{ background: var(--accent-grad); border-color:transparent; color:#fff; box-shadow: var(--glow); }
.ck-steps li.done{ color: var(--text-dim); }
.ck-steps li.done i{ background: rgba(52,211,153,0.15); border-color: rgba(52,211,153,0.5); color:#34d399; }
body:not(.admin-mode) .cart-item{ padding: 10px; border-radius: 16px; background: rgba(255,255,255,0.03); border:1px solid var(--line); }
body:not(.admin-mode) .cart-thumb{ width:58px; height:58px; border-radius: 12px; background:#e8edf5; }
body:not(.admin-mode) .cart-line-total{ font-family: var(--font-display); }
body:not(.admin-mode) .totals{ background: rgba(3,9,20,0.5); border:1px solid var(--line); border-radius: 16px; }
body:not(.admin-mode) .totals-row.grand{ font-size: 19px; border-top-color: var(--line); }
body:not(.admin-mode) .totals-row.discount{ color:#34d399; }
body:not(.admin-mode) .free-bar{ background: rgba(56,189,248,0.08); border:1px solid rgba(56,189,248,0.22); border-radius: 14px; }
body:not(.admin-mode) .free-track{ background: rgba(255,255,255,0.08); }
body:not(.admin-mode) .free-track i{ background: var(--accent-grad); box-shadow: 0 0 12px rgba(56,189,248,0.7); }
body:not(.admin-mode) .choice span{ background: rgba(255,255,255,0.03); border-color: var(--line-strong); border-radius: 14px; padding: 13px 14px; }
body:not(.admin-mode) .choice input:checked + span{ border-color: var(--accent-2); background: rgba(34,211,238,0.1); box-shadow: 0 0 0 3px rgba(34,211,238,0.12); }
body:not(.admin-mode) .coupon-applied{ background: rgba(52,211,153,0.1); color:#34d399; border-radius: 12px; }
body:not(.admin-mode) .pay-box{ background: rgba(251,191,36,0.08); border-color: rgba(251,191,36,0.3); border-radius: 16px; }
body:not(.admin-mode) .order-number{ background: rgba(255,255,255,0.05); border-color: var(--line-strong); font-size:17px; padding: 8px 18px; }
body:not(.admin-mode) .check-anim circle{ fill: rgba(52,211,153,0.12); stroke:#34d399; }
body:not(.admin-mode) .check-anim path{ stroke:#34d399; }
body:not(.admin-mode) .ocard{ background: rgba(255,255,255,0.03); border-color: var(--line); border-radius: 18px; }
body:not(.admin-mode) .tag{ background: rgba(255,255,255,0.05); border-color: var(--line); }
body:not(.admin-mode) .tag.completada{ background: rgba(52,211,153,0.14); color:#34d399; }
body:not(.admin-mode) .pstep.done .pdot, body:not(.admin-mode) .pline.done{ background: var(--accent-2); border-color: var(--accent-2); }
body:not(.admin-mode) .pstep.now .pdot{ border-color: var(--accent-2); box-shadow: 0 0 0 4px rgba(34,211,238,0.18); }
body:not(.admin-mode) .onote{ background: rgba(255,255,255,0.04); }

/* quick search palette */
body:not(.admin-mode) #win-search{ align-items:flex-start; padding-top: max(10vh, 70px); }
.win-search{ max-width: 620px !important; }
.qs-top{ display:flex; align-items:center; gap:12px; padding: 14px 14px 14px 20px; border-bottom:1px solid var(--line); }
.qs-top > svg{ width:20px; height:20px; color: var(--accent-2, #22d3ee); flex-shrink:0; }
.qs-top input{ flex:1; min-width:0; border:0; background:none; font-size:18px; color: var(--text); outline:none; padding:6px 0; }
.qs-top input:focus, .qs-top input:focus-visible{ outline:none !important; box-shadow:none !important; }
.qs-top input::placeholder{ color: var(--text-faint); }
.qs-top input::-webkit-search-cancel-button{ display:none; }
.qs-results{ max-height: min(60vh, 520px); padding: 10px !important; gap:4px !important; }
.qs-head{ font-size:11px; letter-spacing:.14em; text-transform:uppercase; color: var(--text-faint); font-weight:600; padding: 10px 10px 6px; }
.qs-item{
  display:flex; align-items:center; gap:14px; width:100%; text-align:left; padding: 9px 10px; border-radius: 14px;
  border:1px solid transparent; background:none; color: var(--text); transition: background .15s, border-color .15s;
}
.qs-item:hover, .qs-item.on{ background: rgba(59,130,246,0.14); border-color: rgba(96,165,250,0.35); }
.qs-item.out{ opacity:.55; }
.qs-thumb{ width:46px; height:46px; border-radius: 11px; overflow:hidden; flex-shrink:0; background:#e8edf5; }
.qs-thumb .pimg{ width:100%; height:100%; object-fit:cover; }
.qs-thumb .ph span{ font-size:18px; }
.qs-main{ flex:1; min-width:0; display:flex; flex-direction:column; gap:2px; }
.qs-main b{ font-size:14.5px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.qs-main small{ font-size:12px; color: var(--text-faint); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.qs-price{ font-family: var(--font-display); font-weight:600; font-size:14.5px; white-space:nowrap; }
.qs-price small{ font-weight:500; color: var(--text-faint); font-size:.8em; }
.qs-empty{ padding: 28px 14px; text-align:center; color: var(--text-dim); }
.qs-cats{ display:flex; gap:8px; flex-wrap:wrap; padding: 2px 10px 10px; }
.qs-foot{ display:flex; gap:18px; padding: 10px 18px; border-top:1px solid var(--line); font-size:12px; color: var(--text-faint); }
.qs-foot span{ display:inline-flex; gap:4px; align-items:center; }
@media (max-width: 640px){ .qs-foot{ display:none; } body:not(.admin-mode) #win-search{ padding-top: 0; } }

/* login gate: the brand art fills the screen behind a glass card */
.login-brand, .login-perks{ display:none; }
body:not(.admin-mode) .login-brand{ display:flex; justify-content:center; margin: -4px 0 4px; }
body:not(.admin-mode) .login-brand img{ width: 190px; height:auto; filter: drop-shadow(0 10px 30px rgba(37,99,235,0.45)); animation: floaty 7s ease-in-out infinite; }
body:not(.admin-mode) #loginIntro{ text-align:center; font-size:14px; color: var(--text-dim); }
body:not(.admin-mode) #authToggle{ align-self:center; }
body:not(.admin-mode) .login-perks{ display:flex; justify-content:center; gap:14px; flex-wrap:wrap; list-style:none; margin: 2px 0 0; padding: 14px 0 0; border-top:1px solid var(--line); }
.login-perks li{ display:flex; align-items:center; gap:6px; font-size:12px; color: var(--text-faint); }
.login-perks svg{ width:15px; height:15px; color: var(--accent-2, #22d3ee); }
body.auth-gate:not(.admin-mode) #win-login{
  background:
    radial-gradient(800px 560px at 15% 10%, rgba(37,99,235,0.35), transparent 60%),
    radial-gradient(700px 520px at 90% 90%, rgba(34,211,238,0.18), transparent 60%),
    rgba(5,11,24,0.55);
}
body.auth-gate:not(.admin-mode) #win-login .win{ max-width: 430px; background: rgba(12,24,46,0.82); -webkit-backdrop-filter: blur(22px) saturate(140%); backdrop-filter: blur(22px) saturate(140%); }
body.auth-gate:not(.admin-mode) #win-login .win-bar{ display:none; }
body.auth-gate:not(.admin-mode) #win-login .win-body{ padding: 26px 26px 24px; }
body.auth-gate:not(.admin-mode) .topbar{ background: transparent; border-color: transparent; box-shadow:none; }

/* account window */
body:not(.admin-mode) #accountBody strong{ font-family: var(--font-display); font-size: 18px; }

/* ---------- footer ---------- */
.store-foot{ display:none; }
body:not(.admin-mode) .store-foot{
  display:block; margin: 70px calc(50% - 50vw) 0; padding: 40px max(18px, calc((100vw - 1180px) / 2 + 18px)) 26px;
  border-top: 1px solid var(--line); background: linear-gradient(180deg, rgba(8,16,32,0.4), rgba(5,11,24,0.9));
}
body.auth-gate .store-foot{ display:none; }
.foot-grid{ display:grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 30px; }
.foot-brand img{ width: 150px; height:auto; }
.foot-brand p{ color: var(--text-faint); font-size: 13.5px; margin: 10px 0 0; }
.foot-col{ display:flex; flex-direction:column; gap:10px; align-items:flex-start; }
.foot-col b{ font-family: var(--font-display); font-size: 13px; letter-spacing:.12em; text-transform: uppercase; color: var(--text); margin-bottom: 4px; }
.foot-col button{ background:none; border:0; padding:0; color: var(--text-dim); font-size:14px; text-align:left; transition: color .15s; }
.foot-col button:hover{ color: var(--text); }
.foot-wa{ display:inline-flex; align-items:center; gap:8px; padding: 10px 14px; border-radius: 12px; color:#fff; text-decoration:none; font-weight:600; font-size:14px; background: linear-gradient(135deg, #16a34a, #22c55e); box-shadow: 0 10px 30px -12px rgba(34,197,94,0.7); }
.foot-wa svg{ width:18px; height:18px; }
.foot-bottom{ display:flex; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-top: 34px; padding-top: 18px; border-top:1px solid var(--line); font-size:12.5px; color: var(--text-faint); }

/* ---------- toasts & floating cart ---------- */
body:not(.admin-mode) .toast{
  background: rgba(12,24,46,0.92); color: var(--text); border:1px solid var(--line-strong);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 20px 50px -18px rgba(0,0,0,0.9);
}
body:not(.admin-mode) .toast.warn{ background: rgba(76,18,34,0.94); color:#ffe4e8; border-color: rgba(251,113,133,0.45); }
body:not(.admin-mode) .toast-btn{ background: var(--accent-grad); color:#fff; }
body:not(.admin-mode) .toasts{ top: calc(var(--header-h) + 10px + env(safe-area-inset-top, 0px)); }
body:not(.admin-mode) .cart-fab{
  background: rgba(12,24,46,0.88); color: var(--text); border:1px solid rgba(96,165,250,0.4);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 20px 50px -16px rgba(0,0,0,0.9), 0 0 30px -8px rgba(37,99,235,0.6);
}
body:not(.admin-mode) .cart-fab .badge{ background: var(--accent-grad); color:#fff; }
body:not(.admin-mode) .fly-dot{ background: #38bdf8; box-shadow: 0 0 0 4px rgba(56,189,248,0.25), 0 0 20px #38bdf8; }

/* ---------- calculator page ---------- */
body:not(.admin-mode) .calc-page{ max-width: 720px; margin: 0 auto; padding: 26px; }
body:not(.admin-mode) .calc-page .panel-title{ font-size: 26px; letter-spacing:-0.02em; background: var(--text-grad); -webkit-background-clip:text; background-clip:text; color:transparent; }
body:not(.admin-mode) #scResult{ gap:10px; }

/* ---------- desktop ⇄ phone ---------- */
@media (max-width: 1020px){
  body:not(.admin-mode) .hdr-search{ min-width:0; }
  body:not(.admin-mode) .hdr-search .lbl, body:not(.admin-mode) .hdr-search .kbd{ display:none; }
}
@media (max-width: 900px){
  body:not(.admin-mode) .hero-card{ grid-template-columns: 1fr; min-height:0; }
  body:not(.admin-mode) .hero-inner{ padding: 34px 24px 8px; }
  .hero-art{ min-height: 280px; margin-top: -10px; }
  .foot-grid{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px){
  body:not(.admin-mode){ --header-h: 60px; }
  body:not(.admin-mode) .topbar{ gap:10px; padding-left: 14px; padding-right: 14px; }
  body:not(.admin-mode) .topbar .store-tabs{ display:none; }
  body:not(.admin-mode) .topbar-actions{ margin-left:auto; }
  body:not(.admin-mode) .brand-mark, body:not(.admin-mode) .brand-mark img{ height:32px; }
  body:not(.admin-mode) .brand-tag{ display:none; }
  body:not(.admin-mode) .hdr-cart{ display:none !important; }
  body:not(.admin-mode) .hdr-btn{ width:40px; padding:0; justify-content:center; }
  /* on phones the bottom bar already has Cuenta; order lookup and "Mis órdenes" live in the account window and footer */
  body:not(.admin-mode) #lookupBtn, body:not(.admin-mode) #myOrdersBtn, body:not(.admin-mode) #accountBtn, body:not(.admin-mode) #loginBtn{ display:none !important; }
  .pd-mg-strip{ display:none; }
  body:not(.admin-mode) .hero-card .highlights{ display:grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap:10px; }
  body:not(.admin-mode) .hero-card .highlights > div{ padding:0; margin:0; border-right:0; }
  body:not(.admin-mode) .hero-card .highlights span{ font-size:11.5px; line-height:1.3; display:block; }
  .ck-steps li{ font-size:12px; gap:5px; }
  .ck-steps li + li::before{ flex-basis: 8px; }
  body:not(.admin-mode) .wrap{ padding-top: calc(var(--header-h) + 14px + env(safe-area-inset-top, 0px)); }
  /* bottom navigation: a floating glass pill */
  body:not(.admin-mode):not(.auth-gate) .store-nav{
    left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); padding: 4px;
    border-radius: 22px; border:1px solid var(--line-strong);
    background: rgba(9,18,36,0.82); -webkit-backdrop-filter: blur(20px) saturate(150%); backdrop-filter: blur(20px) saturate(150%);
    box-shadow: 0 20px 50px -14px rgba(0,0,0,0.9);
  }
  body:not(.admin-mode) .store-nav button{ min-height:54px; border-radius: 18px; color: var(--text-faint); transition: color .2s, background .2s; }
  body:not(.admin-mode) .store-nav button.on{ color:#fff; background: rgba(59,130,246,0.18); }
  body:not(.admin-mode) .store-nav button.on svg{ filter: drop-shadow(0 0 8px rgba(56,189,248,0.8)); color: #7dd3fc; }
  body:not(.admin-mode) .store-nav .nav-badge{ background: var(--accent-grad); }
  body:not(.admin-mode):not(.auth-gate) .wrap{ padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
  body:not(.admin-mode) .store-foot{ margin: 50px calc(50% - 50vw) 0; padding-left: 16px; padding-right: 16px; padding-bottom: calc(100px + env(safe-area-inset-bottom, 0px)); }
  body:not(.admin-mode) .hero-card{ border-radius: 24px; }
  body:not(.admin-mode) .hero-card h1{ font-size: clamp(32px, 9vw, 44px); }
  body:not(.admin-mode) .hero-card p{ font-size: 15px; }
  body:not(.admin-mode) .hero-card .highlights > div{ padding-right:16px; margin-right:16px; }
  body:not(.admin-mode) .hero-card .highlights b{ font-size: 22px; }
  .hero-art{ min-height: 240px; }
  .float-chip{ max-width: 200px; padding: 6px 10px 6px 6px; }
  .float-chip.fc-0{ top: 8%; right: 3%; } .float-chip.fc-1{ bottom: 8%; left: 3%; }
  .fc-img{ width:36px; height:36px; }
  body:not(.admin-mode) .home-sec{ margin: 34px 0; }
  body:not(.admin-mode) .grid{ grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
  body:not(.admin-mode) .pcard, body:not(.admin-mode) .hcard{ border-radius: 18px; }
  body:not(.admin-mode) .pcard-media, body:not(.admin-mode) .hcard-media{ margin: 6px 6px 0; width: calc(100% - 12px); border-radius: 13px; }
  body:not(.admin-mode) .pcard-body{ padding: 10px 11px 12px; }
  body:not(.admin-mode) .pcard-name{ font-size:14px; }
  body:not(.admin-mode) .price{ font-size:16px; }
  body:not(.admin-mode) .add-btn{ width:38px; height:38px; border-radius: 12px; }
  body:not(.admin-mode) .hscroll{ grid-auto-columns: minmax(170px, 200px); gap:12px; }
  body:not(.admin-mode) .store-controls{ padding: 10px; border-radius: 16px; }
  body:not(.admin-mode) .cat-tiles{ grid-template-columns: repeat(2, minmax(0,1fr)); }
  body:not(.admin-mode) .cat-tile{ grid-template-columns: 44px 1fr; padding: 10px; }
  body:not(.admin-mode) .cat-tile-media{ width:44px; height:44px; }
  .home-cta{ padding: 22px; }
  .foot-grid{ grid-template-columns: 1fr 1fr; gap: 24px; }
  .foot-brand{ grid-column: 1 / -1; }
  body:not(.admin-mode) .calc-page{ padding: 18px; }
  body:not(.admin-mode) .toasts{ top: calc(var(--header-h) + 8px + env(safe-area-inset-top, 0px)); bottom:auto; }
}
@media (max-width: 640px){
  body:not(.admin-mode) .win, body:not(.admin-mode) .win.wide{ border-radius: 26px 26px 0 0; animation: sheetIn .4s cubic-bezier(.2,.85,.25,1) both; }
  body:not(.admin-mode) #win-detail .win{ height: 100%; }
  body:not(.admin-mode) .pd .detail-media{ aspect-ratio: 4/3.4; }
  body:not(.admin-mode) .pd-jump{ top: -18px; }
  body.auth-gate:not(.admin-mode) #win-login{ align-items:center; padding: 16px; }
  body.auth-gate:not(.admin-mode) #win-login .win{ border-radius: 26px; border-bottom: 1px solid var(--line-strong); }
  body.auth-gate:not(.admin-mode) #win-login .grabber{ display:none; }
  body:not(.admin-mode) #win-search .win{ border-radius: 0 0 22px 22px; animation: dropIn .35s cubic-bezier(.2,.85,.25,1) both; }
  body:not(.admin-mode) #win-search{ align-items:flex-start; padding: env(safe-area-inset-top, 0px) 0 0; }
  body:not(.admin-mode) #win-search .grabber{ display:none; }
}
@keyframes dropIn{ from{ transform: translateY(-100%); } to{ transform:none; } }
@media (prefers-reduced-motion: reduce){
  body:not(.admin-mode) .rv, body:not(.admin-mode) .rv *{ opacity:1 !important; transform:none !important; }
  .fx-bg .orb, .float-chip, .login-brand img, .hero-eyebrow i{ animation: none !important; }
}

/* ---------- audit fixes ---------- */
/* Long names and four-digit prices stay inside the card and the product window on a narrow phone. */
body:not(.admin-mode) .pcard-name, body:not(.admin-mode) .pcard-cat, body:not(.admin-mode) .detail-name,
body:not(.admin-mode) .hcard-name{ overflow-wrap: anywhere; min-width: 0; }
body:not(.admin-mode) .pcard-foot{ min-width: 0; flex-wrap: wrap; }
body:not(.admin-mode) .pcard-foot .price{ min-width: 0; }
body:not(.admin-mode) .pcard-foot > button{ flex-shrink: 0; margin-left: auto; }
/* Fingers, not mouse pointers: the small controls get a touch-sized target on phones. */
@media (max-width: 720px){
  body:not(.admin-mode) .stepper button{ min-width: 40px; min-height: 40px; }
  body:not(.admin-mode) .stepper.sm button{ width: 38px; height: 38px; min-width: 38px; min-height: 38px; font-size: 18px; }
  body:not(.admin-mode) .store-foot a{ display: inline-block; padding: 9px 0; }
  body:not(.admin-mode) .win-bar .icon-btn{ min-width: 42px; min-height: 42px; }
}
/* iOS zooms into any field under 16px when it is tapped, also with the phone sideways. */
@media (max-width: 960px) and (hover: none){
  body:not(.admin-mode) input, body:not(.admin-mode) select, body:not(.admin-mode) textarea{ font-size: 16px; }
  body:not(.admin-mode) .qs-top input{ font-size: 18px; }
}
/* Clearer store hierarchy and full-page account entry */
body:not(.admin-mode) .add-btn{ width:auto; min-width:44px; min-height:44px; padding:0 12px; border-radius:12px; }
body:not(.admin-mode) .pcard .price{ font-size:20px; color:var(--text); }
body:not(.admin-mode) .pcard-name{ font-size:16px; line-height:1.4; }
body:not(.admin-mode) .pcard-foot{ gap:8px; }
body.auth-gate:not(.admin-mode) #win-login{ background:var(--bg); background-image:radial-gradient(ellipse at 25% 10%,rgba(59,130,246,.18),transparent 65%); }
body.auth-gate:not(.admin-mode) #win-login .win{ max-width:520px; box-shadow:none; border-color:var(--line-strong); }
body.auth-gate:not(.admin-mode) #win-login .win-body{ padding:24px; }
body.auth-gate:not(.admin-mode) .login-brand img{ width:140px; animation:none; filter:none; }
body:not(.auth-gate) #entryInfo{ display:none; }
body:not(.admin-mode) .login-perks{ justify-content:flex-start; }
body:not(.admin-mode) .login-perks li{ font-size:13px; color:var(--text-dim); }
#win-cart .win-foot{ background:var(--surface); }
@media(max-width:480px){ body.auth-gate:not(.admin-mode) #win-login{ padding:12px; } body.auth-gate:not(.admin-mode) #win-login .win-body{ padding:18px; } }
