/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #1e3a5f;
  --primary-light: #2c5282;
  --primary-dark: #152a45;
  --accent: #3b82f6;
  --accent-light: #60a5fa;
  --bg: #ffffff;
  --bg-gray: #f0f4f8;
  --bg-card: #ffffff;
  --text: #1a202c;
  --text-light: #4a5568;
  --text-muted: #a0aec0;
  --border: #e2e8f0;
  --shadow: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --max-width: 1200px;
  --header-height: 64px;
}

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg-gray);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--primary); }

img { max-width: 100%; height: auto; display: block; }

.gamelist-container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

/* ===== Header ===== */
.gamelist-site-header {
  background: var(--primary);
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.gamelist-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.gamelist-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
}
.gamelist-logo:hover { color: var(--accent-light); }
.gamelist-logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  object-fit: cover;
  display: block;
  border: 2px solid rgba(255,255,255,0.2);
}
.gamelist-logo-text { color: #fff; font-size: 1.3rem; }
.gamelist-logo-text span { color: var(--accent-light); }

.gamelist-main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.gamelist-main-nav a {
  padding: 8px 14px;
  border-radius: 8px;
  color: rgba(255,255,255,0.85);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}

.gamelist-main-nav a:hover, .gamelist-main-nav a.gamelist-active {
  background: rgba(255,255,255,0.15);
  color: #fff;
}

.gamelist-nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.gamelist-nav-toggle span {
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: 0.3s;
}

/* ===== Hero Carousel ===== */
.gamelist-hero-carousel {
  position: relative;
  width: 100%;
  max-width: var(--max-width);
  margin: 24px auto;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 21/8;
  background: var(--primary-dark);
}

.gamelist-carousel-track {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.5s ease;
}

.gamelist-carousel-slide {
  min-width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.gamelist-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gamelist-carousel-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px 32px 28px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: #fff;
}

.gamelist-carousel-overlay h2 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 6px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.gamelist-carousel-overlay p {
  font-size: 0.95rem;
  opacity: 0.9;
  max-width: 500px;
}

.gamelist-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s;
  z-index: 10;
}
.gamelist-carousel-btn:hover {
  background: rgba(255,255,255,0.35);
}
.gamelist-carousel-prev { left: 16px; }
.gamelist-carousel-next { right: 16px; }

.gamelist-carousel-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}
.gamelist-carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}
.gamelist-carousel-dot.gamelist-active {
  background: #fff;
  transform: scale(1.2);
}

/* ===== Featured Banner ===== */
.gamelist-featured-banner {
  display: block;
  position: relative;
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 48px;
  box-shadow: var(--shadow-lg);
  height: 280px;
  text-decoration: none;
  color: #fff;
}
.gamelist-featured-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s;
}
.gamelist-featured-banner:hover .gamelist-featured-bg { transform: scale(1.03); }
.gamelist-featured-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15,23,42,0.85) 0%, rgba(15,23,42,0.5) 50%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px 48px;
}
.gamelist-featured-tag {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  width: fit-content;
}
.gamelist-featured-overlay h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 8px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
  max-width: 500px;
}
.gamelist-featured-overlay p {
  font-size: 0.95rem;
  opacity: 0.9;
  max-width: 450px;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.gamelist-featured-play {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 10px 28px;
  border-radius: 50px;
  margin-top: 16px;
  width: fit-content;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(59,130,246,0.4);
}
.gamelist-featured-banner:hover .gamelist-featured-play {
  background: #fff;
  color: var(--primary);
}

@media (max-width: 768px) {
  .gamelist-featured-banner { height: 200px; }
  .gamelist-featured-overlay { padding: 24px; }
  .gamelist-featured-overlay h2 { font-size: 1.3rem; }
  .gamelist-featured-overlay p { font-size: 0.8rem; }
}

/* ===== Category Pills ===== */
.gamelist-category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 48px;
  padding: 24px 0;
}
.gamelist-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 24px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary);
  background: var(--bg-card);
  border: 2px solid var(--border);
  transition: all 0.25s;
  text-decoration: none;
  box-shadow: var(--shadow);
}
.gamelist-pill:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.gamelist-pill-hot {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.gamelist-pill-hot:hover {
  background: var(--accent);
  border-color: var(--accent);
}

/* ===== Sections ===== */
.gamelist-section { margin-bottom: 48px; }

.gamelist-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--primary);
}
.gamelist-section-header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
}
.gamelist-view-all {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}
.gamelist-view-all:hover { color: var(--primary); }

.gamelist-section-desc {
  color: var(--text-light);
  margin-bottom: 24px;
  font-size: 1rem;
}

/* ===== Game Grid ===== */
.gamelist-game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}

