/* ═══════════════════════════════════════════════════════════
   GAMIFICATION SYSTEM — Level bar, Achievements & Shop modals
   ═══════════════════════════════════════════════════════════ */

/* ── Profile frame: position context for customize btn ── */
.profile-header_frame { position: relative; }

/* ── Customize button ── */
.profile-customize-btn {
  position: absolute; top: 10px; right: 12px; z-index: 4;
  background: rgba(0,0,0,0.30);
  backdrop-filter: blur(16px) saturate(0.7);
  -webkit-backdrop-filter: blur(16px) saturate(0.7);
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 7px; padding: 5px 12px;
  font-size: 11px; font-weight: 500; letter-spacing: 0.04em;
  color: rgba(255,255,255,0.65); cursor: pointer; font-family: inherit;
  transition: background .15s, border-color .15s, color .15s;
}
.profile-customize-btn:hover {
  background: rgba(0,0,0,0.50); border-color: rgba(255,255,255,0.22);
  color: rgba(255,255,255,0.88);
}

/* ── User badge (значок достижения) ── */
.user-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 6px;
  font-size: 13px; line-height: 1;
  cursor: default; flex-shrink: 0; user-select: none;
  vertical-align: middle; position: relative;
  transition: transform 0.15s, box-shadow 0.15s;
  margin-left: 6px;
  transform: translateY(-1px);
}
.user-badge:hover { box-shadow: 0 2px 10px rgba(0,0,0,0.35); }

/* CSS-тултип */
.user-badge[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 7px);
  left: 50%; transform: translateX(-50%);
  background: rgba(16,14,20,0.97);
  color: rgba(255,255,255,0.92);
  font-size: 11px; font-weight: 400;
  padding: 6px 10px; border-radius: 7px;
  white-space: normal; text-align: center;
  max-width: 200px; min-width: 100px;
  pointer-events: none; opacity: 0;
  transition: opacity 0.15s; z-index: 9999;
  box-shadow: 0 4px 18px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.09);
}
.user-badge[data-tooltip]:hover::after { opacity: 1; }

/* Значок в строке ника — чуть крупнее */
.profile-info_username .user-badge { width: 26px; height: 26px; font-size: 19px; border-radius: 7px; }


/* Значок в мини-профиле (profiles.ejs) */
.mini-profile-badge { width: 18px; height: 18px; font-size: 11px; border-radius: 4px; margin-left: 3px; flex-shrink: 0; }

/* ── Level + XP card ── */
.profile-gm-bar {
  display: flex; align-items: center; gap: 18px;
  margin: 24px 0 0;
  padding: 13px 16px 14px 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.028), rgba(255,255,255,0.012));
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06), 0 1px 0 rgba(0,0,0,0.18);
}
.pgb-meta {
  display: flex; flex-direction: column; align-items: flex-start;
  gap: 1px; min-width: 56px; padding-right: 18px;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.pgb-meta__label {
  font-size: 9px; font-weight: 700; letter-spacing: 0.16em;
  color: rgba(200,190,230,0.45); text-transform: uppercase;
  line-height: 1;
}
.pgb-meta__num {
  font-size: 20px; font-weight: 700; color: rgba(255,255,255,0.95);
  line-height: 1.05; letter-spacing: -0.04em;
  margin-top: 4px;
}
.pgb-progress { flex: 1; display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.pgb-progress__head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 12px; line-height: 1;
}
.pgb-progress__xp {
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,0.78);
  letter-spacing: -0.01em;
}
.pgb-progress__next {
  font-size: 11px; color: rgba(200,190,230,0.4); white-space: nowrap;
}
.pgb-track {
  height: 6px; background: rgba(255,255,255,0.06);
  border-radius: 99px; overflow: hidden;
  box-shadow: inset 0 1px 1.5px rgba(0,0,0,0.25);
}
.pgb-fill {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #6e42c8 0%, #9f6eff 80%, #c4aeff00 101%);
  transition: width 0.9s cubic-bezier(0.4, 0, 0.2, 1);
  min-width: 6px;
}
.pgb-ach-btn {
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(255,255,255,0.05); border: none;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.09);
  border-radius: 10px; padding: 9px 12px 9px 16px;
  font-size: 12.5px; font-weight: 600; color: rgba(255,255,255,0.85);
  cursor: pointer; white-space: nowrap; font-family: inherit;
  transition: background .15s, color .15s, box-shadow .15s;
  align-self: stretch;
}
.pgb-ach-btn:hover {
  background: rgba(255,255,255,0.09);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.15);
  color: #fff;
}
.pgb-ach-btn__chev {
  font-size: 18px; line-height: 1; opacity: 0.45;
  margin-top: -2px; font-weight: 400;
}

