body.modal-open {
  overflow: hidden;
}

.gp-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  min-height: 100vh;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: #e0e0e0;
}

/* Shared input styles (from cheater-checker.css) */
.steam-input {
  flex: 1;
  min-width: 200px;
  padding: 12px 20px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 25px;
  font-size: 14px;
  outline: none;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.08);
  color: #e0e0e0;
}

.steam-input:focus {
  border-color: #667eea;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.steam-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.input-clear-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 200px;
}

.input-clear-wrapper .steam-input {
  flex: 1;
  min-width: 0;
  padding-right: 38px;
}

.input-clear-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.6);
  border-radius: 50%;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
  padding: 0;
  flex-shrink: 0;
}

.input-clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  color: white;
}

.input-clear-btn.visible {
  display: flex;
}

/* Modal overlay (shared) */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
}

/* Back button (shared) */
.back-btn {
  color: white;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.15);
  transition: all 0.3s ease;
}

.back-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateX(-3px);
}

.header-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 25px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 15px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}

.gp-header h1 {
  color: white;
  font-size: 1.5rem;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.gp-settings-bar {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.gp-setting {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gp-setting label {
  font-size: 0.9em;
  color: rgba(255,255,255,0.8);
}

.gp-setting select {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.1);
  color: #e0e0e0;
  font-size: 0.9em;
  cursor: pointer;
  backdrop-filter: blur(5px);
}

.gp-setting select option {
  background: #1a1a2e;
  color: #e0e0e0;
}

/* Tabs */
.gp-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 2px solid rgba(255,255,255,0.15);
  padding-bottom: 0;
}

.gp-tab {
  padding: 10px 20px;
  border: none;
  background: transparent;
  color: rgba(255,255,255,0.7);
  font-size: 1em;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  transition: all 0.2s;
  font-weight: 500;
}

.gp-tab:hover {
  color: rgba(255,255,255,0.9);
  border-bottom-color: rgba(102,126,234,0.5);
}

.gp-tab.active {
  color: #667eea;
  border-bottom-color: #667eea;
}

/* Sub-tabs (Популярные / Недавно просмотренные) */
.gp-subtabs {
  display: flex;
  gap: 4px;
  margin-bottom: 14px;
}

.gp-subtab {
  padding: 7px 16px;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  background: transparent;
  color: rgba(255,255,255,0.5);
  font-size: 0.85em;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.gp-subtab:hover {
  color: rgba(255,255,255,0.8);
  background: rgba(255,255,255,0.05);
}

.gp-subtab.active {
  color: #e0e0e0;
  background: rgba(102,126,234,0.2);
  border-color: rgba(102,126,234,0.4);
}

.gp-subtab-content {
  display: none;
}

.gp-subtab-content.active {
  display: block;
}

.gp-tab-content {
  display: none;
}

.gp-tab-content.active {
  display: block;
}

/* Search */
.gp-search-section {
  margin-bottom: 16px;
}

.gp-filters {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.gp-filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gp-filter-group label {
  font-size: 0.85em;
  color: rgba(255,255,255,0.7);
}

.gp-filter-group select {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.1);
  color: #e0e0e0;
  font-size: 0.85em;
  cursor: pointer;
  backdrop-filter: blur(5px);
}

.gp-filter-group select option {
  background: #1a1a2e;
  color: #e0e0e0;
}

/* Section title */
.gp-section-title {
  font-size: 1em;
  margin: 0 0 12px 0;
  color: rgba(255,255,255,0.8);
  font-weight: 600;
}

/* Games grid */
.gp-games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

/* Game card */
.gp-game-card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid rgba(255,255,255,0.1);
}

.gp-game-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

.gp-game-card-poster {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  display: block;
}

.gp-game-card-info {
  padding: 10px;
}

.gp-game-card-title {
  font-size: 0.9em;
  font-weight: 600;
  margin: 0 0 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: #e0e0e0;
}

.gp-game-card-discount {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #e53935;
  color: white;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.75em;
  font-weight: 700;
}

/* Favorite button */
.gp-fav-btn {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,0.5);
  color: rgba(255,255,255,0.5);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  z-index: 2;
  backdrop-filter: blur(4px);
}

.gp-fav-btn:hover {
  background: rgba(0,0,0,0.7);
  color: #ffd700;
}

.gp-fav-btn.active {
  color: #ffd700;
  text-shadow: 0 0 8px rgba(255,215,0,0.5);
}

/* Price badge on card */
.gp-card-price {
  position: absolute;
  bottom: 50px;
  right: 10px;
  background: rgba(0,0,0,0.7);
  color: #4caf50;
  font-weight: 700;
  font-size: 0.85em;
  padding: 4px 10px;
  border-radius: 8px;
  z-index: 2;
  backdrop-filter: blur(4px);
}

.gp-card-price-empty {
  color: #4caf50;
  font-size: 0.8em;
}

.gp-fav-btn-lg {
  width: 40px;
  height: 40px;
  font-size: 24px;
  position: static;
  margin-top: 8px;
}

/* Skeleton */
.gp-skeleton-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}

.gp-skeleton-card {
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.05);
}

.gp-skeleton-card::before {
  content: '';
  display: block;
  width: 100%;
  aspect-ratio: 3/4;
  background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
  background-size: 200% 100%;
  animation: gp-shimmer 1.5s infinite;
}

.gp-skeleton-card::after {
  content: '';
  display: block;
  height: 40px;
  margin: 10px;
  border-radius: 6px;
  background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
  background-size: 200% 100%;
  animation: gp-shimmer 1.5s infinite;
}

