/*
Theme Name: ArcadeX Pro
Theme URI: https://wa.me/+8801516514216
Author: Kausar
Author URI: https://wa.me/+8801516514216
Description: A high-performance WordPress theme for browser-based gaming websites with auto game importing, SEO optimization, and monetization features.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: arcadex
Tags: gaming, arcade, games, dark-mode, responsive, custom-colors, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready
*/

/* =============================================
   CSS CUSTOM PROPERTIES / DESIGN TOKENS
   ============================================= */
:root {
  --ax-primary: #6c5ce7;
  --ax-primary-dark: #5a4bd1;
  --ax-primary-light: #a29bfe;
  --ax-secondary: #00cec9;
  --ax-accent: #fd79a8;
  --ax-warning: #fdcb6e;
  --ax-success: #55efc4;
  --ax-danger: #d63031;

  --ax-bg: #0f0f1a;
  --ax-bg-card: #1a1a2e;
  --ax-bg-card-hover: #16213e;
  --ax-bg-elevated: #0f3460;
  --ax-surface: #1e1e3a;
  --ax-surface-2: #252545;
  --ax-border: rgba(108, 92, 231, 0.2);
  --ax-border-light: rgba(255, 255, 255, 0.08);

  --ax-text: #e8e8f0;
  --ax-text-muted: #9999bb;
  --ax-text-dim: #666688;
  --ax-heading: #ffffff;

  --ax-radius-sm: 6px;
  --ax-radius: 12px;
  --ax-radius-lg: 18px;
  --ax-radius-xl: 24px;
  --ax-radius-full: 9999px;

  --ax-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --ax-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  --ax-shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --ax-shadow-glow: 0 0 20px rgba(108, 92, 231, 0.3);
  --ax-shadow-glow-secondary: 0 0 20px rgba(0, 206, 201, 0.3);

  --ax-transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --ax-transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);

  --ax-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ax-font-display: 'Outfit', var(--ax-font);
  --ax-font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  --ax-header-height: 70px;
  --ax-sidebar-width: 300px;
  --ax-container: 1400px;
}

/* Light Mode */
body.light-mode {
  --ax-bg: #f0f0f8;
  --ax-bg-card: #ffffff;
  --ax-bg-card-hover: #f8f8ff;
  --ax-bg-elevated: #e8e8ff;
  --ax-surface: #ffffff;
  --ax-surface-2: #f4f4ff;
  --ax-border: rgba(108, 92, 231, 0.15);
  --ax-border-light: rgba(0, 0, 0, 0.08);
  --ax-text: #2d2d4e;
  --ax-text-muted: #5c5c7a;
  --ax-text-dim: #9999aa;
  --ax-heading: #1a1a2e;
  --ax-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --ax-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  --ax-shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.15);
}

/* =============================================
   RESET & BASE
   ============================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--ax-font);
  background: var(--ax-bg);
  color: var(--ax-text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  transition: background var(--ax-transition), color var(--ax-transition);
}

img,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--ax-primary-light);
  text-decoration: none;
  transition: color var(--ax-transition);
}

a:hover {
  color: var(--ax-primary);
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--ax-font-display);
  color: var(--ax-heading);
  line-height: 1.3;
  font-weight: 700;
}

/* =============================================
   LAYOUT
   ============================================= */
.ax-container {
  max-width: var(--ax-container);
  margin: 0 auto;
  padding: 0 20px;
}

.ax-grid {
  display: grid;
}

.ax-flex {
  display: flex;
}

/* =============================================
   HEADER
   ============================================= */
#ax-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--ax-header-height);
  background: rgba(15, 15, 26, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--ax-border);
  transition: background var(--ax-transition), box-shadow var(--ax-transition);
}

#ax-header.scrolled {
  box-shadow: var(--ax-shadow);
  background: rgba(15, 15, 26, 0.98);
}

.light-mode #ax-header {
  background: rgba(240, 240, 248, 0.92);
}

.light-mode #ax-header.scrolled {
  background: rgba(240, 240, 248, 0.98);
}

.ax-header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  height: 100%;
  max-width: var(--ax-container);
  margin: 0 auto;
  padding: 0 20px;
}

.ax-logo {
  flex-shrink: 0;
}

.ax-logo a {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ax-logo img {
  height: 38px;
  width: auto;
}

.ax-logo-text {
  font-family: var(--ax-font-display);
  font-size: 1.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--ax-primary), var(--ax-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.ax-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ax-nav ul {
  display: flex;
  align-items: center;
  gap: 4px;
}

.ax-nav ul li a {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  transition: all var(--ax-transition);
  white-space: nowrap;
}

.ax-nav ul li a:hover,
.ax-nav ul li.current-menu-item>a,
.ax-nav ul li.current-menu-parent>a {
  color: var(--ax-primary-light);
  background: rgba(108, 92, 231, 0.12);
}

/* Dropdown */
.ax-nav ul li.menu-item-has-children {
  position: relative;
}

.ax-nav ul li.menu-item-has-children>a::after {
  content: '▾';
  font-size: 0.75rem;
  margin-left: 2px;
  transition: transform var(--ax-transition);
}

.ax-nav ul li.menu-item-has-children:hover>a::after {
  transform: rotate(180deg);
}

.ax-nav ul .sub-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  min-width: 200px;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius);
  padding: 8px;
  opacity: 0;
  pointer-events: none;
  transition: all var(--ax-transition);
  box-shadow: var(--ax-shadow-lg);
  z-index: 100;
}

