/* Navigation console — full-window holographic plot with a left-hand
   tabbed navigator sidebar. Loaded only by the landing pages. */

.console-page,
body.console-page { height: 100vh; overflow: hidden; }

/* The [hidden] attribute must beat the component display rules below —
   otherwise hidden panels (fallback, loader) keep rendering and the
   fallback overlay swallows every pointer event. */
[hidden] { display: none !important; }

.console { position: fixed; inset: 0; z-index: 0; }
#holo-canvas { display: block; width: 100%; height: 100%; touch-action: none; }

/* header floats top-right over the hologram */
.site-header--over {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 6;
  justify-content: flex-end;
  border-bottom: none;
  background: linear-gradient(180deg, rgba(9, 12, 18, 0.7), transparent);
  pointer-events: none;
}
.site-header--over a { pointer-events: auto; }

/* ---- boot + fallback ---- */
.holo-loading {
  position: fixed; left: 0; right: 0; bottom: 26px;
  z-index: 4;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--ink-mute);
}
.holo-loading::after {
  content: ""; margin-left: 12px;
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
  animation: holo-blink 1.1s var(--ease) infinite;
}
@keyframes holo-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.15; } }

.holo-fallback {
  position: fixed; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 18px; z-index: 4; padding: 32px; text-align: center;
}
.holo-fallback .kicker, .holo-fallback .cta-row { justify-content: center; }

/* ---- HUD ---- */
.hud {
  position: fixed; inset: 0; z-index: 3;
  pointer-events: none;
  opacity: 0; transition: opacity 1.1s var(--ease) 0.3s;
}
.holo-ready .hud { opacity: 1; }
.hud-br {
  position: absolute; bottom: 26px; right: 34px;
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-mute);
}

/* ============================================================
   NAVIGATOR SIDEBAR
   ============================================================ */
.nav-sidebar {
  position: fixed;
  left: 22px; top: 74px; bottom: 22px;
  width: 392px; max-width: calc(100vw - 44px);
  z-index: 5;
  background: rgba(12, 17, 26, 0.9);
  -webkit-backdrop-filter: blur(7px);
          backdrop-filter: blur(7px);
  border: 1px solid var(--line-bright);
  border-radius: 5px;
  display: flex; flex-direction: column;
  overflow: hidden;
  opacity: 0; transform: translateX(-12px);
  transition: opacity 0.9s var(--ease) 0.4s, transform 0.9s var(--ease) 0.4s;
}
.holo-ready .nav-sidebar { opacity: 1; transform: translateX(0); }

.sb-head {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--line);
}
.sb-head-title {
  font-family: var(--font-mono);
  font-size: 15px; font-weight: 500;
  letter-spacing: 0.26em; color: var(--ink);
}
.sb-head-sub {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ink-mute); margin-top: 6px;
}

/* ---- user profile ---- */
.sb-profile {
  display: flex; align-items: center; gap: 13px;
  padding: 15px 24px;
  border-bottom: 1px solid var(--line);
}
.sb-avatar {
  flex: 0 0 42px; width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-family: var(--font-mono);
  font-size: 17px; letter-spacing: 0.02em;
  color: var(--accent);
  background: radial-gradient(circle at 50% 34%, rgba(236, 202, 140, 0.16), rgba(236, 202, 140, 0.03));
  border: 1px solid var(--accent-deep);
  box-shadow: 0 0 0 4px rgba(236, 202, 140, 0.035);
}
.sb-profile-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.sb-profile-name { font-size: 15px; color: var(--ink); letter-spacing: 0.01em; }
.sb-profile-role {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink-mute);
}
.sb-profile-loc {
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent-dim); text-align: right; line-height: 1.5;
}

/* ---- tabs ---- */
.sb-tabs { display: flex; border-bottom: 1px solid var(--line); }
.sb-tab {
  flex: 1;
  padding: 13px 6px 11px;
  background: none; border: none;
  border-bottom: 2px solid transparent;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-mute); cursor: pointer;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.sb-tab:hover { color: var(--ink-soft); }
