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

:root {
  --navy-900: #1d2738;
  --navy-800: #232f43;
  --navy-700: #2c3a52;
  --navy-600: #364561;
  --red: #e85d5d;
  --red-soft: rgba(232, 93, 93, 0.55);
  --red-faint: rgba(232, 93, 93, 0.18);
  --white: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.62);
  --text-dim: rgba(255, 255, 255, 0.4);
  --border-soft: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.18);
}

html,
body {
  min-height: 100vh;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
    sans-serif;
  background: radial-gradient(
      ellipse 80% 60% at 80% 50%,
      rgba(232, 93, 93, 0.08) 0%,
      transparent 60%
    ),
    linear-gradient(135deg, var(--navy-800) 0%, var(--navy-700) 100%);
  color: var(--white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Decorative network pattern (right side) */
.bg-network {
  position: fixed;
  top: 0;
  right: 0;
  width: 60vw;
  max-width: 900px;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
  mask-image: radial-gradient(
    ellipse 70% 80% at 80% 50%,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0) 75%
  );
  -webkit-mask-image: radial-gradient(
    ellipse 70% 80% at 80% 50%,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0) 75%
  );
}

.bg-network svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* Subtle grid overlay */
.bg-grid {
  position: fixed;
  inset: 0;
  background-image: linear-gradient(
      rgba(255, 255, 255, 0.025) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.025) 1px,
      transparent 1px
    );
  background-size: 64px 64px;
  pointer-events: none;
  z-index: 0;
  mask-image: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0.6) 0%,
    rgba(0, 0, 0, 0) 70%
  );
  -webkit-mask-image: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0.6) 0%,
    rgba(0, 0, 0, 0) 70%
  );
}

/* Top navigation */
.top-nav {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2.5rem;
}

.nav-mark {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.nav-mark::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 10px var(--red-soft);
}

.lang-toggle {
  display: inline-flex;
  gap: 0.15rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-soft);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 999px;
  padding: 0.22rem;
}

.lang-toggle button {
  background: transparent;
  color: var(--text-muted);
  border: none;
  padding: 0.4rem 0.95rem;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.25s ease;
}

.lang-toggle button.active {
  background: var(--red);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(232, 93, 93, 0.35);
}

.lang-toggle button:hover:not(.active) {
  color: var(--white);
}

.lang-toggle button:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 2px;
}

/* Main */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 2rem 3rem;
  position: relative;
  z-index: 1;
  text-align: center;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.75rem;
  animation: fadeUp 1s cubic-bezier(0.22, 1, 0.36, 1) both;
  max-width: 720px;
}

.logo-frame {
  position: relative;
  width: 84px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-frame::before,
.logo-frame::after {
  content: '';
  position: absolute;
  inset: -10px;
  border-radius: 18px;
  border: 1px solid var(--border-soft);
  pointer-events: none;
}

.logo-frame::after {
  inset: -20px;
  border-color: rgba(255, 255, 255, 0.04);
}

.logo {
  width: 84px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--red);
  color: var(--white);
  font-family: 'Poppins', 'Inter', sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  border-radius: 10px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  user-select: none;
}

.accent-line {
  width: 48px;
  height: 2px;
  background: var(--red);
  border-radius: 2px;
  box-shadow: 0 0 16px var(--red-soft);
}

.brand-name {
  font-family: 'Poppins', 'Inter', sans-serif;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--white);
}

.brand-name span {
  color: var(--red);
}

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.25rem;
  padding: 0.7rem 1.3rem;
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--white);
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: background 0.25s ease, border-color 0.25s ease,
    transform 0.25s ease, box-shadow 0.25s ease;
}

.contact-email:hover {
  background: rgba(232, 93, 93, 0.12);
  border-color: var(--red-soft);
  transform: translateY(-1px);
  box-shadow: 0 10px 30px rgba(232, 93, 93, 0.2);
}

.contact-email:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

.contact-icon {
  color: var(--red);
  flex-shrink: 0;
}

/* Footer */
footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2.5rem;
  font-size: 0.72rem;
  color: var(--text-dim);
  letter-spacing: 0.05em;
  border-top: 1px solid var(--border-soft);
}

footer .foot-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

footer .foot-meta::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--border-strong);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes nodePulse {
  0%,
  100% {
    opacity: 0.6;
  }
  50% {
    opacity: 1;
  }
}

.bg-network circle {
  animation: nodePulse 4s ease-in-out infinite;
}

.bg-network circle:nth-child(3n) {
  animation-delay: 0.5s;
}
.bg-network circle:nth-child(3n + 1) {
  animation-delay: 1.2s;
}

@media (max-width: 768px) {
  .top-nav {
    padding: 1.25rem 1.25rem;
  }
  .nav-mark span {
    display: none;
  }
  footer {
    padding: 1.25rem 1.25rem;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }
  footer .foot-meta::before {
    display: none;
  }
  .bg-network {
    width: 100vw;
    opacity: 0.35;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero,
  .bg-network circle {
    animation: none !important;
  }
}
