/* ============================================================
   PolarisGCS · First Project Review
   Minimal flat system: one ink, one accent, hairline dividers.
   No gradients, no boxed-card default — panels are the exception,
   not the rule. Content reveals as fragments, so little is on
   screen at once.
   ============================================================ */

@font-face { font-family: "Inter"; src: url("../fonts/Inter-Regular.woff") format("woff");   font-weight: 400; font-display: block; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Medium.woff") format("woff");    font-weight: 500; font-display: block; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-SemiBold.woff") format("woff");  font-weight: 600; font-display: block; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Bold.woff") format("woff");      font-weight: 700; font-display: block; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-ExtraBold.woff") format("woff"); font-weight: 800; font-display: block; }
@font-face { font-family: "InterDisplay"; src: url("../fonts/InterDisplay-Bold.woff") format("woff");      font-weight: 700; font-display: block; }
@font-face { font-family: "InterDisplay"; src: url("../fonts/InterDisplay-ExtraBold.woff") format("woff"); font-weight: 800; font-display: block; }

:root {
  --ink:       #0d1524;
  --ink-2:     #5a6579;
  --ink-3:     #98a2b5;
  --paper:     #ffffff;
  --surface:   #f7f8fb;
  --line:      #e6e9f0;

  --blue:      #4a65a8;
  --blue-ink:  #2d3b5e;
  --blue-pale: #f2f4f7;

  --amber:     #a3825f;
  --red:       #a86060;
  --green:     #4d826a;

  --font:    "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --display: "InterDisplay", "Inter", "Segoe UI", Roboto, sans-serif;
  --mono:    "DejaVu Sans Mono", "Liberation Mono", ui-monospace, monospace;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

html, body { height: 100%; background: var(--ink); }
body { font-family: var(--font); }

.reveal { font-family: var(--font); color: var(--ink); -webkit-font-smoothing: antialiased; }
.reveal .slides { text-align: left; }
.reveal .slides section { height: 100%; padding: 0; top: 0 !important; }
.reveal a { color: var(--blue); }

/* ============================================================
   Slide surface — flat, no side rail, no gradient
   ============================================================ */

.stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--surface);
}

.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(13, 21, 36, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13, 21, 36, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.stage-inner {
  position: relative;
  z-index: 3;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5vh 6vw;
  box-sizing: border-box;
}

.stage-inner.top { justify-content: flex-start; padding-top: 6.4vh; }

/* ============================================================
   Header chrome — one line, top right, never collides with content
   ============================================================ */

.kicker {
  position: absolute;
  top: 1.5rem;
  right: 2.2rem;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--ink-3);
  text-transform: uppercase;
}
.kicker b { color: var(--ink-2); }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.55em;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue);
  margin: 0 0 0.75rem 0;
}
.eyebrow::before { content: ""; width: 20px; height: 2px; background: var(--blue); flex: none; }

.headline {
  font-family: var(--display);
  font-size: 3.05rem;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 0.55rem 0;
}
.headline .hl { color: var(--ink); }

.lede {
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink-2);
  max-width: 62ch;
  margin: 0 0 1.3rem 0;
  line-height: 1.5;
}

/* ============================================================
   Fragments: reveal.js's own fragment mechanism (visibility:hidden
   until stepped to, built into reveal.css) keeps each fragment off
   screen until the presenter advances — so only the headline and
   one lede line are visible when a slide first appears. We only
   add the rise-in motion on top of reveal's own visible/hidden swap.
   ============================================================ */

.reveal .slides section .rise {
  opacity: 0;
  transform: translateY(12px);
}
.reveal .slides section.present .rise {
  animation: rise-in 0.5s var(--ease) forwards;
}
.reveal .slides section.present .rise:nth-of-type(1) { animation-delay: 0.03s; }
.reveal .slides section.present .rise:nth-of-type(2) { animation-delay: 0.09s; }
.reveal .slides section.present .rise:nth-of-type(3) { animation-delay: 0.15s; }

@keyframes rise-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reveal .slides section .fragment {
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
  transform: translateY(6px);
}
.reveal .slides section .fragment.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .reveal .slides section .rise { opacity: 1; transform: none; animation: none; }
}

/* ============================================================
   Plain list — replaces boxed cards for most bullet content
   ============================================================ */