.ax-nav ul li.menu-item-has-children:hover .sub-menu {
  opacity: 1;
  pointer-events: all;
  transform: translateX(-50%) translateY(0);
}

.ax-nav ul .sub-menu li a {
  border-radius: var(--ax-radius-sm);
  padding: 10px 12px;
  width: 100%;
  display: flex;
}

.ax-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Search Bar */
.ax-search-wrap {
  position: relative;
}

.ax-search-bar {
  display: flex;
  align-items: center;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius-full);
  padding: 8px 16px;
  gap: 8px;
  transition: all var(--ax-transition);
  width: 200px;
}

.ax-search-bar:focus-within {
  border-color: var(--ax-primary);
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.15);
  width: 260px;
}

.ax-search-bar input {
  background: none;
  border: none;
  outline: none;
  color: var(--ax-text);
  font-size: 0.875rem;
  width: 100%;
}

.ax-search-bar input::placeholder {
  color: var(--ax-text-dim);
}

.ax-search-bar svg {
  color: var(--ax-text-dim);
  flex-shrink: 0;
}

.ax-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  min-width: 320px;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius);
  padding: 8px;
  box-shadow: var(--ax-shadow-lg);
  z-index: 200;
  display: none;
}

.ax-search-results.active {
  display: block;
}

.ax-search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: var(--ax-radius-sm);
  transition: background var(--ax-transition);
  cursor: pointer;
}

.ax-search-result-item:hover {
  background: var(--ax-surface-2);
}

.ax-search-result-item img {
  width: 48px;
  height: 36px;
  object-fit: cover;
  border-radius: 4px;
}

.ax-search-result-item span {
  font-size: 0.875rem;
  color: var(--ax-text);
}

/* Header Buttons */
.ax-btn-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--ax-radius-sm);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
}

.ax-btn-icon:hover {
  color: var(--ax-primary-light);
  border-color: var(--ax-primary);
  background: rgba(108, 92, 231, 0.1);
}

.ax-hamburger {
  display: none;
}

/* =============================================
   HERO / FEATURED SLIDER
   ============================================= */
.ax-hero-slider {
  position: relative;
  overflow: hidden;
  background: var(--ax-bg-card);
  border-bottom: 1px solid var(--ax-border);
}

.ax-slider-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.ax-slide {
  min-width: 100%;
  position: relative;
  height: 480px;
}

.ax-slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.4);
  transition: transform 8s linear;
}

.ax-slide:hover .ax-slide-bg {
  transform: scale(1.05);
}

.ax-slide-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 48px;
  background: linear-gradient(to top, rgba(15, 15, 26, 0.95) 0%, transparent 60%);
}

.ax-slide-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--ax-primary);
  color: #fff;
  padding: 4px 12px;
  border-radius: var(--ax-radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
  width: fit-content;
}

.ax-slide-title {
  font-size: clamp(1.5rem, 4vw, 2.8rem);
  color: #fff;
  margin-bottom: 12px;
}

.ax-slide-desc {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
  max-width: 500px;
  margin-bottom: 24px;
}

.ax-slide-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.ax-slider-controls {
  position: absolute;
  bottom: 24px;
  right: 48px;
  display: flex;
  gap: 8px;
  z-index: 10;
}

.ax-slider-btn {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--ax-radius-sm);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
  backdrop-filter: blur(10px);
}

.ax-slider-btn:hover {
  background: var(--ax-primary);
  border-color: var(--ax-primary);
}

.ax-slider-dots {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 10;
}

.ax-slider-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--ax-radius-full);
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all var(--ax-transition);
  border: none;
}

.ax-slider-dot.active {
  width: 24px;
  background: var(--ax-primary);
}

/* =============================================
   BUTTONS
   ============================================= */
.ax-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--ax-radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  cursor: pointer;
  transition: all var(--ax-transition);
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.ax-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.1);
  opacity: 0;
  transition: opacity var(--ax-transition);
}

.ax-btn:hover::before {
  opacity: 1;
}

.ax-btn-primary {
  background: linear-gradient(135deg, var(--ax-primary), var(--ax-primary-dark));
  color: #fff;
  box-shadow: 0 4px 15px rgba(108, 92, 231, 0.4);
}

