:root {
  --bg: #eff5ff;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-strong: #ffffff;
  --surface-soft: #f5f9ff;
  --ink: #10213f;
  --ink-soft: #4a5c7f;
  --line: rgba(16, 33, 63, 0.1);
  --line-strong: rgba(27, 92, 255, 0.18);
  --blue-700: #1b5cff;
  --blue-800: #1344c7;
  --navy-900: #0b1b33;
  --shadow-lg: 0 24px 70px rgba(10, 28, 58, 0.12);
  --shadow-md: 0 16px 38px rgba(10, 28, 58, 0.08);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 18px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --max: 1200px;
}

html {
  scroll-behavior: smooth;
}

body.subpage-body {
  background:
    radial-gradient(circle at top left, rgba(140, 230, 255, 0.25), transparent 34%),
    radial-gradient(circle at 90% 15%, rgba(27, 92, 255, 0.14), transparent 26%),
    linear-gradient(180deg, #f8fbff 0%, #eef5ff 44%, #ffffff 100%);
  color: var(--ink);
  overflow-x: hidden;
}

.grid-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: 0.45;
  background-image:
    linear-gradient(to right, rgba(16, 33, 63, 0.045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(16, 33, 63, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.7), transparent 88%);
}

.blobs {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  background:
    radial-gradient(circle at 8% 0%, rgba(27, 92, 255, 0.14), transparent 34%),
    radial-gradient(circle at 92% 12%, rgba(54, 211, 255, 0.14), transparent 28%),
    radial-gradient(circle at 50% 100%, rgba(27, 92, 255, 0.06), transparent 32%);
}

.progress-bar {
  position: fixed;
  inset: 0 auto auto 0;
  width: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--blue-700), #3dbeff);
  box-shadow: 0 0 18px rgba(27, 92, 255, 0.35);
  z-index: 1200;
}

.shell {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(248, 251, 255, 0.82);
  border-bottom: 1px solid rgba(16, 33, 63, 0.08);
}

.site-header .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.brand img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.brand-mark,
.brand-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brand-mark strong,
.brand-copy strong {
  font-size: 1.1rem;
  letter-spacing: -0.05em;
  text-transform: uppercase;
}

.brand-mark span,
.brand-copy span {
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  color: #6f83aa;
  text-transform: uppercase;
  margin-top: 2px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
}

.desktop-nav a:not(.button) {
  position: relative;
  font-size: 0.9rem;
  font-weight: 700;
  color: #546786;
}

.desktop-nav a:not(.button)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -7px;
  width: 100%;
  height: 2px;
  transform: scaleX(0);
  transform-origin: left;
  background: linear-gradient(90deg, var(--blue-700), #33c6ff);
  transition: transform 0.28s var(--ease);
}

.desktop-nav a:not(.button):hover::after,
.desktop-nav a:not(.button):focus-visible::after,
.desktop-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.desktop-nav a[aria-current="page"] {
  color: var(--blue-700);
}

.desktop-nav .is-portal-link {
  font-size: 0.82rem;
  color: #6f83aa;
}

.button,
button.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: -0.02em;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), background 0.22s var(--ease), color 0.22s var(--ease);
}

.button:hover,
button.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: linear-gradient(135deg, var(--navy-900), #16386f);
  color: #fff;
  box-shadow: 0 14px 30px rgba(17, 37, 72, 0.22);
  padding: 14px 20px;
}

.button-secondary {
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  border: 1px solid rgba(16, 33, 63, 0.1);
  padding: 14px 20px;
}

.mobile-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  border: 1px solid rgba(16, 33, 63, 0.08);
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
}

.mobile-toggle svg {
  width: 24px;
  height: 24px;
}

.mobile-menu {
  position: fixed;
  inset: 82px 14px auto 14px;
  z-index: 999;
  padding: 18px;
  border: 1px solid rgba(16, 33, 63, 0.09);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-lg);
  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.22s var(--ease), opacity 0.22s var(--ease);
}

.mobile-menu.is-open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.mobile-menu a {
  display: block;
  padding: 14px 8px;
  border-bottom: 1px solid rgba(16, 33, 63, 0.06);
  font-weight: 700;
  color: #395074;
}

.mobile-menu a:last-of-type {
  border-bottom: 0;
}

.mobile-menu a[aria-current="page"] {
  color: var(--blue-700);
}

.mobile-menu .button {
  width: 100%;
  justify-content: center;
  margin-top: 10px;
}

.page-main {
  position: relative;
}

.site-footer {
  padding: 0 0 34px;
}

.site-footer .footer-inner {
  border: 1px solid rgba(16, 33, 63, 0.08);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #617595;
  box-shadow: var(--shadow-md);
}

.site-footer .footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-weight: 700;
}

.site-footer .footer-links a[aria-current="page"] {
  color: var(--blue-700);
}

.site-footer .footer-brand {
  display: block;
  font-size: 1.05rem;
  color: var(--ink);
}

@media (max-width: 960px) {
  .desktop-nav {
    display: none;
  }

  .mobile-toggle {
    display: inline-grid;
    place-items: center;
  }
}

@media (max-width: 720px) {
  .site-header .shell {
    min-height: 74px;
  }

  .mobile-menu {
    inset: 74px 10px auto 10px;
  }

  .site-footer .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
