:root {
  --bg-start: #071a34;
  --bg-end: #3d6f8f;
  --accent-1: #8ccfff;
  --accent-2: #b5dcff;
  --accent-3: #9fc5ea;
  --menu-font-size: clamp(1.08rem, 1.26vw, 1.26rem);
  --text-main: #f4f7fb;
  --text-muted: rgba(230, 236, 247, 0.75);
}

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Space Grotesk", sans-serif;
  background: linear-gradient(90deg, var(--bg-start), var(--bg-end));
  color: var(--text-main);
  overflow: hidden;
  text-rendering: geometricPrecision;
}

.hero {
  position: relative;
  width: 100vw;
  height: 100vh;
  min-height: 680px;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 20%, rgba(174, 216, 255, 0.22), transparent 30%),
    radial-gradient(circle at 86% 82%, rgba(109, 164, 205, 0.35), transparent 36%),
    radial-gradient(circle at 66% 16%, rgba(198, 224, 255, 0.12), transparent 28%),
    radial-gradient(circle at 28% 78%, rgba(255, 255, 255, 0.12), transparent 42%),
    linear-gradient(90deg, var(--bg-start), var(--bg-end));
  background-size: 180% 180%, 170% 170%, 140% 140%, 130% 130%, 220% 220%;
  background-position: 8% 16%, 88% 84%, 68% 18%, 24% 76%, 0% 50%;
  animation: gradientLoop 20s cubic-bezier(0.45, 0.05, 0.2, 0.95) infinite;
  z-index: 0;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 14% 16%, rgba(255, 255, 255, 0.55) 0 3%, transparent 18%),
    radial-gradient(circle at 88% 86%, rgba(170, 213, 248, 0.24) 0 11%, transparent 30%),
    repeating-radial-gradient(circle at 30% 25%, rgba(255, 255, 255, 0.075) 0 1px, transparent 1px 4px),
    repeating-radial-gradient(circle at 74% 72%, rgba(144, 197, 238, 0.07) 0 1px, transparent 1px 5px);
  mix-blend-mode: screen;
  opacity: 0.75;
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 12%, rgba(255, 255, 255, 0.12), transparent 34%);
  pointer-events: none;
  z-index: 0;
}

.top-nav {
  position: absolute;
  top: 28px;
  left: 50%;
  transform: translateX(-50%);
  width: min(1460px, 92vw);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 3;
  animation: navEnter 0.75s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid rgba(236, 247, 255, 0.29);
  background: linear-gradient(120deg, rgba(239, 248, 255, 0.18), rgba(239, 248, 255, 0.04));
  backdrop-filter: blur(14px);
  box-shadow: 0 20px 34px rgba(5, 12, 24, 0.28), inset 0 0 20px rgba(255, 255, 255, 0.08);
  text-decoration: none;
  font-size: var(--menu-font-size);
  font-weight: 500;
  letter-spacing: 0.01em;
  color: #ffffff;
  font-family: "Space Grotesk", sans-serif;
  text-shadow: 0 10px 34px rgba(6, 12, 25, 0.45);
  transition: opacity 0.25s ease;
}

.brand:hover {
  opacity: 0.92;
}

.menu-pill {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 7px;
  border-radius: 999px;
  border: 1px solid rgba(236, 247, 255, 0.29);
  background: linear-gradient(120deg, rgba(239, 248, 255, 0.18), rgba(239, 248, 255, 0.04));
  backdrop-filter: blur(14px);
  box-shadow: 0 24px 40px rgba(5, 12, 24, 0.34), inset 0 0 24px rgba(255, 255, 255, 0.09);
}

.menu-glider {
  position: absolute;
  top: 7px;
  left: 7px;
  height: calc(100% - 14px);
  border-radius: 999px;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.62), rgba(228, 242, 255, 0.2));
  border: 1px solid rgba(255, 255, 255, 0.46);
  box-shadow: 0 0 26px rgba(143, 196, 255, 0.38), inset 0 0 18px rgba(255, 255, 255, 0.25);
  transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1), width 0.42s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 0;
}