.ax-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(108, 92, 231, 0.5);
  color: #fff;
}

.ax-btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

.ax-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.ax-btn-outline {
  background: transparent;
  color: var(--ax-primary-light);
  border: 1px solid var(--ax-primary);
}

.ax-btn-outline:hover {
  background: var(--ax-primary);
  color: #fff;
}

.ax-btn-sm {
  padding: 7px 16px;
  font-size: 0.8rem;
}

.ax-btn-lg {
  padding: 14px 32px;
  font-size: 1rem;
}

.ax-btn-play {
  background: linear-gradient(135deg, #00d2ff, #00cec9);
  color: #0f1923;
  font-weight: 700;
  box-shadow: 0 4px 15px rgba(0, 206, 201, 0.4);
}

.ax-btn-play:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(0, 206, 201, 0.5);
  color: #0f1923;
}

/* =============================================
   SECTIONS
   ============================================= */
.ax-section {
  padding: 60px 0;
}

.ax-section-sm {
  padding: 40px 0;
}

.ax-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.ax-section-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--ax-heading);
  display: flex;
  align-items: center;
  gap: 10px;
}

.ax-section-title::before {
  content: '';
  display: block;
  width: 4px;
  height: 28px;
  background: linear-gradient(to bottom, var(--ax-primary), var(--ax-secondary));
  border-radius: var(--ax-radius-full);
}

.ax-section-link {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ax-primary-light);
  display: flex;
  align-items: center;
  gap: 4px;
  transition: gap var(--ax-transition);
}

.ax-section-link:hover {
  gap: 8px;
}

/* =============================================
   GAME CARDS
   ============================================= */
.ax-games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}

.ax-games-grid-lg {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.ax-game-card {
  background: var(--ax-bg-card);
  border-radius: var(--ax-radius);
  border: 1px solid var(--ax-border-light);
  overflow: hidden;
  transition: all var(--ax-transition);
  position: relative;
  cursor: pointer;
}

.ax-game-card:hover {
  transform: translateY(-4px);
  border-color: var(--ax-border);
  box-shadow: var(--ax-shadow-glow);
}

.ax-card-thumb {
  position: relative;
  padding-top: 65%;
  overflow: hidden;
  background: var(--ax-surface);
}

.ax-card-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--ax-transition-slow);
}

.ax-game-card:hover .ax-card-thumb img {
  transform: scale(1.08);
}

.ax-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 15, 26, 0.9) 0%, transparent 50%);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--ax-transition);
}

.ax-game-card:hover .ax-card-overlay {
  opacity: 1;
}

.ax-card-play-btn {
  width: 56px;
  height: 56px;
  background: var(--ax-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transform: scale(0.7);
  transition: transform var(--ax-transition);
  box-shadow: 0 0 30px rgba(108, 92, 231, 0.6);
}

.ax-game-card:hover .ax-card-play-btn {
  transform: scale(1);
}

.ax-card-badges {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ax-badge {
  padding: 3px 8px;
  border-radius: var(--ax-radius-full);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.ax-badge-new {
  background: var(--ax-success);
  color: #0f1923;
}

.ax-badge-hot {
  background: var(--ax-danger);
  color: #fff;
}

.ax-badge-trending {
  background: var(--ax-warning);
  color: #0f1923;
}

.ax-badge-featured {
  background: var(--ax-primary);
  color: #fff;
}

.ax-card-fav {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  background: rgba(15, 15, 26, 0.7);
  border-radius: 50%;
  border: none;
  color: var(--ax-text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
  backdrop-filter: blur(5px);
}

.ax-card-fav:hover,
.ax-card-fav.active {
  color: var(--ax-accent);
  transform: scale(1.1);
}

.ax-card-body {
  padding: 14px;
}

.ax-card-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ax-heading);
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ax-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--ax-text-dim);
}

.ax-card-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--ax-warning);
}

.ax-card-category {
  color: var(--ax-primary-light);
}

/* Skeleton Loading */
.ax-skeleton {
  background: linear-gradient(90deg, var(--ax-surface) 25%, var(--ax-surface-2) 50%, var(--ax-surface) 75%);
  background-size: 200% 100%;
  animation: ax-shimmer 1.5s infinite;
  border-radius: var(--ax-radius-sm);
}

@keyframes ax-shimmer {
  0% {
    background-position: 200% 0
  }

  100% {
    background-position: -200% 0
  }
}

/* =============================================
   GAME PAGE LAYOUT
   ============================================= */
.ax-game-page {
  padding: 30px 0;
}

.ax-game-layout {
  display: grid;
  grid-template-columns: 1fr var(--ax-sidebar-width);
  gap: 30px;
  align-items: start;
}

.ax-game-player-wrap {
  background: var(--ax-bg-card);
  border-radius: var(--ax-radius-lg);
  border: 1px solid var(--ax-border);
  overflow: hidden;
}

.ax-game-player-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--ax-border);
}

