/* ==========================================================================
   HTS GAME · htsgame.com
   Studio index + project entries. No framework, no external fonts, no JS.
   ========================================================================== */

:root {
  --bg: #0a0b0f;
  --bg-soft: #0e1016;
  --surface: #12141b;
  --surface-2: #171a22;
  --text: #f4f5f8;
  --text-soft: #dfe3ea;
  --muted: #9aa1ae;
  --muted-2: #7c8392;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.16);
  --lime: #d8ff3e;
  --wrap: 1180px;

  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI",
    Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --serif: Georgia, "Times New Roman", "Songti SC", serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",
    monospace;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg);
  background-image:
    radial-gradient(900px 520px at 78% -10%, rgba(139, 92, 246, 0.14), transparent 65%),
    radial-gradient(720px 460px at 4% 2%, rgba(216, 255, 62, 0.05), transparent 62%);
  background-repeat: no-repeat;
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main {
  flex: 1;
}

img {
  max-width: 100%;
}

a {
  color: inherit;
}

::selection {
  background: var(--lime);
  color: #0a0b0f;
}

:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
  border-radius: 6px;
}

[hidden] {
  display: none !important;
}

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

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--lime);
  color: #0a0b0f;
  font-weight: 600;
  text-decoration: none;
  transition: top 0.2s;
}

.skip:focus {
  top: 16px;
}

/* ------------------------------------------------------------------ header */
.site-head {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(10, 11, 15, 0.74);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.head-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 74px;
}

.head-tools {
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  width: 13px;
  height: 13px;
  border-radius: 3px;
  background: var(--lime);
  transform: rotate(45deg);
  box-shadow: 0 0 22px rgba(216, 255, 62, 0.5);
  flex: none;
}

.brand-name {
  display: flex;
  gap: 0.42rem;
  font-size: 1.06rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.brand-name span {
  font-weight: 300;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.brand--sm .brand-name {
  font-size: 0.95rem;
}

.brand--sm .brand-mark {
  width: 11px;
  height: 11px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  transition: color 0.2s;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--text);
}

.nav .nav-cta {
  display: inline-flex;
  align-items: center;
  height: 38px;
  padding: 0 17px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  color: var(--text);
  transition: background 0.2s, border-color 0.2s;
}

.nav .nav-cta:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.3);
}

.lang-menu {
  position: relative;
  flex: none;
}

.lang-menu summary {
  display: flex;
  align-items: center;
  height: 38px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  cursor: pointer;
  list-style: none;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.lang-menu summary::-webkit-details-marker {
  display: none;
}

.lang-menu summary:hover,
.lang-menu[open] summary {
  color: var(--text);
  border-color: var(--line-2);
  background: rgba(255, 255, 255, 0.04);
}

.lang-menu ul {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  z-index: 60;
  min-width: 188px;
  margin: 0;
  padding: 6px;
  list-style: none;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  background: #11131a;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
}

.lang-menu li > a,
.lang-menu li > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 12px;
  border-radius: 9px;
  color: var(--muted);
  font-size: 0.88rem;
  text-decoration: none;
  white-space: nowrap;
}

.lang-menu li > a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.lang-menu li > span[aria-current] {
  color: var(--lime);
}

.lang-menu .code {
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
}

/* ---------------------------------------------------------------- masthead */
.masthead {
  padding: clamp(58px, 8.5vw, 100px) 0 clamp(26px, 4vw, 44px);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--lime);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 14px rgba(216, 255, 62, 0.8);
  animation: pulse 2.6s ease-in-out infinite;
  flex: none;
}

@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}

.masthead h1 {
  margin: 0;
  font-size: clamp(2.55rem, 6.8vw, 5.6rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.05em;
}

.slogan span,
.slogan em {
  display: block;
}

.slogan em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.025em;
  color: var(--lime);
}

html[lang^="zh"] .slogan em {
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-style: normal;
  font-weight: 600;
  letter-spacing: -0.02em;
}

