:root {
  color-scheme: light;
  --bg: #f4f7fb;
  --ink: #151b23;
  --muted: #637083;
  --panel: #ffffff;
  --line: #dce3ed;
  --green: #16845f;
  --green-dark: #0f6046;
  --gold: #d99b25;
  --red: #bd3342;
  --blue: #2366b8;
  --shadow: 0 18px 45px rgba(28, 39, 54, 0.12);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    linear-gradient(135deg, rgba(35, 102, 184, 0.08), transparent 34%),
    linear-gradient(225deg, rgba(217, 155, 37, 0.12), transparent 36%),
    var(--bg);
  color: var(--ink);
  font-family: Arial, "Noto Sans Hebrew", "Segoe UI", sans-serif;
}

.site-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 36px;
}

.site-header {
  margin-bottom: 22px;
}

.site-header p,
.site-header h1,
.game-card h2,
.game-card p {
  margin: 0;
}

.site-header p {
  color: var(--green-dark);
  font-size: 0.92rem;
  font-weight: 900;
}

.site-header h1 {
  margin-top: 4px;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 0.98;
}

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

.game-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.game-card img,
.third-preview {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #101419;
}

.card-body {
  display: grid;
  gap: 9px;
  padding: 16px;
}

.card-body span {
  color: var(--blue);
  font-size: 0.82rem;
  font-weight: 900;
}

.game-card h2 {
  font-size: clamp(1.25rem, 2vw, 1.6rem);
  line-height: 1.1;
}

.game-card p {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.game-card a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: start;
  min-height: 40px;
  margin-top: 4px;
  padding: 0 16px;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 900;
  text-decoration: none;
}

.game-card a:hover,
.game-card a:focus-visible {
  background: var(--green-dark);
  outline: none;
}

.third-preview {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 120%, rgba(217, 155, 37, 0.28), transparent 36%),
    linear-gradient(150deg, #14191f, #0c1117 62%, #1b2028);
}

.third-preview .road {
  position: absolute;
  inset: 18px 22%;
  transform: perspective(340px) rotateX(48deg);
  border-right: 3px solid rgba(255, 255, 255, 0.28);
  border-left: 3px solid rgba(255, 255, 255, 0.28);
  background: #23272f;
}

.third-preview i {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 3px;
  background: repeating-linear-gradient(to bottom, #fff 0 26px, transparent 26px 52px);
  opacity: 0.78;
}

.third-preview i:nth-child(1) {
  left: 33%;
}

.third-preview i:nth-child(2) {
  left: 66%;
}

.third-preview i:nth-child(3) {
  display: none;
}

.third-preview strong {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: var(--gold);
  color: #12161b;
  font-size: 3.4rem;
  line-height: 1;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

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

  .game-card {
    display: grid;
    grid-template-columns: minmax(220px, 0.85fr) 1fr;
  }

  .game-card img,
  .third-preview {
    height: 100%;
    min-height: 210px;
  }
}

@media (max-width: 680px) {
  .site-shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  .game-card {
    display: block;
  }

  .game-card img,
  .third-preview {
    min-height: auto;
  }
}