.ax-game-player-title {
  font-size: 1.1rem;
  font-weight: 700;
}

.ax-game-player-actions {
  display: flex;
  gap: 8px;
}

#ax-game-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  min-height: 420px;
  background: var(--ax-surface);
  text-align: center;
  padding: 40px;
}

.ax-game-thumb-large {
  width: 100%;
  max-width: 300px;
  border-radius: var(--ax-radius);
  box-shadow: var(--ax-shadow-lg);
}

.ax-play-now-btn {
  font-size: 1.1rem;
  padding: 16px 40px;
  border-radius: var(--ax-radius-full);
  animation: ax-pulse 2s ease-in-out infinite;
}

@keyframes ax-pulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(108, 92, 231, 0.4)
  }

  50% {
    box-shadow: 0 0 0 12px rgba(108, 92, 231, 0)
  }
}

#ax-game-frame-wrap {
  display: none;
  position: relative;
  background: #000;
}

#ax-game-frame-wrap.active {
  display: block;
}

#ax-game-iframe {
  width: 100%;
  border: none;
  display: block;
  min-height: 500px;
}

.ax-fullscreen-btn {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  border: none;
  border-radius: var(--ax-radius-sm);
  padding: 8px 12px;
  cursor: pointer;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background var(--ax-transition);
}

.ax-fullscreen-btn:hover {
  background: var(--ax-primary);
}

/* Game Info Tabs */
.ax-game-tabs {
  margin-top: 20px;
}

.ax-tab-nav {
  display: flex;
  border-bottom: 1px solid var(--ax-border);
  gap: 4px;
  margin-bottom: 20px;
}

.ax-tab-btn {
  padding: 10px 20px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--ax-text-muted);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all var(--ax-transition);
  margin-bottom: -1px;
}

.ax-tab-btn.active {
  color: var(--ax-primary-light);
  border-bottom-color: var(--ax-primary);
}

.ax-tab-btn:hover {
  color: var(--ax-text);
}

.ax-tab-panel {
  display: none;
}

.ax-tab-panel.active {
  display: block;
}

/* Game Meta */
.ax-game-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--ax-border);
  margin-bottom: 20px;
}

.ax-game-rating-large {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ax-stars {
  display: flex;
  gap: 3px;
}

.ax-star {
  font-size: 1.2rem;
  color: var(--ax-text-dim);
  cursor: pointer;
  transition: color var(--ax-transition);
}

.ax-star.active,
.ax-star:hover {
  color: var(--ax-warning);
}

.ax-rating-count {
  font-size: 0.8rem;
  color: var(--ax-text-muted);
}

.ax-game-actions-bar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.ax-like-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--ax-radius-sm);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--ax-transition);
}

.ax-like-btn:hover,
.ax-like-btn.active {
  border-color: var(--ax-success);
  color: var(--ax-success);
  background: rgba(85, 239, 196, 0.1);
}

.ax-dislike-btn:hover,
.ax-dislike-btn.active {
  border-color: var(--ax-danger);
  color: var(--ax-danger);
  background: rgba(214, 48, 49, 0.1);
}

.ax-share-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--ax-radius-sm);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--ax-transition);
}

.ax-share-btn:hover {
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
}

.ax-share-btn[aria-expanded="true"] {
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
  background: rgba(108, 92, 231, 0.1);
}

/* ── Share Dropdown ─────────────────────────────────────────── */
.ax-share-dropdown {
  position: absolute;
  bottom: calc(100% + 10px);
  right: 0;
  z-index: 9999;
  width: 300px;
  background: var(--ax-bg-card);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(108, 92, 231, 0.15);
  padding: 16px;
  animation: ax-share-in 0.18s ease;
  backdrop-filter: blur(12px);
}

@keyframes ax-share-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Arrow pointer */
.ax-share-dropdown::after {
  content: '';
  position: absolute;
  bottom: -7px;
  right: 18px;
  width: 12px;
  height: 12px;
  background: var(--ax-bg-card);
  border-right: 1px solid var(--ax-border);
  border-bottom: 1px solid var(--ax-border);
  transform: rotate(45deg);
}

.ax-share-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ax-heading);
}

.ax-share-close {
  background: none;
  border: none;
  color: var(--ax-text-dim);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 2px 6px;
  border-radius: var(--ax-radius-sm);
  transition: background var(--ax-transition), color var(--ax-transition);
}

.ax-share-close:hover {
  background: var(--ax-surface);
  color: var(--ax-text);
}

