/* =========================================================
   Hiusu · estilos (mobile first)
   ========================================================= */
:root {
  --bg: #f6f4fd;
  --surface: #ffffff;
  --surface-2: #f0f0f7;
  --text: #15142a;
  --muted: #6a6985;
  --line: #e6e5f0;
  --hiusu: #3f2d9c;          /* morado del logo */
  --brand: #3f2d9c;
  --brand-2: #5b45cf;
  --brand-ink: #ffffff;
  --brand-soft: #ebe7fb;
  --accent: #7b61ff;
  --ok: #128a55; --ok-soft: #e1f5ea;
  --warn: #b86a00; --warn-soft: #fff1d6;
  --info: #2563eb; --info-soft: #e5eeff;
  --danger: #d6264a; --danger-soft: #fde7ec;
  --wa: #1faa53;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(20, 20, 50, .05), 0 6px 20px rgba(20, 20, 50, .06);
  --shadow-lg: 0 24px 64px rgba(20, 20, 50, .22);
  --nav-h: 66px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e0e16; --surface: #181824; --surface-2: #232332;
    --text: #f1f1f8; --muted: #a3a2bb; --line: #2c2b3d;
    --brand: #9b8aff; --brand-2: #b3a5ff; --brand-soft: #2a2456; --accent: #b3a5ff;
    --ok: #3fd98b; --ok-soft: #153325;
    --warn: #ffb547; --warn-soft: #3a2c13;
    --info: #7ea9ff; --info-soft: #1a2647;
    --danger: #ff6e88; --danger-soft: #3d1a25;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
    --shadow-lg: 0 24px 64px rgba(0, 0, 0, .55);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  padding-bottom: calc(var(--nav-h) + var(--safe-b));
}
body.no-scroll { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.02em; }
code { font-size: .9em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.grow { flex: 1; }
.txt-danger { color: var(--danger); font-style: normal; font-weight: 600; }
.ic { width: 20px; height: 20px; flex: none; }
.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.view { outline: none; min-height: 60vh; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- demo banner ---------- */
.demo-banner {
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  color: #fff; font-size: 12.5px; text-align: center; padding: 6px 16px;
}
.demo-banner code { background: rgba(255,255,255,.2); color: #fff; }
.demo-banner.warn { background: linear-gradient(90deg, #d97706, #ea580c); }

/* ---------- topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--surface) 85%, transparent);
  backdrop-filter: saturate(1.6) blur(14px);
  -webkit-backdrop-filter: saturate(1.6) blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { max-width: 1180px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 12px; }
.logo { display: flex; align-items: center; gap: 9px; margin-right: auto; }
.logo-text { font-family: 'Bagel Fat One', 'Plus Jakarta Sans', system-ui, sans-serif; font-size: 27px; line-height: 1; color: var(--brand); letter-spacing: .01em; padding-top: 2px; }
.logo-mark {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #fff;
  background: var(--hiusu); box-shadow: 0 6px 16px color-mix(in srgb, var(--hiusu) 40%, transparent);
}
.logo-svg { width: 74%; height: auto; }
.logo-svg .shine { stroke: var(--hiusu); }
.logo-mark.lg { width: 64px; height: 64px; border-radius: 18px; }
.top-links { display: none; gap: 4px; }
.top-links a { padding: 8px 14px; border-radius: 10px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 6px; transition: .15s; }
.top-links a:hover { color: var(--text); background: var(--surface-2); }
.top-links a.active { color: var(--brand); background: var(--brand-soft); }
.account { position: relative; }
.account-btn { border: 0; background: none; padding: 0; border-radius: 50%; display: block; }
.account-btn .avatar { width: 38px; height: 38px; box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--brand-soft); }

/* ---------- avatar ---------- */
.avatar {
  --h: 250;
  width: 34px; height: 34px; border-radius: 50%; flex: none; object-fit: cover;
  display: inline-grid; place-items: center; font-weight: 700; font-size: 13px;
  background: hsl(var(--h) 70% 88%); color: hsl(var(--h) 55% 30%);
}
@media (prefers-color-scheme: dark) { .avatar { background: hsl(var(--h) 40% 28%); color: hsl(var(--h) 80% 88%); } }
.avatar.xs { width: 22px; height: 22px; font-size: 9px; }
.avatar.lg { width: 48px; height: 48px; font-size: 17px; }

/* ---------- menu ---------- */
.menu {
  position: absolute; right: 0; top: calc(100% + 10px); width: 260px; z-index: 60;
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg);
  padding: 6px; animation: pop .16s ease;
}
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(.97); } }
.menu-head { display: flex; gap: 10px; align-items: center; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-head div { min-width: 0; display: flex; flex-direction: column; }
.menu-head small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu a, .menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border-radius: 10px; border: 0; background: none; text-align: left; font-weight: 500; }
.menu a:hover, .menu button:hover { background: var(--surface-2); }
.menu .ic { color: var(--muted); width: 18px; height: 18px; }
.menu button { color: var(--danger); }
.menu button .ic { color: var(--danger); }

/* ---------- buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; border-radius: 12px; border: 1px solid transparent; font-weight: 700; font-size: 14.5px;
  background: var(--surface-2); color: var(--text); transition: transform .12s, background .15s, box-shadow .15s, opacity .15s;
  white-space: nowrap; user-select: none;
}
.btn:active:not(:disabled) { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn .ic { width: 18px; height: 18px; }
.btn-sm { padding: 8px 13px; font-size: 13.5px; border-radius: 10px; }
.btn-lg { padding: 14px 20px; font-size: 15.5px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn-primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: var(--brand-ink); box-shadow: 0 6px 18px color-mix(in srgb, var(--brand) 35%, transparent); }
.btn-primary:hover:not(:disabled) { box-shadow: 0 8px 24px color-mix(in srgb, var(--brand) 50%, transparent); }
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-ok { background: var(--ok); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger-ghost { background: var(--danger-soft); color: var(--danger); }
.btn-wa { background: var(--wa); color: #fff; }
.btn-provider { width: 100%; background: var(--surface); border-color: var(--line); padding: 13px; font-weight: 600; }
.btn-provider:hover { background: var(--surface-2); }
.btn.loading { color: transparent !important; pointer-events: none; }
.btn.loading > * { visibility: hidden; }
.btn.loading::after {
  content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%;
  border: 2.5px solid currentColor; border-color: rgba(255,255,255,.9) rgba(255,255,255,.9) transparent transparent;
  animation: spin .7s linear infinite;
}
.btn-ghost.loading::after, .btn-provider.loading::after { border-color: var(--brand) var(--brand) transparent transparent; }
.btn-icon {
  width: 40px; height: 40px; border-radius: 12px; border: 0; background: transparent; color: var(--muted);
  display: inline-grid; place-items: center; flex: none; transition: .15s;
}
.btn-icon:hover { background: var(--surface-2); color: var(--text); }
.btn-icon.danger:hover { background: var(--danger-soft); color: var(--danger); }
.link-btn { background: none; border: 0; color: var(--brand); font-weight: 600; padding: 8px; font-size: 14px; }
.hide-mobile { display: none; }

/* ---------- spinner / loader ---------- */
.spinner { width: 32px; height: 32px; border-radius: 50%; border: 3px solid var(--brand-soft); border-top-color: var(--brand); animation: spin .8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.page-loader { display: grid; place-items: center; padding: 80px 0; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden; padding: 30px 0 26px; color: #fff;
  border-radius: 0 0 28px 28px; margin-bottom: 6px;
  background:
    radial-gradient(500px 260px at 95% 0%, rgba(255,255,255,.14), transparent 70%),
    radial-gradient(600px 360px at -10% 110%, rgba(123,97,255,.55), transparent 70%),
    var(--hiusu);
}
.hero-inner { position: relative; z-index: 1; }
.hero-art { position: absolute; right: 14px; top: 18px; width: 92px; color: #fff; opacity: .16; pointer-events: none; transform: rotate(-8deg); }
.hero-art .logo-svg { width: 100%; }
.hero-art .shine { stroke: transparent; }
@media (min-width: 900px) { .hero { border-radius: 0 0 40px 40px; } .hero-art { width: 300px; right: 6%; top: 50%; transform: translateY(-50%) rotate(-8deg); opacity: .16; } }
.hero-inner { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.eyebrow { display: inline-block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: #fff; background: rgba(255,255,255,.16); padding: 5px 10px; border-radius: 99px; }
.hero h1 { font-size: clamp(28px, 7vw, 50px); font-weight: 800; margin: 12px 0 8px; letter-spacing: -.035em; color: #fff; }
.hl { color: #fff; background: linear-gradient(transparent 62%, rgba(255,255,255,.22) 62%); padding: 0 2px; }
.hero-sub { color: rgba(255,255,255,.82); margin: 0 0 18px; max-width: 520px; font-size: 15.5px; }
.search {
  display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 16px; padding: 0 16px; box-shadow: var(--shadow); max-width: 620px; transition: box-shadow .15s, border-color .15s;
}
.search:focus-within { border-color: #fff; box-shadow: 0 0 0 4px rgba(255,255,255,.35), var(--shadow); }
.search .ic { color: var(--muted); }
.search input { flex: 1; border: 0; outline: 0; background: transparent; padding: 15px 0; font-size: 16px; min-width: 0; }
.hero-stats { display: flex; gap: 18px; margin-top: 16px; font-size: 13.5px; color: rgba(255,255,255,.8); flex-wrap: wrap; }
.hero-stats b { color: #fff; font-size: 15px; }

/* ---------- chips ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 14px 16px; margin: 0 -16px; scrollbar-width: none; scroll-snap-type: x proximity; scroll-padding-inline: 16px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; scroll-snap-align: start; border: 1px solid var(--line); background: var(--surface); color: var(--text);
  padding: 9px 15px; border-radius: 99px; font-weight: 600; font-size: 14px; transition: .15s; display: inline-flex; align-items: center; gap: 6px;
}
.chip:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.chip.active { background: var(--brand); color: #fff; border-color: var(--brand); box-shadow: 0 4px 12px color-mix(in srgb, var(--brand) 30%, transparent); }
.chips.small { padding-top: 4px; }
.chips.small .chip { padding: 7px 12px; font-size: 13px; }
.chip-n { font-size: 11.5px; background: var(--surface-2); color: var(--muted); padding: 0 7px; border-radius: 99px; line-height: 18px; }
.chip.active .chip-n { background: rgba(255,255,255,.22); color: #fff; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; font-size: 14px; }
.select-wrap select {
  appearance: none; border: 1px solid var(--line); background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='3'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center;
  padding: 8px 32px 8px 12px; border-radius: 10px; font-weight: 600; font-size: 13.5px;
}

/* ---------- grid / cards ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding-bottom: 32px; }
.grid > .empty { grid-column: 1 / -1; }
.card {
  background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  display: flex; flex-direction: column; transition: transform .18s, box-shadow .18s; animation: fade .3s ease both;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card:active { transform: scale(.98); }
.card.sold { opacity: .6; }
.card-media {
  --c: #888; position: relative; aspect-ratio: 1; display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(145deg, color-mix(in srgb, var(--c) 22%, var(--surface)), color-mix(in srgb, var(--c) 8%, var(--surface)));
}
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.ph-emoji { font-size: 52px; filter: drop-shadow(0 6px 12px rgba(0,0,0,.12)); }
.card-badge { position: absolute; top: 8px; left: 8px; background: rgba(15,15,25,.78); color: #fff; font-size: 11.5px; font-weight: 700; padding: 4px 9px; border-radius: 99px; }
.card-badge.hot { background: var(--accent); }
.card-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.card-price { font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.card-title { font-size: 14px; font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.5em; line-height: 1.25; }
.card-meta { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12.5px; min-width: 0; }
.card-meta span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card-meta .ic { width: 14px; height: 14px; }
.card-seller { display: flex; align-items: center; gap: 6px; font-size: 12.5px; margin-top: 6px; padding-top: 8px; border-top: 1px dashed var(--line); min-width: 0; }
.card-seller span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.card-seller time { margin-left: auto; color: var(--muted); font-size: 11.5px; white-space: nowrap; }
.card.skel { pointer-events: none; }
.card.skel .card-media, .card.skel i { background: linear-gradient(90deg, var(--surface-2) 25%, var(--line) 50%, var(--surface-2) 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
.card.skel i { display: block; height: 12px; border-radius: 6px; margin: 4px 0; }
.card.skel i:nth-child(1) { width: 40%; height: 16px; }
.card.skel i:nth-child(3) { width: 60%; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- empty ---------- */
.empty { text-align: center; padding: 40px 20px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.empty-emoji { font-size: 46px; margin-bottom: 4px; animation: float 3s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-6px); } }
.empty h3 { font-size: 18px; }
.empty p { margin: 0 0 10px; max-width: 360px; }
.empty-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

/* ---------- detail ---------- */
.back-link { display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; color: var(--muted); font-weight: 600; padding: 14px 0; font-size: 14px; }
.back-link:hover { color: var(--text); }
.back-link .ic { width: 18px; height: 18px; }
.detail { padding-bottom: 110px; }
.detail-grid { display: grid; gap: 20px; }
.gallery-main {
  --c: #888; position: relative; aspect-ratio: 1; border-radius: 22px; overflow: hidden; display: grid; place-items: center;
  background: linear-gradient(145deg, color-mix(in srgb, var(--c) 25%, var(--surface)), color-mix(in srgb, var(--c) 8%, var(--surface)));
  margin: 0 -16px; border-radius: 0;
}
.gallery-main > img { width: 100%; height: 100%; object-fit: cover; }
.gallery-main .ph-emoji { font-size: 110px; }
.track { display: flex; width: 100%; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.track::-webkit-scrollbar { display: none; }
.track img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: center; }
.dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.dots i { width: 7px; height: 7px; border-radius: 99px; background: rgba(255,255,255,.55); transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.dots i.on { width: 20px; background: #fff; }
.gallery-thumbs { display: none; gap: 8px; margin-top: 10px; }
.gallery-thumbs button { width: 70px; height: 70px; border-radius: 12px; overflow: hidden; padding: 0; border: 2px solid transparent; opacity: .6; transition: .15s; background: none; }
.gallery-thumbs button.on { border-color: var(--brand); opacity: 1; }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.detail-top { display: flex; align-items: center; justify-content: space-between; }
.pill { --c: #888; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; padding: 6px 12px; border-radius: 99px; background: color-mix(in srgb, var(--c) 15%, var(--surface)); color: color-mix(in srgb, var(--c) 75%, var(--text)); }
.detail-title { font-size: clamp(23px, 5vw, 32px); font-weight: 800; margin: 12px 0 6px; }
.detail-price { font-size: 30px; font-weight: 800; letter-spacing: -.03em; color: var(--brand); }
.facts { list-style: none; padding: 0; margin: 18px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.facts li { display: flex; gap: 10px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.facts .ic { color: var(--brand); background: var(--brand-soft); width: 36px; height: 36px; padding: 8px; border-radius: 10px; }
.facts div { display: flex; flex-direction: column; min-width: 0; }
.facts small { color: var(--muted); font-size: 12px; }
.facts strong { font-size: 14px; }
.desc h3 { font-size: 15px; margin-bottom: 6px; }
.desc p { margin: 0; color: var(--muted); }
.seller-card { display: flex; align-items: center; gap: 12px; padding: 14px; margin: 18px 0; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.seller-card div { display: flex; flex-direction: column; }
.buy-bar {
  position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b)); z-index: 30;
  display: flex; gap: 10px; align-items: center; padding: 10px 16px;
  background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}
.buy-price { display: flex; flex-direction: column; line-height: 1.1; }
.buy-price small { color: var(--muted); font-size: 11.5px; }
.buy-price strong { font-size: 19px; letter-spacing: -.02em; }
.notice { padding: 12px 14px; border-radius: 12px; font-size: 14px; margin: 12px 0; }
.notice.warn { background: var(--warn-soft); color: var(--warn); }
.notice.info { background: var(--info-soft); color: var(--info); }

/* ---------- modal ---------- */
.modal-wrap { position: fixed; inset: 0; z-index: 100; display: flex; align-items: flex-end; justify-content: center; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(10, 10, 25, .5); opacity: 0; transition: opacity .25s; backdrop-filter: blur(3px); }
.modal {
  position: relative; width: 100%; max-height: 92vh; overflow-y: auto; overscroll-behavior: contain;
  background: var(--surface); border-radius: 26px 26px 0 0; padding: 26px 20px calc(22px + var(--safe-b));
  transform: translateY(100%); transition: transform .3s cubic-bezier(.2, .9, .3, 1); box-shadow: var(--shadow-lg);
}
.modal-wrap.open .modal-backdrop { opacity: 1; }
.modal-wrap.open .modal { transform: none; }
.modal-grip { position: absolute; top: 8px; left: 50%; width: 40px; height: 5px; margin-left: -20px; border-radius: 9px; background: var(--line); }
.modal-x { position: absolute; top: 12px; right: 12px; }
.modal h2 { font-size: 22px; margin-bottom: 14px; }
.dialog h3 { font-size: 19px; margin: 6px 40px 8px 0; }
.dialog p { margin: 0 0 20px; }
.dialog-actions { display: flex; gap: 10px; justify-content: flex-end; }
.dialog-actions .btn { flex: 1; }

/* ---------- auth ---------- */
.auth-head { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; margin-bottom: 18px; }
.auth-head h2 { margin: 8px 0 0; }
.auth-head p { margin: 0; }
.auth-providers { display: grid; gap: 10px; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; margin: 18px 0; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.segmented { display: grid; grid-template-columns: 1fr 1fr; background: var(--surface-2); padding: 4px; border-radius: 12px; margin-bottom: 14px; }
.segmented button { border: 0; background: transparent; padding: 9px; border-radius: 9px; font-weight: 600; color: var(--muted); transition: .15s; }
.segmented button.active { background: var(--surface); color: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.auth-form { display: flex; flex-direction: column; gap: 12px; }
.auth-form .link-btn { align-self: center; }
.pass-wrap { position: relative; }
.pass-wrap input { padding-right: 48px; }
.pass-wrap .btn-icon { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); }
.demo-note { font-size: 12.5px; color: var(--muted); background: var(--surface-2); border-radius: 12px; padding: 10px 12px; margin: 14px 0 0; }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; position: relative; }
.field > span { font-weight: 600; font-size: 13.5px; }
.field em { font-style: normal; font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea, .input-prefix {
  width: 100%; border: 1.5px solid var(--line); background: var(--surface); border-radius: 12px;
  padding: 12px 14px; font-size: 16px; outline: none; transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 48px; }
.field input:focus, .field select:focus, .field textarea:focus, .input-prefix:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.input-prefix { display: flex; align-items: center; gap: 6px; padding: 0 14px; }
.input-prefix b { color: var(--muted); }
.input-prefix input { border: 0; padding: 12px 0; box-shadow: none !important; }
.counter { position: absolute; right: 10px; bottom: 8px; font-size: 11.5px; color: var(--muted); }
.form-error { background: var(--danger-soft); color: var(--danger); padding: 10px 12px; border-radius: 10px; margin: 0; font-size: 14px; font-weight: 500; animation: shake .3s; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
.hint { font-size: 12.5px; color: var(--muted); margin: 8px 0 0; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.cat-picker, .choice { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-picker label, .choice label { cursor: pointer; }
.cat-picker input, .choice input { position: absolute; opacity: 0; pointer-events: none; }
.cat-picker span, .choice span {
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 13px; border-radius: 12px; border: 1.5px solid var(--line);
  font-weight: 600; font-size: 13.5px; transition: .15s; background: var(--surface);
}
.choice { display: grid; grid-template-columns: 1fr 1fr; }
.choice span { justify-content: center; padding: 12px; }
.cat-picker input:checked + span, .choice input:checked + span { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); }
.cat-picker input:focus-visible + span, .choice input:focus-visible + span { box-shadow: 0 0 0 3px var(--brand-soft); }

.switch { position: relative; display: inline-block; width: 46px; height: 28px; flex: none; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch i { position: absolute; inset: 0; background: var(--line); border-radius: 99px; transition: .2s; }
.switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0,0,0,.2); transition: .2s cubic-bezier(.3, 1.4, .5, 1); }
.switch input:checked + i { background: var(--ok); }
.switch input:checked + i::after { transform: translateX(18px); }
.switch input:focus-visible + i { box-shadow: 0 0 0 3px var(--brand-soft); }
.switch-row { display: flex; align-items: center; gap: 14px; justify-content: space-between; padding: 14px; border: 1.5px solid var(--line); border-radius: 14px; cursor: pointer; }
.switch-row div { display: flex; flex-direction: column; }

.stepper { display: flex; align-items: center; gap: 8px; }
.stepper button { width: 44px; height: 44px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font-size: 22px; font-weight: 600; transition: .12s; }
.stepper button:active:not(:disabled) { transform: scale(.9); background: var(--brand-soft); }
.stepper button:disabled { opacity: .35; }
.stepper output { min-width: 40px; text-align: center; font-size: 20px; font-weight: 800; }
.stepper output.bump { animation: bump .25s; }
.stepper small { margin-left: 6px; }
@keyframes bump { 50% { transform: scale(1.3); color: var(--brand); } }

/* ---------- order form / success ---------- */
.order-form { display: flex; flex-direction: column; gap: 14px; }
.order-form h2 { margin-bottom: 0; }
.order-item { display: flex; gap: 12px; align-items: center; padding: 12px; background: var(--surface-2); border-radius: 14px; }
.order-item div:last-child { display: flex; flex-direction: column; min-width: 0; }
.order-thumb, .mini-thumb, .pr-thumb {
  --c: #888; width: 54px; height: 54px; border-radius: 12px; overflow: hidden; flex: none; display: grid; place-items: center;
  background: linear-gradient(145deg, color-mix(in srgb, var(--c) 25%, var(--surface)), color-mix(in srgb, var(--c) 10%, var(--surface)));
}
.order-thumb img, .mini-thumb img, .pr-thumb img { width: 100%; height: 100%; object-fit: cover; }
.order-thumb .ph-emoji, .mini-thumb .ph-emoji, .pr-thumb .ph-emoji { font-size: 26px; }
.order-total { display: flex; justify-content: space-between; align-items: center; padding: 14px 0 2px; border-top: 1px dashed var(--line); font-weight: 600; }
.order-total strong { font-size: 24px; letter-spacing: -.02em; }
.success { text-align: center; display: flex; flex-direction: column; align-items: center; padding-top: 6px; }
.success-check { width: 72px; height: 72px; border-radius: 50%; background: var(--ok); color: #fff; display: grid; place-items: center; animation: pop2 .5s cubic-bezier(.3, 1.6, .5, 1); margin-bottom: 14px; box-shadow: 0 10px 30px color-mix(in srgb, var(--ok) 40%, transparent); }
.success-check .ic { width: 38px; height: 38px; stroke-width: 3; }
@keyframes pop2 { from { transform: scale(0); } }
.success h2 { margin-bottom: 6px; }
.success p { margin: 0 0 20px; }
.success-actions { display: grid; gap: 10px; width: 100%; }

/* ---------- editor ---------- */
.page-head { padding-bottom: 16px; }
.page-head h1 { font-size: clamp(24px, 5vw, 32px); font-weight: 800; }
.page-head p { margin: 6px 0 0; }
.editor { padding-bottom: 40px; }
.editor-grid { display: grid; gap: 20px; }
.surface { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
#ed { display: flex; flex-direction: column; gap: 6px; }
.form-sec { display: flex; flex-direction: column; gap: 14px; padding-bottom: 20px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.form-sec h3 { font-size: 16px; display: flex; align-items: center; gap: 8px; }
.form-sec h3 small { font-weight: 600; font-size: 12.5px; }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding-top: 6px; }
.uploader { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; border-radius: 14px; transition: .15s; }
.uploader.drag { outline: 2px dashed var(--brand); outline-offset: 4px; background: var(--brand-soft); }
.uploader.working { opacity: .6; pointer-events: none; }
.up-item { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; animation: pop .2s; }
.up-item img { width: 100%; height: 100%; object-fit: cover; }
.up-tag { position: absolute; left: 6px; bottom: 6px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 99px; }
.up-del, .up-cover { position: absolute; top: 6px; width: 28px; height: 28px; border-radius: 50%; border: 0; display: grid; place-items: center; background: rgba(10,10,20,.65); color: #fff; }
.up-del { right: 6px; }
.up-cover { left: 6px; }
.up-del .ic, .up-cover .ic { width: 15px; height: 15px; }
.up-add {
  aspect-ratio: 1; border-radius: 14px; border: 2px dashed var(--line); background: var(--surface-2); color: var(--muted);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font-weight: 600; font-size: 12.5px; transition: .15s;
}
.up-add:hover { border-color: var(--brand); color: var(--brand); }
.up-add .ic { width: 26px; height: 26px; }
.preview h3 { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px; }
.preview .card { max-width: 260px; pointer-events: none; }

/* ---------- panel ---------- */
.panel { padding-top: 18px; padding-bottom: 40px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-hello { display: flex; align-items: center; gap: 12px; }
.panel-hello h1 { font-size: 23px; font-weight: 800; }
.panel-hello p { margin: 0; font-size: 14px; }
.tabs {
  display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px 18px; padding: 0 16px;
  border-bottom: 1px solid var(--line); position: sticky; top: 57px; z-index: 20; background: var(--bg);
}
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex: none; display: flex; align-items: center; gap: 7px; padding: 12px 12px; font-weight: 600; font-size: 14px; color: var(--muted); border-bottom: 2.5px solid transparent; margin-bottom: -1px; transition: .15s; }
.tabs a .ic { width: 17px; height: 17px; }
.tabs a.active { color: var(--brand); border-color: var(--brand); }
.tab-body { animation: fade .25s ease; }
.badge { min-width: 19px; height: 19px; padding: 0 5px; border-radius: 99px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 800; display: inline-grid; place-items: center; line-height: 1; }

.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
.stat.wide { grid-column: 1 / -1; }
.hero-stat { background: linear-gradient(135deg, var(--hiusu), #5b45cf); border: 0; color: #fff; }
.hero-stat strong { font-size: 28px; }
.hero-stat small { color: rgba(255,255,255,.85); }
.hero-stat .stat-ic { background: rgba(255,255,255,.18); color: #fff; }
.stat { display: flex; gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; min-width: 0; }
.stat div { display: flex; flex-direction: column; min-width: 0; }
.stat strong { font-size: 21px; font-weight: 800; letter-spacing: -.02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stat small { color: var(--muted); font-size: 12.5px; line-height: 1.2; }
.stat-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.stat.brand .stat-ic { background: var(--brand-soft); color: var(--brand); }
.stat.warn .stat-ic { background: var(--warn-soft); color: var(--warn); }
.stat.ok .stat-ic { background: var(--ok-soft); color: var(--ok); }
.stat.info .stat-ic { background: var(--info-soft); color: var(--info); }
.two-col { display: grid; gap: 16px; align-items: start; }
.two-col .surface h3 { font-size: 16px; }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.sec-head h3 { font-size: 16px; }
.sec-head > a:not(.btn) { color: var(--brand); font-weight: 600; font-size: 13.5px; }
.surface .empty { padding: 24px 10px; }

.mini-list { display: flex; flex-direction: column; }
.mini { display: flex; gap: 12px; align-items: center; padding: 10px 6px; border-radius: 12px; transition: .15s; }
.mini:hover { background: var(--surface-2); }
.mini + .mini { border-top: 1px solid var(--line); }
.mini .grow { display: flex; flex-direction: column; min-width: 0; }
.mini b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-thumb { width: 44px; height: 44px; }

.prod-list { display: flex; flex-direction: column; gap: 10px; }
.prod-row { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 10px; transition: .2s; animation: fade .25s both; }
.prod-row.paused { opacity: .62; }
.pr-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pr-title { font-weight: 700; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12.5px; color: var(--muted); }
.pr-meta b { color: var(--text); }
.prod-row .btn-icon { width: 36px; height: 36px; }
.prod-row .switch { margin: 0 2px; }

/* ---------- orders ---------- */
.orders { display: flex; flex-direction: column; gap: 12px; }
.order { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px; display: flex; flex-direction: column; gap: 12px; animation: fade .25s both; border-left: 4px solid var(--line); }
.surface .order { background: var(--bg); }
.order.st-pendiente { border-left-color: var(--warn); }
.order.st-aceptado { border-left-color: var(--info); }
.order.st-entregado { border-left-color: var(--ok); }
.order.st-rechazado, .order.st-cancelado { opacity: .7; }
.order header { display: flex; gap: 12px; align-items: center; }
.order header .grow { min-width: 0; display: flex; flex-direction: column; }
.order-title { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.order-thumb { width: 48px; height: 48px; }
.status { font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 99px; white-space: nowrap; }
.status.warn { background: var(--warn-soft); color: var(--warn); }
.status.info { background: var(--info-soft); color: var(--info); }
.status.ok { background: var(--ok-soft); color: var(--ok); }
.status.danger { background: var(--danger-soft); color: var(--danger); }
.status.muted { background: var(--surface-2); color: var(--muted); }
.progress { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); font-size: 11.5px; font-weight: 600; color: var(--muted); }
.progress li { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; }
.progress li i { width: 14px; height: 14px; border-radius: 50%; background: var(--line); position: relative; z-index: 1; transition: .3s; }
.progress li + li::before { content: ''; position: absolute; top: 6px; right: 50%; width: 100%; height: 2px; background: var(--line); }
.progress li.done { color: var(--text); }
.progress li.done i { background: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.progress li.done::before { background: var(--brand) !important; }
.order-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; margin: 0; font-size: 13.5px; }
.order-meta div { min-width: 0; }
.order-meta dt { color: var(--muted); font-size: 12px; }
.order-meta dd { margin: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.order-note { margin: 0; padding: 10px 12px; background: var(--surface-2); border-radius: 12px; font-size: 13.5px; font-style: italic; color: var(--muted); }
.order footer { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); }

.account-info { display: flex; gap: 12px; align-items: center; margin: 14px 0; }
.account-info div { display: flex; flex-direction: column; min-width: 0; }
.account-info strong { overflow: hidden; text-overflow: ellipsis; }
#pf { display: flex; flex-direction: column; gap: 14px; }
#pf h3 + p { margin: -10px 0 0; }
#pf .btn { align-self: flex-start; }

/* ---------- toasts ---------- */
.toasts { position: fixed; left: 0; right: 0; top: 12px; z-index: 200; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
.toast {
  display: flex; align-items: center; gap: 10px; background: var(--text); color: var(--bg); padding: 12px 16px;
  border-radius: 14px; font-weight: 600; font-size: 14px; box-shadow: var(--shadow-lg); max-width: 440px;
  transform: translateY(-20px); opacity: 0; transition: .3s cubic-bezier(.2, .9, .3, 1); pointer-events: auto;
}
.toast.in { transform: none; opacity: 1; }
.toast .ic { width: 20px; height: 20px; padding: 3px; border-radius: 50%; background: var(--ok); color: #fff; stroke-width: 3; }
.toast.err .ic { background: var(--danger); }
.toast.info .ic { background: var(--brand); stroke-width: 2.4; }

/* ---------- bottom nav (móvil) ---------- */
.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; height: calc(var(--nav-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: center;
  background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px);
  border-top: 1px solid var(--line);
}
.bottomnav > a, .bottomnav > button {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  height: 100%; font-size: 11px; font-weight: 600; color: var(--muted); border: 0; background: none; transition: color .15s;
}
.bottomnav .ic { width: 23px; height: 23px; transition: transform .2s; }
.bottomnav .active { color: var(--brand); }
.bottomnav .active .ic { transform: translateY(-1px) scale(1.08); }
.bottomnav .badge { position: absolute; top: 8px; left: 50%; margin-left: 4px; }
.bottomnav .fab {
  width: 56px; height: 56px; justify-self: center; border-radius: 18px; margin-top: -26px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff !important;
  box-shadow: 0 10px 24px color-mix(in srgb, var(--brand) 45%, transparent), 0 0 0 5px var(--bg);
}
.bottomnav .fab .ic { width: 28px; height: 28px; stroke-width: 2.6; }
.bottomnav .fab:active { transform: scale(.92); }

/* ---------- responsive ---------- */
@media (max-width: 380px) {
  .hide-xs { display: none; }
  .grid { gap: 10px; }
  .card-body { padding: 9px 10px 10px; }
}
@media (min-width: 560px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 640px) {
  .modal-wrap { align-items: center; padding: 20px; }
  .modal { max-width: 460px; border-radius: 26px; transform: translateY(20px) scale(.97); opacity: 0; transition: transform .25s cubic-bezier(.2, .9, .3, 1), opacity .2s; padding: 30px 28px 26px; }
  .modal-wrap.open .modal { opacity: 1; }
  .modal-sm { max-width: 400px; }
  .modal-grip { display: none; }
}
@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .bottomnav { display: none; }
  .top-links { display: flex; margin-right: 8px; }
  .hide-mobile { display: inline-flex; }
  .hero { padding: 54px 0 34px; }
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
  .detail { padding-bottom: 60px; }
  .detail-grid { grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: start; }
  .gallery { position: sticky; top: 80px; }
  .gallery-main { margin: 0; border-radius: 24px; }
  .gallery-thumbs { display: flex; }
  .buy-bar { position: static; padding: 0; background: none; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; margin-top: 8px; }
  .buy-price { display: none; }
  .editor-grid { grid-template-columns: minmax(0, 1fr) 280px; align-items: start; }
  .preview { position: sticky; top: 84px; }
  .surface { padding: 24px; }
  .two-col { grid-template-columns: 1.2fr 1fr; }
  .tabs { top: 57px; }
}
@media (min-width: 1100px) {
  .grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (hover: none) { .card:hover { transform: none; box-shadow: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* =========================================================
   Añadidos: modalidad, subcategorías, compra rápida, tablero, pre-orden
   ========================================================= */
.card-wrap { position: relative; display: flex; flex-direction: column; min-width: 0; }
.card-wrap > .card { flex: 1; }
.quick-buy {
  position: absolute; right: 8px; top: 8px; z-index: 2; width: 38px; height: 38px; border-radius: 12px; border: 0;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 6px 16px color-mix(in srgb, var(--brand) 45%, transparent);
  transition: transform .15s;
}
.quick-buy:hover { transform: scale(1.08); }
.quick-buy:active { transform: scale(.9); }
.quick-buy .ic { width: 20px; height: 20px; stroke-width: 2.6; }
.card-mode { position: absolute; left: 8px; bottom: 8px; background: var(--info-soft); color: var(--info); font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 99px; }

.mode-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 99px; width: fit-content; }
.mode-badge.now { background: var(--ok-soft); color: var(--ok); }
.mode-badge.pre { background: var(--info-soft); color: var(--info); }
.order-item .mode-badge { margin-top: 4px; }
.pills { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }

.chips.sub { padding-top: 0; margin-top: -6px; }
.chips.sub:empty { display: none; }
.chips.sub .chip { padding: 6px 12px; font-size: 13px; background: var(--surface-2); border-color: transparent; }
.chips.sub .chip.active { background: var(--brand-soft); color: var(--brand); border-color: color-mix(in srgb, var(--brand) 40%, transparent); }
.toolbar-right { display: flex; gap: 8px; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); margin-right: 6px; vertical-align: middle; animation: live 1.6s infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 60%, transparent); } 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

.mode-choice span { flex-direction: column; gap: 2px; text-align: center; }
.mode-choice small { font-weight: 500; font-size: 11.5px; color: var(--muted); }
.pre-note p { margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--info-soft); color: var(--info); font-size: 13px; font-weight: 600; }
.preview .card.pulse { animation: pulse .35s ease; }
@keyframes pulse { 40% { transform: scale(1.04); box-shadow: 0 0 0 3px var(--brand-soft), var(--shadow); } }

.pickup { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: 12px; background: var(--info-soft); color: var(--info); font-size: 13.5px; }
.pickup .ic { width: 18px; height: 18px; }
.pickup.late { background: var(--danger-soft); color: var(--danger); }

.view-toggle { width: fit-content; min-width: 220px; margin-bottom: 4px; }
.kanban {
  display: grid; grid-auto-flow: column; grid-auto-columns: 86%; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory;
  margin: 10px -16px 0; padding: 4px 16px 16px; scroll-padding-inline: 16px; scrollbar-width: none;
}
.kanban::-webkit-scrollbar { display: none; }
.kb-col { scroll-snap-align: start; background: var(--surface-2); border-radius: 18px; padding: 12px; min-height: 320px; border: 2px dashed transparent; transition: border-color .15s, background .15s; }
.kb-col.drop-ok { border-color: var(--brand); background: var(--brand-soft); }
.kb-head { display: flex; align-items: center; justify-content: space-between; font-weight: 700; margin: 2px 4px 12px; }
.kb-head .chip-n { background: var(--surface); }
.kb-list { display: flex; flex-direction: column; gap: 10px; }
.kb-empty { text-align: center; color: var(--muted); font-size: 13px; padding: 30px 10px; margin: 0; }
.order.compact { padding: 12px; gap: 10px; background: var(--surface); }
.order.compact .order-meta { font-size: 12.5px; }
.order.compact footer .btn-wa { padding: 7px 10px; }
.order[draggable="true"] { cursor: grab; }
.order.dragging { opacity: .45; transform: rotate(-1.5deg); }
@media (min-width: 900px) {
  .kanban { grid-auto-flow: row; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: visible; margin: 10px 0 0; padding: 0; }
}
@media (min-width: 560px) {
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 420px) {
  .toolbar { flex-wrap: wrap; }
  .toolbar-right { width: 100%; }
  .toolbar-right .select-wrap { flex: 1; }
  .toolbar-right select { width: 100%; }
}

/* =========================================================
   Añadidos: disponibilidad rápida, pagos, transferencia, ImgBB
   ========================================================= */
.mode-pill {
  display: inline-flex; align-items: center; gap: 4px; border: 0; border-radius: 99px; padding: 2px 9px;
  font-size: 12px; font-weight: 700; line-height: 1.6; transition: transform .12s, filter .15s;
}
.mode-pill.now { background: var(--ok-soft); color: var(--ok); }
.mode-pill.pre { background: var(--info-soft); color: var(--info); }
.mode-pill:hover { filter: brightness(.96); }
.mode-pill:active { transform: scale(.94); }
.mode-pill span { font-size: 9px; opacity: .7; }
.quick-mode { display: flex; flex-direction: column; gap: 16px; }
.quick-mode h2 { margin-bottom: -10px; }
.quick-mode p { margin: 0; }
.stepper input { width: 84px; text-align: center; font-size: 20px; font-weight: 800; border: 1.5px solid var(--line); border-radius: 12px; padding: 8px; background: var(--surface); outline: none; }
.stepper input:focus { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.choice.single { grid-template-columns: 1fr; }
.pay-choice { display: grid; grid-template-columns: 1fr 1fr; }
.pay-choice span { justify-content: center; padding: 12px; }
.transfer { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 14px; background: var(--ok-soft); color: var(--text); border: 1px dashed color-mix(in srgb, var(--ok) 50%, transparent); }
.transfer div { flex: 1; min-width: 0; }
.transfer small { color: var(--ok); font-weight: 700; }
.transfer p { margin: 2px 0 0; font-weight: 600; font-size: 14px; word-break: break-word; }
.check-row { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 14px; cursor: pointer; }
.check-row input { width: 18px; height: 18px; accent-color: var(--brand); }
.sec-gap { margin-top: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.form-error.info { background: var(--info-soft); color: var(--info); animation: none; }
.notice.small { font-size: 13px; margin: 4px 0 0; }
a.link { color: var(--brand); font-weight: 600; text-decoration: underline; }
.buy-bar .btn-ghost { background: var(--surface); }
