:root {
  --bg: #f5f6f8;
  --bg-soft: #ffffff;
  --card: #ffffff;
  --card-hover: #fdfaf6;
  --line: #e3e7ee;
  --text: #1b2431;
  --text-dim: #5c6b80;
  --accent: #df2623;
  --accent-strong: #ac1b19;
  --accent-soft: rgba(223, 38, 35, .1);
  --blue: #2563eb;
  --blue-soft: rgba(37, 99, 235, .1);
  --green: #15803d;
  --green-soft: rgba(21, 128, 61, .1);
  --purple: #7c3aed;
  --purple-soft: rgba(124, 58, 237, .1);
  --shadow: 0 1px 3px rgba(16, 24, 40, .07);
  --shadow-lg: 0 8px 28px rgba(16, 24, 40, .13);
  --radius: 14px;
  font-size: 15px;
}

:root[data-theme="dark"] {
  --bg: #0e1116;
  --bg-soft: #151a22;
  --card: #1a212c;
  --card-hover: #202938;
  --line: #2a3444;
  --text: #e8edf4;
  --text-dim: #93a1b5;
  --accent: #e55250;
  --accent-strong: #ed8785;
  --accent-soft: rgba(229, 82, 80, .16);
  --blue: #60a5fa;
  --blue-soft: rgba(59, 130, 246, .16);
  --green: #4ade80;
  --green-soft: rgba(34, 197, 94, .16);
  --purple: #a78bfa;
  --purple-soft: rgba(167, 139, 250, .16);
  --shadow: none;
  --shadow-lg: 0 8px 28px rgba(0, 0, 0, .45);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
}

/* ── Topbar ───────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 14px;
  padding: 12px 22px;
  /* Color plano, sin degradado: los logos traen fondo blanco o negro según el
     tema, y así se funden con la barra en vez de verse como un recuadro. */
  background: var(--bg-soft);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
/* El ancho se fija en el contenedor, no en la imagen: si se pone en la imagen
   con %, el flex usa el ancho intrínseco (900px) y la marca se infla. */
.brand { display: flex; align-items: center; text-decoration: none; color: var(--text); flex: 0 1 380px; max-width: 380px; min-width: 0; }
/* Banner de 9:1 con las tres marcas: llena la marca y nunca se deforma. */
.brand-logo-img { width: 100%; height: auto; display: block; }
.logo-for-dark { display: none; }
:root[data-theme="dark"] .logo-for-light { display: none; }
:root[data-theme="dark"] .logo-for-dark { display: block; }
.brand-text { display: none; }
.brand-text small { color: var(--text-dim); font-weight: 500; font-size: .72rem; }

.search-wrap { position: relative; flex: 1; max-width: 520px; }
.search-icon { position: absolute; left: 12px; top: 15px; width: 17px; height: 17px; color: var(--text-dim); }
#search {
  width: 100%; padding: 11px 14px 11px 38px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); font-size: .92rem; outline: none; font-family: inherit;
}
#search:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); background: var(--bg-soft); }

.suggestions {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 60;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow-lg); overflow: hidden; max-height: 380px; overflow-y: auto;
}
.sug-item {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 9px 13px; border: none; background: none; cursor: pointer;
  color: var(--text); font-size: .87rem; text-align: left; font-family: inherit;
}
.sug-item:hover, .sug-item.hl { background: var(--accent-soft); }
.sug-item img { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; background: var(--bg); }
.sug-item .sug-kind { margin-left: auto; font-size: .7rem; color: var(--text-dim); }
.sug-item .sug-price { color: var(--green); font-weight: 700; font-size: .78rem; }
/* Marca los privados en el buscador: es el único listado donde aparecen. */
.sug-item .sug-lock {
  display: inline-block; margin-right: 6px; font-size: .78rem;
  filter: drop-shadow(0 0 3px rgba(212, 175, 55, .55));
}

.top-actions { display: flex; gap: 6px; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-width: 40px; height: 40px; padding: 0 12px;
  border-radius: 10px; border: 1px solid var(--line); background: var(--bg-soft);
  cursor: pointer; font-size: 1.05rem; text-decoration: none; color: var(--text);
  font-family: inherit; white-space: nowrap;
  transition: border-color .15s, transform .1s;
}
.ib-ico { font-size: 1.05rem; line-height: 1; }
.ib-txt { font-size: .78rem; font-weight: 700; }
/* El botón de menú es solo icono */
#btn-menu { padding: 0; width: 40px; }
.icon-btn:hover { border-color: var(--accent); transform: translateY(-1px); }

.count-pill { color: var(--text-dim); font-size: .8rem; white-space: nowrap; font-weight: 600; }

.btn-contacto {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 8px;
  background: #25d366; color: #fff; text-decoration: none;
  font-size: .8rem; font-weight: 800; letter-spacing: .4px;
  padding: 11px 16px; border-radius: 11px; white-space: nowrap;
  transition: filter .15s, transform .1s;
}
.btn-contacto:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-contacto svg { width: 18px; height: 18px; }

/* ── Layout ───────────────────────────── */
/* ── Barra lateral ────────────────────────── */
.layout { display: flex; align-items: flex-start; }

