/* ============================================================
   3D Flight Radar — Documentation Page Styles
   Standalone version for the static site (no Electron IPC)
   ============================================================ */

:root {
  --color-bg:         #0a0a0f;
  --color-surface:    #141419;
  --color-border:     rgba(255, 255, 255, 0.08);
  --color-text:       #e0e0e0;
  --color-text-dim:   rgba(255, 255, 255, 0.55);
  --color-accent:     #6ee7b7;
  --color-accent-dim: rgba(110, 231, 183, 0.15);
  --color-white:      #ffffff;

  /* Help content tokens */
  --md-primary:            #6ee7b7;
  --md-surface:            #0a0a0f;
  --md-on-surface:         #e0e0e0;
  --md-on-surface-variant: rgba(255, 255, 255, 0.55);
  --md-primary-container:  rgba(110, 231, 183, 0.12);
  --md-outline-variant:    rgba(255, 255, 255, 0.08);
}

/* ── Reset ──────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

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

body {
  font-family: 'Roboto Flex', system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--color-accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Site header (matches index.html) ───────────────────────── */

.site-header {
  flex-shrink: 0;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-white);
  text-decoration: none;
}
.logo:hover { text-decoration: none; }
.logo-icon { color: var(--color-accent); }
.logo-text {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.header-nav a {
  color: var(--color-text-dim);
  font-size: 14px;
  font-weight: 500;
  transition: color 150ms;
}
.header-nav a:hover {
  color: var(--color-white);
  text-decoration: none;
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 100px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  border: none;
}
.btn-sm {
  padding: 8px 20px;
  font-size: 14px;
  background: transparent;
  color: var(--color-accent);
  border: 1.5px solid rgba(110, 231, 183, 0.35);
}
.btn-sm:hover {
  background: var(--color-accent-dim);
  text-decoration: none;
}

/* ── Help layout (sidebar + content) ────────────────────────── */

.help-layout {
  flex: 1;
  display: flex;
  overflow: hidden;
  min-height: 0;
}

/* ── Left nav sidebar ───────────────────────────────────────── */

.help-nav {
  width: 240px;
  flex-shrink: 0;
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
  overflow-y: auto;
  padding: 20px 10px 32px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.help-nav-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-dim);
  padding: 4px 14px 10px;
}

.help-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.help-nav > ul > li > ul {
  padding-left: 0;
  margin-bottom: 2px;
}

.help-nav a {
  display: block;
  padding: 7px 16px;
  border-radius: 28px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  color: var(--color-text-dim);
  transition: background 180ms, color 180ms;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.help-nav a:hover {
  background: rgba(255, 255, 255, 0.05);
  text-decoration: none;
}

.help-nav a.active {
  background: var(--md-primary-container);
  color: var(--color-accent);
  font-weight: 600;
}

.help-nav a.nav-h3 {
  font-size: 13px;
  font-weight: 400;
  padding: 5px 16px 5px 28px;
}

.help-nav a.nav-h3.active {
  background: var(--md-primary-container);
  color: var(--color-accent);
  font-weight: 600;
}

/* ── Main content ───────────────────────────────────────────── */

.help-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px 40px 48px 32px;
  min-width: 0;
  max-width: 800px;
}

h1 {
  font-size: 28px;
  font-weight: 600;
  margin: 0 0 8px;
  color: var(--color-white);
}

h2 {
  font-size: 20px;
  font-weight: 500;
  margin: 28px 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--color-border);
  scroll-margin-top: 16px;
  color: var(--color-white);
}

h3 {
  font-size: 16px;
  font-weight: 500;
  margin: 18px 0 6px;
  scroll-margin-top: 16px;
  color: var(--color-white);
}

h4 {
  font-size: 15px;
  font-weight: 500;
  margin: 14px 0 4px;
  color: var(--color-white);
}

p { margin: 6px 0 10px; }
ul { margin: 6px 0 10px; padding-left: 20px; }
li { margin: 3px 0; }

kbd {
  display: inline-block;
  padding: 1px 6px;
  font-family: 'Roboto Mono', Consolas, monospace;
  font-size: 13px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  color: inherit;
}

code {
  font-family: 'Roboto Mono', Consolas, monospace;
  font-size: 13px;
  background: rgba(255, 255, 255, 0.06);
  padding: 1px 5px;
  border-radius: 4px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 10px 0;
  font-size: 15px;
}

th, td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--color-border);
}

th {
  font-weight: 500;
  font-size: 13px;
  color: var(--color-text-dim);
}

/* Color swatches */
.color-swatch {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  vertical-align: middle;
  margin-right: 4px;
}

.color-smooth { background: rgb(51,128,255); }
.color-light { background: rgb(0,204,0); }
.color-moderate { background: rgb(255,153,0); }
.color-severe { background: rgb(255,0,0); }
.color-extreme { background: rgb(255,0,255); }
.color-class-b { background: #4582f8; }
.color-class-c { background: #ff00ff; }
.color-class-d { background: #87cefa; }

/* ── Scrollbar ──────────────────────────────────────────────── */

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 100px;
  border: 2px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.28);
  background-clip: padding-box;
}
::-webkit-scrollbar-corner { background: transparent; }

/* ── Responsive ─────────────────────────────────────────────── */

@media (max-width: 768px) {
  .help-nav { display: none; }
  .help-content { padding: 20px 20px 40px; }
  .header-nav a:not(.btn) { display: none; }
}
