:root {
  --bg: #060a10;
  --bg-deep: #03060a;
  --panel: #0e141d;
  --panel-border: #1b2430;
  --text: #f2f4f7;
  --text-muted: #8b96a3;
  --text-faint: #576270;

  --orange: #fc8403;
  --blue: #0064fa;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --radius-sm: 10px;
  --radius-md: 14px;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --nav-height: 64px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

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

h1, h2, h3 {
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.1;
}

.section-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 32px;
}

.page-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, #071019 0%, #060a10 22%, #050810 55%, var(--bg-deep) 100%);
}

.page-bg::before {

  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 45% at 50% 0%, rgba(0, 100, 250, 0.09), transparent 60%),
    radial-gradient(ellipse 60% 40% at 85% 15%, rgba(252, 132, 3, 0.05), transparent 65%);
  pointer-events: none;
}

#waterCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 980px;
  font-weight: 500;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), opacity 0.25s var(--ease);
  white-space: nowrap;
  letter-spacing: -0.005em;
}

.btn-primary {
  background: var(--blue);
  color: #ffffff;
}

.btn-primary:hover {
  background: #0072ff;
}

.btn-primary:active {
  opacity: 0.85;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.1);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 14px 30px;
  font-size: 1rem;
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}

.navbar.scrolled {
  background: rgba(6, 10, 16, 0.78);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.navbar-inner {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
}

.brand-logo {
  height: 24px;
  width: 24px;
  object-fit: contain;
}

.brand-logo-fallback {
  height: 24px;
  width: 24px;
  border-radius: 6px;
  background: var(--blue);
  color: #ffffff;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-links a {
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-muted);
  transition: color 0.2s var(--ease);
}

.nav-links a:hover {
  color: var(--text);
}

.navbar-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 1.5px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}

.nav-toggle.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--nav-height) 24px 60px;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 560px;
}

.hero-logo {
  height: 56px;
  width: 56px;
  object-fit: contain;
  margin: 0 auto 24px;
}

.hero-title {
  font-size: clamp(2.75rem, 6.5vw, 4rem);
  font-weight: 600;
  color: var(--text);
}

.hero-subtitle {
  margin-top: 14px;
  font-size: 1.2rem;
  color: var(--text-muted);
  font-weight: 400;
}

.hero-actions {
  margin-top: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

.about {
  padding: 130px 0;
  position: relative;
}

.about-inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.about h2 {
  font-size: clamp(1.7rem, 3vw, 2.1rem);
  margin-bottom: 18px;
}

.about p {
  color: var(--text-muted);
  font-size: 1.08rem;
  line-height: 1.6;
}

.team {
  padding: 40px 0 140px;
}

.section-heading {
  margin-bottom: 44px;
  text-align: center;
}

.section-heading h2 {
  font-size: clamp(1.7rem, 3vw, 2.1rem);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.team-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  padding: 22px 16px;
  text-align: center;
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease);
}

.team-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
}

.team-avatar-wrap {
  position: relative;
  width: 64px;
  height: 64px;
  margin: 0 auto 14px;
}

.team-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.status-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 2.5px solid #0e141d;
  background: var(--text-faint);
}

.status-dot.online { background: #23a55a; }
.status-dot.idle { background: #f0b232; }
.status-dot.dnd { background: #f23f43; }
.status-dot.offline { background: #6b7280; }

.team-name {
  font-weight: 600;
  font-size: 0.95rem;
}

.team-role {
  margin-top: 3px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.team-presence {
  margin-top: 9px;
  font-size: 0.74rem;
  color: var(--text-faint);
  min-height: 1em;
  line-height: 1.4;
}

.team-presence .activity {
  color: var(--text-muted);
}

.community {
  padding: 110px 0;
}

.community-inner {
  text-align: center;
  max-width: 520px;
  margin: 0 auto;
}

.community-inner h2 {
  font-size: clamp(1.7rem, 3vw, 2.1rem);
  margin-bottom: 12px;
}

.community-inner p {
  color: var(--text-muted);
  font-size: 1.02rem;
  margin-bottom: 32px;
}

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 30px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.92rem;
}

.footer-logo {
  height: 18px;
  width: 18px;
  object-fit: contain;
}

.footer-copy {
  color: var(--text-faint);
  font-size: 0.82rem;
}

.footer-link {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 400;
  transition: color 0.2s var(--ease);
}

.footer-link:hover {
  color: var(--text);
}

@media (max-width: 860px) {
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(6, 10, 16, 0.97);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    padding: 8px 32px 20px;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links a {
    padding: 14px 0;
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-links a:last-child {
    border-bottom: none;
  }

  .navbar-actions .btn-sm {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }
}

@media (max-width: 560px) {
  .section-inner {
    padding: 0 22px;
  }

  .about {
    padding: 100px 0;
  }

  .team {
    padding: 30px 0 100px;
  }

  .team-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .team-card {
    padding: 18px 12px;
  }

  .community {
    padding: 90px 0;
  }

  .footer-inner {
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 380px) {
  .team-grid {
    grid-template-columns: 1fr 1fr;
  }
}