/* ── Modal overlay ── */
#gm-app { font-family: inherit; }
[v-cloak]#gm-app { display: none; }
.gm-overlay {
  position: fixed; inset: 0; z-index: 9500;
  background: rgba(4,2,12,0.80);
  backdrop-filter: blur(8px) saturate(0.65);
  -webkit-backdrop-filter: blur(8px) saturate(0.65);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; animation: gmFadeIn .18s ease;
}
@keyframes gmFadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ── Modal shell ── */
.gm-modal {
    background: #18161b;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 20px;
    box-shadow: 0 40px 80px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.03);
    display: flex; flex-direction: column; overflow: hidden;
    animation: gmSlideUp .22s cubic-bezier(0.34,1.1,0.64,1);
    max-height: min(88vh, 720px);
    padding: 0;
}

.gm-modal .profile-header_frame {margin: 0 16px}
@keyframes gmSlideUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}
.gm-modal--ach  { width: min(96vw, 560px); }
.gm-modal--shop { width: 100%; }    /* ширина задаётся классом container */
.gm-hdr--no-border { border-bottom: none !important; padding-bottom: 12px; }

/* ── Header ── */
.gm-hdr {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 20px; border-bottom: 1px solid rgba(255,255,255,0.05);
  flex-shrink: 0;
}
.gm-hdr__title { font-size: 15px; font-weight: 600; color: #f2f0f7; flex: 1; letter-spacing: -0.01em; }
.gm-hdr__badge {
  background: rgba(50,215,75,0.13); color: #4cd964;
  font-size: 11px; font-weight: 700; padding: 2px 9px;
  border-radius: 99px; letter-spacing: 0.02em; white-space: nowrap;
}
.gm-hdr__btn {
  background: rgba(255,255,255,0.04); border: none;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08);
  border-radius: 8px; padding: 5px 13px; font-size: 12px; font-weight: 500;
  color: rgba(200,190,230,0.6); cursor: pointer; font-family: inherit;
  transition: background .14s, color .14s, box-shadow .14s; white-space: nowrap;
}
.gm-hdr__btn:hover {
  background: rgba(255,255,255,0.07);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.12);
  color: rgba(200,190,230,0.9);
}
.gm-hdr__balance {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,0.04);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06);
  border-radius: 99px; padding: 5px 12px;
  font-size: 12px; color: rgba(200,190,230,0.4); white-space: nowrap;
}
.gm-hdr__balance::before {
  content: ''; width: 8px; height: 8px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ffe066 0%, #ffd60a 60%, #c9a227 100%);
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(201,162,39,0.35);
}
.gm-hdr__balance b { color: rgba(255,255,255,0.9); font-weight: 600; }
.gm-close {
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(255,255,255,0.05); border: none;
  color: rgba(200,190,230,0.45); font-size: 16px; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background .14s, color .14s; flex-shrink: 0;
}
.gm-close:hover { background: rgba(255,255,255,0.1); color: rgba(200,190,230,0.85); }

/* ── Tabs ── */
.gm-tabs {
  display: flex; gap: 4px; padding: 8px 14px 7px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  flex-wrap: wrap; flex-shrink: 0;
  overflow-x: auto; overflow-y: hidden;
  scrollbar-width: none; -ms-overflow-style: none;
}
.gm-tabs::-webkit-scrollbar { display: none; }
.gm-tab {
  padding: 5px 13px; border-radius: 7px; font-size: 12px; font-weight: 500;
  color: rgba(200,190,230,0.45); cursor: pointer; white-space: nowrap;
  transition: background .13s, color .13s, box-shadow .13s;
  user-select: none; flex-shrink: 0;
}
.gm-tab:hover { color: rgba(200,190,230,0.75); }
.gm-tab.active {
  background: rgba(255,255,255,0.05);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.85);
}

