.games {
  padding: 40px 0;
  background: var(--color-bg);
}

.games__inner {
  position: relative;
}

.games__top {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.games__bottom {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 32px;
}

.games__cta {
  display: flex;
  justify-content: center;
  margin-top: 56px;
}

.games__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.game-card {
  background: var(--color-card);
  border: 1px solid var(--color-card-border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  backdrop-filter: blur(8px);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.game-card--large .game-card__thumb {
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 16px;
  background: rgba(0, 0, 0, 0.25);
}

.game-card--large .game-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-card__title {
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 12px;
  overflow-wrap: anywhere;
}

.game-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.game-card__stars {
  display: inline-flex;
  gap: 4px;
}

.game-card__stars span {
  width: 18px;
  height: 18px;
  background: #ffc940;
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 2 14.85 8.6 22 9.27l-5.46 4.73L18.18 22 12 18.27 5.82 22l1.64-7.99L2 9.27 9.15 8.6Z'/></svg>")
    no-repeat center / contain;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M12 2 14.85 8.6 22 9.27l-5.46 4.73L18.18 22 12 18.27 5.82 22l1.64-7.99L2 9.27 9.15 8.6Z'/></svg>")
    no-repeat center / contain;
}

.game-card__choice {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--color-muted);
  background: rgba(255, 255, 255, 0.06);
  padding: 8px 12px;
  border-radius: 999px;
}

.game-card__choice svg {
  width: 16px;
  height: 16px;
  opacity: 0.8;
}

.game-card__play {
  width: 100%;
  margin-top: auto;
}

/* Small horizontal card for home bottom row */
.game-card--small {
  flex-direction: row;
  align-items: center;
  gap: 16px;
  padding: 14px;
}

.game-card--small .game-card__thumb {
  width: 88px;
  height: 88px;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
}

.game-card--small .game-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-card--small .game-card__info {
  flex: 1;
  min-width: 0;
}

.game-card--small .game-card__title {
  margin-bottom: 8px;
  font-size: 18px;
}

.game-card--small .game-card__play {
  width: auto;
  margin-top: 0;
  padding: 10px 16px;
  font-size: 13px;
  flex-shrink: 0;
}

@media (max-width: 720px) {
  .game-card--small {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 12px;
  }
  .game-card--small .game-card__thumb {
    width: 100%;
    height: 180px;
  }
  .game-card--small .game-card__play {
    width: 100%;
  }
}

@media (max-width: 1024px) {
  .games__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .games__top {
    grid-template-columns: minmax(0, 1fr);
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
  }
}

@media (max-width: 720px) {
  .games {
    padding: 64px 0;
  }
  .games__bottom,
  .games__grid {
    grid-template-columns: 1fr 1fr;
  }
  .games__top {
    grid-template-columns: minmax(0, 1fr);
  }
  .game-card--small .game-card__thumb {
    height: 180px;
  }
}
