:root {
  /* Main colors */
  --bg: #11131a;
  --bg-secondary: #181b25;
  --text: #f1f3f8;
  --text-secondary: #b8bdcc;
  --text-muted: #747b8f;

  /* Accent */
  --accent: #7c8cff;
  --accent-hover: #9aa6ff;

  /* Navbar */
  --navbar-bg: rgba(17, 19, 26, 0.82);
  --navbar-border: rgba(124, 140, 255, 0.12);

  /* Hero */
  --hero-overlay: rgba(10, 12, 18, 0.42);
  --hero-overlay-secondary: rgba(31, 25, 55, 0.38);
  --hero-blur: 3.5px;

  /* Borders */
  --border: rgba(255, 255, 255, 0.07);
  --border-radius: 18px;

  /* Shadows */
  --text-shadow: 0 3px 20px rgba(0, 0, 0, 0.65);
  --button-shadow: 0 8px 25px rgba(124, 140, 255, 0.18);

  /* Gallery variables */
  --gallery-radius: 8px;
  --gallery-gap: 12px;
  --gallery-hover-scale: 1.015;

  /* Modal */
  --modal-bg: #181b25;
  --modal-overlay: rgba(5, 7, 12, 0.82);

  /* Layout */
  --content-width: 70vw;
  --max-width: 1100px;
}

/* Global */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: "Lexend", sans-serif;
}

body.modal-open {
  overflow: hidden;
}

/* Twemoji */

img.emoji {
  width: 1em !important;
  height: 1em !important;
  margin: 0 0.05em;
  vertical-align: -0.1em;
}

footer img.emoji {
  width: 1em !important;
  height: 1em !important;
  margin: 0 0.05em;
  vertical-align: -0.1em;
}

/* Navbar */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 18px 0;
  background: var(--navbar-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--navbar-border);
  z-index: 100;
}

.nav-container {
  width: var(--content-width);
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
}

.logo {
  color: var(--text);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.5px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.logo:hover {
  color: var(--accent-hover);
}

nav {
  display: flex;
  align-items: center;
  gap: 30px;
  min-width: 0;
}

nav a {
  position: relative;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s ease;
}

nav a:hover,
nav a.active {
  color: var(--accent-hover);
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -7px;
  width: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 10px;
  transition: width 0.2s ease;
}

nav a:hover::after,
nav a.active::after {
  width: 100%;
}

/* Main */

main {
  flex: 1;
  width: var(--content-width);
  max-width: var(--max-width);
  margin: 0 auto;
  padding-top: 110px;
  padding-bottom: 60px;
  min-width: 0;
}

/* Pages */

.page {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

/* Backdrop */

.backdrop-background {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  isolation: isolate;
}

.backdrop-background::before {
  content: "";
  position: absolute;
  inset: calc(var(--hero-blur) * -1);
  z-index: -2;
  background-image: var(--backdrop-image);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  filter: blur(var(--hero-blur));
  transform: scale(1.05);
}

.backdrop-background::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    135deg,
    var(--hero-overlay),
    var(--hero-overlay-secondary)
  );
}

.backdrop-background h1 {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--text);
  font-size: clamp(42px, 6vw, 64px);
  font-weight: 700;
  letter-spacing: -2px;
  text-align: center;
  text-shadow: var(--text-shadow);
}

.backdrop-background p {
  position: relative;
  z-index: 1;
  margin: 10px 0 0;
  color: var(--text);
  font-size: 18px;
  font-weight: 400;
  text-align: center;
  text-shadow: var(--text-shadow);
}

.backdrop-background span {
  position: absolute;
  right: 18px;
  bottom: 14px;
  z-index: 1;
  color: rgba(255, 255, 255, 0.65);
  font-size: 11px;
  font-weight: 400;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

/* Page header */

.page-header {
  padding: 45px 0 35px;
  min-width: 0;
}

.page-header h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(36px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -1.5px;
}

.page-header p {
  margin: 12px 0 0;
  color: var(--text-secondary);
  font-size: 18px;
  line-height: 1.7;
}

/* Page content */

.page-content {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 30px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  overflow: hidden;
}

.page-content h2 {
  margin: 0 0 20px;
  color: var(--text);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.page-content h2:not(:first-child) {
  margin-top: 40px;
}

.page-content p {
  max-width: 100%;
  margin: 0 0 20px;
  color: var(--text-secondary);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  overflow-wrap: anywhere;
  word-break: normal;
}

/* Content links */

.page-content a:not(.button) {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.2s ease,
    text-decoration-color 0.2s ease;
}

.page-content a:not(.button):hover {
  color: var(--accent-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Buttons */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  max-width: 100%;
  margin-top: 5px;
  padding: 12px 22px;
  background: var(--accent);
  color: var(--bg) !important;
  border: 1px solid var(--accent);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none !important;
  white-space: nowrap;
  box-shadow: var(--button-shadow);
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.button:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--bg) !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(124, 140, 255, 0.28);
}

.button:active {
  transform: translateY(0);
}

/* Contact */

.contact-email {
  margin: 35px 0;
  padding: 25px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  min-width: 0;
}

.contact-email span {
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.contact-email a {
  width: fit-content;
  max-width: 100%;
  color: var(--accent);
  font-size: 20px;
  font-weight: 600;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color 0.2s ease;
}

.contact-email a:hover {
  color: var(--accent-hover);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Footer */

footer {
  width: 100%;
  padding: 25px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.6;
  border-top: 1px solid var(--border);
}

footer a {
  color: var(--text-secondary);
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease;
}

footer a:hover {
  color: var(--accent-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Discord */

.discord-button {
  margin-left: 0;
  width: fit-content !important;
  max-width: 100%;
}

.discord-button i {
  font-size: 18px;
  line-height: 1;
}

/* Mobile */

@media (max-width: 700px) {
  .nav-container {
    width: calc(100% - 40px);
  }

  .logo {
    font-size: 22px;
  }

  nav {
    gap: 16px;
  }

  nav a {
    font-size: 13px;
  }

  main {
    width: calc(100% - 30px);
    max-width: calc(100% - 30px);
    padding-top: 95px;
    padding-bottom: 40px;
  }

  .backdrop-background {
    aspect-ratio: 16 / 9;
    height: auto;
    border-radius: 14px;
  }

  .backdrop-background h1 {
    font-size: 38px;
  }

  .backdrop-background p {
    font-size: 15px;
  }

  .backdrop-background span {
    right: 12px;
    bottom: 10px;
  }

  .page-header {
    padding-top: 25px;
  }

  .page-content {
    padding: 22px;
  }

  .page-content h2 {
    font-size: 23px;
  }

  .page-content p {
    font-size: 15px;
  }

  .contact-email a {
    font-size: 17px;
  }

  .button {
    width: fit-content !important;
    max-width: 100%;
  }

  .discord-button {
    width: fit-content !important;
  }
}
