*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: #ffffff;
  background-color: #02010d;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 20px 64px;
}

/* Header */

.header {
  display: flex;
  justify-content: center;
  padding: 8px 0 40px;
}

.header__logos {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

.header__collab {
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1;
  color: rgba(255, 255, 255, 0.45);
}

.header__logo-link {
  display: inline-flex;
  justify-content: center;
  transition: opacity 0.2s ease;
}

.header__logo-link:hover {
  opacity: 0.85;
}

.header__logo {
  width: min(150px, 48vw);
  height: auto;
}

.header__logo--ph {
  width: min(140px, 44vw);
}

/* Hero */

.hero {
  text-align: center;
  margin-bottom: 48px;
}

.hero__badge {
  display: inline-block;
  margin: 0 0 16px;
  padding: 6px 14px;
  border: 1px solid rgba(233, 9, 28, 0.4);
  border-radius: 999px;
  background: rgba(233, 9, 28, 0.12);
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

.hero__title {
  margin: 0 0 12px;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.hero__tagline {
  margin: 0;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
}

/* Games grid */

.games__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

/* Game card */

.game-card {
  display: flex;
  flex-direction: column;
  background-color: #0d0b1a;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.game-card:hover {
  transform: translateY(-4px);
  border-color: rgba(154, 53, 255, 0.35);
  box-shadow: 0 12px 40px rgba(114, 56, 250, 0.18);
}

.game-card__image-wrap {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: #1a1730;
}

.game-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
  padding: 20px;
}

.game-card__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
}

.game-card__description {
  margin: 0 0 8px;
  flex: 1;
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.65);
}

/* Button */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  min-width: 120px;
  padding: 12px 28px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(180deg, #9a35ff, #7238fa);
  color: #ffffff;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn:hover {
  filter: brightness(1.08);
  box-shadow: 0 6px 20px rgba(154, 53, 255, 0.4);
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

/* Catalog note */

.catalog-note {
  margin-top: 48px;
  text-align: center;
}

.catalog-note__text {
  margin: 0;
  font-size: clamp(0.9375rem, 2.5vw, 1.0625rem);
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.6;
}

.catalog-note__link {
  color: #ffffff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.catalog-note__link:hover {
  color: #c77dff;
}

/* Tablet */

@media (min-width: 640px) {
  .page {
    padding: 32px 32px 80px;
  }

  .header {
    justify-content: flex-start;
    padding-bottom: 48px;
  }

  .header__logos {
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 12px 20px;
    width: auto;
  }

  .header__collab {
    font-size: 0.875rem;
    transform: translateY(6px);
  }

  .header__logo-link:last-child {
    transform: translateY(6px);
  }

  .header__logo {
    width: min(199px, 55vw);
  }

  .header__logo--ph {
    width: min(180px, 50vw);
  }

  .hero {
    margin-bottom: 56px;
  }

  .games__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
  }

  .game-card:last-child {
    grid-column: 1 / -1;
    max-width: calc(50% - 14px);
    justify-self: center;
  }
}

/* Desktop */

@media (min-width: 1024px) {
  .page {
    padding: 40px 40px 96px;
  }

  .hero {
    margin-bottom: 64px;
  }

  .games__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
  }

  .game-card:last-child {
    grid-column: auto;
    max-width: none;
    justify-self: stretch;
  }

  .catalog-note {
    margin-top: 64px;
  }
}