/* ── Scrollable body ── */
.gm-body {
  flex: 1; overflow-y: auto;
  padding: 10px 12px 14px;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.08) transparent;
  display: flex; flex-direction: column; gap: 6px;
}
.gm-body::-webkit-scrollbar { width: 4px; }
.gm-body::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius: 99px; }

/* ── Empty state ── */
.gm-empty { padding: 48px 24px; text-align: center; color: rgba(200,190,230,0.25); font-size: 13px; }

/* ── Achievement card ── */
.ach-row {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px;
  padding: 12px 14px;
  background: rgba(255,255,255,0.022);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05);
  border-radius: 12px;
  transition: background .13s, box-shadow .13s;
}
.ach-row:hover {
  background: rgba(255,255,255,0.038);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.075);
}
.ach-row--unlocked:hover {
  background: rgba(255,255,255,0.04);
  box-shadow: inset 0 0 0 1px rgba(76,217,100,0.28);
}
.ach-row--claimed { opacity: 0.45; }
.ach-row--claimed:hover { opacity: 0.7; }

/* ── Category section header ── */
.ach-sep {
  padding: 16px 4px 4px;
  font-size: 13px; font-weight: 600;
  color: rgba(255,255,255,0.55);
  pointer-events: none;
  letter-spacing: -0.01em;
}
.ach-sep:first-child { padding-top: 4px; }

/* ── Reward badge tile (left side) ── */
.ach-orb {
  width: 52px; height: 52px; border-radius: 14px; flex-shrink: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.04);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07);
  line-height: 1; gap: 2px;
  position: relative;
}
.ach-orb--unlocked {
  background: rgba(76,217,100,0.10);
  box-shadow: inset 0 0 0 1px rgba(76,217,100,0.32);
}
.ach-orb--claimed {
  background: rgba(76,217,100,0.05);
  box-shadow: inset 0 0 0 1px rgba(76,217,100,0.15);
}
.ach-orb__val {
  font-size: 16px; font-weight: 700; color: rgba(255,255,255,0.88);
  letter-spacing: -0.035em;
}
.ach-orb--unlocked .ach-orb__val { color: #c4f5cb; }
.ach-orb--claimed  .ach-orb__val { color: rgba(255,255,255,0.65); }
.ach-orb__unit {
  font-size: 8.5px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: rgba(200,190,230,0.4);
  margin-top: 1px;
}
.ach-orb--unlocked .ach-orb__unit { color: rgba(196,245,203,0.7); }
.ach-orb--claimed  .ach-orb__unit { color: rgba(255,255,255,0.32); }
/* Coin sub-reward — небольшой chip ПОД плиткой, не внутри */
.ach-orb__sub {
    position: absolute;
    left: 50%;
    bottom: -7px;
    transform: translateX(-50%);
    font-size: 10px;
    font-weight: 600;
    color: rgb(255 255 255 / 85%);
    background: rgb(33 33 33 / 95%);
    padding: 1px 6px;
    border-radius: 99px;
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / 25%);
    white-space: nowrap;
    letter-spacing: -0.005em;
    padding: 4px 7px;
}