/* ===== Game Card ===== */
.gamelist-game-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  color: var(--text);
  border: 1px solid var(--border);
}
.gamelist-game-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  color: var(--text);
  border-color: var(--accent);
}

.gamelist-game-card-img {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: #e2e8f0;
}
.gamelist-game-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.gamelist-game-card:hover .gamelist-game-card-img img { transform: scale(1.05); }

.gamelist-game-card-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gamelist-game-card-info {
  padding: 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.gamelist-game-card-info h3 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.gamelist-game-card-info p {
  font-size: 0.8rem;
  color: var(--text-light);
  line-height: 1.5;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.gamelist-game-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.gamelist-game-rating {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
}
.gamelist-game-category {
  background: var(--bg-gray);
  color: var(--text-light);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 4px;
}

/* ===== Game Detail ===== */
.gamelist-game-detail { margin-bottom: 48px; }

.gamelist-game-detail-header { margin-bottom: 24px; }
.gamelist-game-detail-header h1 { font-size: 1.8rem; font-weight: 800; margin-bottom: 10px; }
.gamelist-game-detail-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.gamelist-game-detail-top {
  display: grid;
  grid-template-columns: 400px 1fr;
  gap: 32px;
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 28px;
  margin-bottom: 24px;
  border: 1px solid var(--border);
}
.gamelist-game-detail-cover { border-radius: var(--radius-sm); overflow: hidden; background: #e2e8f0; }
.gamelist-game-detail-cover img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 16/10; }
.gamelist-game-detail-info { display: flex; flex-direction: column; justify-content: center; }
.gamelist-game-detail-info h1 { font-size: 1.8rem; font-weight: 800; margin-bottom: 12px; color: var(--primary); }
.gamelist-game-detail-desc {
  color: var(--text-light); line-height: 1.7; margin: 16px 0 20px; font-size: 0.95rem;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.gamelist-game-date { color: var(--text-muted); font-size: 0.8rem; }
.gamelist-play-now-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--primary); color: #fff; font-size: 1.1rem; font-weight: 700;
  padding: 14px 40px; border-radius: 50px; transition: all 0.3s; text-align: center;
  width: fit-content; box-shadow: 0 4px 16px rgba(30,58,95,0.3);
}
.gamelist-play-now-btn:hover {
  background: var(--accent); color: #fff; transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(59,130,246,0.4);
}
.gamelist-game-detail-tags { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.gamelist-game-detail-tags span {
  background: var(--bg-gray); color: var(--text-light); font-size: 0.75rem; font-weight: 500;
  padding: 4px 12px; border-radius: 20px; border: 1px solid var(--border);
}

/* Play page */
.gamelist-play-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
.gamelist-play-header h1 { font-size: 1.4rem; font-weight: 700; }
.gamelist-back-to-detail {
  font-size: 0.9rem; font-weight: 500; color: var(--accent); padding: 8px 16px;
  border-radius: 8px; border: 1px solid var(--accent); transition: all 0.2s;
}
.gamelist-back-to-detail:hover { background: var(--accent); color: #fff; }

.gamelist-game-frame-wrapper { position: relative; background: #000; border-radius: var(--radius); overflow: hidden; margin-bottom: 32px; }
.gamelist-game-frame-wrapper iframe { width: 100%; height: 600px; border: none; display: block; }
.gamelist-fullscreen-btn {
  position: absolute; bottom: 12px; right: 12px; background: rgba(0,0,0,0.7); color: #fff;
  border: none; padding: 8px 16px; border-radius: 8px; cursor: pointer; font-size: 0.85rem;
  font-weight: 500; transition: background 0.2s; z-index: 10;
}
.gamelist-fullscreen-btn:hover { background: var(--accent); }

.gamelist-game-detail-content {
  background: var(--bg-card); border-radius: var(--radius); padding: 32px;
  box-shadow: var(--shadow); border: 1px solid var(--border);
}
.gamelist-game-detail-content h2 { font-size: 1.4rem; font-weight: 700; margin-bottom: 16px; color: var(--primary); }
.gamelist-game-detail-content h3 { font-size: 1.1rem; font-weight: 600; margin: 24px 0 12px; color: var(--primary); }
.gamelist-game-detail-content p { color: var(--text-light); line-height: 1.8; margin-bottom: 12px; }
.gamelist-game-detail-content ul { padding-left: 24px; margin-bottom: 12px; }
.gamelist-game-detail-content li { color: var(--text-light); line-height: 1.8; margin-bottom: 6px; }

/* ===== Breadcrumb ===== */
.gamelist-breadcrumb { padding: 16px 0; font-size: 0.85rem; color: var(--text-muted); }
.gamelist-breadcrumb a { color: var(--text-light); }
.gamelist-breadcrumb a:hover { color: var(--accent); }
.gamelist-breadcrumb span { margin: 0 6px; }

/* ===== Page Content ===== */
.gamelist-page-content {
  background: var(--bg-card); border-radius: var(--radius); padding: 40px;
  box-shadow: var(--shadow); margin-bottom: 48px; border: 1px solid var(--border);
}
.gamelist-page-content h1 { font-size: 2rem; font-weight: 800; margin-bottom: 8px; color: var(--primary); }
.gamelist-page-content h2 { font-size: 1.3rem; font-weight: 700; margin: 32px 0 12px; color: var(--primary); }
.gamelist-page-content h3 { font-size: 1.05rem; font-weight: 600; margin: 20px 0 8px; color: var(--primary); }
.gamelist-page-content p { color: var(--text-light); line-height: 1.8; margin-bottom: 12px; }
.gamelist-page-content ul { padding-left: 24px; margin-bottom: 16px; }
.gamelist-page-content li { color: var(--text-light); line-height: 1.8; margin-bottom: 6px; }
.gamelist-last-updated { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 24px; }

/* ===== Contact Cards ===== */
.gamelist-contact-info { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; margin: 32px 0; }
.gamelist-contact-card { background: var(--bg-gray); border-radius: var(--radius-sm); padding: 24px; border: 1px solid var(--border); }
.gamelist-contact-card h3 { margin-top: 0; color: var(--primary); }
.gamelist-contact-email { display: inline-block; margin-top: 8px; font-weight: 600; font-size: 1rem; }

/* ===== FAQ ===== */
.gamelist-faq { margin-top: 16px; }
.gamelist-faq-item { background: var(--bg-gray); border-radius: var(--radius-sm); padding: 20px 24px; margin-bottom: 12px; border: 1px solid var(--border); }
.gamelist-faq-item h3 { margin: 0 0 8px; font-size: 1rem; color: var(--primary); }
.gamelist-faq-item p { margin: 0; font-size: 0.9rem; }

/* ===== SEO Content ===== */
.gamelist-seo-content { background: var(--bg-card); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); border: 1px solid var(--border); }
.gamelist-seo-content h2 { margin-top: 0; color: var(--primary); }

/* ===== Footer ===== */
.gamelist-site-footer { background: var(--primary-dark); color: rgba(255,255,255,0.7); padding: 48px 0 0; margin-top: 60px; }
.gamelist-footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.gamelist-footer-col h3 { color: #fff; font-size: 1.2rem; margin-bottom: 12px; }
.gamelist-footer-col h4 { color: #fff; font-size: 0.95rem; margin-bottom: 12px; }
.gamelist-footer-col p { font-size: 0.85rem; line-height: 1.7; }
.gamelist-footer-col ul { list-style: none; }
.gamelist-footer-col li { margin-bottom: 8px; }
.gamelist-footer-col a { color: rgba(255,255,255,0.7); font-size: 0.85rem; }
.gamelist-footer-col a:hover { color: var(--accent-light); }
.gamelist-footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 20px 0; text-align: center; font-size: 0.8rem; }

/* ===== 404 Page ===== */
.gamelist-page-404 { text-align: center; padding: 60px 20px; max-width: 720px; margin: 0 auto; }

/* 404 Scene */
.gamelist-404-scene {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  height: 180px;
}
.gamelist-404-number {
  display: flex;
  gap: 8px;
  line-height: 1;
}
.gamelist-404-digit {
  font-size: 9rem;
  font-weight: 900;
  color: var(--primary);
  text-shadow: 4px 4px 0 rgba(30,58,95,0.15);
  animation: gamelist-404-bounce 2s ease-in-out infinite;
}
.gamelist-404-d1 { animation-delay: 0s; }
.gamelist-404-d2 { animation-delay: 0.3s; color: var(--accent); }
.gamelist-404-d3 { animation-delay: 0.6s; }

@keyframes gamelist-404-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* Ghost character */
.gamelist-404-ghost {
  position: absolute;
  right: 15%;
  top: 10px;
  animation: gamelist-404-float 3s ease-in-out infinite;
}
@keyframes gamelist-404-float {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50% { transform: translateY(-15px) rotate(5deg); }
}
.gamelist-404-ghost-body {
  width: 56px;
  height: 48px;
  background: var(--accent);
  border-radius: 28px 28px 0 0;
  position: relative;
  box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}
.gamelist-404-ghost-eyes {
  display: flex;
  gap: 10px;
  justify-content: center;
  padding-top: 14px;
}
.gamelist-404-ghost-eyes span {
  width: 10px;
  height: 12px;
  background: #fff;
  border-radius: 50%;
  position: relative;
}
.gamelist-404-ghost-eyes span::after {
  content: '';
  position: absolute;
  width: 5px;
  height: 5px;
  background: var(--primary-dark);
  border-radius: 50%;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
}
.gamelist-404-ghost-mouth {
  width: 8px;
  height: 8px;
  background: #fff;
  border-radius: 50%;
  margin: 6px auto 0;
}
.gamelist-404-ghost-skirt {
  display: flex;
  width: 56px;
}
.gamelist-404-ghost-skirt::before,
.gamelist-404-ghost-skirt::after {
  content: '';
  width: 28px;
  height: 14px;
  background: var(--accent);
}
.gamelist-404-ghost-skirt::before { border-radius: 0 0 0 14px; }
.gamelist-404-ghost-skirt::after { border-radius: 0 0 14px 0; }

/* Text content */
.gamelist-page-404 h1 { font-size: 2.2rem; font-weight: 800; margin-bottom: 12px; color: var(--primary); }
.gamelist-404-subtitle { font-size: 1.1rem; color: var(--accent); font-weight: 500; margin-bottom: 8px; }
.gamelist-page-404 > p { color: var(--text-light); line-height: 1.7; margin-bottom: 32px; max-width: 480px; margin-left: auto; margin-right: auto; }

/* Action buttons */
.gamelist-404-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 36px; }
.gamelist-404-btn { display: inline-flex; align-items: center; gap: 6px; padding: 12px 28px; border-radius: 50px; font-size: 0.95rem; font-weight: 600; transition: all 0.25s; text-decoration: none; }
.gamelist-404-btn-primary { background: var(--primary); color: #fff; box-shadow: 0 4px 16px rgba(30,58,95,0.3); }
.gamelist-404-btn-primary:hover { background: var(--accent); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(59,130,246,0.4); }
.gamelist-404-btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.gamelist-404-btn-outline:hover { background: var(--primary); color: #fff; transform: translateY(-2px); }

/* Divider */
.gamelist-404-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 28px;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.gamelist-404-divider::before,
.gamelist-404-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Recommended games */
.gamelist-404-recs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 36px;
}
.gamelist-404-rec-card {
  text-decoration: none;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: all 0.25s;
  box-shadow: var(--shadow);
}
.gamelist-404-rec-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}
.gamelist-404-rec-card img {
  width: 100%;
  height: 90px;
  object-fit: cover;
  display: block;
}
.gamelist-404-rec-info {
  padding: 8px 10px;
}
.gamelist-404-rec-info h4 {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gamelist-404-rec-info span {
  font-size: 0.75rem;
  color: #f59e0b;
  font-weight: 600;
}

/* Hint */
.gamelist-404-hint { font-size: 0.85rem; color: var(--text-muted); }
.gamelist-404-hint a { color: var(--accent); font-weight: 500; }

@media (max-width: 768px) {
  .gamelist-404-digit { font-size: 5rem; }
  .gamelist-404-scene { height: 130px; }
  .gamelist-404-ghost { right: 5%; }
  .gamelist-404-ghost-body { width: 40px; height: 36px; border-radius: 20px 20px 0 0; }
  .gamelist-404-ghost-eyes { gap: 6px; padding-top: 10px; }
  .gamelist-404-ghost-eyes span { width: 7px; height: 9px; }
  .gamelist-404-ghost-skirt { width: 40px; }
  .gamelist-404-ghost-skirt::before, .gamelist-404-ghost-skirt::after { width: 20px; height: 10px; }
  .gamelist-404-recs { grid-template-columns: repeat(2, 1fr); }
  .gamelist-page-404 h1 { font-size: 1.6rem; }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .gamelist-main-nav {
    display: none; position: absolute; top: var(--header-height); left: 0; right: 0;
    background: var(--primary); flex-direction: column; padding: 16px;
    border-bottom: 1px solid rgba(255,255,255,0.1); box-shadow: var(--shadow-md);
  }
  .gamelist-main-nav.gamelist-open { display: flex; }
  .gamelist-nav-toggle { display: flex; }
  .gamelist-hero-carousel { aspect-ratio: 16/9; margin: 16px; }
  .gamelist-carousel-overlay h2 { font-size: 1.2rem; }
  .gamelist-carousel-overlay p { font-size: 0.8rem; }
  .gamelist-game-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
  .gamelist-footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .gamelist-game-frame-wrapper iframe { height: 400px; }
  .gamelist-page-content { padding: 24px; }
  .gamelist-game-detail-content { padding: 20px; }
  .gamelist-game-detail-top { grid-template-columns: 1fr; gap: 20px; padding: 20px; }
  .gamelist-game-detail-cover img { aspect-ratio: 16/9; }
}

@media (max-width: 480px) {
  .gamelist-game-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .gamelist-game-card-info { padding: 10px; }
  .gamelist-game-card-info h3 { font-size: 0.85rem; }
  .gamelist-game-card-info p { display: none; }
  .gamelist-game-frame-wrapper iframe { height: 300px; }
}
