/* ===== Custom Properties ===== */
:root {
  --bg: #000000;
  --card-bg: #111111;
  --card-border: #222222;
  --text: #fafafa;
  --text-muted: #888888;
  --accent: #dcdcdc;
  --font: 'Space Mono', monospace;
  --container: 1120px;
  --header-h: 72px;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ===== Utilities ===== */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 48px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  border-radius: 0;
  padding: 14px 28px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.btn--primary {
  background: var(--text);
  color: var(--bg);
}
.btn--primary:hover {
  background: var(--accent);
}
.btn--outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--card-border);
}
.btn--outline:hover {
  border-color: var(--text);
}
.btn--discord {
  background: var(--text);
  color: var(--bg);
}
.btn--discord:hover {
  background: var(--accent);
}
.btn--sm { padding: 10px 18px; font-size: 0.75rem; }
.btn--lg { padding: 18px 36px; font-size: 0.9rem; }

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  transition: background 0.3s, backdrop-filter 0.3s;
}
.header--scrolled {
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--card-border);
}
.header__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.header__logo-img {
  height: 32px;
  width: auto;
}
.header__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.header__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.header__hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.header__hamburger.active span:nth-child(2) { opacity: 0; }
.header__hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Hero ===== */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% 50%, rgba(255, 255, 255, 0.03), transparent),
    radial-gradient(ellipse 60% 40% at 20% 80%, rgba(255, 255, 255, 0.02), transparent);
  z-index: 0;
}
.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 120px 24px 80px;
}
.hero__title {
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 700;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  max-width: 800px;
  margin: 0 auto 24px;
}
.hero__highlight {
  background: linear-gradient(135deg, #00d4ff, #7b2ff7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero__subtitle {
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto 40px;
}
.hero__actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.hero__actions .btn {
  width: 240px;
  justify-content: center;
}

/* ===== Games Grid ===== */
.games {
  padding: 100px 0;
}
.games__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* ===== Game Card ===== */
.game-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  overflow: hidden;
  transition: border-color 0.3s;
  opacity: 0;
  transform: translateY(24px);
}
.game-card.visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s ease, transform 0.5s ease, border-color 0.3s;
}
.game-card:hover {
  border-color: #444444;
}
.game-card__image {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
.game-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.4);
}
.game-card__placeholder--hangman {
  background: linear-gradient(135deg, #1a1a1a, #0d0d0d);
}
.game-card__placeholder--gradient {
  background: linear-gradient(135deg, #141414, #0a0a0a);
}
.game-card__placeholder--gradient-alt {
  background: linear-gradient(135deg, #0d0d0d, #141414);
}
.game-card__badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 6px 14px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.game-card__body {
  padding: 24px;
}
.game-card__title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.game-card__desc {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* ===== Game Card Actions ===== */
.game-card__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ===== Trailer Modal ===== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.modal--open {
  opacity: 1;
  pointer-events: auto;
}
.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
}
.modal__container {
  position: relative;
  width: 90%;
  max-width: 900px;
}
.modal__close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}
.modal__close:hover {
  color: var(--text-muted);
}
.modal__video {
  display: block;
  width: 100%;
  background: #000;
}

/* ===== CTA ===== */
.cta {
  padding: 100px 0;
  border-top: 1px solid var(--card-border);
}
.cta__inner {
  text-align: center;
}
.cta__subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 480px;
  margin: -24px auto 40px;
}
.cta__subtitle a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s;
}
.cta__subtitle a:hover {
  color: var(--text-muted);
}

/* ===== Footer ===== */
.footer {
  border-top: 1px solid var(--card-border);
  padding: 48px 0;
}
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}
.footer__contact a {
  color: var(--text-muted);
  font-size: 0.85rem;
  transition: color 0.2s;
}
.footer__contact a:hover { color: var(--text); }
.footer__links {
  display: flex;
  gap: 24px;
}
.footer__links a {
  color: var(--text-muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}
.footer__links a:hover { color: var(--text); }
.footer__socials {
  display: flex;
  gap: 16px;
}
.footer__socials a {
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer__socials a:hover { color: var(--text); }
.footer__copy {
  color: #444444;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .games__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .header__hamburger { display: flex; }
  .header__links {
    position: fixed;
    top: var(--header-h);
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 24px;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s, opacity 0.3s;
  }
  .header__links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .games__grid { grid-template-columns: 1fr; }
}
