/* ==========================================================================
   AG NOVA — 02 BASE
   Reset, document defaults, typography defaults, scrollbars, selection.
   Adapted from N.O.V.A. OS. The only divergence is the removal of the
   taskbar padding: this instrument has no taskbar.
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  height: 100%;
}

body {
  min-height: 100%;
  background-color: var(--nova-space);
  color: var(--nova-text-secondary);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(143, 216, 224, 0.055), transparent 70%),
    radial-gradient(ellipse 60% 40% at 90% 100%, rgba(230, 130, 47, 0.035), transparent 70%);
  background-attachment: fixed;
}

/* CRT scanlines. Deliberately excluded from the chart itself: a texture over
   a map degrades legibility of the very thing the operator came to read. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0),
    rgba(255, 255, 255, 0) 3px,
    rgba(0, 0, 0, 0.055) 3px,
    rgba(0, 0, 0, 0.055) 6px
  );
  animation: nova-scanlines-pulse 8s ease-in-out infinite;
}

@keyframes nova-scanlines-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: var(--ls-wide);
  color: var(--nova-text-primary);
  text-transform: uppercase;
}

p { margin-bottom: var(--sp-3); }
p:last-child { margin-bottom: 0; }

a {
  color: var(--nova-cyan);
  text-decoration: none;
  transition: color var(--t-hover) var(--ease-snap);
}
a:hover { color: var(--nova-cyan-bright); }

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--nova-cyan);
  outline-offset: 2px;
}

ul, ol { list-style: none; }

img { max-width: 100%; height: auto; display: block; }

code, kbd, samp, pre {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 0.9em;
}

::selection {
  background: var(--nova-cyan);
  color: var(--nova-space);
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--nova-border) var(--nova-chassis);
}
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track {
  background: var(--nova-chassis);
  border-left: var(--border-thin) solid var(--nova-grid);
}
::-webkit-scrollbar-thumb {
  background: var(--nova-border);
  border: 2px solid var(--nova-chassis);
}
::-webkit-scrollbar-thumb:hover { background: var(--nova-cyan); }

.nova-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;
}

.nova-skip-link {
  position: absolute;
  top: -100px;
  left: var(--sp-4);
  z-index: 200;
  padding: var(--sp-2) var(--sp-4);
  background: var(--nova-cyan);
  color: var(--nova-space);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: var(--fs-small);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
}
.nova-skip-link:focus { top: var(--sp-4); }