/* ── Content ── */
.ach-content { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ach-name {
  font-size: 14.5px; font-weight: 600; color: #f5f3fa;
  display: flex; align-items: center; gap: 7px;
  line-height: 1.2; letter-spacing: -0.012em;
}
.ach-cat-icon { font-size: 12px; opacity: 0.45; font-style: normal; flex-shrink: 0; }
.ach-desc {
  font-size: 12.5px; color: rgba(200,190,230,0.5);
  line-height: 1.4;
}

/* ── Progress ── */
.ach-prog { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; grid-column-start: 1; grid-column-end: 4; }

/* Shimmer loading skeleton */
@keyframes achShimmer {
  0%   { background-position: -200% center; }
  100% { background-position:  200% center; }
}
.ach-prog-shimmer {
  height: 4px; border-radius: 99px; margin-top: 4px;
  background: linear-gradient(90deg,
    rgba(255,255,255,0.03) 0%,
    rgba(255,255,255,0.09) 50%,
    rgba(255,255,255,0.03) 100%
  );
  background-size: 200% 100%;
  animation: achShimmer 1.6s linear infinite;
}

/* Numeric bar */
.ach-prog-item { display: flex; flex-direction: column; gap: 5px; }
.ach-prog-meta {
  display: flex; align-items: baseline; justify-content: space-between; gap: 6px;
}
.ach-prog-label { font-size: 11.5px; color: rgba(200,190,230,0.55); line-height: 1; font-weight: 500; }
.ach-prog-pct   { font-size: 11px; color: rgba(200,190,230,0.4); white-space: nowrap; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.ach-prog-pct--done { color: rgba(76,217,100,0.75); font-weight: 600; }
.ach-prog-track {
  height: 3px; background: rgba(255,255,255,0.05);
  border-radius: 99px; overflow: hidden;
}
.ach-prog-fill {
  height: 100%; border-radius: 99px; min-width: 3px;
  background: linear-gradient(90deg, rgba(200,190,230,0.4), rgba(200,190,230,0.6));
  transition: width .55s cubic-bezier(.25,.8,.25,1);
}
.ach-row--unlocked .ach-prog-fill {
  background: linear-gradient(90deg, rgba(50,180,80,0.6), rgba(76,217,100,0.85));
  box-shadow: 0 0 6px rgba(76,217,100,0.3);
}

/* Boolean check row */
.ach-check-row { display: flex; align-items: center; gap: 8px; }
.ach-check-dot {
  width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
  background: rgba(255,255,255,0.08);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.15);
}
.ach-check-dot--ok {
  background: rgba(76,217,100,0.85);
  box-shadow: inset 0 0 0 1px rgba(76,217,100,1), 0 0 6px rgba(76,217,100,0.4);
}
.ach-check-lbl { font-size: 12px; color: rgba(200,190,230,0.5); }
.ach-check-lbl--ok { color: rgba(76,217,100,0.85); font-weight: 500; }

/* Action area (right side, vertically centered) */
.ach-action {
  display: flex; align-items: center; padding-left: 4px;
  flex-shrink: 0;
}

/* Claimed date */
.ach-claimed-date { font-size: 11px; color: rgba(200,190,230,0.35); white-space: nowrap; }

/* Claim button — App Store "GET" pill: subtle, не приторно */
.ach-claim-btn {
  background: rgba(76,217,100,0.13); border: none;
  box-shadow: inset 0 0 0 1px rgba(76,217,100,0.22);
  color: #4cd964; font-size: 12px; font-weight: 700;
  padding: 6px 16px; min-width: 78px; border-radius: 99px;
  cursor: pointer; white-space: nowrap; font-family: inherit;
  letter-spacing: -0.005em;
  text-align: center;
  transition: background .13s, box-shadow .13s, color .13s;
}
.ach-claim-btn:hover {
  background: rgba(76,217,100,0.22);
  box-shadow: inset 0 0 0 1px rgba(76,217,100,0.4);
  color: #6fe07e;
}
.ach-claim-btn:active { background: rgba(76,217,100,0.3); }
.ach-claim-btn:disabled { opacity: 0.5; cursor: wait; }

/* ── Poster preview: шапка внутри модалки ── */
.gm-modal .profile-header_frame {
  pointer-events: none; user-select: none;
  margin-bottom: 0 !important; flex-shrink: 0;
}
.profile-header_frame.poster.izuna { background-image: url(/img/headers/izuna.webp); }
.gm-skeleton {
  display: inline-block; border-radius: 3px;
  background: rgba(255,255,255,0.10); color: transparent;
  animation: gmSkeletonPulse 1.5s ease-in-out infinite;
}
@keyframes gmSkeletonPulse { 0%, 100% { opacity: 0.4; } 50% { opacity: 0.9; } }

/* ── Shop modal layout ── */
.gm-shop-body { display: flex; flex: 1; overflow: hidden; }

.gm-shop-sidebar {
  width: 196px; flex-shrink: 0; padding: 16px 14px;
  border-right: 1px solid rgba(255,255,255,0.05);
  display: flex; flex-direction: column; gap: 3px;
}
.gm-shop-nav-btn {
  position: relative;
  display: flex; align-items: center; gap: 11px;
  padding: 9px 12px; border-radius: 9px; cursor: pointer;
  font-size: 14px; font-weight: 500; color: rgba(200,190,230,0.55);
  transition: background .13s, color .13s, box-shadow .13s;
  border: none; background: none;
  font-family: inherit; width: 100%; text-align: left;
}
.gm-shop-nav-btn:hover { background: rgba(255,255,255,0.04); color: rgba(200,190,230,0.85); }
.gm-shop-nav-btn.active {
  background: rgba(255,255,255,0.05);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07);
  color: rgba(255,255,255,0.9);
}
.gm-shop-nav-btn.active::before {
  content: ''; position: absolute; left: 4px; top: 10px; bottom: 10px;
  width: 2px; border-radius: 2px;
  background: linear-gradient(180deg, #6e42c8, #c4aeff);
}
.gm-shop-nav-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.gm-nav-icon {
  width: 32px; height: 32px; border-radius: 9px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; background: rgba(255,255,255,0.03);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05);
  color: rgba(200,190,230,0.6);
}
.gm-shop-nav-btn.active .gm-nav-icon {
  color: rgba(255,255,255,0.9);
}
.gm-nav-soon {
  font-size: 10px; color: rgba(200,190,230,0.3);
  font-weight: 400; letter-spacing: 0.04em; text-transform: uppercase;
  display: block; margin-top: 1px;
}

