/* Rival Gaming - Page Styles */
:root {
  --rg-purple: #8b5cf6;
  --rg-purple-dark: #7c3aed;
  --rg-purple-deep: #6d28d9;
  --rg-purple-light: #a855f7;
  --rg-purple-glow: rgba(139,92,246,0.15);
  --rg-cyan: #00e5ff;
  --rg-bg: #0f1118;
  --rg-card: rgba(255,255,255,0.03);
  --rg-card-border: rgba(255,255,255,0.06);
  --rg-card-hover: rgba(139,92,246,0.15);
  --rg-text: #e2e8f0;
  --rg-text-dim: rgba(255,255,255,0.5);
  --rg-text-muted: rgba(255,255,255,0.3);
  --rg-warning: #f59e0b;
  --rg-error: #ef4444;
  --rg-success: #10b981;
  --rg-info: #3b82f6;
}

/* Hide forum-specific chrome on RG pages */
.rg-page .p-body-header,
.rg-page .p-breadcrumbs,
.rg-page .block-minorHeader,
.rg-page .p-body-sideNav { display: none; }
.rg-page .p-body-main { padding: 0; }
.rg-page .p-body-content { max-width: 100%; }
.rg-page .p-body-inner { display: block; }
.rg-page .p-body-pageContent { padding: 0; }

/* Base page container */
.rg-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px;
  color: var(--rg-text);
}

/* Glass panel */
.rg-glass {
  background: var(--rg-card);
  border: 1px solid var(--rg-card-border);
  border-radius: 16px;
  backdrop-filter: blur(16px);
}
.rg-glass:hover {
  border-color: rgba(139,92,246,0.2);
  box-shadow: 0 0 20px rgba(139,92,246,0.08);
}

/* Stat card */
.rg-stat {
  background: var(--rg-card);
  border: 1px solid var(--rg-card-border);
  border-radius: 12px;
  padding: 16px;
  transition: all 0.3s;
}
.rg-stat:hover {
  transform: scale(1.02);
  border-color: rgba(139,92,246,0.2);
}
.rg-stat-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}
.rg-stat-value {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.rg-stat-label {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255,255,255,0.6);
}
.rg-stat-sub {
  font-size: 10px;
  color: var(--rg-text-muted);
}

/* Section heading */
.rg-heading {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  background: linear-gradient(90deg, rgba(139,92,246,0.6), rgba(168,85,247,0.4));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

/* Grid layouts */
.rg-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.rg-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.rg-grid-4 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 640px) { .rg-grid-4 { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 768px) { .rg-grid-5 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) {
  .rg-grid-5 { grid-template-columns: repeat(5, 1fr); }
}

/* Game card */
.rg-game-card {
  background: var(--rg-card);
  border: 1px solid var(--rg-card-border);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s;
}
.rg-game-card:hover {
  transform: scale(1.03);
  border-color: rgba(139,92,246,0.3);
  box-shadow: 0 0 20px rgba(139,92,246,0.15);
}
.rg-game-card img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
}
.rg-game-card-info {
  padding: 10px;
}
.rg-game-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--rg-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rg-game-card-meta {
  font-size: 11px;
  color: var(--rg-text-dim);
  margin-top: 2px;
}

/* Button styles */
.rg-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  color: white;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
}
.rg-btn-primary {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed, #6d28d9);
  box-shadow: 0 4px 20px rgba(139,92,246,0.4);
}
.rg-btn-primary:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 30px rgba(139,92,246,0.5);
}
.rg-btn-ghost {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--rg-text-dim);
}
.rg-btn-ghost:hover {
  background: rgba(255,255,255,0.08);
  color: var(--rg-text);
}
.rg-btn-sm {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 8px;
}

/* Hero banner */
.rg-hero {
  position: relative;
  overflow: hidden;
  padding: 20px;
  background: linear-gradient(160deg, rgba(139,92,246,0.15) 0%, rgba(109,40,217,0.08) 50%, transparent 100%);
  border-bottom: 1px solid rgba(139,92,246,0.15);
}
.rg-hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: rgFloat 6s ease-in-out infinite;
}
@keyframes rgFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

/* Pill badge */
.rg-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  backdrop-filter: blur(8px);
}

/* Shimmer animation */
@keyframes rgShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
.rg-shimmer {
  background: linear-gradient(90deg, #7c3aed, #a855f7, #c084fc, #a855f7);
  background-size: 200% 100%;
  animation: rgShimmer 3s ease-in-out infinite;
}

/* Pulse dot */
.rg-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--rg-success);
  animation: pulse 2s cubic-bezier(0.4,0,0.6,1) infinite;
}

/* List item row */
.rg-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  transition: all 0.2s;
  cursor: pointer;
}
.rg-list-item:hover {
  background: rgba(255,255,255,0.03);
}

/* Table styles */
.rg-table {
  width: 100%;
  border-collapse: collapse;
}
.rg-table th {
  text-align: left;
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--rg-text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--rg-card-border);
}
.rg-table td {
  padding: 10px 12px;
  font-size: 13px;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}