@keyframes gp-shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Empty state */
.gp-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: rgba(255,255,255,0.5);
  font-size: 1em;
}

/* Game modal */
.gp-game-modal {
  background: #1a1a2e;
  border-radius: 16px;
  max-width: 1000px;
  width: 95%;
  max-height: 90vh;
  overflow-y: auto;
  margin: 5vh auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.1);
  position: relative;
}

.gp-game-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  position: sticky;
  top: 0;
  background: #1a1a2e;
  z-index: 10;
  border-radius: 16px 16px 0 0;
}

.gp-game-modal-header h2 {
  margin: 0;
  font-size: 1.2em;
}

.gp-game-modal-body {
  padding: 20px;
  color: #e0e0e0;
  position: relative;
}

.gp-game-modal-body::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--poster-bg, none);
  background-size: cover;
  background-position: center;
  filter: blur(30px) brightness(0.4);
  z-index: 0;
  border-radius: 0 0 16px 16px;
}

.gp-game-modal-body > * {
  position: relative;
  z-index: 1;
}

.gp-game-poster-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

.gp-game-poster {
  max-width: 400px;
  max-height: 400px;
  object-fit: contain;
  border-radius: 12px;
  display: block;
  margin: 0 auto;
}

.gp-game-meta {
  margin-bottom: 16px;
  font-size: 0.9em;
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
}

/* Screenshots / Store links slider */
.gp-game-screenshots {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 8px 0;
  margin-bottom: 16px;
  scrollbar-width: thin;
  flex-wrap: wrap;
}

.gp-game-screenshots::-webkit-scrollbar {
  height: 6px;
}

.gp-game-screenshots::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.2);
  border-radius: 3px;
}

.gp-store-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 12px 16px;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  text-decoration: none;
  color: #e0e0e0;
  transition: all 0.2s;
}

.gp-store-link:hover {
  background: rgba(102,126,234,0.15);
  border-color: rgba(102,126,234,0.4);
  transform: translateY(-2px);
}

.gp-store-name {
  font-weight: 600;
  font-size: 0.9em;
  margin-bottom: 4px;
}

.gp-store-price {
  font-size: 1.1em;
  font-weight: 700;
  color: #4caf50;
}

.gp-store-buy {
  font-size: 0.8em;
  color: #667eea;
}

/* Prices table */
.gp-game-prices {
  margin-bottom: 16px;
}

.gp-prices-title {
  font-size: 0.95em;
  font-weight: 600;
  margin: 0 0 8px;
  color: #e0e0e0;
}

.gp-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  margin-bottom: 4px;
  font-size: 0.9em;
  border: 1px solid rgba(255,255,255,0.05);
}

.gp-price-row:hover {
  background: rgba(255,255,255,0.08);
}

.gp-price-platform {
  opacity: 0.7;
  font-size: 0.85em;
}

.gp-price-value {
  font-weight: 700;
  color: #4caf50;
}

.gp-price-discount {
  background: #e53935;
  color: white;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.8em;
  font-weight: 600;
  margin-left: 8px;
}

.gp-price-link {
  color: #667eea;
  text-decoration: none;
  font-size: 0.85em;
}

.gp-price-link:hover {
  text-decoration: underline;
}

/* Chart */
.gp-game-chart {
  margin-bottom: 16px;
}

.gp-chart-title {
  font-size: 0.95em;
  font-weight: 600;
  margin: 0 0 8px;
  color: #e0e0e0;
}

.gp-chart-canvas {
  width: 100%;
  height: 120px;
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
}

/* Actions */
.gp-game-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.gp-share-btn {
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.1);
  color: #e0e0e0;
  cursor: pointer;
  font-size: 0.9em;
  transition: background 0.2s;
}

.gp-share-btn:hover {
  background: rgba(255,255,255,0.2);
}

.gp-hg-link {
  color: #667eea;
  text-decoration: none;
  font-size: 0.9em;
}

.gp-hg-link:hover {
  text-decoration: underline;
}

/* Toast */
.gp-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.85);
  color: white;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.9em;
  z-index: 9999;
  backdrop-filter: blur(8px);
}

/* Pagination */
.gp-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  margin: 16px 0;
}

.gp-page-btn {
  padding: 6px 12px;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 6px;
  background: transparent;
  color: rgba(255,255,255,0.6);
  font-size: 0.85em;
  cursor: pointer;
  transition: all 0.2s;
}

.gp-page-btn:hover:not(:disabled) {
  color: #e0e0e0;
  background: rgba(255,255,255,0.08);
}

.gp-page-btn.active {
  color: #667eea;
  border-color: rgba(102,126,234,0.5);
  background: rgba(102,126,234,0.15);
}

.gp-page-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.gp-page-ellipsis {
  color: rgba(255,255,255,0.4);
  padding: 0 4px;
}

/* Responsive */
@media (max-width: 600px) {
  .gp-games-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 8px;
  }

  .gp-settings-bar {
    flex-direction: column;
    gap: 8px;
  }

  .gp-filters {
    flex-direction: column;
    gap: 8px;
  }

  .gp-game-modal {
    width: 100%;
    max-width: 100%;
    max-height: 100vh;
    border-radius: 0;
    margin: 0;
  }

  .gp-game-poster {
    max-width: 250px;
    max-height: 250px;
  }

  .gp-screenshot {
    min-width: 160px;
    height: 100px;
  }
}
