@font-face {
  font-family: Lora;
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
  src: url(assets/fonts/lora-cyrillic.woff2) format("woff2");
  unicode-range: U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}

@font-face {
  font-family: Lora;
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
  src: url(assets/fonts/lora-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
  font-family: Onest;
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(assets/fonts/onest-cyrillic.woff2) format("woff2");
  unicode-range: U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}

@font-face {
  font-family: Onest;
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(assets/fonts/onest-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

:root {
  color-scheme: light;
  --paper: #f9f3e8;
  --card: #fffaf1;
  --ink: #30241e;
  --muted: #5d4b40;
  --line: #e6dacc;
  --clay: #963f2e;
  --clay-hover: #763022;
  --serif: Lora, Georgia, serif;
  --sans: Onest, system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1rem/1.56 var(--sans);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.19em; }

:focus-visible {
  outline: 3px solid #2d60a8;
  outline-offset: 5px;
}

.skip {
  position: fixed;
  z-index: 2;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  background: var(--card);
  border-radius: 6px;
  transform: translateY(-200%);
}

.skip:focus { transform: translateY(0); }

.shell { width: min(1248px, calc(100% - 96px)); margin-inline: auto; }

.top { border-bottom: 1px solid var(--line); }

.top-inner {
  min-height: 77px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  font: 700 clamp(1.1rem, 2vw, 1.38rem)/1.15 var(--serif);
  letter-spacing: -0.045em;
  text-decoration: none;
  white-space: nowrap;
}

.mark {
  position: relative;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  border-radius: 7px 12px 7px 12px;
  transform: rotate(-11deg);
  background: var(--clay);
}

.mark::after {
  position: absolute;
  content: "";
  inset: 6px;
  border: 2px solid #fff4e1;
  border-radius: 50%;
}

nav { display: flex; align-items: center; gap: clamp(18px, 3vw, 40px); }

nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 600;
  text-decoration: none;
}

nav a:hover { color: var(--clay); text-decoration: underline; }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.93fr) minmax(0, 1.32fr);
  align-items: center;
  gap: clamp(32px, 4vw, 62px);
  padding-block: clamp(44px, 5.4vw, 82px) clamp(60px, 6vw, 88px);
}

.hero h1, .catalog h2, .game h3, footer h2 { margin: 0; font-family: var(--serif); }

.hero h1 {
  max-width: 11ch;
  font-weight: 700;
  font-size: clamp(2.55rem, 5.05vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.hero p {
  max-width: 35ch;
  margin: 25px 0 28px;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.4vw, 1.22rem);
  line-height: 1.53;
  text-wrap: pretty;
}

.hero-picture {
  display: block;
  overflow: hidden;
  border-radius: 24px;
  background: #e8cba4;
  aspect-ratio: 3 / 2;
}

.hero-picture img, .cover { display: block; width: 100%; height: 100%; object-fit: cover; }

.action {
  display: inline-flex;
  width: fit-content;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0.65em 1.16em;
  border: 1px solid transparent;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  line-height: 1.2;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}

.primary { min-height: 50px; background: var(--clay); color: #fff8ec; }
.primary:hover { background: var(--clay-hover); }

.catalog {
  padding-block: clamp(25px, 3vw, 44px) clamp(54px, 7vw, 94px);
  border-top: 1px solid var(--line);
  scroll-margin-top: 12px;
}

.catalog h2 {
  margin-bottom: clamp(23px, 3vw, 37px);
  font-size: clamp(2.05rem, 3.4vw, 3.35rem);
  font-weight: 700;
  letter-spacing: -0.06em;
  line-height: 1.12;
}

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

.game {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: var(--card);
}

.cover {
  height: auto;
  aspect-ratio: 1.78;
  border-radius: 16px 16px 0 0;
  background: #e7d3b8;
}

.semechki .cover { background: #cbdaeb; }
.kotiki .cover { background: #e9c5b0; }

.game-body {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  padding: 53px clamp(17px, 2vw, 27px) 25px;
}

.game-icon {
  position: absolute;
  top: -34px;
  left: clamp(17px, 2vw, 27px);
  width: 70px;
  height: 70px;
  border: 4px solid var(--card);
  border-radius: 19px;
  background: var(--card);
  object-fit: cover;
}

.game h3 {
  font-size: clamp(1.27rem, 2.22vw, 1.9rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.17;
}

.game-body > p:not(.availability) {
  margin: 11px 0 21px;
  color: var(--muted);
  line-height: 1.5;
  text-wrap: pretty;
}

.store, .game-body .availability { margin-top: auto; }

.store { color: var(--ink); border-color: #cbb7a5; }
.store:hover { color: var(--clay-hover); border-color: #ac7667; background: #f6e9dc; }

.privacy-link {
  margin-top: 12px;
  color: var(--clay);
  font-size: 0.94rem;
  text-underline-offset: 0.18em;
}

.privacy-policy {
  max-width: 72ch;
  border-top: 1px solid var(--line);
  line-height: 1.6;
  overflow-wrap: anywhere;
  scroll-margin-top: 1.5rem;
}

.privacy-policy:last-child { margin-bottom: 2rem; }
.privacy-policy summary { padding: 12px 0; color: var(--clay); cursor: pointer; }
.privacy-policy summary:hover { color: var(--clay-hover); }
.privacy-policy summary h2 { display: inline; margin: 0; font-size: 1rem; line-height: 1.4; }
.privacy-policy[open] { padding-bottom: 1rem; }
.privacy-policy h3 { margin: 1.5em 0 0.4em; font-size: 1.2rem; }
.privacy-policy p, .privacy-policy ul { margin: 0.65em 0; }
.privacy-policy ul { padding-inline-start: 1.4em; }
.privacy-policy a { color: var(--clay); text-decoration: underline; text-underline-offset: 0.18em; }

.availability {
  display: flex;
  align-items: center;
  min-height: 46px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 600;
}

.footer-inner {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px 24px;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  padding-block: 25px 43px;
}

footer h2 { font-size: 1.36rem; letter-spacing: -0.045em; }
footer a { color: var(--clay); overflow-wrap: anywhere; font-weight: 600; }

@media (max-width: 1050px) {
  .shell { width: calc(100% - 64px); }
  .hero { gap: 29px; }
  .hero h1 { font-size: clamp(2.45rem, 5.3vw, 3.7rem); }
  .hero p { margin-block: 19px 23px; }
  .game-grid { gap: 14px; }
}

@media (max-width: 799px) {
  .shell { width: calc(100% - 36px); }
  .top-inner { min-height: 65px; }
  .hero { grid-template-columns: 1fr; gap: 27px; padding-block: 38px 44px; }
  .hero h1 { max-width: 13ch; font-size: clamp(2.15rem, 8.5vw, 4rem); }
  .hero-break { display: none; }
  .hero p { margin-block: 18px 22px; }
  .hero-picture { border-radius: 16px; }
  .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .game h3 { font-size: clamp(1.38rem, 3.8vw, 1.75rem); }
  .footer-inner { padding-bottom: 32px; }
}

@media (max-width: 539px) {
  .game-grid { grid-template-columns: 1fr; }
  .wordmark { gap: 8px; }
  .mark { width: 21px; height: 21px; }
  .mark::after { inset: 5px; }
  nav { gap: 13px; }
  nav a { font-size: 0.88rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .action { transition: none; }
}