html[lang="ja"] .slogan em {
  font-family: "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif CJK JP", serif;
  font-style: normal;
  font-weight: 600;
  letter-spacing: -0.02em;
}

html[lang="ko"] .slogan em {
  font-family: "AppleMyungjo", "Nanum Myeongjo", "Noto Serif CJK KR", serif;
  font-style: normal;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.masthead-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
  gap: clamp(30px, 5vw, 64px);
  margin-top: clamp(34px, 5vw, 52px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.masthead-lede {
  max-width: 58ch;
  margin: 0;
  color: var(--muted);
  font-size: clamp(0.98rem, 1.3vw, 1.08rem);
  line-height: 1.7;
}

.masthead-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.masthead-links a {
  color: var(--text-soft);
  font-size: 0.92rem;
  text-decoration: none;
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 4px;
  transition: color 0.2s, border-color 0.2s;
}

.masthead-links a:hover {
  color: var(--lime);
  border-color: rgba(216, 255, 62, 0.5);
}

/* ------------------------------------------------------------------- cards */
.game-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 20px;
}

.game-card {
  flex: 0 0 380px;
  max-width: 100%;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(180deg, var(--surface), #0f1117);
  transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1),
    border-color 0.35s, box-shadow 0.35s;
}

.game-card:hover {
  transform: translateY(-5px);
  border-color: color-mix(in srgb, var(--g) 50%, transparent);
  box-shadow: 0 34px 70px -32px rgba(0, 0, 0, 0.95);
}

.game-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.game-card__art {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0b0c10;
}

.game-card__art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.game-card:hover .game-card__art img {
  transform: scale(1.05);
}

.game-card__art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(10, 11, 15, 0.62));
  pointer-events: none;
}

