/* Витрина мгновенных ключей ПК-игр (/category/pc-game-keys) */

.pk-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Компактная плашка преимуществ под баннером */
.pk-trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.pk-trust-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.09);
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  white-space: nowrap;
}
.pk-trust-chip i {
  color: #38bdf8;
  font-size: 13px;
}
.pk-trust-chip--green i { color: #34d399; }
.pk-trust-chip--violet i { color: #a78bfa; }

/* Панель поиска, фильтров и сортировки */
.pk-toolbar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(18, 22, 38, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.09);
}

.pk-toolbar-top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.pk-search-box {
  position: relative;
  flex: 1 1 260px;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.pk-search-box:focus-within {
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.18);
  background: rgba(255, 255, 255, 0.1);
}
.pk-search-box > i {
  position: absolute;
  left: 13px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 14px;
  pointer-events: none;
}
.pk-search-input {
  width: 100%;
  background: transparent;
  border: 0;
  outline: 0;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 11px 36px 11px 38px;
}
.pk-search-input::placeholder {
  color: rgba(255, 255, 255, 0.48);
  font-weight: 500;
}
.pk-search-clear {
  position: absolute;
  right: 8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}
.pk-search-clear.visible { display: inline-flex; }

.pk-sort-select-wrap {
  position: relative;
  flex: 0 0 auto;
}
.pk-sort-select {
  appearance: none;
  -webkit-appearance: none;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 11px 34px 11px 14px;
  cursor: pointer;
  outline: none;
}
.pk-sort-select option {
  background: #14182b;
  color: #fff;
}
.pk-sort-select:focus {
  border-color: #7c3aed;
}
.pk-sort-select-wrap i {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.65);
}

/* Ряды фильтров: регион и платформа */
.pk-filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pk-filter-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.5);
  margin-right: 2px;
  white-space: nowrap;
}
.pk-pills {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.pk-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.11);
  color: rgba(255, 255, 255, 0.8);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.pk-pill:hover {
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(255, 255, 255, 0.24);
  color: #fff;
}
.pk-pill.active {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.24), rgba(124, 58, 237, 0.30));
  border-color: rgba(56, 189, 248, 0.65);
  color: #fff;
}
.pk-pill-cnt {
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.85);
}
.pk-pill.active .pk-pill-cnt {
  background: rgba(56, 189, 248, 0.32);
  color: #fff;
}
.pk-pill--cis.active {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.65);
}
.pk-pill--ru.active {
  background: rgba(16, 185, 129, 0.2);
  border-color: rgba(16, 185, 129, 0.65);
}

/* Статус-строка с количеством найденных игр */
.pk-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.65);
}
.pk-meta-bar strong { color: #fff; }
.pk-reset-btn {
  display: none;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #cbd5e1;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.pk-reset-btn.visible { display: inline-flex; }
.pk-reset-btn:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }

/* Сетка карточек игр */
.pk-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
@media (max-width: 1180px) {
  .pk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .pk-grid { grid-template-columns: 1fr; gap: 12px; }
}

/* Карточка игры */
.pk-card {
  display: flex;
  flex-direction: column;
  background: rgba(20, 24, 42, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 15px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}
.pk-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.38);
}
.pk-card.selected {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.35), 0 12px 28px rgba(56, 189, 248, 0.16);
}

/* Обложка 460x215 (нативное соотношение Steam header) */
.pk-cover-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 460 / 215;
  background: linear-gradient(135deg, #162244, #2b1854);
  overflow: hidden;
}
.pk-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pk-cover-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-align: center;
  background: radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.25), transparent 55%),
              linear-gradient(135deg, #132042 0%, #2a1756 100%);
  color: #fff;
}
.pk-cover-fallback i {
  font-size: 28px;
  color: #38bdf8;
  margin-bottom: 6px;
  opacity: 0.9;
}
.pk-cover-fallback span {
  font-size: 13px;
  font-weight: 800;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 90%;
}

