:root {
  --font-display: "Trebuchet MS", "Avenir Next", "Segoe UI", sans-serif;
  --font-body: "Gill Sans", "Noto Sans", "Lucida Grande", sans-serif;
  --ink-strong: #1f2933;
  --ink-soft: #52606d;
  --surface: #f4f2ec;
  --surface-panel: #fffaf1;
  --surface-card: #fffdf8;
  --line-soft: #d9cdb7;
  --line-strong: #2f3e4d;
  --accent: #df5f2f;
  --accent-strong: #bb4522;
  --accent-alt: #1a7a80;
  --shadow-soft: 0 14px 30px rgba(31, 41, 51, 0.12);
  --shadow-lift: 0 28px 54px rgba(31, 41, 51, 0.2);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-body);
  color: var(--ink-strong);
  background:
    radial-gradient(circle at 85% -12%, rgba(223, 95, 47, 0.26), transparent 38%),
    radial-gradient(circle at 0% 0%, rgba(26, 122, 128, 0.26), transparent 34%),
    linear-gradient(170deg, #f8f3e7 0%, #ede4d5 50%, #e7dcc9 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image:
    linear-gradient(35deg, rgba(47, 62, 77, 0.08) 1px, transparent 1px),
    linear-gradient(-35deg, rgba(47, 62, 77, 0.08) 1px, transparent 1px);
  background-size: 22px 22px;
  z-index: -1;
}

.landing {
  width: min(1120px, calc(100vw - 2rem));
  margin: clamp(0.8rem, 2vw, 1.4rem) auto 2rem;
  display: grid;
  gap: clamp(1rem, 2vw, 1.5rem);
}

.landing-main {
  display: grid;
}

.landing-header {
  position: relative;
  overflow: clip;
  background: linear-gradient(145deg, rgba(255, 253, 248, 0.95), rgba(252, 245, 232, 0.95));
  border: 2px solid rgba(47, 62, 77, 0.18);
  border-radius: 2rem;
  padding: clamp(1.2rem, 2.6vw, 2rem);
  box-shadow: var(--shadow-lift);
  animation: rise-in 320ms ease-out both;
}

.landing-header::after {
  content: "";
  position: absolute;
  width: 14rem;
  height: 14rem;
  right: -3rem;
  bottom: -7rem;
  background: radial-gradient(circle, rgba(223, 95, 47, 0.26), rgba(223, 95, 47, 0));
  pointer-events: none;
}

.landing-header-main {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  align-items: end;
}

.landing-header h1 {
  margin: 0 0 0.6rem;
  font-family: var(--font-display);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 0.95;
}

.landing-copy {
  display: grid;
  gap: 0.15rem;
}

.landing-header p {
  margin: 0;
  max-width: 56ch;
  color: var(--ink-soft);
  font-size: clamp(1rem, 1.35vw, 1.16rem);
  line-height: 1.55;
}

.language-selector {
  min-width: min(100%, 14rem);
  display: grid;
  gap: 0.45rem;
}

.language-selector label {
  color: var(--ink-strong);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.language-selector select {
  width: 100%;
  min-height: 2.85rem;
  padding: 0.7rem 0.9rem;
  border-radius: 0.95rem;
  border: 1px solid var(--line-soft);
  background-color: var(--surface-card);
  color: var(--ink-strong);
  font: 700 1rem var(--font-body);
}

.language-selector select:focus-visible,
.game-link:focus-visible {
  outline: 3px solid rgba(26, 122, 128, 0.55);
  outline-offset: 3px;
}

.games-list {
  display: grid;
  gap: 0.95rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.game-card {
  position: relative;
  display: grid;
  gap: 0.85rem;
  align-content: start;
  padding: clamp(1rem, 2vw, 1.4rem);
  border-radius: 1.35rem;
  border: 1px solid var(--line-soft);
  background:
    linear-gradient(130deg, rgba(255, 253, 248, 0.98), rgba(255, 248, 236, 0.98));
  box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
  animation: rise-in 420ms ease-out both;
}

.game-card:nth-child(2) {
  animation-delay: 70ms;
}

.game-card::before {
  content: "";
  width: 2.4rem;
  height: 0.38rem;
  border-radius: 100vmax;
  background: linear-gradient(90deg, var(--accent), rgba(223, 95, 47, 0));
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
  border-color: rgba(223, 95, 47, 0.45);
}

.game-card h2 {
  margin: 0;
  font-family: var(--font-display);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  line-height: 1;
}

.game-card p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.5;
}

.game-card-head,
.game-card-footer {
  display: contents;
}

.game-link {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 2.85rem;
  padding: 0.7rem 1rem;
  border-radius: 0.95rem;
  border: 1px solid transparent;
  font: 700 1rem var(--font-display);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fffaf4;
  text-decoration: none;
  background: linear-gradient(130deg, var(--accent), var(--accent-strong));
  box-shadow: 0 14px 20px rgba(187, 69, 34, 0.28);
  transition: transform 160ms ease, filter 160ms ease;
}

.game-link::after {
  content: "->";
  font-size: 0.9rem;
}

.game-link:hover {
  transform: translateY(-2px);
  filter: saturate(1.1) brightness(1.03);
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 760px) {
  .landing {
    width: calc(100vw - 1rem);
    margin-top: 0.5rem;
    gap: 0.8rem;
  }

  .landing-header-main {
    align-items: start;
  }

  .language-selector {
    width: 100%;
  }

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

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0s !important;
  }
}