/* ── Shop main ── */
.gm-shop-main { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-width: 0; }

/* ── Poster action button ── */
.gm-action-btn {
  padding: 7px 16px; border-radius: 8px; font-size: 12.5px;
  font-weight: 600; font-family: inherit; cursor: pointer;
  transition: background .15s, box-shadow .15s, color .15s;
  border: none; white-space: nowrap;
}
.gm-action-btn--activate,
.gm-action-btn--free {
  background: rgba(50,215,75,0.10); color: #4cd964;
  box-shadow: inset 0 0 0 1px rgba(50,215,75,0.28);
}
.gm-action-btn--activate:hover,
.gm-action-btn--free:hover {
  background: rgba(50,215,75,0.18);
  box-shadow: inset 0 0 0 1px rgba(50,215,75,0.4);
}
.gm-action-btn--cancel {
  background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.6);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07);
}
.gm-action-btn--cancel:hover {
  background: rgba(255,255,255,0.08);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.12);
}
.gm-action-btn--buy {
  background: rgba(159,110,255,0.10); color: #c4aeff;
  box-shadow: inset 0 0 0 1px rgba(159,110,255,0.28);
}
.gm-action-btn--buy:hover {
  background: rgba(159,110,255,0.18);
  box-shadow: inset 0 0 0 1px rgba(159,110,255,0.4);
}
.gm-action-btn--active {
  background: rgba(50,215,75,0.07); color: rgba(76,217,100,0.6);
  box-shadow: inset 0 0 0 1px rgba(50,215,75,0.2);
  cursor: default;
}
.gm-action-btn--locked {
  background: rgba(255,255,255,0.03); color: rgba(200,190,230,0.25);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05);
  cursor: not-allowed;
}

/* ── Poster requirements panel ── */
.gm-poster-detail {
  flex-shrink: 0; padding: 12px 18px 10px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.gm-poster-detail__head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 10px;
}
.gm-poster-detail__name {
  font-size: 15px; font-weight: 600; color: #f2f0f7; flex: 1;
}
.gm-poster-detail__reqs { display: flex; flex-direction: column; gap: 7px; }
.gm-pd-req {
  display: flex; flex-direction: column; gap: 4px;
}
.gm-pd-req__label {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px; color: rgba(200,190,230,0.6);
}
.gm-pd-req__pct { font-size: 11px; color: rgba(200,190,230,0.45); }
.gm-pd-req__ok  { font-size: 11px; color: rgba(76,217,100,0.7); font-weight: 500; }
.gm-pd-req__track {
  height: 3px; background: rgba(255,255,255,0.05); border-radius: 99px; overflow: hidden;
}
.gm-pd-req__fill {
  height: 100%; border-radius: 99px;
  background: linear-gradient(90deg, rgba(200,190,230,0.35) 0%, rgba(200,190,230,0.5) 100%);
  transition: width .5s cubic-bezier(.4,0,.2,1);
}
.gm-pd-req__fill--done {
  background: linear-gradient(90deg, rgba(50,180,80,0.55) 0%, rgba(76,217,100,0.7) 100%);
}
.gm-pd-req__link {
  font-size: 11px; color: rgba(159,110,255,0.7); text-decoration: none;
  display: inline-block; margin-top: 2px;
  transition: color .14s;
}
.gm-pd-req__link:hover { color: #c4aeff; }
.gm-poster-detail--no-reqs {
  display: flex; align-items: center; gap: 12px;
}

/* ── Poster scroll area ── */
.gm-content-scroll {
  flex: 1; overflow-y: auto; padding: 14px 16px 18px;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.07) transparent;
}
.gm-content-scroll::-webkit-scrollbar { width: 4px; }
.gm-content-scroll::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.07); border-radius: 99px; }

