/* ============================================================
   GAME PAGE — game.css  (نسخة نظيفة)
   ============================================================ */

/* ── Variables ─────────────────────────────────────────── */
:root {
  --gp-bg:        #f5f5f7;
  --gp-surface:   #ffffff;
  --gp-border:    #e4e4e7;
  --gp-text:      #111827;
  --gp-muted:     #6b7280;
  --gp-accent:    #16a34a;
  --gp-accent2:   #27ae60;
  --gp-danger:    #dc2626;
  --gp-warn:      #d97706;
  --gp-radius:    12px;
  --gp-shadow:    0 2px 12px rgba(0,0,0,.08);
}

body.dark-mode {
  --gp-bg:      #0d0d0d;
  --gp-surface: #1a1a1a;
  --gp-border:  #2a2a2a;
  --gp-text:    #f0f0f0;
  --gp-muted:   #9ca3af;
}

/* ── Reset + Base ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Tajawal', 'Roboto', Tahoma, sans-serif;
  background: var(--gp-bg);
  color: var(--gp-text);
  min-height: 100vh;
  font-size: 14px;
}

.main-wrap { width: 100%; }

/* ── Page Wrapper ───────────────────────────────────────── */
.gp-wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 12px 12px 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ── Game Header ────────────────────────────────────────── */
/* gp-header عمود يضم: (1) صف علوي = الصورة+المعلومات جنبًا إلى
   جنب على كل الشاشات، (2) الأزرار بالأسفل بعرض الكرت كامل. */
.gp-header {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  padding: 14px;
  box-shadow: var(--gp-shadow);
}

.gp-top-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

/* ── Cover Image ────────────────────────────────────────── */
/* نسبة عرض/ارتفاع محجوزة على الحاوية نفسها (مو الصورة) — المساحة
   ثابتة من أول تحميل الصفحة فما في أي "قفزة" بالمحتوى تحتها لاحقًا.
   الصورة نفسها تُعرض كاملة بدون أي قصّ (object-fit: contain)، فلو
   نسبة الصورة الحقيقية مختلفة شوي تفضل مساحة فاضية خفيفة بدل القصّ. */
.gp-cover {
  position: relative;
  flex: 0 0 auto;
  width: 108px;
  aspect-ratio: 3 / 4;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0,0,0,.22);
  background: var(--gp-bg, #f4f4f4);
}
@media (min-width: 400px) { .gp-cover { width: 124px; } }
@media (min-width: 480px) { .gp-cover { width: 140px; } }
@media (min-width: 700px) { .gp-cover { width: 170px; } }

.gp-cover-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  opacity: 0;
  transition: opacity .2s ease;
}
.gp-cover-img.loaded { opacity: 1; }

/* تأثير hover خفيف */
.gp-cover:hover .gp-cover-img {
  transform: scale(1.025);
  transition: opacity .2s ease, transform .4s ease;
}

/* ── Info Panel ─────────────────────────────────────────── */
.gp-panel { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 12px; }

/* مجموعة العنوان + التواريخ — مقرّبين من بعض بمسافة أصغر من باقي أقسام اللوحة */
.gp-panel-head { display: flex; flex-direction: column; gap: 6px; }

.gp-title {
  font-size: 1.1rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--gp-text);
}
@media (min-width: 480px) { .gp-title { font-size: 1.3rem; } }

/* ── Publish / Update dates (سجل الموقع) ─────────────────── */
.gp-dates-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  font-size: .78rem;
  color: var(--gp-muted);
}
.gp-date-item { display: inline-flex; align-items: center; gap: 5px; }
.gp-date-item i { font-size: .75rem; opacity: .8; }

/* ── Stats Row ──────────────────────────────────────────── */
.gi-stats-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.gi-stat-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--gp-muted);
}
.gi-stat-item:not(:first-child) {
  padding-inline-start: 14px;
  border-inline-start: 1px solid var(--gp-border);
}
.gi-stat-item svg {
  width: 16px; height: 16px;
  fill: var(--gp-muted);
  flex-shrink: 0;
}
.gi-stat-value { font-weight: 600; color: var(--gp-text); }

