:root {
  --navy-900: #0B1B3A;
  --navy-700: #1A3A5F;
  --lime-500: #B5FF2E;
  --orange-500: #FF6B2C;
  --white-100: #FFFFFF;
  --ink-700: #2D3648;
  --gradient-main: linear-gradient(135deg, #0B1B3A, #1A3A5F);
  --gradient-accent: linear-gradient(135deg, #B5FF2E, #FF6B2C);
  --border-strong: 2px solid #FFFFFF;
  --shadow-hard: 8px 8px 0 0 #B5FF2E;
  --font-heading: "Space Grotesk", "Noto Sans SC", sans-serif;
  --font-display: "Playfair Display", "Noto Serif SC", serif;
  --font-body: "Inter", "Noto Sans SC", sans-serif;
  --font-mono: "Roboto Mono", monospace;
  --header-height: 64px;
  --rail-width: 280px;
  --content-width: 1200px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  background: var(--navy-900);
  color: var(--white-100);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
  letter-spacing: inherit;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  line-height: 1.2;
  color: var(--white-100);
  margin: 0 0 0.5em;
  font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.5rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }

p {
  margin: 0 0 1em;
}

a {
  color: var(--lime-500);
  text-decoration-color: currentColor;
}

a:hover {
  text-decoration: none;
}

strong {
  font-weight: 700;
  color: var(--white-100);
}

blockquote {
  font-family: var(--font-display);
  font-size: 1.4rem;
  line-height: 1.5;
  border-left: 4px solid var(--orange-500);
  padding-left: 1rem;
  margin: 1.5rem 0;
  color: var(--white-100);
}

:focus-visible {
  outline: 3px solid var(--lime-500);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: -100%;
  left: 16px;
  z-index: 2000;
  padding: 12px 20px;
  background: var(--lime-500);
  color: var(--navy-900);
  font-family: var(--font-heading);
  font-weight: 700;
  text-decoration: none;
  border: 3px solid var(--navy-900);
  box-shadow: 4px 4px 0 0 var(--navy-900);
  transition: top 0.2s ease;
}

.skip-link:focus-visible {
  top: 16px;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: var(--navy-900);
  border-bottom: 3px solid var(--lime-500);
  transition: box-shadow 0.3s ease;
}

.site-header[data-scrolled="true"] {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white-100);
  text-decoration: none;
}

.brand-link:hover {
  color: var(--white-100);
}

.brand-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  background: var(--gradient-accent);
  color: var(--navy-900);
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  border: 2px solid var(--white-100);
  box-shadow: 3px 3px 0 0 var(--lime-500);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-name {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

.brand-tagline {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.brand-link-rail {
  display: none;
}

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid var(--white-100);
  background: transparent;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--white-100);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.header-rail {
  position: fixed;
  top: 0;
  left: 0;
  width: min(320px, 85vw);
  height: 100vh;
  z-index: 1002;
  display: flex;
  flex-direction: column;
  padding: calc(var(--header-height) + 16px) 20px 32px;
  background: var(--navy-900);
  border-right: 3px solid var(--lime-500);
  overflow-y: auto;
  transform: translateX(-105%);
  transition: transform 0.3s ease;
}

.header-rail[data-open="true"] {
  transform: translateX(0);
}

.site-nav {
  margin-bottom: auto;
}

.nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  border-left: 3px solid transparent;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.nav-link:hover {
  background: rgba(181, 255, 46, 0.08);
  color: var(--white-100);
}

.nav-link[aria-current="page"] {
  background: rgba(181, 255, 46, 0.12);
  border-left-color: var(--lime-500);
  color: var(--lime-500);
}

.header-rail-foot {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 32px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  text-decoration: none;
  border: 2px solid var(--navy-900);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  background: var(--orange-500);
  color: var(--navy-900);
  box-shadow: 4px 4px 0 0 var(--navy-900);
}

.btn-primary:hover {
  background: var(--lime-500);
  color: var(--navy-900);
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 0 var(--navy-900);
}

.btn-block {
  display: flex;
  width: 100%;
}

.progress-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  overflow: hidden;
}

.progress-bar {
  display: block;
  width: var(--progress, 0%);
  height: 100%;
  background: var(--gradient-accent);
  transition: width 0.2s linear;
}

.back-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 900;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--navy-900);
  background: var(--orange-500);
  color: var(--navy-900);
  font-size: 22px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 5px 5px 0 0 var(--navy-900);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.back-top:hover {
  background: var(--lime-500);
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 0 var(--navy-900);
}