.ax-share-copy-row {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.ax-share-url-input {
  flex: 1;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text-muted);
  font-size: 0.75rem;
  padding: 8px 10px;
  outline: none;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ax-share-copy-btn {
  flex-shrink: 0;
  padding: 8px 14px;
  background: var(--ax-primary);
  color: #fff;
  border: none;
  border-radius: var(--ax-radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--ax-transition), transform 0.15s;
}

.ax-share-copy-btn:hover {
  background: var(--ax-primary-dark);
}

.ax-share-copy-btn.copied {
  background: var(--ax-success);
  color: #0f1923;
}

.ax-share-socials {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.ax-share-social {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: var(--ax-radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--ax-transition);
  border: 1px solid var(--ax-border);
  color: #fff;
}

.ax-share-fb {
  background: #1877F2;
  border-color: #1877F2;
}

.ax-share-tw {
  background: #000;
  border-color: #333;
}

.ax-share-wa {
  background: #25D366;
  border-color: #25D366;
  color: #fff;
}

.ax-share-rd {
  background: #FF4500;
  border-color: #FF4500;
}

.ax-share-fb:hover {
  background: #0d65d8;
  color: #fff;
}

.ax-share-tw:hover {
  background: #1a1a1a;
  color: #fff;
}

.ax-share-wa:hover {
  background: #1da851;
  color: #fff;
}

.ax-share-rd:hover {
  background: #e03d00;
  color: #fff;
}

/* Mobile: full-width dropdown */
@media (max-width: 480px) {
  .ax-share-dropdown {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    border-radius: var(--ax-radius-lg) var(--ax-radius-lg) 0 0;
    border-bottom: none;
    padding: 20px;
  }

  .ax-share-dropdown::after {
    display: none;
  }

  .ax-share-socials {
    grid-template-columns: 1fr 1fr;
  }
}


/* =============================================
   SIDEBAR
   ============================================= */
.ax-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.ax-widget {
  background: var(--ax-bg-card);
  border: 1px solid var(--ax-border-light);
  border-radius: var(--ax-radius);
  padding: 20px;
}

.ax-widget-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ax-heading);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ax-border);
  display: flex;
  align-items: center;
  gap: 8px;
}

.ax-games-list-sm {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ax-game-list-item {
  display: flex;
  gap: 12px;
  padding: 8px;
  border-radius: var(--ax-radius-sm);
  transition: background var(--ax-transition);
  align-items: center;
}

.ax-game-list-item:hover {
  background: var(--ax-surface);
}

.ax-game-list-thumb {
  width: 60px;
  height: 45px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

.ax-game-list-info h4 {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ax-heading);
  margin-bottom: 4px;
}

.ax-game-list-meta {
  font-size: 0.72rem;
  color: var(--ax-text-dim);
  display: flex;
  gap: 8px;
}

/* =============================================
/* =============================================
   AD SLOTS — Responsive
   ============================================= */

/* ── Base container ──────────────────────────── */
.ax-ad-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  overflow: hidden;
  box-sizing: border-box;
}

/* ── "Advertisement" label ───────────────────── */
.ax-ad-label {
  display: block;
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ax-text-dim);
  opacity: 0.6;
  margin-bottom: 2px;
  text-align: center;
  width: 100%;
}

/* ── Inner ad wrapper ────────────────────────── */
.ax-ad-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-sizing: border-box;
}

.ax-ad-inner ins,
.ax-ad-inner iframe,
.ax-ad-inner>* {
  display: block;
  max-width: 100%;
}

/* ── Placeholder (no ad configured) ─────────── */
.ax-ad-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  min-height: inherit;
  background: var(--ax-surface);
  border: 1px dashed var(--ax-border);
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text-dim);
  font-size: 0.75rem;
  text-align: center;
  padding: 12px;
}

.ax-ad-placeholder span {
  font-size: 0.72rem;
  font-weight: 600;
}

.ax-ad-placeholder small {
  font-size: 0.65rem;
  opacity: 0.7;
}

/* ── Per-slot sizing ─────────────────────────── */
/* Header: full-width leaderboard bar */
.ax-ad-header {
  width: 100%;
  min-height: 90px;
  margin: 10px 0;
  background: transparent;
}

/* Below-game: full width, leaderboard height */
.ax-ad-below_game {
  width: 100%;
  min-height: 90px;
  margin-top: 20px;
}

/* Sidebar: fixed 300px wide */
.ax-ad-sidebar {
  width: 100%;
  min-height: 250px;
}

/* In-game: compact banner */
.ax-ad-in_game {
  width: 100%;
  min-height: 50px;
  margin: 8px 0;
}

/* ── Size modifier classes ───────────────────── */
.ax-ad-size-728x90 .ax-ad-inner {
  min-height: 90px;
}

.ax-ad-size-970x90 .ax-ad-inner {
  min-height: 90px;
}

.ax-ad-size-320x50 .ax-ad-inner {
  min-height: 50px;
}

.ax-ad-size-300x250 .ax-ad-inner {
  min-height: 250px;
}

.ax-ad-size-300x600 .ax-ad-inner {
  min-height: 600px;
}

.ax-ad-size-responsive .ax-ad-inner {
  width: 100%;
  min-height: 90px;
}