.sidebar {
  position: sticky; top: 61px; flex: none; width: 236px;
  height: calc(100vh - 61px); overflow-y: auto;
  padding: 18px 12px; border-right: 1px solid var(--line);
  background: var(--bg-soft);
}
.side-nav { display: flex; flex-direction: column; gap: 4px; }
.side-link {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 13px; border-radius: 11px;
  color: var(--text-dim); text-decoration: none;
  font-size: .87rem; font-weight: 600; line-height: 1.2;
  transition: background .14s, color .14s;
}
.side-link svg { width: 20px; height: 20px; flex: none; }
.side-link:hover { background: var(--bg); color: var(--text); }
.side-link.activo { background: var(--accent-soft); color: var(--accent-strong); font-weight: 800; }
.side-link.activo svg { stroke: var(--accent-strong); }

.side-grupo {
  font-size: .66rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px;
  color: var(--text-dim); opacity: .75; padding: 16px 13px 5px;
}
.sidebar-fondo { display: none; }
#btn-menu { display: none; }

#app { flex: 1; min-width: 0; max-width: 1280px; margin: 0 auto; padding: 22px; }

/* En pantallas medianas y chicas la barra se esconde y sale como cajón */
/* Con el logo grande y los botones con texto, el contador de la barra estorba:
   esa cifra ya se ve dentro de cada pantalla. */
@media (max-width: 1400px) {
  .count-pill { display: none; }
}

@media (max-width: 1100px) {
  .brand { flex-basis: 300px; max-width: 300px; }
}

@media (max-width: 900px) {
  #btn-menu { display: inline-flex; }
  .ib-txt { display: none; }
  .icon-btn { padding: 0; width: 40px; }
  .brand { flex-basis: 250px; max-width: 250px; }
  .sidebar {
    position: fixed; top: 0; left: 0; height: 100vh; z-index: 60;
    width: 250px; padding-top: 18px;
    transform: translateX(-100%); transition: transform .22s ease;
    box-shadow: var(--shadow-lg);
  }
  .sidebar.abierta { transform: translateX(0); }
  .sidebar-fondo {
    display: block; position: fixed; inset: 0; z-index: 55;
    background: rgba(0, 0, 0, .45);
  }
  .sidebar-fondo[hidden] { display: none; }
}
:root[data-theme="dark"] .topbar {
  background: #000;
  border-bottom-color: #23262c;
}
:root[data-theme="dark"] .sidebar { background: #08090b; }

.loading { color: var(--text-dim); text-align: center; padding: 60px 0; }

/* ── Filtros ──────────────────────────── */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.chip {
  border: 1px solid var(--line); background: var(--bg-soft); color: var(--text-dim);
  padding: 6px 13px; border-radius: 999px; font-size: .82rem; cursor: pointer;
  transition: all .15s; font-family: inherit; font-weight: 500;
}
.chip:hover { color: var(--text); border-color: var(--text-dim); }
.chip.active { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-strong); font-weight: 700; }
.chip.fav-chip.active { background: var(--purple-soft); border-color: var(--purple); color: var(--purple); }
.chip .n { opacity: .6; font-size: .72rem; margin-left: 4px; }
.filters select {
  background: var(--bg-soft); color: var(--text);
  border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px;
  font-size: .84rem; outline: none; font-family: inherit;
}
.filters .spacer { margin-left: auto; }

.range-row {
  display: flex; flex-wrap: wrap; gap: 18px; align-items: center;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 16px; margin-bottom: 18px; box-shadow: var(--shadow);
}
.range-group { display: flex; align-items: center; gap: 10px; font-size: .8rem; color: var(--text-dim); font-weight: 600; }
.range-group output { color: var(--accent-strong); font-weight: 800; min-width: 42px; }
.range-group input[type="range"] { accent-color: var(--accent); width: 150px; }
.range-reset { margin-left: auto; }

.section-title { font-size: 1.05rem; font-weight: 800; margin: 26px 0 14px; display: flex; align-items: center; gap: 10px; }
.section-title .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

