:root {
  --bg: #07101d;
  --line-strong: rgba(116, 212, 255, 0.28);
  --text: #eef4ff;
  --text-dim: rgba(222, 233, 248, 0.7);
  --accent: #74d4ff;
  --accent-strong: #bcefff;
  --hot: #ff745c;
  --font-display: "Rajdhani", "Noto Sans SC", sans-serif;
  --font-body: "Space Grotesk", "Noto Sans SC", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  font-family: var(--font-body);
  background:
    radial-gradient(circle at 18% 16%, rgba(116, 212, 255, 0.12), transparent 24%),
    radial-gradient(circle at 84% 20%, rgba(255, 116, 92, 0.12), transparent 20%),
    linear-gradient(180deg, #0b1526 0%, #040914 58%, #02060e 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(116, 212, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(116, 212, 255, 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.5;
  pointer-events: none;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  width: 100%;
}

button {
  font: inherit;
}

.page-shell {
  position: relative;
  min-height: 100vh;
}

.page-noise {
  position: fixed;
  inset: 0;
  background: linear-gradient(transparent 0%, rgba(255, 255, 255, 0.025) 48%, transparent 100%);
  opacity: 0.18;
  mix-blend-mode: screen;
  pointer-events: none;
}

.topbar,
.library-page {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 0 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 14px;
  height: 14px;
  border: 1px solid var(--accent);
  background: linear-gradient(135deg, var(--accent), var(--hot));
  box-shadow: 0 0 16px rgba(116, 212, 255, 0.42);
  transform: rotate(45deg);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-copy strong,
.eyebrow,
.game-meta strong,
.game-meta span,
.lang-button {
  font-family: var(--font-display);
  letter-spacing: 0.08em;
}

.brand-copy strong {
  font-size: 1.08rem;
}

.brand-copy span {
  font-size: 0.74rem;
  color: var(--text-dim);
}

.language-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.lang-button {
  min-width: 58px;
  padding: 9px 12px;
  border: 1px solid rgba(116, 212, 255, 0.26);
  color: var(--text-dim);
  background: rgba(6, 16, 29, 0.5);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms ease;
}

.lang-button:hover,
.lang-button:focus-visible {
  color: var(--accent-strong);
  border-color: rgba(116, 212, 255, 0.45);
}

.lang-button.is-active {
  color: #04111f;
  border-color: var(--accent);
  background: linear-gradient(135deg, var(--accent-strong), #7ecfff);
  box-shadow: 0 0 18px rgba(116, 212, 255, 0.24);
}

.library-page {
  padding: 28px 0 72px;
}

.page-heading {
  margin-bottom: 30px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 0.9rem;
}

.page-heading h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  line-height: 0.96;
}

.page-heading p:last-child {
  margin: 12px 0 0;
  color: var(--text-dim);
  font-size: 1rem;
}

.game-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.game-card {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: rgba(6, 16, 29, 0.72);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.26);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.game-card:hover,
.game-card:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(116, 212, 255, 0.5);
  box-shadow: 0 30px 56px rgba(0, 0, 0, 0.34);
}

.game-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(2, 8, 15, 0.18) 64%, rgba(2, 8, 15, 0.92) 100%);
  pointer-events: none;
}

.game-shot {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.game-shot img {
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}

.game-card:hover .game-shot img,
.game-card:focus-visible .game-shot img {
  transform: scale(1.03);
}

.game-meta {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 1;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
}

.game-meta strong {
  display: block;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  line-height: 0.96;
}

.game-meta span {
  color: var(--accent-strong);
  font-size: 0.82rem;
  white-space: nowrap;
}

.empty-state {
  padding: 28px;
  border: 1px dashed var(--line-strong);
  color: var(--text-dim);
}

.site-note {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 26px;
}

.site-note-card {
  padding: 18px 20px;
  border: 1px solid rgba(116, 212, 255, 0.18);
  background: rgba(6, 16, 29, 0.62);
}

.site-note-label {
  margin: 0 0 10px;
  color: var(--accent-strong);
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.08em;
}

.site-note-text {
  margin: 0;
  color: var(--text-dim);
  line-height: 1.65;
}

.site-note-link {
  color: var(--text);
  font-family: var(--font-display);
  letter-spacing: 0.04em;
}

.site-note-link:hover,
.site-note-link:focus-visible {
  color: var(--accent-strong);
}

@media (max-width: 860px) {
  .game-gallery {
    grid-template-columns: 1fr;
  }

  .site-note {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .topbar,
  .library-page {
    width: min(100% - 24px, 1120px);
  }

  .topbar {
    padding-top: 18px;
    flex-wrap: wrap;
  }

  .library-page {
    padding-top: 18px;
  }

  .game-meta {
    left: 14px;
    right: 14px;
    bottom: 14px;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}