.gm-section-label {
  font-size: 14px; font-weight: 600; letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.25); margin: 12px 0 8px 2px;
}
.gm-section-label:first-child { margin-top: 0; }

.gm-poster-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px; margin-bottom: 2px;
}

.gm-poster-item {
  border-radius: 12px; overflow: hidden; cursor: pointer;
  border: 1.5px solid rgba(255,255,255,0.06);
  background: #18161b; transition: border-color .14s, transform .14s;
}
.gm-poster-item:hover { border-color: rgba(255,255,255,0.13); transform: translateY(-2px); }
.gm-poster-item.gm-pi--selected { border-color: rgba(159,110,255,0.65); }
.gm-poster-item.gm-pi--active   { border-color: rgba(50,215,75,0.45); }
.gm-poster-item.gm-pi--locked   { opacity: 1; }
.gm-poster-item.gm-pi--pending  { opacity: 0.75; }

/* Индикатор проверки условий в заголовке секции */
.gm-section-checking {
  font-size: 11px; font-weight: 400; color: rgba(255,255,255,0.35);
  margin-left: 8px; display: inline-flex; align-items: center; gap: 5px;
}
.gm-dot-pulse {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(159,110,255,0.7);
  animation: gmDotPulse 1.2s ease-in-out infinite;
  display: inline-block;
}
@keyframes gmDotPulse {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50%       { opacity: 1;   transform: scale(1.2); }
}

/* Значок «не известно» для pending-постеров */
.gm-pi-badge--pending {
  color: rgba(255,255,255,0.35); background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
}

