/* =====================================================
   DESIGN TOKENS
   ===================================================== */
:root {
  --bg:           #08090e;
  --surface:      #0f1117;
  --border:       #1e2330;
  --accent:       #4a9eff;
  --accent-dim:   #1a3a5c;
  --text-primary: #e2e8f0;
  --text-muted:   #6b7a95;
  --accent-light: #6ab1ff;
  --error:        #e05c5c;
  --font-sans:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono:    'Courier New', Courier, monospace;
  --max-width:    1200px;
  --section-pad:  6rem;
  --gap:          1.5rem;
  --radius:       6px;
}

/* =====================================================
   RESET
   ===================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img, svg { display: block; max-width: 100%; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-size: 16px; }

/* =====================================================
   LAYOUT
   ===================================================== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}
section { padding: var(--section-pad) 0; }

/* =====================================================
   TYPOGRAPHY UTILITIES
   ===================================================== */
.section-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}
.section-heading {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
}

/* =====================================================
   BUTTON
   ===================================================== */
.btn {
  display: inline-block;
  padding: 0.75rem 2rem;
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover {
  background: var(--accent-dim);
  box-shadow: 0 0 20px rgba(74,158,255,0.2);
}
.btn-primary {
  background: var(--accent);
  color: var(--bg);
}
.btn-primary:hover {
  background: var(--accent-light);
  box-shadow: 0 0 20px rgba(74,158,255,0.4);
  color: var(--bg);
}

/* =====================================================
   SECTION DIVIDER
   ===================================================== */
.section-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0;
  color: var(--border);
}
.section-divider::before,
.section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.section-divider span { color: var(--accent); font-size: 0.5rem; }

/* =====================================================
   TOAST
   ===================================================== */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  padding: 1rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  z-index: 999;
  transform: translateY(100px);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
}
.toast.toast--visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}
.toast--success { border-left: 3px solid var(--accent); }
.toast--error   { border-left: 3px solid var(--error); }

/* =====================================================
   SCROLL ENTRANCE ANIMATIONS
   ===================================================== */
.animate-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* =====================================================
   NAVIGATION
   ===================================================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  transition: background 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: var(--surface);
  border-bottom-color: var(--border);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4rem;
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.nav__wordmark {
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.1em;
  color: var(--text-primary);
}
.nav__diamond {
  color: var(--accent);
  font-size: 0.45rem;
  line-height: 1;
}
.nav__sub {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}
.nav__links {
  display: flex;
  gap: 2.5rem;
}
.nav__links a {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav__links a:hover { color: var(--text-primary); }

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 6px;
}
.nav__hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text-primary);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.nav.nav-open .nav__hamburger span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav.nav-open .nav__hamburger span:nth-child(2) { opacity: 0; }
.nav.nav-open .nav__hamburger span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
}
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.footer__copy {
  font-size: 0.8rem;
  color: var(--text-muted);
}
.footer__links {
  display: flex;
  gap: 2rem;
}
.footer__links a {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.footer__links a:hover { color: var(--text-primary); }

/* Mobile nav */
@media (max-width: 767px) {
  .nav__hamburger { display: flex; }
  .nav__links {
    display: none;
    position: absolute;
    top: 4rem; left: 0; right: 0;
    background: var(--surface);
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--border);
  }
  .nav.nav-open .nav__links { display: flex; }
  .nav__links li { border-top: 1px solid var(--border); }
  .nav__links a { display: block; padding: 1rem 2rem; }
  .footer__inner { flex-direction: column; text-align: center; }
  .footer__links { justify-content: center; }
}

/* =====================================================
   HERO
   ===================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 4rem;
}
.hero__globe-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

/* ── CSS 3D Globe ──────────────────────────────────── */
.globe-scene {
  position: relative;
  width: 420px;
  height: 420px;
  perspective: 600px;
}
.globe-3d {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  animation: spinGlobe 22s linear infinite;
}
@keyframes spinGlobe {
  from { transform: rotateX(12deg) rotateY(0deg); }
  to   { transform: rotateX(12deg) rotateY(360deg); }
}
.globe-ring { position: absolute; border-radius: 50%; }