.sb-tab.is-active { color: var(--accent); border-bottom-color: var(--accent-deep); }

/* ---- content body ---- */
.sb-body { flex: 1; overflow-y: auto; padding: 24px 24px 32px; }
.sb-body p { font-size: 13.5px; color: var(--ink-soft); }

.sb-hint {
  font-family: var(--font-mono);
  font-size: 10.5px; line-height: 1.7; letter-spacing: 0.02em;
  color: var(--ink-mute); margin: 0 0 18px;
}

/* ---- tab roster: clickable items that fly the camera + open an overlay ---- */
.sb-list { display: flex; flex-direction: column; gap: 9px; margin-top: 4px; }
.sb-item {
  display: flex; align-items: center; gap: 13px;
  width: 100%; text-align: left;
  padding: 14px;
  background: rgba(236, 202, 140, 0.04);
  border: 1px solid var(--line-bright); border-radius: 3px;
  cursor: pointer;
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}
.sb-item:hover { border-color: var(--accent-deep); background: rgba(236, 202, 140, 0.08); }
.sb-item.is-active { border-color: var(--accent-deep); background: rgba(236, 202, 140, 0.09); }
.sb-item-glyph {
  flex: 0 0 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--accent-dim);
  border: 1px solid var(--line-bright); border-radius: 50%;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.sb-item:hover .sb-item-glyph,
.sb-item.is-active .sb-item-glyph { color: var(--accent); border-color: var(--accent-deep); }
.sb-item-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sb-item-name { font-size: 15px; color: var(--ink); }
.sb-item-meta {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--ink-mute);
}

.sb-back {
  display: inline-flex; align-items: center;
  background: none; border: none; padding: 0;
  margin-bottom: 18px;
  font-family: var(--font-mono);
  font-size: 10.5px; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--ink-soft); cursor: pointer;
  transition: color 0.3s var(--ease);
}
.sb-back:hover { color: var(--accent); }

.sb-kicker {
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-dim); margin: 0 0 12px;
}
.sb-title {
  font-size: 22px; font-weight: 300; line-height: 1.2;
  letter-spacing: -0.015em; margin: 0 0 14px;
}
.sb-lede { font-size: 15px; line-height: 1.6; color: var(--ink); margin: 0 0 14px; }

.sb-readout {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1px;
  margin: 20px 0 8px;
  background: var(--line); border: 1px solid var(--line);
}
.sb-readout > div { background: var(--bg-raised); padding: 11px 13px; }
.sb-readout dt {
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--ink-mute); margin-bottom: 5px;
}
.sb-readout dd {
  margin: 0; font-family: var(--font-mono);
  font-size: 13.5px; color: var(--accent-dim);
}

.sb-section {
  font-family: var(--font-mono);
  font-size: 10.5px; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--ink-soft);
  margin: 30px 0 6px;
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
}
.sb-count { color: var(--accent-dim); float: right; }
.sb-empty, .sb-loading {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.08em;
  color: var(--ink-mute); padding: 16px 0;
}

.sb-links { display: flex; flex-direction: column; gap: 9px; margin-top: 26px; }
.sb-links .cta { text-align: center; }

/* ---- destination: place card ---- */
.sb-place {
  display: flex; align-items: center; gap: 13px;
  width: 100%; text-align: left;
  padding: 15px 14px; margin-top: 10px;
  background: rgba(236, 202, 140, 0.04);
  border: 1px solid var(--line-bright); border-radius: 3px;
  cursor: pointer;
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}
.sb-place:hover { border-color: var(--accent-deep); background: rgba(236, 202, 140, 0.08); }
.sb-place-glyph {
  flex: 0 0 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; color: var(--accent-dim);
  border: 1px solid var(--line-bright); border-radius: 50%;
}
.sb-place:hover .sb-place-glyph { color: var(--accent); border-color: var(--accent-deep); }
.sb-place-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sb-place-name { font-size: 15px; color: var(--ink); }
.sb-place-meta {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--ink-mute);
}

