:root {
  color-scheme: dark;
  --text: #ffffff;
  --base: #222222;
  --mantle: #1a1a1a;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  min-width: 320px;
  overflow-x: hidden;
  background: #000000;
  color: var(--text);
  font-family: "Baloo Bhaijaan 2", system-ui, sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.splash-background {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #000000;
}

.splash-poster,
.splash-video {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  width: 300vh;
  height: 100vh;
  min-width: 100vw;
  min-height: 56.25vw;
  border: 0;
  object-fit: cover;
  pointer-events: none;
  transform: translate(-50%, -50%);
  user-select: none;
}

.splash-poster {
  opacity: 1;
  transition: opacity 300ms ease;
}

.splash-video {
  opacity: 0;
  transition: opacity 300ms ease;
}

.video-loaded .splash-poster {
  opacity: 0;
}

.video-loaded .splash-video {
  opacity: 1;
}

.reduced-motion .splash-video {
  display: none;
}

.reduced-motion .splash-poster {
  opacity: 1;
}

.splash-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: rgba(0, 0, 0, 0.7);
  pointer-events: none;
}

.site-header {
  position: relative;
  z-index: 10;
  display: flex;
  height: 98px;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem;
}

.brand {
  display: inline-flex;
  flex: 0 1 auto;
  min-width: 0;
}

.brand img {
  display: block;
  width: min(305px, 58vw);
  max-width: 100%;
  height: auto;
}

.header-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.5rem;
}

.nav-button {
  display: inline-flex;
  min-height: 40px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.5rem 1.25rem;
  border: 1px solid var(--base);
  border-radius: 0.75rem;
  background: var(--mantle);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1rem;
  transition: background-color 300ms ease, transform 150ms ease;
}

.nav-button:hover {
  background: var(--base);
}

.nav-button:active {
  transform: translateY(1px);
}

.nav-button:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}

.discord-button svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  fill: currentColor;
}

.hero {
  position: relative;
  z-index: 1;
  display: flex;
  width: 100%;
  min-height: calc(100vh - 196px);
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.hero-copy {
  display: flex;
  max-width: 900px;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
}

.hero h1,
.hero p {
  width: fit-content;
  margin: 0;
  text-shadow: 3px 3px 9px #000000;
}

.hero h1 {
  font-size: clamp(3rem, 8vw, 4.5rem);
  font-weight: 400;
  line-height: 1;
}

.hero p {
  font-size: 1rem;
  line-height: 1.5rem;
}

@media (max-width: 960px) {
  .home-page .nav-blog,
  .home-page .nav-press,
  .games-page .nav-blog,
  .games-page .nav-press,
  .blog-page .nav-press,
  .blog-page .nav-jobs,
  .press-page .nav-blog,
  .press-page .nav-jobs,
  .jobs-page .nav-blog,
  .jobs-page .nav-press,
  .contact-page .nav-blog,
  .contact-page .nav-press,
  .about-page .nav-blog,
  .about-page .nav-press,
  .projects-page .nav-blog,
  .projects-page .nav-press,
  .virucide-page .nav-blog,
  .virucide-page .nav-press,
  .beetleball-page .nav-blog,
  .beetleball-page .nav-press {
    display: none;
  }
}

@media (max-width: 760px) {
  .brand img {
    width: min(230px, 38vw);
  }

  .header-actions {
    gap: 0.3rem;
  }

  .nav-button {
    padding-inline: 0.75rem;
    font-size: 0.7rem;
  }
}

@media (max-width: 560px) {
  .site-header {
    height: auto;
    min-height: 82px;
  }

  .discord-button {
    gap: 0.45rem;
    padding-inline: 0.8rem;
  }

  .hero {
    min-height: calc(100vh - 164px);
  }

  .home-page .brand img {
    width: min(170px, 42vw);
  }

  .home-page .header-actions {
    gap: 0.25rem;
  }

  .home-page .nav-button {
    min-height: 36px;
    padding-inline: 0.55rem;
    font-size: 0.64rem;
  }

  .home-page .nav-blog,
  .home-page .nav-press,
  .home-page .nav-jobs,
  .home-page .nav-about {
    display: none;
  }
}

@media (max-width: 420px) {
  .discord-button span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .discord-button {
    width: 40px;
    padding: 0;
  }

  .nav-button:not(.discord-button) {
    padding-inline: 0.7rem;
  }
}