/* Meridians: 2px-wide vertical ovals, each pre-rotated around Y at different angles */
.mer {
  top: 0; left: 50%;
  width: 2px; height: 420px;
  margin-left: -1px;
  border: 1px solid rgba(74,158,255,0.22);
  transform-origin: 50% 50%;
}
.mer-0   { transform: rotateY(0deg);   }
.mer-30  { transform: rotateY(30deg);  }
.mer-60  { transform: rotateY(60deg);  }
.mer-90  { transform: rotateY(90deg);  }
.mer-120 { transform: rotateY(120deg); }
.mer-150 { transform: rotateY(150deg); }

/* Latitude parallels: flat rings rotated 90° on X, shifted along Z axis */
.lat { left: 50%; border: 1px solid rgba(74,158,255,0.18); transform-origin: 50% 50%; }
.lat-eq {
  width: 420px; height: 420px; top: 0; margin-left: -210px;
  transform: rotateX(90deg);
}
.lat-30n {
  width: 364px; height: 364px; top: 28px; margin-left: -182px;
  transform: rotateX(90deg) translateZ(105px);
}
.lat-30s {
  width: 364px; height: 364px; top: 28px; margin-left: -182px;
  transform: rotateX(90deg) translateZ(-105px);
}
.lat-60n {
  width: 210px; height: 210px; top: 105px; margin-left: -105px;
  transform: rotateX(90deg) translateZ(182px);
}
.lat-60s {
  width: 210px; height: 210px; top: 105px; margin-left: -105px;
  transform: rotateX(90deg) translateZ(-182px);
}

/* Static tactical overlay */
.globe-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.globe-overlay svg { width: 100%; height: 100%; }

/* Pulsing target dot */
.globe-dot {
  position: absolute;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  transform: translate(-50%, -50%);
  animation: dotPulse 2.5s ease-in-out infinite;
}
.globe-dot::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  animation: dotRing 2.5s ease-in-out infinite;
}
@keyframes dotPulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.5; }
}
@keyframes dotRing {
  0%   { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(2.8); opacity: 0; }
}

/* Scan line */
.globe-scanline {
  position: absolute;
  left: 5%; right: 5%;
  height: 80px;
  background: linear-gradient(to bottom,
    transparent,
    rgba(74,158,255,0.04),
    rgba(74,158,255,0.07),
    rgba(74,158,255,0.04),
    transparent
  );
  animation: scanSweep 5s ease-in-out infinite;
  pointer-events: none;
}
@keyframes scanSweep {
  0%   { top: 5%;  opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { top: 78%; opacity: 0; }
}

/* Coordinate label */
.globe-coords {
  position: absolute;
  bottom: 18%; right: 8%;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  pointer-events: none;
}

/* Radial glow behind globe */
.globe-glow {
  position: absolute;
  inset: -20%;
  border-radius: 50%;
  background: radial-gradient(circle at center, rgba(74,158,255,0.07) 0%, transparent 65%);
  pointer-events: none;
  z-index: -1;
}

/* Hero text */
.hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.5rem;
  padding-top: 2rem;
  padding-bottom: 2rem;
  max-width: 560px;
}
.hero__classify {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.hero__heading {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.hero__sub {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 400px;
  line-height: 1.6;
}

/* Hero responsive */
@media (max-width: 767px) {
  .hero__content { align-items: center; text-align: center; max-width: 100%; }
  .hero__heading  { font-size: clamp(2rem, 10vw, 3rem); }
  .globe-scene    { width: 280px; height: 280px; }
  .mer            { height: 280px; }
  .lat-eq  { width: 280px; height: 280px; margin-left: -140px; }
  .lat-30n { width: 242px; height: 242px; top: 19px; margin-left: -121px;
             transform: rotateX(90deg) translateZ(70px); }
  .lat-30s { width: 242px; height: 242px; top: 19px; margin-left: -121px;
             transform: rotateX(90deg) translateZ(-70px); }
  .lat-60n { width: 140px; height: 140px; top: 70px; margin-left: -70px;
             transform: rotateX(90deg) translateZ(121px); }
  .lat-60s { width: 140px; height: 140px; top: 70px; margin-left: -70px;
             transform: rotateX(90deg) translateZ(-121px); }
}

/* =====================================================
   MISSION
   ===================================================== */
.mission__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 4rem;
}
.mission__copy p {
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}
.mission__copy p:last-child { margin-bottom: 0; }

.classified {
  font-family: var(--font-mono);
  font-size: 0.8em;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-shadow: 0 0 12px rgba(74,158,255,0.4);
}
.classified--sm {
  font-family: var(--font-mono);
  font-size: 0.75em;
  color: var(--accent);
  letter-spacing: 0.04em;
  text-shadow: 0 0 8px rgba(74,158,255,0.3);
}

.mission__stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.stat { display: flex; flex-direction: column; gap: 0.25rem; }
.stat__value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
}
.stat__label {
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

@media (max-width: 1023px) {
  .mission__grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* =====================================================
   VACANCIES
   ===================================================== */
.vacancy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--gap);
  margin-bottom: 2rem;
}
.vacancy-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.vacancy-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 4px 24px rgba(74,158,255,0.12);
}
.vacancy-card__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}
.vacancy-card__desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
}
.vacancy-card__link {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.04em;
  transition: letter-spacing 0.2s;
  margin-top: 0.5rem;
  align-self: flex-start;
}
.vacancy-card:hover .vacancy-card__link { letter-spacing: 0.08em; }