/* ---- destination: itinerary ---- */
.itin { list-style: none; padding: 0; margin: 18px 0 8px; }
.itin li {
  display: flex; gap: 14px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}
.itin li:last-child { border-bottom: none; }
.itin-date {
  flex: 0 0 62px;
  font-family: var(--font-mono);
  font-size: 12px; color: var(--accent-dim);
  font-variant-numeric: tabular-nums; letter-spacing: 0.02em;
}
.itin-what { font-size: 13.5px; color: var(--ink-soft); line-height: 1.5; }

/* ---- footer ---- */
.sb-foot {
  border-top: 1px solid var(--line);
  padding: 13px 24px;
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
}
.sb-foot-row {
  display: flex; justify-content: space-between;
  color: var(--ink-mute); line-height: 2;
}
.sb-foot-on { color: var(--accent-dim); }

/* ---- crew manifest ---- */
.crew {
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}
.crew:last-child { border-bottom: none; }
.crew-top { display: flex; align-items: center; gap: 10px; }
.crew-dot { flex: 0 0 9px; width: 9px; height: 9px; border-radius: 50%; }
.crew-name { font-size: 14px; color: var(--ink); flex: 1; }
.crew-role {
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-mute);
  border: 1px solid var(--line-bright); border-radius: 2px;
  padding: 2px 7px;
}
.crew-sig { margin-top: 11px; }
.crew-sig-head {
  display: flex; justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 6px;
}
.crew-pct { color: var(--accent-dim); }
.crew-bar { height: 3px; background: var(--line); overflow: hidden; }
.crew-bar i {
  display: block; height: 100%;
  background: var(--accent-dim);
  transition: width 0.7s var(--ease);
}

/* ============================================================
   IN-SPACE CONTENT OVERLAY
   Track mode (Seoul / Istanbul): a small card pinned to the body
   with a leader line. Fixed mode (Vessel): a taller docked card.
   ============================================================ */
.holo-overlay {
  position: fixed; inset: 0; z-index: 7;
  pointer-events: none;
}
/* when the planet rotates behind the camera, fade the leader line + anchor
   but keep the card itself visible so the user can keep reading */
.holo-overlay.ov-offscreen .ov-anchor,
.holo-overlay.ov-offscreen .ov-link { opacity: 0; }

.ov-anchor {
  position: absolute; left: 0; top: 0;
  width: 12px; height: 12px; margin: -6px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  background: rgba(236, 202, 140, 0.12);
  box-shadow: 0 0 12px rgba(236, 202, 140, 0.55);
  transition: opacity 0.3s var(--ease);
}
.ov-anchor::after {
  content: ""; position: absolute; inset: 3.5px;
  border-radius: 50%; background: var(--accent);
}
.ov-link {
  position: absolute; left: 0; top: 0;
  height: 1px; transform-origin: 0 0;
  background: linear-gradient(90deg, var(--accent), rgba(236, 202, 140, 0.15));
  opacity: 0.7;
  transition: opacity 0.3s var(--ease);
}

.ov-card {
  position: absolute;
  width: 320px; max-width: calc(100vw - 32px);
  max-height: 64vh;
  display: flex; flex-direction: column;
  background: rgba(12, 17, 26, 0.72);
  -webkit-backdrop-filter: blur(11px);
          backdrop-filter: blur(11px);
  border: 1px solid var(--line-bright);
  border-radius: 5px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  pointer-events: auto;
  overflow: hidden;
  animation: ov-in 0.4s var(--ease);
  transition: opacity 0.3s var(--ease);
}
.ov-card.is-dragging { transition: none; }
@keyframes ov-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.holo-overlay.is-fixed .ov-anchor,
.holo-overlay.is-fixed .ov-link { display: none; }
.holo-overlay.is-fixed .ov-card {
  top: 74px; right: 22px; left: auto !important;
  width: 392px; max-height: calc(100vh - 120px);
  animation-name: ov-in-fixed;
}
@keyframes ov-in-fixed { from { opacity: 0; transform: translateX(12px); } to { opacity: 1; transform: translateX(0); } }