.chip {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(10, 11, 15, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--text-soft);
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.chip--soon {
  color: var(--lime);
  border-color: rgba(216, 255, 62, 0.3);
}

.chip--play {
  color: var(--lime);
  border-color: rgba(216, 255, 62, 0.35);
}

.game-card__body {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 0 22px 22px;
}

.game-card__icon {
  width: 60px;
  height: 60px;
  margin-top: -30px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 17px;
  background: #0b0c10;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.55);
  position: relative;
  z-index: 2;
}

.game-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

.game-card__row h3 {
  margin: 0;
  font-size: 1.18rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.game-card__arrow {
  color: var(--muted-2);
  font-size: 1.05rem;
  transition: color 0.25s, transform 0.25s;
}

.game-card:hover .game-card__arrow {
  color: var(--g);
  transform: translate(3px, -3px);
}

.game-card__desc {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  min-height: calc(1.58em * 3);
  margin: 10px 0 18px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.58;
}

.game-card__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: auto 0 0;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
}

.game-card__meta span {
  opacity: 0.5;
}

.game-card--skeleton {
  pointer-events: none;
}

.game-card--skeleton:hover {
  transform: none;
  border-color: var(--line);
  box-shadow: none;
}

.game-card--skeleton .game-card__art {
  background: linear-gradient(100deg, #151821 25%, #252a39 45%, #151821 65%);
  background-size: 220% 100%;
  animation: shimmer 1.8s linear infinite;
}

.game-card--skeleton .game-card__art::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(216, 255, 62, 0.16);
  box-shadow: 0 0 44px rgba(216, 255, 62, 0.16);
  transform: translate(-50%, -50%) rotate(45deg);
  animation: pulse 2.2s ease-in-out infinite;
}

.game-card--skeleton .game-card__art::after,
.game-card--skeleton .game-card__art .chip {
  display: none;
}

.game-card--skeleton .game-card__body {
  min-height: 210px;
}

.skeleton-square {
  display: block;
  width: 60px;
  height: 60px;
  margin-top: -30px;
  border-radius: 17px;
  background: #242836;
  position: relative;
  z-index: 2;
}

.skeleton-line {
  display: block;
  height: 11px;
  margin-top: 14px;
  border-radius: 6px;
  background: #242836;
}

.skeleton-line--title {
  width: 58%;
  height: 18px;
  margin-top: 20px;
}

.skeleton-line--short {
  width: 42%;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.load-error {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 26px;
  border: 1px dashed var(--line-2);
  border-radius: 16px;
  color: var(--muted);
  font-size: 0.94rem;
}

.load-error p {
  margin: 0;
}

.load-error .link-arrow {
  margin-left: auto;
  flex: none;
}

.more-strip {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 20px;
  padding: 22px 26px;
  border: 1px dashed var(--line-2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.015);
  color: inherit;
  text-decoration: none;
  transition: border-color 0.25s, background 0.25s;
}

.more-strip:hover {
  border-color: rgba(216, 255, 62, 0.45);
  background: rgba(216, 255, 62, 0.03);
}

.more-strip .more-plus {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: none;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  color: var(--lime);
  font-size: 1.25rem;
  font-weight: 300;
}

.more-strip__text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.more-strip__text strong {
  font-size: 1rem;
  font-weight: 650;
}

.more-strip__text span {
  color: var(--muted);
  font-size: 0.88rem;
}

.more-strip .more-link {
  margin-left: auto;
  flex: none;
  color: var(--lime);
  font-size: 0.9rem;
  font-weight: 600;
}

.empty-games {
  display: flex;
  align-items: center;
  gap: 26px;
  padding: clamp(26px, 4vw, 44px);
  border: 1px dashed var(--line-2);
  border-radius: 16px;
}

.empty-mark {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  flex: none;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  color: var(--lime);
  font-size: 1.4rem;
  font-weight: 300;
}

.empty-games h2 {
  margin: 0 0 6px;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.empty-games p {
  margin: 0;
  max-width: 58ch;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.6;
}

.empty-games .link-arrow {
  margin-left: auto;
  flex: none;
}

.link-arrow {
  color: var(--lime);
  font-size: 0.94rem;
  font-weight: 600;
  text-decoration: none;
}

.link-arrow:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ----------------------------------------------------------------- endnote */
.endnote {
  padding: clamp(46px, 6vw, 74px) 0 clamp(30px, 4vw, 46px);
}

.endnote p {
  margin: 0;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
}

.endnote a {
  color: var(--text-soft);
  text-decoration: none;
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 2px;
}

.endnote a:hover {
  color: var(--lime);
  border-color: rgba(216, 255, 62, 0.5);
}

/* ------------------------------------------------------------------- about */
.page-hero {
  padding: clamp(56px, 8vw, 96px) 0 8px;
}

.page-hero h1 {
  max-width: 18ch;
  margin: 0 0 26px;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.page-lead {
  max-width: 640px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  line-height: 1.65;
}

.section {
  padding: clamp(44px, 6.5vw, 82px) 0;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: clamp(24px, 3.4vw, 36px);
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.section-note {
  margin: 0;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.prose {
  max-width: 760px;
  padding-top: 30px;
}

.prose h2 {
  margin: 0 0 18px;
  font-size: clamp(1.45rem, 2.6vw, 2rem);
  letter-spacing: -0.03em;
}

.prose p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 1.01rem;
  line-height: 1.75;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(22px, 4vw, 54px);
}

.principle {
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.principle .num {
  color: var(--lime);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
}

.principle h3 {
  margin: 14px 0 10px;
  font-size: 1.1rem;
  font-weight: 650;
  letter-spacing: -0.015em;
}

.principle p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.65;
}

.contact-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: clamp(30px, 5vw, 54px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(700px 300px at 0% 0%, rgba(216, 255, 62, 0.09), transparent 62%),
    var(--surface);
}

.contact-band h2 {
  margin: 0 0 10px;
  font-size: clamp(1.75rem, 3vw, 2.45rem);
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.contact-band p {
  margin: 0;
  color: var(--muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 52px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 0.94rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.2s, background 0.2s, border-color 0.2s;
}

.btn-primary {
  background: var(--lime);
  color: #0a0b0f;
}

.btn-primary:hover {
  background: #e8ff74;
  transform: translateY(-2px);
}

.btn-ghost {
  border-color: var(--line-2);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.3);
}

/* ------------------------------------------------------------------- legal */
.legal {
  padding: clamp(56px, 8vw, 92px) 0 40px;
}

.narrow {
  max-width: 720px;
}

.legal h1 {
  margin: 0 0 14px;
  font-size: clamp(2.2rem, 5vw, 3.3rem);
  letter-spacing: -0.045em;
  line-height: 1.02;
}

.updated {
  margin: 0 0 34px;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.legal h2 {
  margin: 38px 0 10px;
  font-size: 1.18rem;
  letter-spacing: -0.02em;
}

.legal p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.75;
}

.legal a {
  color: var(--lime);
  text-underline-offset: 3px;
}

.legal .eyebrow,
.notfound .eyebrow {
  color: var(--lime);
}

/* --------------------------------------------------------------------- 404 */
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.notfound {
  display: flex;
  align-items: center;
  min-height: 58vh;
  padding: clamp(56px, 9vw, 100px) 0;
}

.notfound h1 {
  max-width: 16ch;
  margin: 0 0 20px;
  font-size: clamp(2.5rem, 6vw, 4.4rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.notfound p {
  max-width: 46ch;
  margin: 0 0 30px;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.7;
}

/* ------------------------------------------------------------------ footer */
.site-foot {
  margin-top: clamp(40px, 6vw, 70px);
  border-top: 1px solid var(--line);
  padding: 46px 0 54px;
}

.foot-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr auto;
  gap: 36px;
  align-items: start;
}

.foot-brand p {
  margin: 14px 0 0;
  color: var(--muted-2);
  font-size: 0.88rem;
}

.foot-nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.foot-nav a {
  color: var(--muted);
  font-size: 0.9rem;
  text-decoration: none;
}

.foot-nav a:hover {
  color: var(--text);
}

.foot-copy {
  margin: 0;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
}

/* --------------------------------------------------------------- responsive */
@media (max-width: 900px) {
  .project-body {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .project-meta {
    position: static;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0 26px;
    align-items: start;
  }

  .project-meta dl {
    margin-top: 0;
  }

  .project-links {
    grid-column: 2;
    margin-top: 14px;
  }

  .foot-inner {
    grid-template-columns: 1fr 1fr;
  }

  .foot-copy {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .masthead-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .masthead-links {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px 22px;
  }

  .project-hero {
    min-height: 400px;
  }

  .project-big-num {
    top: 40px;
    font-size: 7rem;
  }

  .project-hero-inner {
    padding-top: 120px;
  }

  .project-screens {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 8px;
    scrollbar-width: thin;
  }

  .shot {
    flex: 0 0 64%;
    scroll-snap-align: start;
  }

  .project-next {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .principles {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .nav {
    gap: 14px;
  }

  .head-tools {
    gap: 10px;
  }

  .nav a:not(.nav-cta) {
    display: none;
  }

  .nav a:first-child {
    display: inline-flex;
  }

  .nav .nav-cta {
    display: none;
  }

  .contact-band {
    flex-direction: column;
    align-items: flex-start;
  }

  .empty-games {
    flex-wrap: wrap;
  }

  .more-strip {
    flex-wrap: wrap;
    gap: 14px;
  }

  .load-error {
    flex-wrap: wrap;
    gap: 12px;
  }

  .load-error .link-arrow {
    margin-left: 0;
  }

  .more-strip .more-link {
    margin-left: 60px;
  }

  .empty-games .link-arrow {
    margin-left: 0;
  }
}

@media (max-width: 640px) {
  .wrap {
    width: min(100% - 40px, var(--wrap));
  }

  .masthead h1 {
    font-size: clamp(2.35rem, 10.4vw, 3.2rem);
  }

  .project-hero h1 {
    font-size: clamp(2.6rem, 13vw, 3.6rem);
  }

  .game-card {
    flex: 1 1 100%;
  }

  .project-meta {
    grid-template-columns: 1fr;
  }

  .project-links {
    grid-column: 1;
  }

  .foot-inner {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .foot-copy {
    grid-column: 1;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