/* ── Grid de productos ────────────────── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(225px, 1fr)); gap: 16px; }

@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; cursor: pointer; text-decoration: none; color: var(--text);
  display: flex; flex-direction: column; position: relative;
  box-shadow: var(--shadow);
  transition: transform .18s, border-color .18s, box-shadow .18s;
  animation: fadeUp .35s ease both;
}
.card:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: var(--shadow-lg); }

.card-img { position: relative; aspect-ratio: 1 / 1; overflow: hidden; }
.card-img img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  opacity: 0; transition: opacity .3s;
}
.card-img.loaded img { opacity: 1; }
.card-img::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, var(--bg) 40%, var(--line) 50%, var(--bg) 60%);
  background-size: 200% 100%;
  animation: shimmer 1.3s infinite;
}
.card-img.loaded::before { display: none; }
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -80% 0; } }

.card-badges-top {
  position: absolute; top: 10px; left: 10px; z-index: 2;
  display: flex; flex-direction: column; gap: 6px; align-items: flex-start;
}
.badge-new {
  background: var(--green); color: #fff; font-size: .68rem; font-weight: 800;
  padding: 3px 9px; border-radius: 999px; letter-spacing: .5px;
}
.badge-draft {
  position: absolute; bottom: 10px; left: 10px; z-index: 2;
  background: #64748b; color: #fff; font-size: .68rem; font-weight: 700;
  padding: 3px 9px; border-radius: 999px;
}
.badge-private {
  position: absolute; bottom: 10px; left: 10px; z-index: 2;
  background: linear-gradient(90deg, #f0c94a, #d4af37); color: #241c02;
  font-size: .68rem; font-weight: 800; padding: 3px 10px; border-radius: 999px;
  letter-spacing: .4px; white-space: nowrap;
}
.badge-fuego {
  background: linear-gradient(90deg, var(--accent), #ff8a3d); color: #fff;
  font-size: .68rem; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  letter-spacing: .3px; white-space: nowrap;
}
.detail-badges { display: flex; gap: 8px; margin-bottom: 8px; }
.detail-badges:empty { display: none; }

.card-actions { position: absolute; top: 8px; right: 8px; z-index: 3; display: flex; flex-direction: column; gap: 6px; }
.mini-action {
  display: grid; place-items: center; width: 32px; height: 32px;
  border-radius: 9px; border: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg-soft) 88%, transparent);
  backdrop-filter: blur(4px);
  cursor: pointer; font-size: .9rem; transition: transform .1s;
}
.mini-action:hover { transform: scale(1.12); }
.mini-action.on { background: var(--accent); border-color: var(--accent); }

.card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-name { font-size: .92rem; font-weight: 650; line-height: 1.3; }
.card-prices { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.price-tag { font-size: .78rem; padding: 3px 9px; border-radius: 8px; font-weight: 700; }
.price-tag.venta { background: var(--accent-soft); color: var(--accent-strong); }
.price-tag.drop { background: var(--blue-soft); color: var(--blue); }
.price-tag.gain { background: var(--green-soft); color: var(--green); }
.card-cats { display: flex; gap: 5px; flex-wrap: wrap; }
.mini-cat { font-size: .68rem; color: var(--text-dim); background: var(--bg); padding: 2px 8px; border-radius: 6px; }

.gain-meter { height: 5px; border-radius: 4px; background: var(--bg); overflow: hidden; }
.gain-meter > i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--green), #86efac); }
.gain-meter-label { font-size: .68rem; color: var(--text-dim); }
.gain-meter-label b { color: var(--green); }

.empty { text-align: center; color: var(--text-dim); padding: 70px 0; }
#sentinel { height: 10px; }

/* ── Detalle ──────────────────────────── */
.back-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--bg-soft); border: 1px solid var(--line); color: var(--text-dim);
  padding: 8px 15px; border-radius: 10px; cursor: pointer; font-size: .86rem;
  margin-bottom: 18px; font-family: inherit;
}
.back-btn:hover { color: var(--text); border-color: var(--text-dim); }

.detail { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 26px; }
.detail > div { min-width: 0; }
@media (max-width: 900px) { .detail { grid-template-columns: 1fr; } }

.gallery-main {
  border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  background: var(--bg-soft); aspect-ratio: 1/1; display: grid; place-items: center;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.gallery-main video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.gallery-main iframe { width: 100%; height: 100%; border: none; background: #000; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.gallery-thumbs img {
  width: 62px; height: 62px; object-fit: cover; border-radius: 8px;
  border: 2px solid var(--line); cursor: pointer; opacity: .7; background: var(--bg-soft);
}
.gallery-thumbs img.sel { border-color: var(--accent); opacity: 1; }
.vid-thumb {
  width: 62px; height: 62px; border-radius: 8px;
  border: 2px solid var(--line); cursor: pointer; opacity: .8;
  background: #10151d; color: #fff; font-size: 1.3rem;
  display: grid; place-items: center;
}
.vid-thumb.sel { border-color: var(--accent); opacity: 1; }

/* Secciones Imágenes / Videos (material de Drive) */
.count-badge {
  background: var(--accent-soft); color: var(--accent-strong);
  font-size: .72rem; font-weight: 800; padding: 2px 9px; border-radius: 999px;
}
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(105px, 1fr)); gap: 8px; }
.media-grid a { display: block; aspect-ratio: 1/1; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.media-grid img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .15s; }
.media-grid a:hover img { transform: scale(1.06); }
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.video-tile {
  position: relative; aspect-ratio: 1/1; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--line); background: #10151d; cursor: pointer;
}
.video-tile img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: .85; }
.video-tile:hover img { opacity: 1; }
.play-badge {
  position: absolute; inset: 0; display: grid; place-items: center;
  color: #fff; font-size: 1.6rem; text-shadow: 0 2px 10px rgba(0,0,0,.7);
  background: radial-gradient(circle, rgba(0,0,0,.25), transparent 70%);
}
.video-tile.playing { cursor: default; }
.video-tile iframe, .video-tile video { width: 100%; height: 100%; border: none; }

.detail-info h1 { font-size: 1.45rem; line-height: 1.25; margin-bottom: 4px; font-weight: 800; }
.plat-name { color: var(--text-dim); font-size: .84rem; margin-bottom: 14px; }
.plat-name b { color: var(--text); }
.detail-actions { display: flex; gap: 8px; margin-bottom: 10px; }

.price-cards { display: flex; gap: 10px; flex-wrap: wrap; margin: 14px 0 18px; }
.price-card {
  flex: 1; min-width: 120px; background: var(--card); border: 1px solid var(--line);
  border-radius: 12px; padding: 12px 14px; box-shadow: var(--shadow);
}
.price-card .lbl { font-size: .72rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: .6px; font-weight: 600; }
.price-card .val { font-size: 1.25rem; font-weight: 800; margin-top: 3px; }
.price-card.venta .val { color: var(--accent-strong); }
.price-card.drop .val { color: var(--blue); }
.price-card.gain .val { color: var(--green); }

