/* Reset & Base Variables */
:root {
  --bg-main: #0f111a;
  --bg-card: #1a1d2d;
  --text-primary: #f3f4f6;
  --text-muted: #9ca3af;
  --accent: #6366f1;
  --accent-hover: #4f46e5;
  --border-color: #2a2f45;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-primary);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header */
.site-header {
  text-align: center;
  padding: 3.5rem 0 2.5rem;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 2.5rem;
}

.site-header h1 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 0.5rem;
}

.site-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 540px;
  margin: 0 auto;
}

/* Responsive Game Showcase Layout */
main {
  flex: 1;
}

.game-list {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  margin-bottom: 4rem;
}

.game-showcase {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 1.75rem;
  align-items: stretch;
}

/* Right Preview & Description Panel */
.game-details-panel {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.preview-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.preview-gallery img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: #25293e;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.preview-gallery img:hover {
  transform: scale(1.03);
  border-color: var(--accent);
}

.game-overview h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.game-overview p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}

.game-overview p:last-child {
  margin-bottom: 0;
}

/* Stack vertically on tablets & phones */
@media (max-width: 850px) {
  .game-showcase {
    grid-template-columns: 1fr;
  }
}

/* Game Card */
.game-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.game-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.4);
}

.card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #25293e;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.genre-tag {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background-color: rgba(15, 17, 26, 0.85);
  color: var(--text-primary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  backdrop-filter: blur(4px);
}

.card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-content h2 {
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
}

.card-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
  flex: 1;
}

/* Play Button */
.play-btn {
  display: inline-block;
  text-align: center;
  background-color: var(--accent);
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  padding: 0.75rem 1.25rem;
  border-radius: 8px;
  transition: background-color 0.15s ease;
}

.play-btn:hover {
  background-color: var(--accent-hover);
}

/* Footer & Studio Bio */
.site-footer {
  border-top: 1px solid var(--border-color);
  background-color: #131622;
  padding: 3rem 0 2rem;
  text-align: center;
  color: var(--text-muted);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.studio-bio h3 {
  color: var(--text-primary);
  font-size: 1.25rem;
  margin-bottom: 0.4rem;
}

.studio-bio p {
  max-width: 540px;
  font-size: 0.95rem;
  margin: 0 auto;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.social-btn {
  background-color: var(--bg-card);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.55rem 1.1rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  transition: border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

.social-btn:hover {
  border-color: var(--accent);
  background-color: rgba(99, 102, 241, 0.15);
  transform: translateY(-2px);
}

.copyright {
  font-size: 0.85rem;
  margin-top: 0.5rem;
  opacity: 0.8;
}
/* Clickable Preview Thumbnails & Lightbox */
.preview-gallery img {
  cursor: zoom-in;
}

.lightbox {
  position: fixed;
  inset: 0;
  background-color: rgba(10, 12, 18, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  z-index: 1000;
  backdrop-filter: blur(6px);
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 92vw;
  max-height: 88vh;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.lightbox-close {
  position: absolute;
  top: 1.25rem;
  right: 1.75rem;
  background: none;
  border: none;
  color: #f3f4f6;
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  transition: color 0.15s ease, transform 0.15s ease;
}

.lightbox-close:hover {
  color: var(--accent);
  transform: scale(1.1);
}