.plist { display: flex; flex-direction: column; list-style: none; margin: 0; padding: 0; }
.plist > li,
.plist > div {
  display: flex;
  align-items: baseline;
  gap: 0.9rem;
  padding: 0.7rem 0;
  border-top: 1px solid var(--line);
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--ink);
}
.plist > li:first-child,
.plist > div:first-child { border-top: none; }
.plist .n { font-family: var(--mono); font-size: 0.78rem; font-weight: 700; color: var(--ink-3); flex: none; width: 1.4em; }
.plist .t { flex: 1; }
.plist .t small { display: block; font-size: 0.78rem; font-weight: 500; color: var(--ink-2); margin-top: 0.15rem; }

/* inline number row */

.stat-line { display: flex; gap: 2.6rem; }
.stat-line .stat { display: flex; flex-direction: column; gap: 0.15rem; }
.stat-line .stat .n {
  font-family: var(--display); font-size: 2rem; font-weight: 800;
  letter-spacing: -0.03em; color: var(--blue); line-height: 1;
}
.stat-line .stat .n.amber { color: var(--amber); }
.stat-line .stat .n.red { color: var(--red); }
.stat-line .stat .l { font-size: 0.7rem; font-weight: 600; color: var(--ink-2); max-width: 16ch; line-height: 1.3; }

.chip {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.03em;
  color: var(--blue-ink); background: var(--blue-pale);
  padding: 0.3rem 0.65rem; border-radius: 999px; white-space: nowrap;
}
.chip.plain { color: var(--ink-2); background: var(--surface); border: 1px solid var(--line); }

.note-line {
  font-size: 0.88rem; font-weight: 600; color: var(--ink-2);
  line-height: 1.45;
}
.note-line b { color: var(--ink); font-weight: 700; }

/* a panel is the exception, used only for the interactive diagrams */
.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1rem 1.1rem;
  box-sizing: border-box;
}

/* ============================================================
   Figures — clickable to expand, cropped to a stated height
   ============================================================ */

figure { margin: 0; }
figure img {
  display: block; width: 100%;
  height: var(--shot-h, auto);
  object-fit: cover; object-position: top center;
  border-radius: 10px; border: 1px solid var(--line);
  background: var(--paper);
  cursor: zoom-in;
}
figure.mid img { object-position: center center; }
figcaption { font-size: 0.68rem; font-weight: 600; color: var(--ink-3); margin-top: 0.4rem; line-height: 1.3; }

/* ============================================================
   Lightbox
   ============================================================ */

#lightbox {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(8, 12, 22, 0.86);
  display: flex; align-items: center; justify-content: center;
  padding: 5vh 5vw;
  opacity: 0; pointer-events: none;
  transition: opacity 0.22s var(--ease);
}
#lightbox.open { opacity: 1; pointer-events: auto; }
#lightbox img {
  max-width: 100%; max-height: 100%;
  border-radius: 10px;
  box-shadow: 0 30px 70px -20px rgba(0,0,0,0.6);
  transform: scale(0.97);
  transition: transform 0.22s var(--ease);
}
#lightbox.open img { transform: scale(1); }
#lightbox .lb-close {
  position: absolute; top: 1.6rem; right: 2rem;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,0.1); color: #fff;
  border: 1px solid rgba(255,255,255,0.2);
  font-size: 1.1rem; line-height: 1; cursor: pointer;
  display: grid; place-items: center;
}
#lightbox .lb-cap {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  color: #c7cede; font-size: 0.78rem; font-weight: 600; text-align: center;
}

/* ============================================================
   Chart primitives
   ============================================================ */

.chart-svg { width: 100%; height: auto; display: block; }
.chart-axis { stroke: var(--line); stroke-width: 1; }
.chart-axis-lbl { font-size: 8.5px; font-weight: 700; fill: var(--ink-3); }
.chart-gridline { stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 3; }

/* ---------- Reveal chrome ---------- */

.reveal .progress { color: var(--blue); height: 3px; }
.reveal .controls { color: var(--blue); right: 14px; bottom: 10px; }

/* ============================================================
   Legacy tokens — kept so the existing interactive diagrams
   (RF chart, literature table, architecture SVG, gateway tier
   board, telemetry SVG, mission lifecycle) render unchanged.
   Those components are not being redesigned this pass.
   ============================================================ */

:root {
  --ink-4:       #a8b2c4;
  --line-2:      #c8d2e2;
  --surface-2:   #eef2f9;
  --blue-mid:    #4a86ff;
  --amber-pale:  #fbeedd;
  --green-pale:  #e2f4ec;
  --red-pale:    #fbe9e9;
  --violet:      #6042c9;
  --violet-pale: #ece7fb;
}