.rg-table tr:hover td {
  background: rgba(255,255,255,0.02);
}

/* Status badges */
.rg-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}
.rg-badge-working { background: rgba(16,185,129,0.12); color: #10b981; border: 1px solid rgba(16,185,129,0.2); }
.rg-badge-testing { background: rgba(245,158,11,0.12); color: #f59e0b; border: 1px solid rgba(245,158,11,0.2); }
.rg-badge-outdated { background: rgba(239,68,68,0.12); color: #ef4444; border: 1px solid rgba(239,68,68,0.2); }
.rg-badge-admin { background: rgba(250,204,21,0.12); color: #facc15; border: 1px solid rgba(250,204,21,0.2); }
.rg-badge-ultimate { background: linear-gradient(135deg, rgba(139,92,246,0.2), rgba(168,85,247,0.15)); color: #c084fc; border: 1px solid rgba(139,92,246,0.3); }
.rg-badge-pro { background: rgba(59,130,246,0.12); color: #60a5fa; border: 1px solid rgba(59,130,246,0.2); }

/* Search input */
.rg-search {
  width: 100%;
  padding: 10px 16px 10px 40px;
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--rg-text);
  font-size: 14px;
  outline: none;
  transition: all 0.3s;
}
.rg-search:focus {
  border-color: rgba(139,92,246,0.4);
  box-shadow: 0 0 20px rgba(139,92,246,0.1);
}
.rg-search::placeholder {
  color: var(--rg-text-muted);
}

/* Tabs */
.rg-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  overflow-x: auto;
}
.rg-tab {
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  color: var(--rg-text-dim);
  background: transparent;
  border: 1px solid transparent;
  transition: all 0.2s;
  white-space: nowrap;
}
.rg-tab:hover { background: rgba(255,255,255,0.04); }
.rg-tab.active {
  background: rgba(139,92,246,0.15);
  border-color: rgba(139,92,246,0.3);
  color: #c084fc;
}

/* Loading spinner */
.rg-spinner {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(139,92,246,0.2);
  border-top-color: var(--rg-purple);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.rg-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 12px;
  color: var(--rg-text-dim);
  font-size: 14px;
}

/* Responsive - Tablet */
@media (max-width: 900px) {
  .rg-grid-5 { grid-template-columns: repeat(3, 1fr); }
  .rg-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .rg-table th:nth-child(n+4),
  .rg-table td:nth-child(n+4) { display: none; }
}

/* Responsive - Mobile */
@media (max-width: 640px) {
  .rg-container { padding: 10px; }
  .rg-hero { padding: 14px; }
  .rg-stat-value { font-size: 18px; }
  .rg-stat-label { font-size: 11px; }
  .rg-stat { padding: 12px; }
  .rg-grid-2 { grid-template-columns: 1fr; }
  .rg-grid-3 { grid-template-columns: 1fr; }
  .rg-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .rg-grid-5 { grid-template-columns: repeat(2, 1fr); }
  .rg-hide-mobile { display: none; }
  .rg-game-card-title { font-size: 12px; }
  .rg-game-card-meta { font-size: 10px; }
  .rg-game-card-info { padding: 8px; }
  .rg-heading { font-size: 9px; }
  .rg-btn { padding: 8px 14px; font-size: 12px; }
  .rg-search { padding: 8px 12px 8px 36px; font-size: 13px; }
  .rg-tabs { gap: 2px; }
  .rg-tab { padding: 6px 10px; font-size: 11px; }
  .rg-list-item { gap: 8px; padding: 8px 10px; }
  .rg-table th { font-size: 10px; padding: 6px 8px; }
  .rg-table td { font-size: 12px; padding: 8px; }
  .rg-table th:nth-child(n+3),
  .rg-table td:nth-child(n+3) { display: none; }
  .rg-glass { border-radius: 12px; }
}

/* Responsive - Small phones */
@media (max-width: 400px) {
  .rg-container { padding: 8px; }
  .rg-grid-4 { grid-template-columns: 1fr 1fr; gap: 8px; }
  .rg-grid-5 { grid-template-columns: 1fr 1fr; gap: 8px; }
  .rg-stat-value { font-size: 16px; }
  .rg-hero { padding: 12px; }
}

/* Landing page specific */
.rg-landing { padding: 0; max-width: 100%; }
.rg-landing .p-body-main--withSideNav { padding-left: 0; }

/* Empty state */
.rg-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--rg-text-muted);
  font-size: 14px;
}

/* Progress bar */
.rg-progress {
  height: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  overflow: hidden;
}
.rg-progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.7s ease;
}

/* Map container */
.rg-map-container {
  position: relative;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--rg-card-border);
}

/* Scrollbar hide */
.rg-scroll-hide { scrollbar-width: none; -ms-overflow-style: none; }
.rg-scroll-hide::-webkit-scrollbar { display: none; }