.back-top[hidden] {
  display: none;
}

main,
#main-content {
  padding-top: var(--header-height);
}

.section {
  padding: 64px 24px;
}

.container {
  max-width: var(--content-width);
  margin: 0 auto;
}

.grid {
  display: grid;
  gap: 24px;
}

.card {
  background: var(--navy-700);
  border: var(--border-strong);
  box-shadow: var(--shadow-hard);
  padding: 24px;
  color: var(--white-100);
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  background: var(--lime-500);
  color: var(--navy-900);
  text-transform: uppercase;
  letter-spacing: 1px;
  border: 2px solid var(--navy-900);
}

.data-label {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.6);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 24px;
}

.breadcrumbs a {
  color: var(--lime-500);
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.breadcrumbs .sep {
  color: var(--orange-500);
}

.site-footer {
  background: var(--navy-900);
  border-top: 3px solid var(--orange-500);
  color: var(--white-100);
  padding: 48px 24px 24px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  max-width: var(--content-width);
  margin: 0 auto 48px;
}

.footer-brand p {
  margin: 0 0 8px;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 700;
  color: var(--lime-500);
  letter-spacing: 1px;
}

.footer-tagline {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}

.footer-about {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.8);
}

.footer-heading {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--orange-500);
  margin: 0 0 16px;
}

.footer-sitemap ul,
.footer-legal ul,
.footer-contact ul {
  list-style: none;
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 0;
}

.footer-sitemap a,
.footer-legal a {
  font-family: var(--font-body);
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-sitemap a:hover,
.footer-legal a:hover {
  color: var(--lime-500);
}

.footer-contact ul li {
  font-family: var(--font-mono);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.7;
}

.footer-bottom {
  max-width: var(--content-width);
  margin: 0 auto;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
}

html.js [data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

html.js [data-reveal][data-reveal-visible] {
  opacity: 1;
  transform: none;
}

@media (min-width: 768px) {
  .footer-inner {
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  }
}

@media (min-width: 1024px) {
  main,
  #main-content,
  .site-footer {
    padding-top: 0;
    margin-left: var(--rail-width);
  }

  .site-header {
    width: var(--rail-width);
    height: 100vh;
    flex-direction: column;
    align-items: stretch;
    padding: 0;
    background: var(--navy-900);
    border-right: 3px solid var(--lime-500);
    border-bottom: none;
  }

  .header-bar {
    display: none;
  }

  .header-rail {
    position: static;
    width: auto;
    height: auto;
    padding: 32px 24px;
    border-right: none;
    transform: none;
    transition: none;
    overflow: visible;
  }

  .brand-link-rail {
    display: flex;
    margin-bottom: 40px;
  }

  .brand-mark {
    width: 48px;
    height: 48px;
    font-size: 22px;
    box-shadow: 4px 4px 0 0 var(--lime-500);
  }

  .brand-name {
    font-size: 24px;
  }

  .brand-tagline {
    font-size: 11px;
  }

  .header-rail-foot {
    margin-top: 0;
  }

  .btn-block {
    font-size: 13px;
    padding: 12px 16px;
  }

  .site-footer {
    padding: 64px 48px 24px;
  }
}

@media (max-width: 1023px) {
  .header-rail {
    padding-top: calc(var(--header-height) + 16px);
  }
}

@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;
  }

  html.js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