.gm-poster-item__img {
    width: 100%; aspect-ratio: 21/9; object-fit: cover; display: block;
    object-position: top right;
}
.gm-poster-item__ph {
  width: 100%; aspect-ratio: 21/9; display: flex; align-items: center;
  justify-content: center; background: linear-gradient(135deg, #1a1428 0%, #22193a 100%);
  color: rgba(255,255,255,0.07); font-size: 26px;
}
.gm-poster-item__foot {
  padding: 7px 10px 9px; display: flex; align-items: center;
  justify-content: space-between; gap: 6px;
}
.gm-poster-item__name {
  font-size: 13px; font-weight: 500; color: rgba(200,190,230,0.8);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1;
}
.gm-pi-badge { font-size: 12px; font-weight: 500; white-space: nowrap; flex-shrink: 0; }
.gm-pi-badge--active { color: #32d74b; }
.gm-pi-badge--price  { color: #c8a83a; }
.gm-pi-badge--locked { color: rgba(200,190,230,0.22); }

/* Badge img inside span */
.user-badge-img { width: 100%; height: 100%; object-fit: contain; border-radius: inherit; display: block; }

/* ── Badge shop grid ── */
.gm-badge-shop { display: flex; flex-direction: column; padding-bottom: 72px; }

.gm-badge-shopbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 4px 0 14px; gap: 12px;
}
.gm-badge-shopbar__balance { font-size: 12px; color: rgba(255,255,255,0.45); }
.gm-badge-shopbar__balance strong { color: #c9a227; }
.gm-badge-shopbar__count { font-size: 11px; color: rgba(255,255,255,0.28); }

/* Grid */
.gm-badge-grid2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

/* Card */
.gm-badge-card {
  display: flex; flex-direction: column; align-items: center;
  gap: 8px; padding: 18px 10px 14px;
  background: rgba(0, 0, 0, 0.05);
  border: 1.5px solid rgba(255,255,255,0.07);
  border-radius: 16px; cursor: pointer; text-align: center;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
  position: relative; user-select: none;
}
.gm-badge-card:hover { background: rgba(255,255,255,0.09); }
/* Примеривается, но не установлен */
.gm-badge-card--preview {
    border-color: rgb(255 255 255 / 12%) !important;
    background: rgb(255 255 255 / 3%) !important;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.15);
}
/* Установлен на сервере */
.gm-badge-card--installed {
  box-shadow: 0 0 0 2px var(--bc, #7b1dff), 0 4px 16px rgba(0,0,0,0.3);
}
/* Заблокирован (ачивка не получена) */
.gm-badge-card--locked { opacity: 0.55; cursor: default; }
.gm-badge-card--locked:hover { background: rgba(255,255,255,0.05); }
/* Eligible — ачивка получена, значок ещё не куплен */
.gm-badge-card--eligible { cursor: default; }
.gm-badge-card--eligible:hover { background: rgba(255,255,255,0.06); }
/* Карточка "Без значка" */
.gm-badge-card--empty { border-style: dashed; }

.gm-badge-card__icon {
  width: 52px; height: 52px; border-radius: 13px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; line-height: 1;
  transition: transform 0.15s;
}
.gm-badge-card:hover:not(.gm-badge-card--locked) .gm-badge-card__icon { transform: scale(1.08); }
.gm-badge-card__icon img { width: 100%; height: 100%; object-fit: contain; border-radius: 11px; }

.gm-badge-card__name {
  font-size: 16px; font-weight: 600;
  color: rgba(255,255,255,0.88); line-height: 1.3;
}
.gm-badge-card--locked .gm-badge-card__name { color: rgba(255,255,255,0.45); }

.gm-badge-card__cond {
    font-size: 12px;
    color: rgb(255 255 255 / 46%);
    line-height: 1.35;
}

/* Статус-чип */
.gm-badge-chip {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 9px; font-weight: 700; padding: 2px 7px;
  border-radius: 99px; letter-spacing: 0.02em; margin-top: 2px;
}
.gm-badge-chip--on  { background: rgba(50,215,75,0.15); color: #32d74b; }
.gm-badge-chip--try { background: rgba(255,255,255,0.12); color: rgba(255,255,255,0.7); }
.gm-badge-chip--buy { background: rgba(201,162,39,0.15); color: #c9a227; }

/* Кнопка покупки внутри карточки */
.gm-badge-card__buy {
  margin-top: 4px; padding: 5px 10px;
  background: rgba(159,110,255,0.15); color: rgba(159,110,255,0.95);
  border: 1px solid rgba(159,110,255,0.25); border-radius: 7px;
  font-size: 10px; font-weight: 700; cursor: pointer;
  font-family: inherit; white-space: nowrap;
  transition: background 0.15s; line-height: 1;
}
.gm-badge-card__buy:hover { background: rgba(159,110,255,0.28); }
.gm-badge-card__buy:disabled { opacity: 0.4; cursor: default; }

/* Action bar (снизу, sticky) */
.gm-badge-action {
  border-top: 1px solid rgba(255,255,255,0.09);
  padding-top: 16px; margin-top: 16px;
  display: flex; align-items: center; gap: 10px;
}
.gm-badge-action__info { flex: 1; min-width: 0; }
.gm-badge-action__name { font-size: 13px; font-weight: 600; }
.gm-badge-action__hint { font-size: 11px; color: rgba(255,255,255,0.38); margin-top: 1px; }

@media (max-width: 600px) {
  .gm-shop-sidebar { display: none; }
  .gm-modal--shop { border-radius: 0 0 20px 20px; max-height: none; }
  .gm-shop-body { overflow: visible; }
  .gm-shop-main { overflow: visible; }
  .gm-content-scroll { overflow-y: visible; }
  .gm-overlay--shop { overflow-y: auto; align-items: flex-start; padding: 0 0 24px; }
  .gm-poster-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-gm-bar { padding: 11px 14px; gap: 14px; margin: 24px 0 0; }
  .pgb-meta { min-width: 48px; padding-right: 14px; }
  .pgb-meta__num { font-size: 24px; }
  .pgb-progress__next { display: none; }
  .pgb-ach-btn { padding: 8px 10px 8px 13px; font-size: 12px; }
}