/* Бейджи поверх обложки */
.pk-badge-plat {
  position: absolute;
  top: 8px;
  left: 8px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: 7px;
  background: rgba(10, 14, 26, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2px;
}
.pk-badge-plat--steam i { color: #66c0f4; }
.pk-badge-plat--ea i { color: #ff5a5f; }
.pk-badge-plat--rockstar i { color: #fbbf24; }
.pk-badge-plat--ubisoft i { color: #60a5fa; }
.pk-badge-plat--epic i { color: #e2e8f0; }

.pk-badge-disc {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 4px 8px;
  border-radius: 7px;
  background: #10b981;
  color: #031f16;
  font-size: 11.5px;
  font-weight: 900;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.4);
}

/* Тело карточки */
.pk-body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  padding: 12px 13px 13px;
  gap: 8px;
}
.pk-title {
  font-size: 14px;
  font-weight: 800;
  color: #fff;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
}

.pk-tags-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
}
.pk-reg-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
}
.pk-reg-badge--ru {
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #6ee7b7;
}
.pk-reg-badge--global {
  background: rgba(56, 189, 248, 0.16);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: #7dd3fc;
}
.pk-reg-badge--cis {
  background: rgba(245, 158, 11, 0.16);
  border: 1px solid rgba(245, 158, 11, 0.42);
  color: #fcd34d;
}
.pk-stock {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.52);
  white-space: nowrap;
}

.pk-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.pk-prices {
  display: flex;
  align-items: baseline;
  gap: 7px;
  flex-wrap: wrap;
}
.pk-price {
  font-size: 17px;
  font-weight: 900;
  color: #fff;
  font-family: 'JetBrains Mono', 'Inter', monospace;
  white-space: nowrap;
}
.pk-rrp {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.42);
  text-decoration: line-through;
  white-space: nowrap;
}
.pk-buy-btn {
  flex: 0 0 auto;
  padding: 8px 13px;
  border-radius: 10px;
  border: 0;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #fff;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 800;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.12s ease;
  white-space: nowrap;
}
.pk-buy-btn:hover { opacity: 0.92; }
.pk-card.selected .pk-buy-btn {
  background: linear-gradient(135deg, #059669, #10b981);
}

/* Кнопка «Показать ещё» */
.pk-more-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}
.pk-more-btn {
  padding: 12px 26px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}
.pk-more-btn:hover {
  background: rgba(56, 189, 248, 0.18);
  border-color: rgba(56, 189, 248, 0.55);
}
.pk-more-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* Пустое состояние поиска */
.pk-empty {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 44px 20px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.14);
  gap: 8px;
}
.pk-empty.visible { display: flex; }
.pk-empty i { font-size: 30px; color: rgba(255, 255, 255, 0.4); }
.pk-empty-title { font-size: 16px; font-weight: 800; color: #fff; }
.pk-empty-sub { font-size: 13px; color: rgba(255, 255, 255, 0.6); }

/* Плашка региона в сайдбаре оформления */
.pk-sidebar-region-note {
  margin: 0 0 10px;
  padding: 9px 11px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.45;
  font-weight: 600;
  display: none;
}
.pk-sidebar-region-note.is-ru {
  display: block;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #a7f3d0;
}
.pk-sidebar-region-note.is-global {
  display: block;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #bae6fd;
}
.pk-sidebar-region-note.is-cis {
  display: block;
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fde68a;
}

/* Мобильная адаптация 375px без горизонтального переполнения */
@media (max-width: 768px) {
  .pk-toolbar { padding: 12px; gap: 10px; }
  .pk-search-box { flex: 1 1 100%; }
  .pk-sort-select-wrap { width: 100%; }
  .pk-sort-select { width: 100%; }
  .pk-search-input { font-size: 16px; }
  .pk-filter-row { flex-direction: column; align-items: flex-start; gap: 6px; }
  .pk-pills {
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .pk-pills::-webkit-scrollbar { display: none; }
  .pk-trust-strip {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .pk-trust-strip::-webkit-scrollbar { display: none; }
}