/* Keep AdSense ins block correctly sized */
.ax-ad-slot ins {
  display: block;
  width: 100%;
}

/* ── Responsive breakpoints ──────────────────── */
/* On tablet/mobile, fixed-width ads become responsive */
@media (max-width: 768px) {

  .ax-ad-size-728x90 .ax-ad-inner,
  .ax-ad-size-970x90 .ax-ad-inner {
    width: 100% !important;
    height: auto !important;
    min-height: 50px;
  }

  .ax-ad-size-728x90 .ax-ad-inner ins,
  .ax-ad-size-970x90 .ax-ad-inner ins {
    width: 100% !important;
    height: 50px !important;
  }
}

@media (max-width: 480px) {

  /* On very small screens: hide tall sidebar ad, show mobile banner */
  .ax-ad-size-300x600 .ax-ad-inner {
    height: 250px !important;
  }

  /* Header ad collapses to mobile banner height */
  .ax-ad-header {
    min-height: 50px;
  }
}


/* =============================================
   FILTER BAR
   ============================================= */
.ax-filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 20px 0;
  border-bottom: 1px solid var(--ax-border);
  margin-bottom: 30px;
}

.ax-filter-group {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.ax-filter-btn {
  padding: 7px 16px;
  border-radius: var(--ax-radius-full);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--ax-transition);
}

.ax-filter-btn:hover {
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
}

.ax-filter-btn.active {
  background: var(--ax-primary);
  border-color: var(--ax-primary);
  color: #fff;
}

.ax-sort-select {
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text);
  padding: 8px 12px;
  font-size: 0.85rem;
  margin-left: auto;
  cursor: pointer;
  outline: none;
  transition: border-color var(--ax-transition);
}

.ax-sort-select:focus {
  border-color: var(--ax-primary);
}

/* =============================================
   CATEGORY PILLS
   ============================================= */
.ax-categories-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 24px 0;
}

.ax-cat-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  min-width: 80px;
  background: var(--ax-bg-card);
  border: 1px solid var(--ax-border-light);
  border-radius: var(--ax-radius);
  color: var(--ax-text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--ax-transition);
  text-align: center;
}

.ax-cat-pill .cat-icon {
  font-size: 1.5rem;
}

.ax-cat-pill:hover,
.ax-cat-pill.active {
  background: rgba(108, 92, 231, 0.1);
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
  transform: translateY(-2px);
}

/* =============================================
   BREADCRUMB
   ============================================= */
.ax-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--ax-text-dim);
  flex-wrap: wrap;
  padding: 16px 0;
}

.ax-breadcrumb a {
  color: var(--ax-text-muted);
  transition: color var(--ax-transition);
}

.ax-breadcrumb a:hover {
  color: var(--ax-primary-light);
}

.ax-breadcrumb .sep {
  color: var(--ax-text-dim);
}

.ax-breadcrumb .current {
  color: var(--ax-text);
}

/* =============================================
   PAGINATION
   ============================================= */
.ax-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 40px 0;
  flex-wrap: wrap;
}

.ax-page-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--ax-radius-sm);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
  text-decoration: none;
}

.ax-page-btn:hover {
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
}

.ax-page-btn.active {
  background: var(--ax-primary);
  border-color: var(--ax-primary);
  color: #fff;
}

.ax-load-more {
  margin: 20px auto;
  display: block;
  padding: 14px 40px;
}

/* =============================================
   FOOTER
   ============================================= */
#ax-footer {
  background: var(--ax-bg-card);
  border-top: 1px solid var(--ax-border);
  margin-top: 60px;
}

.ax-footer-top {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 48px;
  padding: 60px 0 40px;
}

.ax-footer-brand .ax-logo-text {
  font-size: 1.8rem;
  margin-bottom: 12px;
  display: block;
}

.ax-footer-brand p {
  color: var(--ax-text-muted);
  font-size: 0.875rem;
  line-height: 1.7;
  max-width: 260px;
  margin-bottom: 20px;
}

.ax-social-links {
  display: flex;
  gap: 10px;
}

.ax-social-link {
  width: 36px;
  height: 36px;
  border-radius: var(--ax-radius-sm);
  border: 1px solid var(--ax-border);
  background: var(--ax-surface);
  color: var(--ax-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
  font-size: 0.85rem;
}

.ax-social-link:hover {
  border-color: var(--ax-primary);
  color: var(--ax-primary-light);
  background: rgba(108, 92, 231, 0.1);
}

.ax-footer-col h4 {
  font-size: 0.9rem;
  margin-bottom: 16px;
  color: var(--ax-heading);
}

.ax-footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ax-footer-col ul li a {
  color: var(--ax-text-muted);
  font-size: 0.85rem;
  transition: color var(--ax-transition);
  display: flex;
  align-items: center;
  gap: 6px;
}

.ax-footer-col ul li a:hover {
  color: var(--ax-primary-light);
}

.ax-footer-bottom {
  border-top: 1px solid var(--ax-border);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.ax-footer-bottom p {
  font-size: 0.8rem;
  color: var(--ax-text-dim);
}

.ax-footer-links {
  display: flex;
  gap: 16px;
}

.ax-footer-links a {
  font-size: 0.8rem;
  color: var(--ax-text-dim);
  transition: color var(--ax-transition);
}

.ax-footer-links a:hover {
  color: var(--ax-primary-light);
}

/* =============================================
   COOKIE NOTICE
   ============================================= */
.ax-cookie-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--ax-surface);
  border-top: 1px solid var(--ax-border);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  z-index: 9999;
  transform: translateY(100%);
  transition: transform var(--ax-transition-slow);
}

