/* Sardworks. One dark world, one accent. Layout: a narrow centred column, sections split by rules. */
:root {
  color-scheme: dark;
  --night: #06080c;      /* page */
  --slate: #12161d;      /* raised band */
  --rule: #2b323d;       /* section lines */
  --snow: #f2f6fa;       /* text */
  --mist: #9aa7b6;       /* quiet text */
  --ice: #4cc4f2;        /* the accent: the Lost Gifts logo's blue */
  --ice-deep: #0b3a52;
  --display: "Barlow Condensed", "Arial Narrow", Arial, sans-serif;
  --body: "Barlow", "Segoe UI", Arial, sans-serif;
  --col: 55rem;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 6rem; font-size: clamp(100%, 0.55vw + 8px, 150%); }
body {
  margin: 0;
  background: var(--night);
  color: var(--snow);
  font: 400 1.0625rem/1.65 var(--body);
  text-align: center;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; }

.wrap { width: min(var(--col), 100% - 40px); margin-inline: auto; }

/* header */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(6, 8, 12, .94);
  border-bottom: 2px solid var(--rule);
}
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 14px; }
.logo { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-decoration: none; color: var(--ice); }
.logo svg { width: 3.6rem; height: 2.5rem; }
.logo span { color: var(--snow); font: 600 1.25rem/1 var(--body); letter-spacing: -.01em; }
nav { display: flex; gap: 26px; flex-wrap: wrap; justify-content: flex-end; }
nav a { text-decoration: none; font-weight: 600; font-size: .95rem; color: var(--mist); }
nav a:hover { color: var(--snow); }

/* intro band */
.band { background: var(--slate); border-bottom: 2px solid var(--rule); padding-block: 38px; }
.band p { margin: 0; }
.band-lead { font-weight: 600; }

/* sections */
section.game, section.dig, section.more { padding-block: 64px 72px; border-bottom: 2px solid var(--rule); }
h1, h2 {
  margin: 0;
  font: 400 2.75rem/1.1 var(--display);
  letter-spacing: .06em;
  text-transform: uppercase;
  text-wrap: balance;
}
h2 { font-size: 2.25rem; }
h1::after, h2::after {
  content: ""; display: block; width: 56px; height: 2px; margin: 22px auto 0; background: var(--ice);
}
.lede { max-width: 58ch; margin: 28px auto 0; }

/* trailer + buttons */
.pitch { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 32px; align-items: center; margin-top: 44px; }
.trailer { position: relative; aspect-ratio: 16 / 9; background: #000; }
.trailer video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.trailer-play { position: absolute; inset: 0; padding: 0; border: 0; background: none; cursor: pointer; }
.trailer-play img { width: 100%; height: 100%; object-fit: cover; }
.play-mark {
  position: absolute; left: 50%; top: 50%; width: 76px; height: 54px; translate: -50% -50%;
  background: var(--ice); transition: scale .15s;
}
.play-mark::after {
  content: ""; position: absolute; left: 50%; top: 50%; translate: -38% -50%;
  border-left: 20px solid var(--night); border-block: 12px solid transparent;
}
.trailer-play:hover .play-mark { scale: 1.08; }

.actions { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; text-align: left; }
.btn {
  display: inline-block; padding: 13px 26px; border: 2px solid var(--ice);
  background: var(--ice); color: #04121a;
  font: 600 1rem/1.2 var(--display); letter-spacing: .14em; text-transform: uppercase; text-decoration: none;
  cursor: pointer; transition: background .15s, color .15s;
}
.btn:hover { background: var(--snow); border-color: var(--snow); }
.btn-quiet { background: transparent; color: var(--snow); border-color: var(--rule); }
.btn-quiet:hover { background: transparent; border-color: var(--ice); color: var(--ice); }
.btn-small { padding: 9px 16px; font-size: .9rem; }
.release { margin: 4px 0 0; color: var(--mist); line-height: 1.4; }
.release strong { color: var(--snow); font: 500 1.35rem/1.3 var(--display); letter-spacing: .04em; }

/* the snowfield */
.field {
  position: relative; margin-top: 40px; aspect-ratio: 16 / 8;
  overflow: hidden; background: #2f7d34; cursor: crosshair; touch-action: pan-y;
  border: 2px solid var(--rule);
}
.field canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#snow { filter: drop-shadow(0 4px 0 #b4cbe0) drop-shadow(0 9px 7px rgba(8, 30, 20, .55)); }
.marks { position: absolute; inset: 0; pointer-events: none; }
.mark {
  position: absolute; translate: -50% -135%;
  padding: 2px 9px; background: var(--night); color: var(--ice);
  font: 600 .9rem/1.4 var(--display); letter-spacing: .08em; white-space: nowrap;
  animation: found .35s ease-out;
}
@keyframes found { from { opacity: 0; translate: -50% -80%; } }
.hud { position: absolute; left: 12px; top: 12px; display: flex; gap: 8px; flex-wrap: wrap; pointer-events: none; }
.tag { padding: 4px 12px; background: rgba(6, 8, 12, .88); font-size: .9rem; color: var(--mist); }
.tag b { color: var(--snow); font-weight: 600; font-variant-numeric: tabular-nums; }
.field-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 16px; text-align: left; }
.field-foot p { margin: 0; color: var(--mist); }
.field-buttons { display: flex; gap: 10px; flex-wrap: wrap; }