/* التقييم داخل نفس شريط الإحصائيات */
.gi-stat-rating svg { fill: #f59e0b; }
.gi-rating-count { font-size: 12px; color: var(--gp-muted); }

/* ── Rate this game (تقييمك الشخصي) ──────────────────────── */
.gp-rate-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.gp-rate-label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--gp-muted);
}

.gi-stars {
  display: flex;
  gap: 2px;
}
.gi-star {
  font-size: 22px;
  color: #d1d5db;
  cursor: pointer;
  transition: color .15s, transform .15s;
  user-select: none;
}
.gi-star.active, .gi-star:hover { color: #f59e0b; transform: scale(1.15); }

/* ── Review Drawer ──────────────────────────────────────── */
.rr-drawer {
  display: none;
  flex-direction: column;
  gap: 10px;
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: 8px;
  padding: 14px;
}
.rr-drawer.show { display: flex; }

.rr-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.rr-drawer-title { font-weight: 700; font-size: .9rem; }
.rr-drawer-close {
  background: none; border: none; cursor: pointer;
  font-size: 1.4rem; color: var(--gp-muted); line-height: 1;
}

.rr-drawer-rating {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .85rem;
  color: var(--gp-muted);
}
.rr-drawer-rating-stars i { font-size: 1.2rem; color: #f59e0b; }

.rr-drawer-textarea {
  width: 100%;
  border: 1px solid var(--gp-border);
  border-radius: 8px;
  padding: 10px;
  font-family: inherit;
  font-size: .9rem;
  resize: vertical;
  background: var(--gp-bg);
  color: var(--gp-text);
  outline: none;
}
.rr-drawer-textarea:focus { border-color: var(--gp-accent2); }

.rr-drawer-actions { display: flex; gap: 8px; justify-content: flex-end; }

.rr-drawer-skip {
  padding: 6px 14px; border-radius: 6px; border: 1px solid var(--gp-border);
  background: none; cursor: pointer; font-size: .85rem; color: var(--gp-muted);
}
.rr-drawer-submit {
  padding: 6px 16px; border-radius: 6px; border: none;
  background: var(--gp-accent2); color: #fff;
  cursor: pointer; font-size: .85rem; font-weight: 600;
}
.rr-drawer-note { font-size: .78rem; color: var(--gp-muted); }

/* ── Action Buttons ─────────────────────────────────────── */
.gi-actions-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.gi-actions-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.gi-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: none;
  border-radius: 8px;
  padding: 9px 14px;
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, transform .1s, box-shadow .2s;
  font-family: inherit;
  white-space: nowrap;
}
.gi-btn svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.gi-btn:active { transform: scale(.97); }

.gi-btn-primary {
  background: var(--gp-accent2);
  color: #fff;
  width: 100%;
}
.gi-btn-primary:hover { background: #1e8449; box-shadow: 0 3px 10px rgba(39,174,96,.3); }

.gi-btn-follow {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  color: var(--gp-text);
  flex: 1 1 130px;
  min-width: 0;
  white-space: normal;
  text-align: center;
  line-height: 1.15;
}
.gi-btn-follow.is-active { background: var(--gp-accent); color: #fff; border-color: var(--gp-accent); }

.gi-share-wrap { position: relative; flex: 1 1 90px; min-width: 0; }
.gi-btn-share {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  color: var(--gp-text);
  width: 100%;
}
.gi-btn-share:hover { background: var(--gp-border); }

.gi-btn-like {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  color: var(--gp-text);
  flex: 0 0 auto;
}
.gi-btn-like i { font-size: 1rem; }
.gi-btn-like:hover, .gi-btn-like.active {
  background: #fee2e2;
  border-color: #fca5a5;
  color: var(--gp-danger);
}
body.dark-mode .gi-btn-like:hover,
body.dark-mode .gi-btn-like.active {
  background: rgba(220,38,38,.15);
  border-color: rgba(220,38,38,.4);
}

.gi-like-count { font-size: .85rem; font-weight: 600; }

/* Share Menu */
.gi-share-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
  overflow: hidden;
  z-index: 200;
  min-width: 180px;
}
.gi-share-menu.active { display: block; }

.gi-share-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 14px;
  border: none;
  background: none;
  cursor: pointer;
  font-size: .85rem;
  color: var(--gp-text);
  font-family: inherit;
  text-align: left;
  transition: background .15s;
}
.gi-share-item:hover { background: var(--gp-bg); }
.gi-share-ico { width: 20px; display: flex; justify-content: center; }
.gi-share-ico svg { width: 18px; height: 18px; fill: currentColor; }

/* Lists Modal */
.gi-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 99999;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.gi-modal-overlay.active { display: flex; align-items: flex-end; justify-content: center; }

.gi-bottom-sheet {
  background: var(--gp-surface);
  border-radius: 16px 16px 0 0;
  width: 100%;
  max-width: 480px;
  padding: 16px 0 24px;
  position: relative;
  z-index: 100000;
}

.gi-sheet-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px 14px;
  border-bottom: 1px solid var(--gp-border);
}
.gi-sheet-title { font-weight: 700; font-size: 1rem; flex: 1; }
.gi-close-btn {
  background: none; border: none; cursor: pointer;
  font-size: 1.5rem; color: var(--gp-muted); line-height: 1;
}

