/* gamify.css — Paper Trade Lab rewards + contest badges (GTAVI INSIDER, neon-noir).
   Injected panels only; everything is namespaced .cg-* so existing styles are untouched.
   Works on markets.html (lab rewards) and win-earn.html (contest badges). */

.cg-panel {
  margin: 0 0 22px;
  padding: 20px 22px;
  border: 1px solid var(--line, #2a2433);
  border-radius: 14px;
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(255,45,120,.08), transparent 55%),
    radial-gradient(120% 140% at 100% 100%, rgba(34,211,238,.08), transparent 55%),
    var(--panel, var(--surface, #14101c));
  color: var(--ink, #f4f1ea);
}

.cg-eyebrow {
  font: 700 11px/1.4 system-ui, sans-serif;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--cyan, #22d3ee);
}

.cg-h {
  font-family: 'Pricedown Bl', 'Bebas Neue', 'Archivo', sans-serif;
  font-size: 34px;
  letter-spacing: .02em;
  margin: 4px 0 12px;
  color: #fff;
}

.cg-h .cg-level-name {
  background: linear-gradient(92deg, #ff2d78, #ff9a3c 55%, #22d3ee);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.cg-stats { display: flex; flex-wrap: wrap; gap: 10px; }

.cg-stat {
  min-width: 96px;
  padding: 10px 14px;
  border: 1px solid var(--line, #2a2433);
  border-radius: 10px;
  background: rgba(0,0,0,.28);
  text-align: center;
}

.cg-stat .cg-num {
  display: block;
  font-family: 'Pricedown Bl', 'Bebas Neue', sans-serif;
  font-size: 30px;
  color: #fff;
}

.cg-stat .cg-lab {
  display: block;
  font-size: 13px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted, #9a93a8);
  margin-top: 2px;
}

.cg-badges {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.cg-badge {
  display: flex; gap: 10px; align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line, #2a2433);
  border-radius: 10px;
  background: rgba(0,0,0,.22);
  opacity: .45;
  filter: grayscale(.8);
}

.cg-badge.cg-unlocked {
  opacity: 1; filter: none;
  border-color: rgba(255,45,120,.55);
  box-shadow: 0 0 0 1px rgba(255,45,120,.25), 0 6px 18px -8px rgba(255,45,120,.6);
}

.cg-badge .cg-ico { font-size: 24px; line-height: 1; }
.cg-badge .cg-bname { font-weight: 700; font-size: 14px; color: #fff; }
.cg-badge .cg-bdesc { font-size: 13px; color: var(--muted, #9a93a8); line-height: 1.35; }

.cg-lb { margin-top: 18px; }

.cg-lb h4 {
  font-family: 'Pricedown Bl', 'Bebas Neue', sans-serif;
  font-size: 22px; letter-spacing: .02em; color: #fff; margin: 0 0 8px;
}

.cg-note { font: 400 11px system-ui, sans-serif; color: var(--muted, #9a93a8); letter-spacing: .02em; }

.cg-lb ol { list-style: none; margin: 0; padding: 0; }

.cg-lb li {
  display: flex; align-items: baseline; gap: 10px;
  padding: 8px 4px;
  border-bottom: 1px dashed var(--line, #2a2433);
  font-size: 14px;
  cursor: default;
}

.cg-lb li.cg-me { font-weight: 700; }
.cg-lb li.cg-me .cg-pname { color: var(--cyan, #22d3ee); }
.cg-lb li button.cg-switch {
  background: none; border: none; color: inherit; font: inherit;
  cursor: pointer; padding: 0; text-align: left;
}
.cg-lb li button.cg-switch:hover .cg-pname { text-decoration: underline; }

.cg-lb .cg-rank { font-family: 'Pricedown Bl','Bebas Neue',sans-serif; font-size: 18px; color: var(--ce-pink, #ff2d78); width: 26px; }
.cg-lb .cg-meta { margin-left: auto; color: var(--muted, #9a93a8); font-size: 13px; white-space: nowrap; }

.cg-lb-actions { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

.cg-btn {
  appearance: none; cursor: pointer;
  padding: 9px 16px; border-radius: 9px;
  border: 1px solid var(--line, #2a2433);
  background: rgba(255,45,120,.12); color: #fff;
  font: 700 13px/1 system-ui, sans-serif;
}
.cg-btn:hover { background: rgba(255,45,120,.22); }
.cg-btn.ghost { background: transparent; color: var(--muted, #9a93a8); }
.cg-btn.ghost:hover { color: #fff; }

/* Contest badge shelf (win-earn.html) — slimmer strip */
.cg-contest-strip { margin: 18px 0 6px; }
.cg-contest-strip .cg-badges { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }

/* Badge-unlock toast */
.cg-toast {
  position: fixed; left: 50%; bottom: 26px;
  transform: translateX(-50%) translateY(20px);
  max-width: min(92vw, 420px);
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid rgba(255,45,120,.6);
  background: rgba(12,8,20,.96);
  color: #fff; font-size: 14px; line-height: 1.4;
  box-shadow: 0 18px 50px -12px rgba(255,45,120,.55);
  opacity: 0; pointer-events: none;
  transition: opacity .35s ease, transform .35s ease;
  z-index: 9999;
}
.cg-toast.cg-show { opacity: 1; transform: translateX(-50%) translateY(0); }
.cg-toast strong { color: var(--cyan, #22d3ee); }

@media (prefers-reduced-motion: reduce) {
  .cg-toast { transition: none; }
}

@media (max-width: 560px) {
  .cg-stat { min-width: 0; flex: 1 1 30%; }
  .cg-h { font-size: 28px; }
}
