:root {
  --ink: #e5f3f8;
  --muted: #aac7d1;
  --accent: #003c71;
  --accent-2: #f59e0b;
  --bg-0: #031320;
  --bg-1: #07263a;
  --bg-2: #0f3f54;
}

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 80% 20%, rgba(0, 60, 113, 0.24), transparent 40%),
    radial-gradient(circle at 10% 80%, rgba(245, 158, 11, 0.12), transparent 38%),
    linear-gradient(140deg, var(--bg-0), var(--bg-1) 48%, var(--bg-2));
  min-height: 100dvh;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  position: relative;
  overflow-x: hidden;
}

.background-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.25;
  background-image:
    linear-gradient(to right, rgba(170, 199, 209, 0.14) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(170, 199, 209, 0.14) 1px, transparent 1px);
  background-size: 50px 50px;
  mask-image: radial-gradient(circle at center, black 35%, transparent 80%);
}

.background-403 {
  position: fixed;
  right: clamp(-0.12em, -3vw, -0.04em);
  bottom: clamp(-0.22em, -5.2vw, -0.09em);
  font-family: "Sora", "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: clamp(14rem, 54vw, 44rem);
  line-height: 0.78;
  letter-spacing: -0.07em;
  color: rgba(180, 247, 239, 0.08);
  pointer-events: none;
  user-select: none;
  z-index: 1;
  text-shadow:
    0 0 35px rgba(0, 60, 113, 0.32),
    0 0 90px rgba(0, 60, 113, 0.24),
    0 30px 105px rgba(2, 8, 12, 0.6);
  filter: saturate(120%);
  opacity: 0.95;
  animation: glow-shift 8s ease-in-out infinite;
}

.layout {
  width: min(1200px, 92vw);
  margin: 0 auto;
  min-height: 0;
  height: 100%;
  padding: clamp(2.3rem, 5.2vh, 3.8rem) 0 clamp(0.65rem, 1.6vh, 1.3rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  position: relative;
  z-index: 2;
}

.site-footer {
  width: min(1200px, 92vw);
  margin: 0 auto;
  padding: 0 0 clamp(0.65rem, 1.4vh, 1rem);
  position: relative;
  z-index: 2;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.2rem 1rem;
  margin: 0 0 0.55rem;
  padding: 0;
  list-style: none;
}

.footer-link {
  color: rgba(229, 243, 248, 0.62);
  text-decoration: none;
  font-size: clamp(0.72rem, 1.2vw, 0.82rem);
  letter-spacing: 0.02em;
  transition: color 160ms ease, text-decoration-color 160ms ease;
}

.footer-link:hover {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: rgba(229, 243, 248, 0.5);
}

.footer-link .fa-arrow-up-right-from-square {
  font-size: 0.72em;
  margin-left: 0.22em;
  vertical-align: 0.06em;
}

.site-footer p {
  margin: 0;
  color: rgba(229, 243, 248, 0.82);
  font-size: clamp(0.72rem, 1.2vw, 0.82rem);
  line-height: 1.45;
  letter-spacing: 0.02em;
  text-align: center;
}

#legal-updated {
  white-space: nowrap;
}

.content {
  width: min(66%, 760px);
  padding: clamp(1rem, 1.4vw, 1.3rem) 0;
  animation: slide-up 0.85s ease-out;
}

.brand-mark {
  width: clamp(86px, 8vw, 120px);
  height: clamp(86px, 8vw, 120px);
  margin: 0 0 0.95rem;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 22px rgba(2, 8, 12, 0.42));
}

.eyebrow {
  margin: 0;
  letter-spacing: 0.18em;
  font-size: 0.8rem;
  color: #f8fbff;
  font-weight: 700;
}

