:root {
  --bg: #050505;
  --bg2: #0c0c0d;
  --card: #111113;
  --line: rgba(255, 255, 255, 0.1);
  --line-hi: rgba(255, 255, 255, 0.28);
  --text: #f2f2f2;
  --muted: #9a9a9e;
  --red: #e3121f;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--text); }
img, video { max-width: 100%; display: block; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.label {
  font-family: "Chakra Petch", "Inter", sans-serif;
  font-size: 13px; font-weight: 600; letter-spacing: 0.32em; text-transform: uppercase; color: var(--muted);
}
.dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); margin: 0 0.9em; vertical-align: middle; }

/* ---------- intro (logo reveal video) */
.intro {
  position: fixed; inset: 0; z-index: 100; background: #000;
  display: grid; place-items: center;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}
.intro video { width: min(100vw, 177.78vh); height: auto; }
.intro.done { opacity: 0; visibility: hidden; }
.intro .skip {
  position: absolute; right: 20px; bottom: 20px;
  font: 600 12px/1 "Chakra Petch", sans-serif; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--muted); background: transparent; border: 1px solid var(--line); padding: 10px 14px; cursor: pointer;
}
.intro .skip:hover { color: #fff; border-color: var(--line-hi); }

/* ---------- header */
.top {
  position: fixed; top: 0; left: 0; right: 0; z-index: 20;
  transition: background 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.top.solid { background: rgba(5, 5, 5, 0.86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-color: var(--line); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { width: 34px; height: auto; }
.brand span { font: 700 15px/1 "Chakra Petch", sans-serif; letter-spacing: 0.34em; }
.nav { display: flex; gap: 30px; }
.nav a { font: 600 13px/1 "Chakra Petch", sans-serif; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.nav a:hover { color: #fff; }

/* ---------- hero */
.hero { position: relative; height: 100vh; min-height: 560px; overflow: hidden; background: #000; }
.hero picture, .hero img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero img { object-fit: cover; object-position: center 45%; animation: slowzoom 18s ease-out both; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 38%; background: linear-gradient(180deg, transparent, var(--bg)); }
.hero .cta { position: absolute; left: 0; right: 0; bottom: 7vh; z-index: 2; text-align: center; }
.hero .cta .label { color: #d9d9d9; }
.scroll {
  display: inline-block; margin-top: 22px; width: 24px; height: 38px; border: 1px solid var(--line-hi); border-radius: 12px; position: relative;
}
.scroll::before { content: ""; position: absolute; left: 50%; top: 8px; width: 2px; height: 8px; margin-left: -1px; background: var(--red); border-radius: 2px; animation: wheel 1.8s ease-in-out infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }
@keyframes slowzoom { from { transform: scale(1.08); } to { transform: scale(1); } }

/* ---------- sections */
section { padding: 110px 0; }
.head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 44px; flex-wrap: wrap; }
h2 { font: 700 clamp(34px, 5vw, 56px)/1.05 "Chakra Petch", sans-serif; margin: 12px 0 0; letter-spacing: 0.01em; text-transform: uppercase; }
h2 .r { color: var(--red); }
.intro-text { color: var(--muted); max-width: 460px; margin: 0; }

/* games list */
.games { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.game { background: var(--bg); padding: 34px 32px 30px; position: relative; transition: background 0.25s ease; }
.game:hover { background: var(--card); }
.game::before { content: ""; position: absolute; left: 0; top: 0; width: 0; height: 2px; background: var(--red); transition: width 0.35s ease; }
.game:hover::before { width: 100%; }
.game .num { font: 600 13px/1 "Chakra Petch", sans-serif; letter-spacing: 0.2em; color: var(--muted); }
.game h3 { font: 700 30px/1.1 "Chakra Petch", sans-serif; text-transform: uppercase; margin: 18px 0 10px; letter-spacing: 0.02em; }
.game p { color: var(--muted); margin: 0 0 22px; max-width: 460px; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tag { font: 600 11px/1 "Chakra Petch", sans-serif; letter-spacing: 0.2em; text-transform: uppercase; color: #cfcfcf; border: 1px solid var(--line); padding: 7px 10px; }
.tag.live { color: #fff; border-color: rgba(227, 18, 31, 0.6); background: rgba(227, 18, 31, 0.12); }
.game.featured { grid-column: 1 / -1; padding: 46px 40px 40px; }
.game.featured h3 { font-size: clamp(36px, 5vw, 54px); }

/* about */
.about { background: var(--bg2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.about .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about p { color: var(--muted); }
.about .art { position: relative; aspect-ratio: 1; overflow: hidden; border: 1px solid var(--line); }
.about .art img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(0.15); }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 34px; }
.pillars div { background: var(--bg2); padding: 18px 16px; }
.pillars b { display: block; font: 700 15px/1.2 "Chakra Petch", sans-serif; letter-spacing: 0.22em; text-transform: uppercase; margin-bottom: 6px; }
.pillars span { color: var(--muted); font-size: 14px; line-height: 1.5; }

/* contact */
.contact { text-align: center; }
.contact .mail {
  display: inline-block; margin-top: 26px; font: 700 clamp(22px, 4vw, 38px)/1.2 "Chakra Petch", sans-serif; letter-spacing: 0.04em; text-decoration: none;
  border-bottom: 2px solid var(--red); padding-bottom: 6px;
}
.contact .mail:hover { color: var(--red); }

footer { border-top: 1px solid var(--line); padding: 34px 0; }
footer .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
footer img { width: 120px; opacity: 0.85; }
footer .links { display: flex; gap: 22px; }
footer a, footer small { color: var(--muted); font-size: 14px; text-decoration: none; }
footer a:hover { color: #fff; }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.in { opacity: 1; transform: none; }

/* document pages */
.doc { max-width: 780px; padding-top: 140px; padding-bottom: 90px; }
.doc h1 { font: 700 clamp(36px, 5vw, 52px)/1.1 "Chakra Petch", sans-serif; text-transform: uppercase; margin: 12px 0 8px; }
.doc h2 { font-size: 22px; margin-top: 40px; }
.doc p, .doc li { color: var(--muted); }
.doc a { color: #fff; }
.doc .updated { color: var(--red); font-weight: 600; }

@media (min-aspect-ratio: 17/9) {
  .hero .cta .label { display: none; }
  .hero .cta { bottom: 3vh; }
}
@media (max-aspect-ratio: 4/5) {
  .hero { height: 128vw; min-height: 0; }
  .hero img { object-fit: contain; object-position: center 62%; animation: none; }
  .hero .cta { bottom: 2vh; }
  .hero .cta .label { display: none; }
}
@media (max-width: 860px) {
  section { padding: 80px 0; }
  .games { grid-template-columns: 1fr; }
  .about .wrap { grid-template-columns: 1fr; gap: 36px; }
  .nav { gap: 18px; }
}
@media (max-width: 560px) {
  .nav .hide-sm { display: none; }
  .brand span { display: none; }
  .game, .game.featured { padding: 28px 22px 24px; }
  .pillars { grid-template-columns: 1fr; }
  footer .wrap { flex-direction: column; text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  *, .reveal { animation: none !important; transition: none !important; opacity: 1 !important; transform: none !important; }
}