.ov-bar {
  flex: 0 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  padding: 13px 16px 13px 20px;
  border-bottom: 1px solid var(--line);
  touch-action: none;
}
.holo-overlay.is-track .ov-bar { cursor: move; }
.ov-card.is-dragging .ov-bar { cursor: grabbing; }
.ov-title {
  font-family: var(--font-mono);
  font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-dim);
}
.ov-close {
  flex: 0 0 auto;
  background: none; border: 1px solid var(--line-bright);
  color: var(--ink-soft);
  width: 28px; height: 28px; border-radius: 2px;
  font-size: 14px; line-height: 1; cursor: pointer;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}
.ov-close:hover { border-color: var(--accent-deep); color: var(--ink); }
.ov-body { flex: 1; overflow-y: auto; padding: 20px 20px 26px; }
.ov-body p { font-size: 13.5px; color: var(--ink-soft); }
.ov-body > :first-child { margin-top: 0; }

/* ============================================================
   WIDE IN-GALAXY PANEL — timeline / training / journal
   ============================================================ */
.gx-scrim {
  position: fixed; top: 0; bottom: 0; right: 0;
  left: 430px;
  z-index: 8;
  background: rgba(5, 7, 11, 0.42);
  -webkit-backdrop-filter: blur(1.5px);
          backdrop-filter: blur(1.5px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.4s var(--ease);
}
body.panel-open .gx-scrim { opacity: 1; pointer-events: auto; }

.gx-panel {
  position: fixed;
  top: 74px; right: 22px; bottom: 22px;
  left: 430px;
  z-index: 9;
  background: var(--bg-panel);
  border: 1px solid var(--line-bright);
  border-radius: 5px;
  display: flex; flex-direction: column;
  overflow: hidden;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.62);
  animation: gx-in 0.42s var(--ease);
}
@keyframes gx-in {
  from { opacity: 0; transform: translateX(12px); }
  to   { opacity: 1; transform: translateX(0); }
}
.gx-panel-bar {
  flex: 0 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 22px;
  border-bottom: 1px solid var(--line);
}
.gx-panel-title {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--accent-dim);
}
.gx-panel-close {
  background: none; border: 1px solid var(--line-bright);
  color: var(--ink-soft);
  width: 30px; height: 30px; border-radius: 2px;
  font-size: 15px; line-height: 1; cursor: pointer;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}
.gx-panel-close:hover { border-color: var(--accent-deep); color: var(--ink); }
.gx-panel-body { flex: 1; overflow: auto; }
.gx-content { padding: 30px 34px 46px; }
.gx-content[data-content="training"],
.gx-content[data-content="journal"] { max-width: 720px; margin: 0 auto; }
.gx-content .timeline-container { margin-top: 4px; }

@media (max-width: 760px) {
  .site-header--over { padding: 12px 18px; }
  .nav-sidebar {
    left: 12px; right: 12px; bottom: 12px;
    top: auto; width: auto; max-width: none;
    max-height: 60vh;
  }
  .hud-br { bottom: calc(60vh + 20px); right: 16px; }
  .holo-loading { bottom: calc(60vh + 20px); }
  .gx-scrim { left: 0; }
  .gx-panel {
    top: 44px; left: 10px; right: 10px; bottom: calc(60vh + 16px);
  }
  .gx-content { padding: 22px 16px 32px; }

  /* overlay is forced to fixed mode on narrow screens — dock it above the sheet */
  .holo-overlay.is-fixed .ov-card {
    top: 44px; left: 10px !important; right: 10px;
    width: auto; max-height: calc(40vh - 60px);
  }
}