.gi-lists { padding: 8px 0; }

.gi-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  cursor: pointer;
  transition: background .15s;
  user-select: none;
}
.gi-list-item:hover { background: var(--gp-bg); }
.gi-list-item.selected { color: var(--gp-accent); }

.gi-list-check {
  width: 22px; height: 22px;
  border: 2px solid var(--gp-muted);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  color: transparent;
  flex-shrink: 0;
  transition: all .2s;
}
.gi-list-item.selected .gi-list-check {
  background: var(--gp-accent);
  border-color: var(--gp-accent);
  color: #fff;
}
.gi-list-label { font-weight: 500; }

/* ── Reminder Banner ────────────────────────────────────── */
.gp-reminder {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: .85rem;
  color: #1e40af;
}
body.dark-mode .gp-reminder {
  background: rgba(39,174,96,.1);
  border-color: rgba(39,174,96,.25);
  color: #86efac;
}
.gp-reminder i { flex-shrink: 0; }
.gp-reminder .game-name-highlight { font-weight: 700; }

/* ── Collapsible Section ────────────────────────────────── */
.gp-section {
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  overflow: hidden;
  box-shadow: var(--gp-shadow);
}

.gp-section-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 14px 16px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: .95rem;
  font-weight: 700;
  color: var(--gp-text);
  text-align: left;
  transition: background .15s;
}
.gp-section-toggle:hover { background: var(--gp-bg); }
.gp-section-toggle i:first-child { color: var(--gp-accent2); width: 18px; }
.gp-section-toggle .gp-toggle-chevron {
  margin-left: auto;
  color: var(--gp-muted);
  transition: transform .25s ease;
  font-size: .8rem;
}
.gp-section.collapsed .gp-toggle-chevron { transform: rotate(-90deg); }

.gp-section-body {
  padding: 0 16px 16px;
  border-top: 1px solid var(--gp-border);
}
.gp-section.collapsed .gp-section-body { display: none; }

/* Section without toggle (always visible header) */
.gp-section-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gp-border);
  font-size: .95rem;
  font-weight: 700;
  color: var(--gp-text);
}
.gp-section-head i { color: var(--gp-accent2); }

/* ── Info Rows ──────────────────────────────────────────── */
.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
@media (max-width: 480px) { .info-grid { grid-template-columns: 1fr; } }

.info-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 9px 0;
  border-bottom: 1px solid var(--gp-border);
  font-size: .85rem;
}
.info-row:last-child { border-bottom: none; }