h1 {
  font-family: "Sora", "Space Grotesk", sans-serif;
  margin: 0.7rem 0 1.2rem;
  font-size: clamp(2rem, 6vw, 4rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.code {
  color: #cf2338;
  text-shadow: 0 0 28px rgba(207, 35, 56, 0.34);
}

.lead {
  margin: 0;
  font-size: clamp(1.1rem, 2.35vw, 1.5rem);
  line-height: 1.5;
  max-width: 56ch;
}

.subtle {
  margin-top: 1rem;
  color: var(--muted);
  line-height: 1.6;
  max-width: 52ch;
}

.warning-note {
  margin-top: 1.5rem;
  color: #dbedf3;
  line-height: 1.55;
  font-size: clamp(0.94rem, 1.5vw, 1.04rem);
  max-width: 58ch;
  padding: 0;
}

.ip-line {
  margin: 1rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.65rem;
  align-items: center;
  padding: 0;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  font-size: clamp(0.86rem, 1.28vw, 0.95rem);
  line-height: 1.45;
}

.ip-label {
  color: var(--muted);
  font-size: 0.93em;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ip-meta {
  color: #e2e8f0;
  padding: 0.16rem 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(226, 232, 240, 0.22);
  background: rgba(2, 6, 23, 0.28);
  font-size: 0.93em;
}

.cta-group {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.cta-dropdown {
  position: relative;
}

.cta-dropdown-toggle {
  cursor: pointer;
  font-family: inherit;
}

.cta-dropdown-toggle .cta-arrow i {
  transition: transform 200ms ease;
}

.cta-dropdown-toggle[aria-expanded="true"] .cta-arrow i {
  transform: rotate(180deg);
}

.cta-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.45rem);
  left: 0;
  min-width: 100%;
  margin: 0;
  padding: 0.3rem 0;
  list-style: none;
  background: rgba(7, 26, 44, 0.96);
  border: 1px solid rgba(0, 60, 113, 0.55);
  border-radius: 0.75rem;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 36px rgba(2, 8, 12, 0.52);
  z-index: 10;
  white-space: nowrap;
}

.cta-dropdown-menu.is-open {
  display: block;
  animation: fade-in 140ms ease;
}

.cta-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.48rem 1rem;
  color: #e5f0fb;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background 140ms ease, color 140ms ease;
}

.cta-dropdown-item:hover {
  background: rgba(0, 60, 113, 0.38);
  color: #fff;
}

.cta-dropdown-item .fa-arrow-up-right-from-square {
  font-size: 0.72em;
  opacity: 0.7;
}

.cta-button {
  margin-top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.36rem;
  border: 1px solid rgba(0, 60, 113, 0.7);
  border-radius: 999px;
  padding: 0.5rem 0.82rem;
  text-decoration: none;
  color: #e5f0fb;
  background: linear-gradient(110deg, rgba(0, 60, 113, 0.72), rgba(245, 158, 11, 0.4));
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: 0.01em;
  transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.cta-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1;
  color: #c7dcf2;
  text-shadow: 0 0 18px rgba(0, 60, 113, 0.42);
  transition: transform 160ms ease;
}

.cta-arrow i {
  font-size: 1em;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(5, 12, 18, 0.34);
}

.cta-button:hover .cta-arrow {
  transform: translateX(5px) scale(1.06);
}

.cta-button:focus-visible {
  outline: 3px solid rgba(0, 60, 113, 0.52);
  outline-offset: 2px;
}

@media (max-width: 980px) {
  .layout {
    min-height: 0;
    align-items: flex-end;
    padding-top: clamp(1.35rem, 3.2vh, 2.1rem);
  }

  .content {
    width: 100%;
    padding-bottom: 1.3rem;
  }

  .background-403 {
    font-size: clamp(9rem, 52vw, 20rem);
    right: clamp(-0.24em, -6.5vw, -0.08em);
    bottom: clamp(-0.18em, -6vw, -0.05em);
    opacity: 0.82;
  }
}

@keyframes slide-up {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes glow-shift {
  0%,
  100% {
    text-shadow:
      0 0 35px rgba(0, 60, 113, 0.3),
      0 0 90px rgba(0, 60, 113, 0.22),
      0 30px 105px rgba(2, 8, 12, 0.6);
  }

  50% {
    text-shadow:
      0 0 52px rgba(0, 60, 113, 0.38),
      0 0 120px rgba(0, 60, 113, 0.3),
      0 38px 125px rgba(2, 8, 12, 0.68);
  }
}

/* ── 404 toast ───────────────────────────────────────────── */
.toast-404 {
  position: fixed;
  bottom: clamp(1rem, 3vh, 2rem);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1rem 0.7rem 1.1rem;
  max-width: min(480px, 92vw);
  background: rgba(7, 26, 44, 0.94);
  border: 1px solid rgba(245, 158, 11, 0.48);
  border-radius: 0.75rem;
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.45;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(2, 8, 12, 0.52);
  z-index: 200;
  animation: toast-in 320ms cubic-bezier(0.22, 1, 0.36, 1);
}

.toast-404--out {
  animation: toast-out 300ms ease forwards;
}

.toast-404__close {
  flex-shrink: 0;
  margin-left: auto;
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 1.15rem;
  line-height: 1;
  padding: 0.1rem 0.25rem;
  border-radius: 0.3rem;
  transition: color 140ms ease;
}

.toast-404__close:hover {
  color: var(--ink);
}

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

@keyframes toast-out {
  to {
    opacity: 0;
    transform: translateX(-50%) translateY(14px);
  }
}