.ax-cookie-bar.show {
  transform: translateY(0);
}

.ax-cookie-bar p {
  font-size: 0.85rem;
  color: var(--ax-text-muted);
}

/* =============================================
   NOTIFICATIONS / TOAST
   ============================================= */
.ax-toast-container {
  position: fixed;
  bottom: 30px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

.ax-toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius);
  box-shadow: var(--ax-shadow-lg);
  font-size: 0.875rem;
  color: var(--ax-text);
  min-width: 260px;
  max-width: 320px;
  animation: ax-toast-in 0.3s ease;
}

@keyframes ax-toast-in {
  from {
    opacity: 0;
    transform: translateY(20px)
  }

  to {
    opacity: 1;
    transform: translateY(0)
  }
}

.ax-toast-success {
  border-left: 3px solid var(--ax-success);
}

.ax-toast-error {
  border-left: 3px solid var(--ax-danger);
}

.ax-toast-info {
  border-left: 3px solid var(--ax-primary);
}

/* =============================================
   LOADING / SPINNER
   ============================================= */
.ax-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--ax-border);
  border-top-color: var(--ax-primary);
  border-radius: 50%;
  animation: ax-spin 0.7s linear infinite;
}

@keyframes ax-spin {
  to {
    transform: rotate(360deg)
  }
}

/* =============================================
   COMMENTS AREA
   ============================================= */
.ax-comments {
  margin-top: 40px;
}

.ax-comments-title {
  font-size: 1.2rem;
  margin-bottom: 24px;
}

.comment-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.comment-body {
  background: var(--ax-bg-card);
  border: 1px solid var(--ax-border-light);
  border-radius: var(--ax-radius);
  padding: 20px;
}

.comment-author {
  font-weight: 600;
  color: var(--ax-heading);
  margin-bottom: 4px;
}

.comment-meta {
  font-size: 0.75rem;
  color: var(--ax-text-dim);
  margin-bottom: 12px;
}

.comment-content {
  font-size: 0.9rem;
  color: var(--ax-text);
  line-height: 1.65;
}

#commentform input,
#commentform textarea {
  background: var(--ax-surface);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text);
  padding: 12px 16px;
  font-size: 0.9rem;
  width: 100%;
  outline: none;
  transition: border-color var(--ax-transition);
}

#commentform input:focus,
#commentform textarea:focus {
  border-color: var(--ax-primary);
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1200px) {
  .ax-footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 1024px) {
  .ax-game-layout {
    grid-template-columns: 1fr;
  }

  .ax-sidebar {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .ax-widget {
    flex: 1;
    min-width: 280px;
  }
}

@media (max-width: 768px) {
  :root {
    --ax-header-height: 60px;
  }

  .ax-nav {
    display: none;
  }

  .ax-nav.open {
    display: flex;
    position: fixed;
    top: var(--ax-header-height);
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--ax-bg);
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    overflow-y: auto;
    z-index: 999;
    border-top: 1px solid var(--ax-border);
  }

  .ax-nav.open ul {
    flex-direction: column;
    width: 100%;
    gap: 4px;
  }

  .ax-nav.open ul li a {
    width: 100%;
    padding: 14px 16px;
  }

  .ax-hamburger {
    display: flex;
  }

  .ax-search-bar {
    width: 150px;
  }

  .ax-search-bar:focus-within {
    width: 180px;
  }

  .ax-games-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
  }

  .ax-slide {
    height: 320px;
  }

  .ax-slide-content {
    padding: 24px;
  }

  .ax-footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  .ax-section {
    padding: 40px 0;
  }
}

@media (max-width: 480px) {
  .ax-games-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .ax-footer-top {
    grid-template-columns: 1fr;
  }

  .ax-footer-brand {
    display: none;
  }

  .ax-search-bar {
    display: none;
  }
}

/* =============================================
   SCROLLBAR
   ============================================= */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--ax-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--ax-surface-2);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--ax-primary);
}

/* =============================================
   SELECTION
   ============================================= */
::selection {
  background: rgba(108, 92, 231, 0.3);
  color: #fff;
}

/* =============================================
   UTILITIES
   ============================================= */
.ax-text-center {
  text-align: center;
}