.info-label {
  color: var(--gp-muted);
  min-width: 120px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.info-label i { width: 14px; text-align: center; }
.info-value { font-weight: 600; color: var(--gp-text); word-break: break-word; }
.info-value a { color: var(--gp-accent2); text-decoration: none; }
.info-value a:hover { text-decoration: underline; }

.official-site-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 6px;
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  color: var(--gp-accent2);
  font-size: .85rem;
  text-decoration: none;
  transition: background .15s;
}
.official-site-icon:hover { background: var(--gp-border); }

/* ── Gallery ────────────────────────────────────────────── */
.ps-gallery { position: relative; }

.ps-gallery-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  margin-top: 4px;
}

.ps-gallery-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.ps-gallery-track::-webkit-scrollbar { display: none; }

.ps-gallery-slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--gp-border);
}
.ps-gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  cursor: zoom-in;
}

.ps-gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(0,0,0,.55);
  border: none;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
  z-index: 5;
  transition: background .2s;
}
.ps-gallery-nav:hover { background: rgba(0,0,0,.8); }
.ps-gallery-nav:disabled { opacity: .3; cursor: default; }
.ps-gallery-nav.prev { left: 8px; }
.ps-gallery-nav.next { right: 8px; }

.ps-gallery-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 10px 0 2px;
}
.ps-gallery-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--gp-border);
  cursor: pointer;
  transition: background .2s, transform .2s;
}
.ps-gallery-dot.is-active {
  background: var(--gp-accent2);
  transform: scale(1.3);
}

/* ── Review Section ─────────────────────────────────────── */
.review-content {
  font-size: .9rem;
  line-height: 1.7;
  color: var(--gp-text);
}
.youtube-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 8px;
  margin-top: 8px;
}
.youtube-container iframe {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  border: none;
}