/* loop */
.loop { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin: 44px 0 0; padding: 0; text-align: left; }
.loop li { counter-increment: step; border-top: 2px solid var(--rule); padding-top: 16px; }
.loop h3 { margin: 0 0 6px; font: 500 1.5rem/1.2 var(--display); letter-spacing: .06em; text-transform: uppercase; }
.loop h3::before { content: counter(step) ". "; color: var(--ice); }
.loop p { margin: 0; color: var(--mist); }

/* screenshots */
.shots { margin: 56px 0 0; }
.shot-main { aspect-ratio: 16 / 9; background: #000; }
.shot-main img { width: 100%; height: 100%; object-fit: cover; }
.shots figcaption { margin-top: 12px; color: var(--mist); min-height: 1.65em; }
.thumbs { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.thumbs button { padding: 0; border: 2px solid transparent; background: none; cursor: pointer; opacity: .55; transition: opacity .15s; }
.thumbs button:hover { opacity: 1; }
.thumbs button[aria-pressed="true"] { opacity: 1; border-color: var(--ice); }

/* facts */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: 20px; margin: 56px 0 0; }
.facts div { border-top: 2px solid var(--rule); padding-top: 14px; }
.facts dt { color: var(--mist); font-size: .95rem; }
.facts dd { margin: 2px 0 0; font: 500 1.5rem/1.3 var(--display); letter-spacing: .03em; }
.closing { margin: 52px 0 0; }

/* footer */
footer { padding-block: 52px 64px; }
.contact-line { margin: 0; }
.social { list-style: none; display: flex; justify-content: center; gap: 28px; flex-wrap: wrap; margin: 22px 0 0; padding: 0; }
.social a { color: var(--ice); text-decoration: none; font: 500 1.05rem/1 var(--display); letter-spacing: .14em; text-transform: uppercase; }
.social a:hover { color: var(--snow); }
.copy { margin: 30px 0 0; color: var(--mist); font-size: .9rem; }

@media (max-width: 720px) {
  h1 { font-size: 2.25rem; }
  h2 { font-size: 1.9rem; }
  nav { gap: 16px; }
  .pitch { grid-template-columns: 1fr; }
  .actions { align-items: center; text-align: center; }
  .field { aspect-ratio: 1 / 1; }
  .loop { grid-template-columns: 1fr; }
  .thumbs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  section.game, section.dig, section.more { padding-block: 48px 56px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}
