/* Raklem: the series page. A bento of the games: Dawn of Drivers (out first) big, with its Windows download,
   trailer, a screenshot and its Steam price beside it, then War on Earth and Zombie Apocalypse. Barlow and
   Barlow Condensed are War on Earth's own files (war-on-earth/assets/fonts); the RAKLEM mark is the top line
   of Dawn of Drivers' logo (dawn-of-drivers/assets/img/raklem-mark-*.webp). */

@font-face { font-family: 'Barlow Condensed'; font-weight: 600; font-style: normal; font-display: swap; src: url('../war-on-earth/assets/fonts/Barlow-Condensed-600.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 700; font-style: normal; font-display: swap; src: url('../war-on-earth/assets/fonts/Barlow-Condensed-700.woff2') format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 800; font-style: normal; font-display: swap; src: url('../war-on-earth/assets/fonts/Barlow-Condensed-800.woff2') format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 400; font-style: normal; font-display: swap; src: url('../war-on-earth/assets/fonts/Barlow-400.woff2') format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 500; font-style: normal; font-display: swap; src: url('../war-on-earth/assets/fonts/Barlow-500.woff2') format('woff2'); }

:root {
  color-scheme: dark;
  --bg: #08090b;
  --bg-2: #0e1013;
  --bone: #ece6d9;
  --bone-2: #c3bcae;
  --bone-3: #948d81;
  --line: rgba(236, 230, 217, 0.1);
  --amber: #ffb12e;
  --amber-hi: #ffd27a;
  --amber-ink: #160f03;
  --green: #7dff4a;
  --green-ink: #0b1a05;
  --steam: #ec4a1d;
  --steam-hi: #ff6a2b;
  --f-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --f-text: 'Barlow', 'Segoe UI', system-ui, sans-serif;
  --wrap: 1280px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background: var(--bg); }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--bone); font: 400 1.0625rem/1.5 var(--f-text); -webkit-font-smoothing: antialiased; overflow-x: hidden; overflow-x: clip; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--amber); text-underline-offset: 3px; }
a:hover { color: var(--amber-hi); }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 100; padding: 8px 14px; background: var(--amber); color: var(--amber-ink); font-weight: 600; }
.skip:focus { top: 8px; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }

/* ------------------------------------------------------------ top bar */
.top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 24px 0; }
.top__brand img { width: 124px; }
.top__links { display: flex; flex-wrap: wrap; gap: 8px 26px; }
.top__links a { color: var(--bone-2); text-decoration: none; font: 600 0.95rem/1 var(--f-display); letter-spacing: 0.12em; text-transform: uppercase; }
.top__links a:hover { color: var(--amber); }

/* ------------------------------------------------------------ the series in one line */
.intro { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 48px; padding: 36px 0 32px; }
.intro h1 { flex: 1 1 560px; margin: 0; font: 800 clamp(2.5rem, 5.6vw, 4.9rem)/0.95 var(--f-display); text-transform: uppercase; }
.intro h1 span { color: var(--amber); }
.intro p { flex: 0 1 360px; margin: 0; color: var(--bone-2); font-size: 1.125rem; }

/* ------------------------------------------------------------ the bento */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 250px; gap: 14px; padding-bottom: 100px; }
.tile {
  position: relative; overflow: hidden; isolation: isolate; display: flex; flex-direction: column; justify-content: flex-end; gap: 6px;
  margin: 0; padding: 26px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-2); color: var(--bone); text-decoration: none;
}
.tile__bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease-out); }
.tile:hover > .tile__bg { transform: scale(1.03); }
.tile__shade { position: absolute; inset: 0; z-index: -1; }
.tile h2, .tile h3 { margin: 0; font: 800 2.1rem/1 var(--f-display); text-transform: uppercase; }
.tile p { margin: 0; color: var(--bone-2); font-size: 0.95rem; }
.tile .kicker { margin: 0; color: var(--amber); font: 700 0.8rem/1.2 var(--f-display); letter-spacing: 0.2em; text-transform: uppercase; }
.link { color: var(--amber); text-decoration: none; font: 700 0.95rem/1.2 var(--f-display); letter-spacing: 0.1em; text-transform: uppercase; }
.link:hover { color: var(--amber-hi); }
.tile .soon { color: var(--bone-3); font: 700 0.95rem/1.2 var(--f-display); letter-spacing: 0.1em; text-transform: uppercase; }