/* ── Spotify ────────────────────────────────────────────── */
.spotify-section .gp-section-head i { color: #1db954; }
.spotify-embed { border-radius: 12px; overflow: hidden; margin-top: 4px; }
.spotify-embed iframe { display: block; border-radius: 12px; }

/* ── Description ────────────────────────────────────────── */
.description-content {
  font-size: .9rem;
  line-height: 1.75;
  color: var(--gp-text);
}
.description-content p { margin-bottom: .6em; }
.description-heading { font-weight: 700; color: var(--gp-accent2); }
.highlighted-word { background: #fef9c3; padding: 0 2px; border-radius: 3px; }
body.dark-mode .highlighted-word { background: rgba(234,179,8,.2); }

/* ── Download / Help Blocks ─────────────────────────────── */
.gp-action-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  padding: 14px 16px;
  box-shadow: var(--gp-shadow);
  flex-wrap: wrap;
}
.gp-action-block-text {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .9rem;
  font-weight: 500;
}
.gp-action-block-text i { font-size: 1rem; }

.gp-dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 20px;
  border-radius: 8px;
  border: none;
  font-weight: 700;
  font-size: .9rem;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: opacity .2s;
  white-space: nowrap;
}
.gp-dl-btn:hover { opacity: .88; }
.gp-dl-btn-green { background: var(--gp-accent); color: #fff; }
.gp-dl-btn-orange { background: var(--gp-warn); color: #fff; }

/* ── Ratings & Reviews ──────────────────────────────────── */
.rr-section { background: var(--gp-surface); border: 1px solid var(--gp-border); border-radius: var(--gp-radius); padding: 16px; box-shadow: var(--gp-shadow); }

.rr-title { font-size: 1rem; font-weight: 700; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.rr-title i { color: var(--gp-accent2); }

.rr-summary-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  flex-wrap: wrap;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--gp-border);
  margin-bottom: 14px;
}

.rr-summary-left { display: flex; flex-direction: column; gap: 6px; min-width: 80px; }

.rr-avg { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.rr-avg-value { font-size: 2.4rem; font-weight: 900; line-height: 1; }
.rr-avg-label { font-size: .72rem; color: var(--gp-muted); text-align: center; }
.rr-avg-stars i { font-size: .85rem; color: #f59e0b; }

.rr-count { text-align: center; }
.rr-count-value { font-size: 1rem; font-weight: 700; }
.rr-count-label { font-size: .75rem; color: var(--gp-muted); }

.rr-bars { flex: 1; min-width: 160px; display: flex; flex-direction: column; gap: 5px; }
.rr-bar-row { display: flex; align-items: center; gap: 6px; font-size: .75rem; }
.rr-bar-stars { display: flex; gap: 2px; width: 60px; flex-shrink: 0; }
.rr-bar-stars i { font-size: .65rem; color: #f59e0b; }
.rr-bar-track { flex: 1; height: 6px; background: var(--gp-border); border-radius: 3px; overflow: hidden; }
.rr-bar-fill { height: 100%; background: #f59e0b; border-radius: 3px; transition: width .5s ease; }
.rr-bar-pct { width: 30px; text-align: right; color: var(--gp-muted); font-size: .72rem; }

.rr-card {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 10px;
}
.rr-card-head { display: flex; gap: 10px; margin-bottom: 10px; }
.rr-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--gp-border);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.rr-avatar img { width: 100%; height: 100%; object-fit: cover; }
.rr-avatar-fallback { color: var(--gp-muted); }

.rr-meta { display: flex; flex-direction: column; gap: 3px; }
.rr-name { font-weight: 700; font-size: .88rem; }
.rr-profile-link { color: inherit; text-decoration: none; cursor: pointer; }
.rr-profile-link:hover { text-decoration: underline; opacity: .85; }
.rr-avatar .rr-profile-link { display: block; width: 100%; height: 100%; }
.rr-sub { display: flex; align-items: center; gap: 8px; }
.rr-stars i { font-size: .75rem; color: #f59e0b; }
.rr-date { font-size: .75rem; color: var(--gp-muted); }
.rr-text { font-size: .88rem; line-height: 1.6; color: var(--gp-text); }

.rr-card-actions { margin-top: 10px; }
.rr-helpful {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px;
  border: 1px solid var(--gp-border);
  border-radius: 20px;
  background: none;
  cursor: pointer;
  font-size: .8rem;
  color: var(--gp-muted);
  transition: all .15s;
}
.rr-helpful:hover { background: var(--gp-border); color: var(--gp-text); }
.rr-helpful-count { font-weight: 600; }

.rr-empty { text-align: center; padding: 24px; color: var(--gp-muted); font-size: .9rem; }

.rr-pagination { display: flex; gap: 4px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }
.rr-page {
  min-width: 36px; height: 36px; padding: 0 10px;
  border: 1px solid var(--gp-border); border-radius: 8px;
  background: none; cursor: pointer;
  font-size: .85rem; color: var(--gp-text); font-family: inherit;
  transition: background .15s;
}
.rr-page:hover { background: var(--gp-border); }
.rr-page.active { background: var(--gp-accent2); color: #fff; border-color: var(--gp-accent2); }
.rr-page:disabled { opacity: .4; cursor: default; }

/* ── FAQs ────────────────────────────────────────────────── */
.faqs-section { background: var(--gp-surface); border: 1px solid var(--gp-border); border-radius: var(--gp-radius); overflow: hidden; box-shadow: var(--gp-shadow); }
.faqs-title {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gp-border);
  font-size: .95rem; font-weight: 700;
}
.faqs-title i { color: var(--gp-warn); }

.faqs-container { padding: 0 16px; }

.faq-item { border-bottom: 1px solid var(--gp-border); }
.faq-item:last-child { border-bottom: none; }

.faq-question {
  font-size: .9rem;
  font-weight: 600;
  padding: 12px 0 6px;
  color: var(--gp-text);
}
.faq-answer {
  font-size: .85rem;
  line-height: 1.65;
  color: var(--gp-muted);
  padding-bottom: 12px;
}
.highlight-term {
  background: #dbeafe;
  color: #1e40af;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 600;
  font-size: .82rem;
}
body.dark-mode .highlight-term {
  background: rgba(39,174,96,.2);
  color: #86efac;
}

/* ── Social Section ─────────────────────────────────────── */
.social-reminder-section { background: var(--gp-surface); border: 1px solid var(--gp-border); border-radius: var(--gp-radius); overflow: hidden; box-shadow: var(--gp-shadow); }
.social-reminder-title {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gp-border);
  font-size: .95rem; font-weight: 700;
}
.social-reminder-content { padding: 14px 16px; }
.reminder-message { font-size: .88rem; line-height: 1.6; color: var(--gp-muted); margin-bottom: 14px; }

.social-links-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
@media (max-width: 400px) { .social-links-grid { grid-template-columns: repeat(2, 1fr); } }

.social-link-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 8px;
  border-radius: 10px;
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  text-decoration: none;
  color: var(--gp-text);
  transition: transform .2s, box-shadow .2s;
  font-size: .78rem;
  font-weight: 600;
  text-align: center;
}
.social-link-item:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.1); }

.social-icon {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  color: #fff;
}
.facebook-icon  { background: #1877f2; }
.telegram-icon  { background: #0088cc; }
.instagram-icon { background: linear-gradient(45deg,#f09433,#e6683c,#dc2743,#cc2366,#bc1888); }
.youtube-icon   { background: #ff0000; }
.discord-icon   { background: #5865f2; }
.tiktok-icon    { background: #010101; }

/* ── Comments ────────────────────────────────────────────── */
.comments-section {
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: var(--gp-radius);
  overflow: hidden;
  box-shadow: var(--gp-shadow);
}
.comments-container { padding: 16px; }
.comments-title {
  display: flex; align-items: center; gap: 8px;
  font-size: .95rem; font-weight: 700;
  margin-bottom: 4px;
}
.comments-title i { color: var(--gp-accent2); }
.comments-count { color: var(--gp-muted); font-weight: 400; font-size: .85rem; }
.comments-description { font-size: .83rem; color: var(--gp-muted); margin-bottom: 16px; }

/* Comment Form */
.comment-form-container {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 16px;
}
.comment-form { display: flex; flex-direction: column; gap: 10px; }

.comment-userbar {
  display: flex; align-items: center; gap: 10px;
}
.comment-userbar-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--gp-border);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.comment-avatar-img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .2s; }
.comment-avatar-img.loaded { opacity: 1; }
.comment-userbar-name {
  display: flex; align-items: center; gap: 6px;
  font-weight: 700; font-size: .88rem;
}
.comment-userbar-badges { display: flex; gap: 4px; }

.form-row { display: flex; gap: 10px; flex-wrap: wrap; }
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-group.half { flex: 1; min-width: 140px; }
.form-group label { font-size: .8rem; font-weight: 600; color: var(--gp-muted); }
.form-group input,
.form-group textarea {
  padding: 9px 12px;
  border: 1px solid var(--gp-border);
  border-radius: 8px;
  font-family: inherit;
  font-size: .88rem;
  background: var(--gp-surface);
  color: var(--gp-text);
  outline: none;
  transition: border-color .2s;
}
.form-group input:focus,
.form-group textarea:focus { border-color: var(--gp-accent2); }
.form-group textarea { resize: vertical; }

.markdown-hint { font-size: .75rem; color: var(--gp-muted); }

.form-actions { display: flex; gap: 8px; justify-content: flex-end; }

.cancel-reply-btn {
  padding: 8px 14px; border-radius: 8px;
  border: 1px solid var(--gp-border);
  background: none; cursor: pointer;
  font-size: .85rem; color: var(--gp-muted); font-family: inherit;
}
.submit-comment-btn {
  padding: 8px 16px; border-radius: 8px; border: none;
  background: var(--gp-accent2); color: #fff;
  cursor: pointer; font-size: .85rem; font-weight: 600; font-family: inherit;
  display: flex; align-items: center; gap: 6px;
}

/* Sort Toolbar */
.comments-toolbar { margin-bottom: 14px; }
.comments-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.comments-filter-label { font-size: .78rem; color: var(--gp-muted); white-space: nowrap; }

.comments-seg { display: flex; gap: 0; border: 1px solid var(--gp-border); border-radius: 8px; overflow: hidden; }
.comments-filter-btn {
  padding: 6px 12px; border: none;
  background: none; cursor: pointer;
  font-size: .8rem; font-family: inherit; color: var(--gp-muted);
  border-right: 1px solid var(--gp-border);
  transition: background .15s;
}
.comments-filter-btn:last-child { border-right: none; }
.comments-filter-btn.is-active { background: var(--gp-accent2); color: #fff; }
.comments-sort-select.is-hidden { display: none; }

/* Comment Items */
.comments-list { display: flex; flex-direction: column; gap: 8px; }

.comment-item {
  background: var(--gp-bg);
  border: 1px solid var(--gp-border);
  border-radius: 10px;
  padding: 12px;
}
.comment-reply { margin-left: 24px; border-left: 3px solid var(--gp-accent2); }
[dir="rtl"] .comment-reply { margin-left: 0; margin-right: 24px; border-left: none; border-right: 3px solid var(--gp-accent2); }

.comment-header {
  display: flex; align-items: flex-start; gap: 10px; margin-bottom: 8px;
}
.comment-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--gp-border);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; overflow: hidden; font-size: .85rem; color: var(--gp-muted);
}
.comment-avatar.premium-user { box-shadow: 0 0 0 2px #f59e0b; }

.comment-meta { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.comment-author-section { display: flex; align-items: center; gap: 6px; }
.comment-author { font-weight: 700; font-size: .88rem; }
.comment-profile-link { color: inherit; text-decoration: none; cursor: pointer; }
.comment-profile-link:hover { text-decoration: underline; opacity: .85; }
.comment-avatar .comment-profile-link { display: block; width: 100%; height: 100%; }
.comment-badges { display: flex; gap: 3px; }

.comment-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; border-radius: 50%;
  font-size: .65rem;
}
.badge-admin { background: #dc2626; color: #fff; }
.badge-moderator { background: #7c3aed; color: #fff; }
.badge-premium { background: transparent; }
.user-dropdown-badge { width: 18px; height: 18px; object-fit: contain; }

.comment-time { font-size: .75rem; color: var(--gp-muted); }
.reply-indicator { font-size: .75rem; color: var(--gp-accent2); }

.comment-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-shrink: 0; }
[dir="rtl"] .comment-actions { margin-left: 0; margin-right: auto; }

.comment-action-btn {
  display: flex; align-items: center; gap: 4px;
  padding: 4px 8px; border-radius: 6px; border: none;
  background: none; cursor: pointer;
  font-size: .78rem; color: var(--gp-muted); font-family: inherit;
  transition: background .15s;
}
.comment-action-btn:hover { background: var(--gp-border); color: var(--gp-text); }
.like-btn.liked { color: var(--gp-danger); }
.like-count { font-size: .78rem; }

.comment-content-wrapper {
  font-size: .88rem; line-height: 1.6; color: var(--gp-text);
}
.comment-content-wrapper code {
  background: var(--gp-border); padding: 2px 5px; border-radius: 4px;
  font-family: monospace; font-size: .82rem;
}

.replies-container {
  display: flex; flex-direction: column; gap: 8px; margin-top: 10px;
}

.no-comments {
  display: flex; flex-direction: column; align-items: center;
  gap: 8px; padding: 30px; text-align: center;
}
.no-comments-icon i { font-size: 2rem; color: var(--gp-border); }
.no-comments-text h3 { font-size: .95rem; color: var(--gp-muted); }
.no-comments-text p { font-size: .82rem; color: var(--gp-muted); }

/* ── Suggested Games ────────────────────────────────────── */
.suggested-games { background: var(--gp-surface); border: 1px solid var(--gp-border); border-radius: var(--gp-radius); overflow: hidden; box-shadow: var(--gp-shadow); }
.suggested-title {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gp-border);
  font-size: .95rem; font-weight: 700;
}
.suggested-title i { color: var(--gp-accent); }

.suggested-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}
@media (max-width: 600px) { .suggested-grid { grid-template-columns: repeat(2, 1fr); } }

.suggested-card {
  display: flex; flex-direction: column;
  cursor: pointer;
  border-right: 1px solid var(--gp-border);
  border-bottom: 1px solid var(--gp-border);
  transition: background .15s;
  overflow: hidden;
}
.suggested-card:nth-child(4n) { border-right: none; }
@media (max-width: 600px) {
  .suggested-card:nth-child(2n) { border-right: none; }
}
.suggested-card:hover { background: var(--gp-bg); }

.suggested-card img {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  display: block;
  transition: opacity .3s;
}
.suggested-name {
  padding: 6px 8px 2px;
  font-size: .78rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.3;
}
.suggested-info {
  display: flex; gap: 6px; flex-wrap: wrap;
  padding: 4px 8px 8px;
  font-size: .72rem; color: var(--gp-muted);
}

/* ── Report Modal ────────────────────────────────────────── */
.report-box-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.55); z-index: 99999;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.report-box-overlay.show { display: block; }

.report-box-modal {
  display: none; position: fixed;
  top: 50%; left: 50%; transform: translate(-50%,-50%);
  background: var(--gp-surface);
  border: 1px solid var(--gp-border);
  border-radius: 14px;
  width: calc(100% - 32px);
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  z-index: 100000;
  box-shadow: 0 12px 40px rgba(0,0,0,.2);
}
.report-box-modal.show { display: block; }

.report-box-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gp-border);
}
.report-box-header h3 { font-size: .95rem; font-weight: 700; }
.report-box-close {
  background: none; border: none; cursor: pointer;
  font-size: 1.5rem; color: var(--gp-muted); line-height: 1;
}
.report-box-content { padding: 16px; }
.report-game-url { word-break: break-all; font-size: .78rem; color: var(--gp-muted); }

.report-options { display: flex; flex-direction: column; gap: 10px; margin: 14px 0; }
.report-option {
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; font-size: .88rem;
}
.report-option input[type="radio"] { accent-color: var(--gp-accent2); }

.report-form .form-group label { font-weight: 600; font-size: .85rem; color: var(--gp-muted); display: flex; flex-direction: column; gap: 6px; }
.report-form textarea {
  width: 100%; padding: 10px;
  border: 1px solid var(--gp-border); border-radius: 8px;
  font-family: inherit; font-size: .88rem;
  background: var(--gp-bg); color: var(--gp-text); resize: vertical;
}

.submit-btn {
  width: 100%; margin-top: 14px;
  padding: 10px; border: none; border-radius: 8px;
  background: var(--gp-accent2); color: #fff;
  font-weight: 700; font-size: .9rem; cursor: pointer;
  font-family: inherit;
}
.submit-btn:hover { opacity: .88; }

/* ── Notifications ──────────────────────────────────────── */
.rating-notification {
  position: fixed;
  bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: #1f2937; color: #fff;
  padding: 10px 20px; border-radius: 10px;
  font-size: .88rem; z-index: 9999;
  opacity: 0; transition: opacity .25s, transform .25s;
  white-space: pre-wrap; text-align: center; max-width: 90%;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
}
.rating-notification.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.rating-notification.error { background: var(--gp-danger); }

.comment-notification {
  position: fixed;
  bottom: 24px; right: 16px;
  background: var(--gp-surface); border: 1px solid var(--gp-border);
  border-radius: 10px; padding: 10px 14px;
  display: flex; align-items: center; gap: 8px;
  font-size: .85rem; z-index: 9999;
  box-shadow: 0 4px 16px rgba(0,0,0,.12);
  opacity: 0; transform: translateY(12px); transition: opacity .25s, transform .25s;
}
[dir="rtl"] .comment-notification { right: auto; left: 16px; }
.comment-notification.show { opacity: 1; transform: translateY(0); }
.comment-notification.success .notification-icon i { color: var(--gp-accent); }
.comment-notification.error .notification-icon i { color: var(--gp-danger); }

/* ── Utility ─────────────────────────────────────────────── */
.tr-no { /* translation-excluded — no style needed */ }

/* RTL flips */
[dir="rtl"] .gp-section-toggle { text-align: right; }
[dir="rtl"] .info-label { min-width: auto; }
[dir="rtl"] .comment-action-btn { flex-direction: row-reverse; }
