:root {
  --bg-dark: #0a0930;
  --bg-mid: #15155f;
  --bg-light: #2524a0;
  --primary: #19d1d3;
  --primary-strong: #00b4b8;
  --text-main: #ffffff;
  --text-soft: #d7d8ff;
  --header-height: 72px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Chakra Petch", sans-serif;
  color: var(--text-main);
  background:
    radial-gradient(circle at 18% 14%, rgba(255, 136, 34, 0.26) 0%, rgba(255, 136, 34, 0) 34%),
    radial-gradient(circle at 78% 0%, rgba(255, 90, 20, 0.2) 0%, rgba(255, 90, 20, 0) 32%),
    linear-gradient(135deg, #050403 0%, #0a0705 40%, #1a0f07 68%, #080605 100%);
  padding-top: var(--header-height);
}

.container {
  width: min(1450px, 92%);
  margin: 0 auto;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 50;
  backdrop-filter: blur(10px);
  background: rgba(10, 6, 4, 0.86);
  border-bottom: 1px solid rgba(255, 158, 84, 0.2);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
}

.header-inner {
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
  color: var(--text-main);
  text-decoration: none;
}

.logo-image {
  height: 52px;
  width: auto;
  display: block;
}

.header-actions {
  display: flex;
  gap: 10px;
}

.btn {
  font-family: "Audiowide", sans-serif;
  border: none;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 600;
  letter-spacing: 0.3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  color: #031436;
  background: linear-gradient(90deg, var(--primary), #58f0da);
}

.btn-outline {
  color: #ffe9d2;
  border: 1px solid rgba(255, 176, 112, 0.5);
  background: rgba(255, 125, 50, 0.08);
}

.hero {
  padding: 72px 0 48px;
  background: transparent;
}

.hero-grid {
  display: grid;
  gap: 34px;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.hero-art {
  border-radius: 18px;
  overflow: hidden;
}

.hero-art-image {
  width: 100%;
  height: 100%;
  min-height: 300px;
  object-fit: cover;
  display: block;
}

.hero-kicker {
  font-family: "Audiowide", sans-serif;
  margin: 0;
  color: #ffb067;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

h1 {
  font-family: "Audiowide", sans-serif;
  font-size: clamp(2rem, 3.8vw, 3.25rem);
  margin: 12px 0 12px;
  line-height: 1.1;
  text-transform: uppercase;
  color: #fff2e3;
}

.hero-copy p {
  max-width: 520px;
  color: #e4d3c1;
  line-height: 1.6;
}

.btn-big {
  margin-top: 16px;
  padding: 12px 22px;
}

.hero-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.game-card,
.tile {
  border-radius: 16px;
  min-height: 120px;
  background: #2332a6;
  border: none;
  box-shadow: none;
  display: flex;
  align-items: flex-end;
  padding: 14px;
  font-weight: 800;
  letter-spacing: 0.4px;
  color: #ffffff;
}

.game-card-large {
  grid-column: span 2;
  min-height: 180px;
  background: radial-gradient(circle at 70% 20%, #2f74ff 0, #0f176e 68%);
}

.featured-card {
  position: relative;
  overflow: hidden;
  align-items: stretch;
  padding: 0;
}

.featured-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.95;
}

.featured-card-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px;
  background: linear-gradient(
    to top,
    rgba(3, 7, 35, 0.88) 0%,
    rgba(5, 10, 48, 0.35) 45%,
    rgba(5, 10, 48, 0) 100%
  );
}

.featured-card-title {
  font-weight: 800;
  letter-spacing: 0.4px;
  align-self: flex-start;
}

.featured-card-button {
  align-self: flex-start;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.featured-card:hover .featured-card-button {
  opacity: 1;
  transform: translateY(0);
}

.games {
  padding: 20px 0 110px;
}

h2 {
  font-family: "Audiowide", sans-serif;
  margin: 12px 0 18px;
  font-size: 1.6rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #ffe4c4;
}

.games-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.tile {
  min-height: 145px;
  transition: none;
}

.game-tile {
  position: relative;
  overflow: hidden;
  padding: 0;
  min-height: 310px;
  isolation: isolate;
}

.game-tile::before {
  content: none;
}

.game-tile-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: none;
  filter: none;
  transition: none;
}

.game-tile-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  padding: 14px;
  background: none;
  z-index: 2;
}

.game-tile-title {
  font-weight: 700;
  letter-spacing: 0.35px;
}

.game-tile-button {
  align-self: center;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.game-tile-featured:hover .game-tile-button {
  opacity: 1;
  transform: translateY(0);
}

.game-tile-featured::after {
  content: none;
}

.game-tile-featured:hover .game-tile-image {
  transform: none;
  filter: none;
}

.game-tile-placeholder {
  padding: 14px;
  align-items: stretch;
  justify-content: stretch;
  background: #2332a6;
}

.game-placeholder-content {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 0;
  position: relative;
  z-index: 2;
}

.game-tile-placeholder span {
  font-weight: 700;
  opacity: 0.92;
}

.game-tile-button-visible {
  align-self: center;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.game-tile-placeholder:hover .game-tile-button-visible {
  opacity: 1;
  transform: translateY(0);
}

.game-tile-locked {
  cursor: not-allowed;
}

.game-tile-locked-hint {
  align-self: center;
  text-align: center;
  max-width: 220px;
  padding: 8px 10px;
  border-radius: 10px;
  font-weight: 600;
  line-height: 1.3;
  background: rgba(0, 0, 0, 0.62);
  color: #ffdcb9;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.game-tile-locked:hover .game-tile-locked-hint {
  opacity: 1;
  transform: translateY(0);
}

.game-page-main {
  padding: 28px 0 56px;
}

.game-page-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.game-page-top h1 {
  margin: 0;
}

.game-frame-shell {
  width: min(1100px, 100%);
  margin: 0 auto;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(145, 180, 255, 0.35);
  box-shadow:
    inset 0 0 28px rgba(76, 118, 255, 0.28),
    0 24px 48px rgba(0, 0, 0, 0.45);
  background: radial-gradient(circle at 50% 0%, rgba(42, 90, 255, 0.26), #050812 58%);
}

.game-frame {
  width: 100%;
  border: 0;
  display: block;
  aspect-ratio: 16 / 9;
  min-height: 460px;
  background: #02030b;
}

.promo-modal {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 80;
  width: min(920px, calc(100% - 24px));
  border-radius: 14px;
  background: linear-gradient(90deg, #4539c7, #352f9d);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 20px 36px rgba(8, 10, 46, 0.5);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.promo-title {
  margin: 0;
  font-weight: 800;
  letter-spacing: 0.35px;
}

.promo-text {
  margin: 2px 0 0;
  color: #e2e4ff;
}

.close-modal {
  position: absolute;
  top: 6px;
  right: 8px;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.promo-modal.is-hidden {
  opacity: 0;
  transform: translate(-50%, 22px);
  pointer-events: none;
}

.site-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(7, 9, 37, 0.84);
}

.footer-inner {
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #c5c7fa;
}

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

  .games-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  :root {
    --header-height: 64px;
  }

  .header-inner {
    height: 64px;
  }

  .logo-image {
    height: 42px;
  }

  .games-grid {
    grid-template-columns: 1fr;
  }

  .game-frame {
    min-height: 320px;
  }

  .game-page-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .promo-modal {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 18px;
  }
}