.ax-text-muted {
  color: var(--ax-text-muted);
}

.ax-mt-20 {
  margin-top: 20px;
}

.ax-mb-20 {
  margin-bottom: 20px;
}

.ax-hidden {
  display: none !important;
}

.ax-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* =============================================
   FAVORITES PANEL
   ============================================= */

/* ── Overlay backdrop ──────────────────────── */
.ax-fav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(3px);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.ax-fav-overlay.open {
  opacity: 1;
  pointer-events: all;
}

/* ── Slide-in panel ────────────────────────── */
.ax-fav-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 360px;
  height: 100%;
  background: var(--ax-bg-card);
  border-left: 1px solid var(--ax-border);
  box-shadow: -8px 0 40px rgba(0, 0, 0, 0.4);
  z-index: 10001;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.ax-fav-panel.open {
  transform: translateX(0);
}

body.ax-panel-open {
  overflow: hidden;
}

/* ── Panel header ──────────────────────────── */
.ax-fav-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid var(--ax-border);
  background: var(--ax-surface);
  flex-shrink: 0;
}

.ax-fav-panel-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ax-heading);
}

.ax-fav-panel-close {
  width: 32px;
  height: 32px;
  background: var(--ax-bg-card);
  border: 1px solid var(--ax-border);
  border-radius: var(--ax-radius-sm);
  color: var(--ax-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  transition: all var(--ax-transition);
}

.ax-fav-panel-close:hover {
  background: var(--ax-danger);
  border-color: var(--ax-danger);
  color: #fff;
}

/* ── Panel body (scrollable) ───────────────── */
.ax-fav-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  scroll-behavior: smooth;
}

.ax-fav-panel-body::-webkit-scrollbar {
  width: 4px;
}

.ax-fav-panel-body::-webkit-scrollbar-track {
  background: transparent;
}

.ax-fav-panel-body::-webkit-scrollbar-thumb {
  background: var(--ax-surface-2);
  border-radius: 2px;
}

/* ── Game grid inside panel ────────────────── */
.ax-fav-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ax-fav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--ax-surface);
  border: 1px solid var(--ax-border-light);
  border-radius: var(--ax-radius-sm);
  transition: border-color var(--ax-transition), background var(--ax-transition);
}

.ax-fav-item:hover {
  border-color: var(--ax-border);
  background: var(--ax-surface-2, var(--ax-surface));
}

.ax-fav-thumb-link {
  flex-shrink: 0;
  display: block;
}

.ax-fav-thumb {
  width: 72px;
  height: 54px;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  background: var(--ax-bg);
}

.ax-fav-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ax-fav-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: var(--ax-surface-2, var(--ax-bg));
}

.ax-fav-thumb-overlay {
  position: absolute;
  inset: 0;
  background: rgba(108, 92, 231, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0;
  transition: opacity var(--ax-transition);
  border-radius: 6px;
}

.ax-fav-item:hover .ax-fav-thumb-overlay {
  opacity: 1;
}

.ax-fav-info {
  flex: 1;
  min-width: 0;
}

.ax-fav-item-title {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ax-heading);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
  transition: color var(--ax-transition);
}

.ax-fav-item-title:hover {
  color: var(--ax-primary-light);
}

.ax-fav-item-cat {
  font-size: 0.72rem;
  color: var(--ax-primary-light);
  background: rgba(108, 92, 231, 0.12);
  padding: 2px 7px;
  border-radius: var(--ax-radius-full);
}

.ax-fav-remove {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  background: none;
  border: 1px solid var(--ax-border);
  border-radius: 50%;
  color: var(--ax-text-dim);
  cursor: pointer;
  font-size: 0.7rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ax-transition);
}

.ax-fav-remove:hover {
  background: var(--ax-danger);
  border-color: var(--ax-danger);
  color: #fff;
}

/* ── Empty state ───────────────────────────── */
.ax-fav-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  color: var(--ax-text-muted);
  gap: 10px;
}

.ax-fav-empty p {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ax-text);
}

.ax-fav-empty small {
  font-size: 0.8rem;
  color: var(--ax-text-dim);
}

/* ── Loading spinner inside panel ──────────── */
.ax-fav-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

/* ── Header badge counter ──────────────────── */
.ax-fav-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  background: var(--ax-danger);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  border-radius: var(--ax-radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  border: 2px solid var(--ax-bg);
  pointer-events: none;
}

/* ── Mobile: full-width panel ──────────────── */
@media (max-width: 480px) {
  .ax-fav-panel {
    width: 100%;
    border-left: none;
    border-top: 1px solid var(--ax-border);
    border-radius: var(--ax-radius-lg) var(--ax-radius-lg) 0 0;
    top: auto;
    bottom: 0;
    right: 0;
    height: 85dvh;
    transform: translateY(100%);
  }

  .ax-fav-panel.open {
    transform: translateY(0);
  }
}