@font-face {
  font-family: "Forum KT";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/forum-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Forum KT";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/forum-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Geologica KT";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("fonts/geologica-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Geologica KT";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("fonts/geologica-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --stone: #eceeea;
  --light: rgba(255, 255, 255, 0.6);
  --stroke: #b7bfb8;
  --ground: #98a19a;
  --ink: #1d2220;
  --muted: #59635e;
  --lapis: #2941a6;
  --lapis-hover: #1f3590;
  --on-lapis: #f4f6ff;
  --arch-fill-top: rgba(255, 255, 255, 0.55);
  --arch-fill-bottom: rgba(255, 255, 255, 0);
  --display: "Forum KT", "Times New Roman", serif;
  --text: "Geologica KT", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --stone: #0f131a;
    --light: rgba(123, 148, 255, 0.09);
    --stroke: #36415a;
    --ground: #4c5872;
    --ink: #e6eaf2;
    --muted: #9ba5b9;
    --lapis: #7b94ff;
    --lapis-hover: #97abff;
    --on-lapis: #0a0f1e;
    --arch-fill-top: rgba(123, 148, 255, 0.07);
    --arch-fill-bottom: rgba(123, 148, 255, 0);
    color-scheme: dark;
  }
}

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

html,
body {
  margin: 0;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  background:
    radial-gradient(ellipse 70% 60% at 78% 18%, var(--light), transparent 70%),
    var(--stone);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--text);
  -webkit-font-smoothing: antialiased;
}

.page {
  min-height: 100vh;
  min-height: 100svh;
  max-width: 76rem;
  margin: 0 auto;
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1.25rem, 5vw, 4rem);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  grid-template-rows: auto 1fr auto;
  grid-template-areas:
    "mark mark"
    "text arcade"
    "foot foot";
  column-gap: clamp(2rem, 6vw, 6rem);
  row-gap: 2.5rem;
}

.mark {
  grid-area: mark;
  margin: 0;
  font: 400 0.9375rem/1 var(--display);
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--muted);
}

.intro {
  grid-area: text;
  align-self: center;
  display: grid;
  gap: 1.5rem;
}

h1 {
  margin: 0;
  font: 400 clamp(2.75rem, 6.6vw, 5.75rem)/1.02 var(--display);
  letter-spacing: -0.005em;
  text-wrap: balance;
}

.lead {
  margin: 0;
  max-width: 36ch;
  color: var(--muted);
  font-size: clamp(1.0625rem, 1.3vw, 1.1875rem);
}

.arcade {
  --arch-h: clamp(10rem, 32vw, 19rem);
  grid-area: arcade;
  align-self: center;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1.7fr;
  align-items: end;
  gap: clamp(0.5rem, 1.4vw, 1rem);
  padding-bottom: 0.75rem;
  border-bottom: 1.5px solid var(--ground);
}

.arch,
.door {
  height: var(--arch-h);
  border-radius: 999px 999px 0 0;
}

.arch {
  border: 1.5px solid var(--stroke);
  border-bottom: 0;
  background: linear-gradient(to bottom, var(--arch-fill-top), var(--arch-fill-bottom) 75%);
}

.door {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 0.25rem;
  padding: 0 0.75rem 1.4rem;
  background: var(--lapis);
  color: var(--on-lapis);
  text-decoration: none;
  transition: background-color 180ms ease, transform 180ms ease;
}

.door:hover {
  background: var(--lapis-hover);
  transform: translateY(-3px);
}

.door:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 5px;
}

.door-label {
  font: 500 1.125rem/1.2 var(--text);
}

.door-note {
  font-size: 0.8125rem;
  line-height: 1.3;
  opacity: 0.8;
  text-align: center;
}

.foot {
  grid-area: foot;
  margin: 0;
  font-size: 0.8125rem;
  color: var(--muted);
}

@media (prefers-reduced-motion: no-preference) {
  .arcade > * {
    animation: rise 700ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }
  .arcade > :nth-child(2) { animation-delay: 70ms; }
  .arcade > :nth-child(3) { animation-delay: 140ms; }
  .arcade > :nth-child(4) { animation-delay: 230ms; }
}

@keyframes rise {
  from {
    transform: translateY(14px);
    opacity: 0.2;
  }
}

@media (max-width: 760px) {
  .page {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto auto 1fr;
    grid-template-areas:
      "mark"
      "text"
      "arcade"
      "foot";
    row-gap: 2.25rem;
  }

  .intro {
    align-self: start;
  }

  .arcade {
    --arch-h: clamp(9rem, 46vw, 13rem);
    align-self: start;
    grid-template-columns: 1fr 1fr 1fr 2.2fr;
  }

  .foot {
    align-self: end;
  }
}