.menu-item {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  color: #deebfb;
  font-size: var(--menu-font-size);
  font-weight: 500;
  letter-spacing: 0.01em;
  width: 116px;
  padding: 11px 8px;
  border-radius: 999px;
  transition: color 0.22s ease, transform 0.22s ease;
}

.menu-item:hover {
  color: #f4f9ff;
  transform: translateY(-1px);
}

.menu-item.active {
  color: #0c1421;
}

.auth-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn {
  border: none;
  cursor: pointer;
  font-size: clamp(0.92rem, 1.02vw, 1.02rem);
  line-height: 1;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: inherit;
}

.btn.login {
  color: #f5f8ff;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.17), rgba(255, 255, 255, 0.05));
  backdrop-filter: blur(12px);
  box-shadow: inset 0 0 14px rgba(255, 255, 255, 0.12), 0 10px 20px rgba(3, 9, 20, 0.22);
}

.btn.cta {
  color: #06121d;
  border: 1px solid rgba(182, 226, 255, 0.65);
  background: linear-gradient(125deg, #f3f9ff, #b8dbff);
  box-shadow: 0 12px 24px rgba(126, 189, 255, 0.42), 0 0 24px rgba(153, 196, 255, 0.3);
}

.btn.cta:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.video-shell {
  position: absolute;
  inset: 16% 11% 4%;
  border-radius: 34px;
  overflow: hidden;
  border: 1px solid rgba(222, 240, 255, 0.38);
  box-shadow:
    0 60px 100px rgba(2, 9, 22, 0.52),
    0 0 0 1px rgba(190, 223, 255, 0.22),
    inset 0 0 84px rgba(164, 206, 255, 0.1);
  z-index: 1;
}

.video-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(145deg, rgba(237, 248, 255, 0.65), rgba(157, 204, 244, 0.26), rgba(237, 248, 255, 0.22));
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.12) contrast(1.08) brightness(0.92);
}

.video-vignette {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 56% 58%, transparent 22%, rgba(4, 10, 20, 0.52) 100%),
    linear-gradient(to top, rgba(6, 12, 22, 0.48), transparent 45%),
    linear-gradient(to right, rgba(6, 12, 22, 0.42), rgba(6, 12, 22, 0.1) 36%, transparent 56%);
  pointer-events: none;
}

.frame-shine {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(108deg, rgba(255, 255, 255, 0.34), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 18%);
  mix-blend-mode: screen;
  pointer-events: none;
  animation: sheen 8s ease-in-out infinite;
}


@keyframes navEnter {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes gradientLoop {
  0% {
    background-position: 8% 16%, 88% 84%, 68% 18%, 24% 76%, 0% 50%;
  }
  50% {
    background-position: 14% 22%, 82% 78%, 60% 24%, 30% 70%, 100% 50%;
  }
  100% {
    background-position: 8% 16%, 88% 84%, 68% 18%, 24% 76%, 0% 50%;
  }
}

@keyframes sheen {
  0%, 100% {
    opacity: 0.55;
  }
  50% {
    opacity: 0.9;
  }
}

@media (max-width: 1100px) {
  .top-nav {
    width: 96vw;
    top: 20px;
  }

  .brand {
    font-size: 1.15rem;
  }

  .menu-item {
    width: 86px;
    padding: 10px 8px;
    font-size: 0.86rem;
  }

  .btn {
    padding: 14px 22px;
    font-size: 0.95rem;
  }

  .video-shell {
    inset: 15% 3% 4%;
  }

}

@media (max-width: 760px) {
  body {
    overflow-y: auto;
  }

  .hero {
    min-height: 780px;
  }

  .top-nav {
    position: static;
    transform: none;
    width: 100%;
    padding: 18px 12px 10px;
    flex-direction: column;
    gap: 12px;
    animation: none;
  }

  .brand {
    font-size: 1.2rem;
  }

  .menu-pill {
    width: 100%;
    justify-content: center;
    flex-wrap: nowrap;
  }

  .menu-item {
    width: 70px;
    font-size: 0.68rem;
    padding: 9px 4px;
  }

  .auth-actions {
    width: 100%;
    justify-content: center;
  }

  .btn {
    font-size: 0.82rem;
    padding: 12px 16px;
  }

  .video-shell {
    inset: 27% 1.5% 2%;
    border-radius: 20px;
  }

}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
