/* --- BASIS EINSTELLUNGEN --- */
:root {
  --bg-color: rgb(10, 22, 40);
  --card-bg: rgb(17, 31, 58);
  --accent-color: #d4af37;
  --text-light: #f5f5f5;
  --text-muted: rgb(138, 155, 181);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg-color);
  font-family: 'Segoe UI', system-ui, sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh; 
  overflow-x: hidden;
}

/* --- HEADER --- */
.header {
  text-align: center;
  padding: 50px 20px 20px;
}

.header h1 {
  color: var(--accent-color);
  font-size: 24px;
  letter-spacing: 7px;
  font-weight: normal;
}

/* --- LAYOUT & EINLEITUNG --- */
.main-content {
  flex-grow: 1; 
  max-width: 1200px;
  margin: 0 auto 40px auto;
  padding: 0 20px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 50px; /* Abstand zwischen Einleitungstext und den Karten */
}

.intro-section {
  text-align: center;
  max-width: 750px; 
  margin: 0 auto;
  color: var(--text-muted); 
  font-size: 16px;
  line-height: 1.6;
}

/* --- GRID LAYOUT (Nur für die Karten) --- */
.game-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  width: 100%;
}

/* --- KARTEN DESIGN & HOVER --- */
.game-card {
  display: flex;
  flex-direction: column; 
  background-color: var(--card-bg);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; 
}

.game-card:hover {
  transform: translateY(-8px);
  box-shadow: 0px 10px 30px 0px rgba(212, 175, 55, 0.5);
}

/* --- BILD & RAND OPTIMIERUNG --- */
.image-wrapper {
  position: relative;
  width: 100%;
  
  /* NEU: Wir geben dem Bild wieder eine feste Höhe für mehr Vertikalität */
  height: 400px; 
  
  /* flex-grow: 1 und min-height: 250px werden gelöscht */
}

.image-wrapper img {
  /* position: absolute, top, left, height, width werden gelöscht */
  
  width: 100%;
  height: 100%;
  object-fit: cover; /* Wichtig: Behält das Seitenverhältnis bei und beschneidet das Bild */
  display: block;
}

.card-title {
  color: var(--text-light);
  text-align: center;
  font-size: 18px;
  font-weight: normal;
  padding: 16px; /* Kompakter, gleichmässiger Abstand */
  margin: 0;
  transition: color 0.3s ease;
}

.game-card:hover .card-title {
  color: var(--accent-color);
}

/* --- BUTTON OVERLAY --- */
.card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%; 
  background-color: rgba(10, 22, 40, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 10;
}

.game-card:hover .card-overlay {
  opacity: 1;
}

.card-button {
  background-color: var(--accent-color);
  color: var(--bg-color);
  padding: 16px 40px;
  border-radius: 50px;
  font-size: 18px;
  box-shadow: 0px 4px 14px 0px rgba(0,0,0,0.5);
  transition: transform 0.2s ease;
}

.card-button:hover {
  transform: scale(1.05);
}

/* --- FOOTER --- */
.footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  padding: 30px;
  margin-top: 60px;
  border-top: 1px solid rgba(212, 175, 55, 0.15);
}

.footer a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
}

.footer a:hover {
  color: var(--text-light);
}

.footer span {
  color: var(--accent-color);
}

/* --- RESPONSIVE (Tablets & Handys) --- */
@media (max-width: 992px) {
  .game-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 650px) {
  .game-grid { grid-template-columns: 1fr; }
}