.tile--feature { grid-column: span 2; grid-row: span 2; gap: 14px; padding: 32px; border-color: var(--amber); }
.tile--feature .tile__bg { object-position: 50% 40%; }
.tile--feature .tile__shade { background: linear-gradient(0deg, rgba(8,9,11,.95) 8%, rgba(8,9,11,.35) 55%, rgba(8,9,11,0) 80%); }
.tile--feature .kicker { color: var(--green); font-size: 0.875rem; }
.tile__logo img { width: min(420px, 100%); }
.tile--feature p { max-width: 480px; color: var(--bone); font-size: 1.0625rem; }

.tile--wide { grid-column: span 2; }
.tile--wide .tile__shade { background: linear-gradient(90deg, rgba(8,9,11,.92) 20%, rgba(8,9,11,.2) 75%); }
.tile--wide p { max-width: 380px; }
#war-on-earth .tile__bg { object-position: 80% 40%; }
#zombie-apocalypse .tile__bg { object-position: 50% 45%; filter: saturate(.7) brightness(.75); }

.tile--download, .tile--steam { justify-content: space-between; gap: 12px; }
.tile--download { background: #12230b; border-color: rgba(125,255,74,.4); }
.tile--download .kicker { color: var(--green); }
.tile--download h3 { font-size: 1.9rem; }
.tile--download p, .tile--download p a { color: #b7c9ad; }
.tile--download p a:hover { color: var(--green); }
.tile--steam { background: #1a0f0b; border-color: rgba(236,74,29,.45); }
.tile--steam .kicker { color: var(--steam-hi); }
.tile .tile__price { margin: 0; color: var(--bone); font: 800 3rem/1 var(--f-display); }
.tile__stack { display: flex; flex-direction: column; gap: 6px; }

.btn-tile {
  display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 16px; text-decoration: none;
  font: 800 1.05rem/1 var(--f-display); letter-spacing: 0.08em; text-transform: uppercase; transition: filter .2s, transform .2s var(--ease-out);
}
.btn-tile:hover { filter: brightness(1.1); transform: translateY(-1px); }
.btn-tile--go, .btn-tile--go:hover { background: var(--green); color: var(--green-ink); }
.btn-tile--steam, .btn-tile--steam:hover { background: var(--steam); color: #fff; }
.btn-tile svg { width: 18px; height: 18px; flex: none; }

.tile--trailer { padding: 22px; }
.tile--trailer .tile__shade { background: linear-gradient(0deg, rgba(8,9,11,.9), rgba(8,9,11,.1) 60%); }
.tile__play {
  position: absolute; top: 50%; left: 50%; width: 64px; height: 64px; margin: -40px 0 0 -32px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(255,177,46,.92); color: var(--amber-ink); transition: transform .25s var(--ease-out);
}
.tile--trailer:hover .tile__play { transform: scale(1.08); }
.tile__play svg { width: 22px; height: 22px; margin-left: 3px; }
.tile__title { font: 800 1.4rem/1 var(--f-display); text-transform: uppercase; }
.tile__sub { color: var(--bone-2); font-size: 0.875rem; }
.tile--shot { padding: 0; }
.tile--shot img { width: 100%; height: 100%; object-fit: cover; }

/* ------------------------------------------------------------ footer */
.foot { border-top: 1px solid var(--line); padding: 32px 0 40px; }
.foot__in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.foot__in img { width: 100px; }
.foot__in p { margin: 0; color: var(--bone-3); font-size: 0.875rem; }

/* ------------------------------------------------------------ 404 */
.lost { display: grid; place-items: center; min-height: 100vh; padding: 24px 16px; text-align: center; }
.lost__in { display: grid; justify-items: center; gap: 18px; max-width: 560px; }
.lost__in > img { width: min(300px, 70vw); }
.lost h1 { margin: 0; font: 800 clamp(2.4rem, 7vw, 4rem)/1 var(--f-display); text-transform: uppercase; }
.lost p { margin: 0; color: var(--bone-2); }
.lost .kicker { margin: 0; color: var(--amber); font: 700 0.8rem/1.2 var(--f-display); letter-spacing: 0.2em; text-transform: uppercase; }
.lost .btn-tile { padding: 0 26px; background: var(--amber); color: var(--amber-ink); }

/* ------------------------------------------------------------ smaller screens */
@media (max-width: 900px) {
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile--feature, .tile--wide { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .top__links { display: none; }
  .bento { grid-template-columns: 1fr; grid-auto-rows: minmax(230px, auto); }
  .tile, .tile--feature, .tile--wide { grid-column: auto; grid-row: auto; }
  .tile--feature { min-height: 460px; padding: 24px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