.vacancies__fallback { font-size: 0.875rem; color: var(--text-muted); }
.vacancies__fallback-link { color: var(--accent); transition: opacity 0.2s; }
.vacancies__fallback-link:hover { opacity: 0.8; }

/* =====================================================
   CONTACT
   ===================================================== */
.contact__grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 4rem;
  align-items: start;
}
.contact__info { padding-top: 3.75rem; }

.contact__detail {
  margin-bottom: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.contact__detail-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.contact__detail-value { font-size: 0.95rem; color: var(--text-primary); }
a.contact__detail-value:hover { color: var(--accent); }

/* =====================================================
   SHARED FORM COMPONENTS  (contact form + apply form)
   ===================================================== */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}
.form-label {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.form-input,
.form-textarea {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
  -webkit-appearance: none;
}
.form-input:focus,
.form-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(74,158,255,0.15);
}
.form-input.error,
.form-textarea.error { border-color: #e05c5c; }
.form-textarea { resize: vertical; min-height: 120px; }

/* Honeypot: visually hidden but not display:none */
.form-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  opacity: 0;
}

@media (max-width: 1023px) {
  .contact__grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .contact__info  { padding-top: 0; }
}

/* =====================================================
   VACANCY PAGE
   ===================================================== */
.vacancy-page { padding-top: 4rem; min-height: 80vh; }
.vacancy-page__inner { padding-top: 3rem; padding-bottom: 6rem; }
.vacancy-page__title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 2.5rem;
  letter-spacing: -0.01em;
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.breadcrumb a { transition: color 0.2s; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb__sep { color: var(--border); }

/* Vacancy content */
.vacancy-content { max-width: 800px; }
.vacancy-section { margin-bottom: 1.25rem; padding: 1.5rem 0; }
.vacancy-section__heading {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.vacancy-section p {
  font-size: 0.95rem;
  color: var(--text-muted);
}
.vacancy-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.vacancy-list li {
  font-size: 0.93rem;
  color: var(--text-muted);
  padding-left: 1.25rem;
  position: relative;
}
.vacancy-list li::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* Apply section */
.vacancy-section--apply { margin-top: 1.5rem; }

/* Form grid (2-col for apply form) */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 1.5rem;
}
.form-group--full { grid-column: 1 / -1; }
.form-label--opt  { font-size: 0.65rem; color: var(--text-muted); font-weight: 400; margin-left: 0.25rem; }
.form-label--note { font-size: 0.65rem; color: var(--text-muted); font-weight: 400; margin-left: 0.25rem;
                    font-family: var(--font-mono); }

/* File input */
.form-file { padding: 0.6rem 1rem; cursor: pointer; }
.form-file::-webkit-file-upload-button {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: var(--accent);
  padding: 0.3rem 0.75rem;
  border-radius: 4px;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  margin-right: 0.75rem;
  transition: background 0.2s;
}
.form-file::-webkit-file-upload-button:hover {
  background: var(--accent);
  color: var(--bg);
}

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