.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 18px; border-radius: 11px; border: none; cursor: pointer;
  font-size: .9rem; font-weight: 700; text-decoration: none; color: #fff;
  transition: filter .15s, transform .1s; font-family: inherit;
}
.btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn svg { width: 16px; height: 16px; flex: none; }
.btn.small { padding: 8px 14px; font-size: .82rem; }
.link-group { margin-bottom: 14px; }
.link-group-title {
  font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .8px;
  color: var(--text-dim); margin-bottom: 8px;
}
.btn.brand { background: #fff; border: 1px solid var(--line); padding: 9px 16px; }
.btn.brand img { height: 24px; display: block; }
.btn.brand span { color: #1b2431; font-weight: 800; }
.btn.brand:hover { border-color: var(--accent); }
.btn.dropi { background: #ea580c; }
.btn.effi { background: #2563eb; }
.btn.canva { background: #7c3aed; }
.btn.drive { background: #16a34a; }
.btn.ghost { background: var(--bg-soft); border: 1px solid var(--line); color: var(--text-dim); }
.btn.ghost:hover { color: var(--text); }

/* ── Producto privado (premium) ──────────────────────────── */
.private-banner {
  position: relative; overflow: hidden;
  background: linear-gradient(160deg, #0b0b0d 0%, #171209 55%, #0b0b0d 100%);
  border: 1px solid #caa243; border-radius: 16px;
  padding: 20px 22px; margin-bottom: 20px;
  box-shadow: 0 12px 30px rgba(0,0,0,.4), inset 0 0 50px rgba(212,175,55,.05);
}
.private-banner::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 32%, rgba(212,175,55,.16) 48%, transparent 64%);
  background-size: 220% 100%;
  animation: privateShine 5.5s ease-in-out infinite;
}
@keyframes privateShine {
  0% { background-position: 140% 0; }
  55%, 100% { background-position: -40% 0; }
}
.private-head { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.private-lock { font-size: 1.5rem; line-height: 1; animation: lockGlow 2.4s ease-in-out infinite; }
@keyframes lockGlow {
  0%, 100% { filter: drop-shadow(0 0 2px rgba(240,197,74,.35)); transform: scale(1) rotate(0deg); }
  50% { filter: drop-shadow(0 0 12px rgba(240,197,74,.9)); transform: scale(1.1) rotate(-4deg); }
}
.private-title {
  font-size: 1.1rem; font-weight: 900; letter-spacing: 1.3px; text-transform: uppercase;
  background: linear-gradient(90deg, #f0c94a, #fdeeb3 45%, #d4af37);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.private-exclusividad {
  margin-left: auto; font-size: .64rem; font-weight: 800; letter-spacing: 1.4px;
  color: #241c02; background: linear-gradient(90deg, #f0c94a, #d4af37);
  padding: 4px 11px; border-radius: 999px; text-transform: uppercase; white-space: nowrap;
}
.private-text {
  position: relative; z-index: 1; color: #d8d2c2; font-size: .86rem;
  line-height: 1.45; margin-bottom: 14px;
}
.private-actions { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.btn.whatsapp-private { background: #25d366; color: #06210f; }
.btn.whatsapp-private:hover { background: #1ebe5b; }
.btn.whatsapp-private svg { width: 17px; height: 17px; }
.private-maquila {
  font-size: .74rem; font-weight: 700; color: #d4af37;
  border: 1px dashed rgba(212,175,55,.55); border-radius: 999px;
  padding: 7px 13px; display: inline-flex; align-items: center; gap: 6px;
}

/* Plataformas bloqueadas en productos privados */
.btn.brand.locked {
  position: relative; cursor: not-allowed;
  border: 1.5px dashed #caa243; background: var(--bg-soft);
}
.btn.brand.locked:hover { filter: none; transform: none; }
.btn.brand.locked img { filter: grayscale(1) blur(1.6px); opacity: .35; }
.btn.brand.locked .lock-ico {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-size: 1.05rem; color: #d4af37;
}
.locked-note {
  font-size: .74rem; font-weight: 600; color: var(--text-dim);
  margin: 4px 0 10px;
}
.btn.whatsapp-private.pulse { animation: waPulse 2.2s ease-in-out infinite; }
@keyframes waPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, .5); }
  55% { box-shadow: 0 0 0 11px rgba(37, 211, 102, 0); }
}

/* ── Bloques del Inicio ─────────────────── */
.ini-hero {
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
  background: linear-gradient(120deg, var(--card), var(--accent-soft));
  border: 1px solid var(--line); border-radius: 18px;
  padding: 26px 28px; margin-bottom: 18px; box-shadow: var(--shadow);
}
.ini-hero-txt { flex: 1 1 340px; min-width: 0; }
.ini-kicker {
  font-size: .68rem; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase;
  color: var(--accent-strong); display: block; margin-bottom: 7px;
}
.ini-hero h1 { font-size: 1.55rem; font-weight: 800; line-height: 1.15; margin-bottom: 8px; }
.ini-hero p { color: var(--text-dim); font-size: .92rem; line-height: 1.5; margin-bottom: 16px; }
.ini-hero-btns { display: flex; gap: 10px; flex-wrap: wrap; }

.ini-accesos { display: grid; grid-template-columns: repeat(auto-fit, minmax(146px, 1fr)); gap: 10px; margin-bottom: 20px; }
.acceso {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 15px 10px; border-radius: 14px; text-decoration: none; text-align: center;
  background: var(--card); border: 1px solid var(--line); color: var(--text);
  transition: transform .12s, border-color .14s, box-shadow .16s;
}
.acceso:hover { transform: translateY(-2px); border-color: var(--accent); box-shadow: var(--shadow-lg); }
.acc-ico { font-size: 1.45rem; line-height: 1; margin-bottom: 3px; }
.acceso b { font-size: .84rem; font-weight: 800; }
.acceso small { font-size: .71rem; color: var(--text-dim); }

.ver-mas { margin-left: auto; font-size: .76rem; font-weight: 700; color: var(--accent-strong); text-decoration: none; }
.ver-mas:hover { text-decoration: underline; }

/* Tira horizontal de productos */
.tira {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(210px, 1fr);
  gap: 14px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x proximity;
}
.tira > * { scroll-snap-align: start; }

/* Producto estrella */
.ini-estrella { margin-bottom: 20px; }
.estrella-card {
  display: flex; gap: 20px; align-items: center; flex-wrap: wrap;
  background: linear-gradient(115deg, var(--card), rgba(245, 158, 11, .1));
  border: 1px solid var(--line); border-radius: 18px; padding: 18px;
  text-decoration: none; color: var(--text); box-shadow: var(--shadow);
  transition: transform .12s, box-shadow .16s;
}
.estrella-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.estrella-card img { width: 150px; height: 150px; border-radius: 14px; object-fit: cover; flex: none; background: var(--bg); }
.estrella-info { flex: 1 1 260px; min-width: 0; }
.estrella-tag {
  display: inline-block; font-size: .68rem; font-weight: 800; letter-spacing: .6px;
  background: linear-gradient(90deg, #f59e0b, var(--accent)); color: #fff;
  padding: 4px 11px; border-radius: 999px; margin-bottom: 9px; text-transform: uppercase;
}
.estrella-info h2 { font-size: 1.15rem; font-weight: 800; margin-bottom: 6px; line-height: 1.2; }
.estrella-info p { color: var(--text-dim); font-size: .85rem; margin-bottom: 11px; }
.estrella-info p b { color: var(--text); }
.estrella-cifras { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.estrella-gan { font-size: 1.6rem; font-weight: 800; color: var(--green); }
.estrella-margen { font-size: .8rem; font-weight: 700; color: var(--text-dim); }

/* Podio */
.podio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: end; }
.podio-item {
  display: flex; flex-direction: column; align-items: center; gap: 5px; text-align: center;
  text-decoration: none; color: var(--text); padding: 12px 8px 0;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px 14px 0 0;
  transition: transform .12s;
}
.podio-item:hover { transform: translateY(-3px); }
.podio-medalla { font-size: 1.5rem; line-height: 1; }
.podio-item img { width: 62px; height: 62px; border-radius: 12px; object-fit: cover; background: var(--bg); }
.podio-item b {
  font-size: .78rem; font-weight: 700; line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.podio-gan { font-size: .95rem; font-weight: 800; color: var(--green); }
.podio-base { display: block; width: 100%; border-radius: 6px 6px 0 0; margin-top: 8px; }
.lugar-1 .podio-base { height: 34px; background: linear-gradient(180deg, #f0c94a, #d4af37); }
.lugar-2 .podio-base { height: 22px; background: linear-gradient(180deg, #d7dce3, #b3bbc6); }
.lugar-3 .podio-base { height: 14px; background: linear-gradient(180deg, #e0a878, #c07f4a); }

/* Recursos disponibles */
.ini-recursos { margin-top: 6px; }
.recursos-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.recurso {
  position: relative; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 15px 15px 18px; box-shadow: var(--shadow);
}
.rec-ico { font-size: 1.25rem; display: block; margin-bottom: 5px; }
.recurso b { font-size: 1.4rem; font-weight: 800; display: block; line-height: 1; }
.recurso small { font-size: .74rem; color: var(--text-dim); display: block; margin-top: 3px; }
.recurso i { position: absolute; left: 0; bottom: 0; height: 4px; background: var(--green); }

/* Categorías en el inicio */
.ini-cats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.ini-cat {
  display: flex; align-items: center; gap: 10px; cursor: pointer; font-family: inherit;
  padding: 13px 14px; border-radius: 13px; text-align: left;
  background: var(--card); border: 1px solid var(--line); color: var(--text);
  transition: border-color .14s, transform .12s;
}
.ini-cat:hover { border-color: var(--accent); transform: translateY(-2px); }
.ini-cat .chip-ico { width: 21px; height: 21px; opacity: 1; color: var(--accent); }
.ini-cat b { font-size: .84rem; font-weight: 700; flex: 1; min-width: 0; }
.ini-cat small { font-size: .74rem; color: var(--text-dim); font-weight: 700; }

/* Resumen de envíos en el inicio */
.env-resumen { display: grid; grid-template-columns: repeat(auto-fit, minmax(165px, 1fr)); gap: 12px; }
.env-mini { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 15px; box-shadow: var(--shadow); }
.env-mini.alerta { border-color: var(--accent); background: var(--accent-soft); }
.env-mini-lbl { font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--text-dim); }
.env-mini b { display: block; font-size: 1.25rem; font-weight: 800; margin: 4px 0 2px; }
.env-mini small { font-size: .74rem; color: var(--text-dim); }

/* Llamado final */
.ini-cta {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 22px 24px; margin-top: 20px; box-shadow: var(--shadow);
}
.ini-cta h2 { font-size: 1.05rem; font-weight: 800; margin-bottom: 4px; }
.ini-cta p { color: var(--text-dim); font-size: .86rem; }

@media (max-width: 640px) {
  .ini-hero { padding: 20px; gap: 16px; }
  .ini-hero h1 { font-size: 1.28rem; }
  .estrella-card img { width: 100%; height: 190px; }
  .podio-item b { font-size: .72rem; }
  .tira { grid-auto-columns: minmax(168px, 1fr); }
}

/* Estadísticas para envíos */
.env-titulo { font-size: .95rem; font-weight: 800; margin: 20px 0 10px; display: flex; align-items: center; gap: 8px; }
.env-titulo small {
  font-size: .7rem; font-weight: 700; color: var(--text-dim);
  background: var(--bg-soft); border: 1px solid var(--line);
  padding: 2px 8px; border-radius: 999px;
}
.env-pie { font-size: .8rem; color: var(--text-dim); margin-top: 10px; }

.tabla-envios td { vertical-align: middle; }
.tabla-envios .col-num { min-width: 130px; }
.tabla-envios .col-dev { color: var(--text-dim); font-weight: 700; }
.env-barra {
  display: inline-block; width: 62px; height: 6px; border-radius: 99px;
  background: var(--bg); overflow: hidden; margin-right: 8px; vertical-align: middle;
}
.env-barra i { display: block; height: 100%; border-radius: 99px; }
.env-barra i.exc { background: var(--green); }
.env-barra i.bien { background: #22c55e; }
.env-barra i.regular { background: #f59e0b; }
.env-barra i.mal { background: var(--accent); }
.e-exc, .e-bien { color: var(--green); font-weight: 800; }
.e-regular { color: #b45309; font-weight: 800; }
.e-mal { color: var(--accent-strong); font-weight: 800; }
:root[data-theme="dark"] .e-regular { color: #fbbf24; }

.env-tag {
  font-size: .68rem; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  white-space: nowrap; text-transform: uppercase; letter-spacing: .3px;
}
.env-tag.exc, .env-tag.bien { background: var(--green-soft); color: var(--green); }
.env-tag.regular { background: rgba(245, 158, 11, .14); color: #b45309; }
.env-tag.mal { background: var(--accent-soft); color: var(--accent-strong); }
:root[data-theme="dark"] .env-tag.regular { color: #fbbf24; }

.transp {
  font-size: .74rem; font-weight: 700; padding: 3px 9px; border-radius: 7px;
  white-space: nowrap; border: 1px solid var(--line); background: var(--bg-soft);
}
.transp.t-servientrega { border-color: var(--green); color: var(--green); }
.transp.t-laarcourier { border-color: var(--blue); color: var(--blue); }
.transp.t-gintracom { border-color: var(--purple); color: var(--purple); }
.transp.t-urbano { border-color: var(--accent); color: var(--accent-strong); }
.transp-sub { font-size: .74rem; color: var(--text-dim); margin: -4px 0 12px 0; padding-left: 2px; }

/* Iconos en los chips de categoría */
.chip { display: inline-flex; align-items: center; gap: 6px; }
.chip-ico { width: 15px; height: 15px; flex: none; opacity: .8; }
.chip.active .chip-ico { opacity: 1; }

/* Más rentables: lista con barra de fuego */
.rent-lista {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
}
.rent-row {
  display: grid; grid-template-columns: 34px 54px 1fr auto;
  align-items: center; gap: 13px; padding: 13px 16px;
  border-bottom: 1px solid var(--line); text-decoration: none; color: var(--text);
  transition: background .14s;
}
.rent-row:last-child { border-bottom: none; }
.rent-row:hover { background: var(--card-hover); }
.rent-row.top { background: linear-gradient(90deg, rgba(255, 138, 61, .09), transparent 45%); }
.rent-row.top:hover { background: linear-gradient(90deg, rgba(255, 138, 61, .16), var(--card-hover) 45%); }

.rent-pos { font-size: 1rem; font-weight: 800; color: var(--text-dim); text-align: center; }
.rent-img { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; background: var(--bg); }

.rent-cuerpo { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.rent-nombre {
  font-weight: 700; font-size: .89rem; line-height: 1.25;
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.rent-precios { font-size: .75rem; color: var(--text-dim); }
.rent-precios b { color: var(--text); font-weight: 700; }
.rent-barra { height: 7px; border-radius: 99px; background: var(--bg); overflow: hidden; }
.rent-barra i {
  display: block; height: 100%; border-radius: 99px;
  background: linear-gradient(90deg, #f59e0b, #f97316 55%, var(--accent));
}

.rent-cifra { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; white-space: nowrap; }
.rent-cifra b { font-size: 1.12rem; font-weight: 800; color: var(--green); }
.rent-cifra small { font-size: .7rem; color: var(--text-dim); font-weight: 600; }
.rent-fuego { font-size: .78rem; line-height: 1; margin-top: 2px; }

@media (max-width: 640px) {
  .rent-row { grid-template-columns: 24px 44px 1fr; gap: 10px; padding: 12px 13px; }
  .rent-img { width: 44px; height: 44px; }
  .rent-cifra { grid-column: 2 / -1; flex-direction: row; align-items: baseline; gap: 8px; }
  .rent-cifra b { font-size: 1rem; }
  .rent-fuego { margin-top: 0; }
}

/* Lista de precios */
.precios-barra { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.precios-buscar { position: relative; flex: 1; min-width: 220px; max-width: 420px; }
.precios-buscar svg {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  width: 16px; height: 16px; color: var(--text-dim); pointer-events: none;
}
#buscar-precio {
  width: 100%; padding: 10px 14px 10px 36px;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px;
  color: var(--text); font-size: .89rem; outline: none; font-family: inherit;
}
#buscar-precio:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.precios-conteo { font-size: .8rem; font-weight: 600; color: var(--text-dim); white-space: nowrap; }
.sin-resultados { text-align: center; color: var(--text-dim); padding: 30px 14px !important; }
.tabla-wrap {
  overflow-x: auto; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.tabla-precios { width: 100%; border-collapse: collapse; font-size: .86rem; }
.tabla-precios th {
  text-align: left; padding: 12px 14px; font-size: .7rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .6px; color: var(--text-dim);
  border-bottom: 1px solid var(--line); background: var(--bg-soft);
  position: sticky; top: 0;
}
.tabla-precios td { padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tabla-precios tr:last-child td { border-bottom: none; }
.tabla-precios tbody tr:hover { background: var(--card-hover); }
.tabla-precios td:first-child { white-space: normal; min-width: 220px; }
.tabla-precios a { color: var(--text); text-decoration: none; font-weight: 600; }
.tabla-precios a:hover { color: var(--accent-strong); }
.tabla-precios .col-gan { color: var(--green); font-weight: 800; }

/* Cómo empezar */
.guia-texto { color: var(--text-dim); font-size: .89rem; line-height: 1.55; }
.guia-texto b { color: var(--text); }
.guia-lista { list-style: none; display: flex; flex-direction: column; gap: 11px; }
.guia-lista li {
  color: var(--text-dim); font-size: .88rem; line-height: 1.5;
  padding-left: 20px; position: relative;
}
.guia-lista li::before { content: "→"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.guia-lista b, .guia-texto a, .guia-lista a { color: var(--accent-strong); font-weight: 700; }
.guia-lista b { color: var(--text); }
.paso { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.paso:last-child { margin-bottom: 0; }
.paso-num {
  flex: none; display: grid; place-items: center; width: 30px; height: 30px;
  border-radius: 50%; background: var(--accent); color: #fff;
  font-weight: 800; font-size: .85rem;
}
.paso h3 { font-size: .95rem; font-weight: 800; margin-bottom: 3px; }
.paso p { color: var(--text-dim); font-size: .87rem; line-height: 1.5; }
.paso p b { color: var(--text); }
.paso p a { color: var(--accent-strong); font-weight: 700; }

/* Al imprimir la lista de precios: solo la tabla */
@media print {
  .topbar, .sidebar, .sidebar-fondo, .precios-barra, .compare-tray, .section-title + .chart-sub { display: none !important; }
  .tabla-wrap { border: none; box-shadow: none; overflow: visible; }
  .tabla-precios { font-size: 10pt; }
  #app { padding: 0; max-width: none; }
}

/* Página "Próximamente" (Eventos y clases) */
.proximamente {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 48px 26px; text-align: center; box-shadow: var(--shadow);
}
.prox-icono { font-size: 3rem; line-height: 1; margin-bottom: 14px; }
.proximamente h2 {
  font-size: 1.5rem; font-weight: 800; margin-bottom: 10px;
  background: linear-gradient(90deg, var(--accent), #ff8a3d);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.proximamente p {
  color: var(--text-dim); font-size: .92rem; line-height: 1.5;
  max-width: 440px; margin: 0 auto 22px;
}

/* Tarjetas de links creativos (todos los productos) */
.creative-row { display: flex; gap: 10px; flex-wrap: wrap; }
.creative-card {
  display: flex; align-items: center; gap: 11px; text-decoration: none; color: #fff;
  flex: 1 1 250px; min-width: 0; padding: 11px 15px; border-radius: 12px;
  transition: filter .15s, transform .1s;
}
.creative-card:hover { filter: brightness(1.09); transform: translateY(-1px); }
.creative-card.canva { background: #7c3aed; }
.creative-card.drive { background: #16a34a; }
.creative-card svg { width: 21px; height: 21px; flex: none; }
.cc-body { display: flex; flex-direction: column; min-width: 0; }
.cc-body b { font-size: .88rem; font-weight: 800; }
.cc-body small { font-size: .72rem; font-weight: 600; opacity: .88; line-height: 1.3; }

#btn-theme.locked { opacity: .55; cursor: not-allowed; }

.detail-section {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px; margin-bottom: 16px; box-shadow: var(--shadow);
}
.detail-section h2 { font-size: .95rem; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; font-weight: 800; }

.seg-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.seg-chip { background: var(--purple-soft); color: var(--purple); font-size: .8rem; padding: 5px 12px; border-radius: 999px; font-weight: 600; }
.seg-row { margin-bottom: 8px; font-size: .88rem; color: var(--text-dim); }
.seg-row b { color: var(--text); }

.copy-block { background: var(--bg); border: 1px solid var(--line); border-radius: 11px; padding: 13px 15px; margin-bottom: 10px; }
.copy-block-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.copy-block-head span { font-weight: 700; font-size: .8rem; color: var(--accent-strong); }
.copy-btn {
  background: var(--accent-soft); color: var(--accent-strong); border: none; border-radius: 8px;
  padding: 5px 12px; font-size: .76rem; font-weight: 700; cursor: pointer; font-family: inherit;
}
.copy-btn:hover { filter: brightness(1.1); }
.copy-block pre { white-space: pre-wrap; font-family: inherit; font-size: .85rem; color: var(--text-dim); line-height: 1.5; }

.specs-html { font-size: .88rem; color: var(--text-dim); line-height: 1.6; overflow-x: auto; }
.specs-html p { margin-bottom: 8px; }
.specs-html strong { color: var(--text); }
.specs-html img { max-width: 100%; border-radius: 10px; margin: 8px 0; }
.specs-html table { border-collapse: collapse; width: 100%; margin: 10px 0; font-size: .84rem; }
.specs-html th, .specs-html td { border: 1px solid var(--line); padding: 7px 10px; text-align: left; }
.specs-html th { color: var(--text); background: var(--bg); width: 45%; }
.specs-html hr { border: none; border-top: 1px solid var(--line); margin: 12px 0; }
.specs-html h2, .specs-html h3 { font-size: .95rem; color: var(--text); margin: 12px 0 6px; }

.faq-text { white-space: pre-wrap; font-size: .87rem; color: var(--text-dim); line-height: 1.55; }

.link-list { display: flex; flex-direction: column; gap: 8px; }
.link-item {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px;
}
.link-item .url { flex: 1; font-size: .8rem; color: var(--text-dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Comparador ───────────────────────── */
.compare-tray[hidden] { display: none; }
.compare-tray {
  position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 80;
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 10px 9px 20px; box-shadow: var(--shadow-lg); font-size: .86rem; font-weight: 600;
}
.compare-table-wrap { overflow-x: auto; }
.compare-table { border-collapse: collapse; width: 100%; min-width: 640px; }
.compare-table th, .compare-table td {
  border: 1px solid var(--line); padding: 10px 14px; text-align: left;
  font-size: .86rem; vertical-align: top; background: var(--card);
}
.compare-table th { width: 150px; color: var(--text-dim); font-size: .76rem; text-transform: uppercase; letter-spacing: .5px; background: var(--bg-soft); }
.compare-table img { width: 110px; height: 110px; object-fit: cover; border-radius: 10px; }
.compare-table .cmp-name { font-weight: 700; font-size: .92rem; }

/* ── Dashboard ────────────────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat-tile {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; box-shadow: var(--shadow);
}
.stat-tile .lbl { font-size: .74rem; color: var(--text-dim); font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.stat-tile .val { font-size: 1.7rem; font-weight: 800; margin-top: 4px; }
.stat-tile .sub { font-size: .76rem; color: var(--text-dim); margin-top: 2px; }

.chart-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px; margin-bottom: 18px; box-shadow: var(--shadow);
}
.chart-card h2 { font-size: .98rem; font-weight: 800; margin-bottom: 4px; }
.chart-card .chart-sub { font-size: .8rem; color: var(--text-dim); margin-bottom: 14px; }

.hbar-row { display: grid; grid-template-columns: 150px 1fr 46px; align-items: center; gap: 10px; margin-bottom: 8px; cursor: pointer; }
.hbar-row:hover .hbar-fill { filter: brightness(1.12); }
.hbar-label { font-size: .82rem; color: var(--text); text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar-track { height: 18px; border-radius: 0 4px 4px 0; background: var(--bg); position: relative; }
.hbar-fill { position: absolute; inset: 0 auto 0 0; border-radius: 0 4px 4px 0; background: var(--accent); min-width: 2px; }
.hbar-val { font-size: .8rem; font-weight: 700; color: var(--text-dim); }

.scatter-svg { width: 100%; height: auto; display: block; }
.scatter-svg circle { cursor: pointer; }

.rank-list { display: flex; flex-direction: column; gap: 6px; }
.rank-row {
  display: grid; grid-template-columns: 34px 44px 1fr 90px 1fr; align-items: center; gap: 10px;
  padding: 7px 10px; border-radius: 10px; cursor: pointer; text-decoration: none; color: var(--text);
}
.rank-row:hover { background: var(--accent-soft); }
/* Filas de ranking que no llevan foto (destinos de envío) */
.rank-row.sin-img { grid-template-columns: 34px 1fr 130px 1fr; cursor: default; }
.rank-row.sin-img:hover { background: transparent; }
.rank-pos { font-weight: 800; font-size: .9rem; text-align: center; }
.rank-row img { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; background: var(--bg); }
.rank-name { font-size: .86rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-gain { font-weight: 800; color: var(--green); font-size: .88rem; text-align: right; }
.rank-bar { height: 8px; border-radius: 0 4px 4px 0; background: var(--bg); overflow: hidden; }
.rank-bar > i { display: block; height: 100%; background: var(--green); border-radius: 0 4px 4px 0; }

.chart-tooltip {
  position: fixed; z-index: 90; pointer-events: none;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px;
  padding: 8px 12px; font-size: .8rem; box-shadow: var(--shadow-lg); max-width: 240px;
}
.chart-tooltip b { display: block; margin-bottom: 2px; }
.chart-tooltip .tt-dim { color: var(--text-dim); }

/* ── Toast ────────────────────────────── */
.toast {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%);
  background: var(--green); color: #fff; font-weight: 700; font-size: .86rem;
  padding: 10px 22px; border-radius: 999px; z-index: 100;
  box-shadow: var(--shadow-lg);
}

@media (max-width: 640px) {
  .topbar { flex-wrap: wrap; padding: 10px 14px; gap: 8px; }
  .brand { order: 1; }
  .brand-text { display: none; }
  .btn-contacto { order: 2; margin-left: auto; padding: 9px 12px; font-size: .72rem; }
  .search-wrap { order: 3; max-width: none; flex-basis: 100%; }
  .top-actions { order: 4; }
  .count-pill { display: none; }
  #app { padding: 14px; }
  .hbar-row { grid-template-columns: 100px 1fr 40px; }
  .rank-row { grid-template-columns: 28px 36px 1fr 70px; }
  .rank-bar { display: none; }
}
