/* =====================================================================
 * Visual do jogo: "cockpit" azul-noite (canvas Cockpits por papel).
 * Cores em variáveis: troque aqui para mudar o tema. Um tema só (escuro).
 * Fontes: Pixelify Sans (títulos) e Barlow (interface), do Google Fonts;
 * sem internet, caem nas fontes do sistema.
 * ===================================================================== */
:root {
  color-scheme: dark;
  --bg: #0a1230; --bg-2: #10224f; --surface: #121e3e; --surface-2: #18274d; --surface-3: #1b2b55;
  --text: #eaf1ff; --muted: #a9b8da; --faint: #8796bd; --line: #2a3d6b; --line-soft: #24365f;
  --accent: #7fb2ff; --accent-strong: #b9d3ff; --accent-soft: rgba(127, 178, 255, .1); --on-accent: #ffffff;
  --go: linear-gradient(180deg, #3a7bf0 0%, #2457cc 100%); --go-border: #7fb2ff;
  --launch: linear-gradient(180deg, #27a84a 0%, #1c8a3a 100%); --launch-border: #6fe08c;
  --ok: #4ade80; --ok-soft: rgba(74, 222, 128, .12); --warn: #ffc247; --warn-soft: rgba(255, 194, 71, .12);
  --fail: #ff6b6b; --fail-soft: rgba(255, 107, 107, .13); --pending: #8796bd; --pending-soft: #22335e;
  --top: #0c1736; --top-2: #0c1736; --top-text: #eaf1ff; --top-muted: #a9b8da;
  /* Cor de cada papel da equipe (sempre com ícone + texto, nunca só a cor) */
  --sci: #b794ff; --eng: #ff9a3c; --mgr: #ff7ac6; --com: #3fd0ff; --dir: #7fb2ff;
  --radius: 16px; --radius-sm: 12px;
  --shadow: 0 10px 28px rgba(0, 0, 0, .3);
  --shadow-lift: 0 12px 32px rgba(0, 0, 0, .45), 0 0 0 1px rgba(127, 178, 255, .25);
  --font-ui: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-title: "Pixelify Sans", ui-monospace, Consolas, monospace;
}

* { box-sizing: border-box; }
body { margin: 0; color: var(--text); font: 16px/1.5 var(--font-ui); -webkit-font-smoothing: antialiased; min-height: 100vh;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 12% 18%, rgba(255, 255, 255, .75) 0 1.2px, transparent 1.7px),
    radial-gradient(circle at 63% 42%, rgba(255, 255, 255, .55) 0 1px, transparent 1.5px),
    radial-gradient(circle at 37% 77%, rgba(255, 255, 255, .7) 0 1.3px, transparent 1.8px),
    radial-gradient(circle at 86% 12%, rgba(173, 205, 255, .85) 0 1.1px, transparent 1.6px),
    radial-gradient(circle at 78% 83%, rgba(255, 255, 255, .5) 0 .9px, transparent 1.4px),
    linear-gradient(180deg, #0a1230 0%, #0c1a42 60%, #10224f 100%);
  background-size: 230px 190px, 310px 260px, 270px 210px, 350px 300px, 190px 170px, 100% 100%;
  background-attachment: fixed; }
.pixel { font-family: var(--font-title); letter-spacing: .04em; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 8px; letter-spacing: -.01em; }
h1 { font-size: 26px; } h2 { font-size: 18px; } h3 { font-size: 15px; }
p { margin: 0 0 10px; }
button { font: inherit; color: inherit; }
.muted { color: var(--muted); }
.small { font-size: 13px; }

/* ------------------------------------------------------------ Topo (HUD) */
.ico { flex: none; display: inline-block; vertical-align: middle; }
.top { background: var(--top); color: var(--top-text); padding: 10px 16px 0; position: sticky; top: 0; z-index: 20;
  border-bottom: 1px solid #253a6a; box-shadow: 0 1px 0 rgba(76, 195, 255, .22), 0 8px 24px rgba(0, 0, 0, .35); }
.brand { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; max-width: 1240px; margin: 0 auto; }
.logo { display: flex; align-items: center; gap: 12px; }
.emblem { flex: none; }
.logo-sep { width: 1px; height: 38px; background: #2c426f; }
.logo strong { display: block; font-size: 18px; font-weight: 700; line-height: 1.05; text-transform: uppercase; }
.logo span { display: block; font-size: 13px; color: var(--top-muted); }
.top-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.top-actions .chip { color: var(--top-muted); font-size: 13px; font-weight: 600; margin-right: 4px; }
.top .btn { background: var(--surface); border: 1.5px solid var(--line); color: var(--top-text); display: inline-flex; align-items: center; gap: 6px; }
.top .btn:hover:not(:disabled) { background: var(--surface-2); border-color: var(--accent); }
.top .btn.on { background: rgba(63, 208, 255, .14); border-color: var(--com); color: var(--com); font-weight: 700; }

/* Barra de fases: setas azuis (atual), concluídas com ✓ verde, próximas apagadas */
.steps { max-width: 1240px; margin: 10px auto 0; overflow-x: auto; scrollbar-width: none; }
.steps::-webkit-scrollbar { display: none; }
.steps-cap { display: block; font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }
.steps ol { display: flex; list-style: none; margin: 0; padding: 0 0 10px; min-width: 760px; gap: 2px; filter: drop-shadow(0 0 10px rgba(76, 195, 255, .18)); }
.steps li { flex: 1; }
.steps li.extra { flex: .85; }
.steps button { width: 100%; height: 100%; min-height: 46px; border: 0; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 4px 16px 4px 22px; font-size: 15px; font-weight: 600; line-height: 1.15; color: var(--faint); background: var(--surface);
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%, 14px 50%); transition: background .15s, color .15s; }
.steps li:first-child button { clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%); padding-left: 12px; }
.steps li.done button { background: #17305f; color: #a9c8ff; }
.steps li.done .num { color: var(--ok); }
.steps li.current button { background: var(--go); color: #fff; }
.steps .num { font-family: var(--font-title); font-size: 15px; display: inline-flex; }
.steps .lbl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.steps .lbl-s { display: none; }
.steps button:disabled { cursor: default; opacity: .6; }
.steps button:not(:disabled):hover { filter: brightness(1.2); }
.steps button:focus-visible { outline: 3px solid var(--warn); outline-offset: -3px; }
@media (max-width: 700px) {
  .steps ol { min-width: 0; gap: 2px; }
  .steps li { min-width: 0; }
  .steps button { padding: 4px 6px 4px 17px; min-height: 42px; font-size: 13px; }
  .steps li:first-child button { padding-left: 8px; }
  .steps .lbl { display: none; }
  .steps li.current { flex: 2.6; }
  .steps-cap { display: none; }
  .hud { gap: 4px; } .hud-card { padding: 6px 8px; } .hud-bar { height: 4px; } .hud-ic { display: none; }
  .steps li.current .lbl { display: block; }
}

/* Idiomas: bandeiras */
.langs { display: flex; gap: 2px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 12px; padding: 3px; margin-right: 4px; }
.flag { display: flex; align-items: center; gap: 5px; border: 0; background: none; color: var(--top-muted); border-radius: 8px; padding: 4px 8px 4px 5px; cursor: pointer; font-size: 12px; font-weight: 700; letter-spacing: .04em; min-height: 32px; }
.flag svg { width: 20px; height: 14px; border-radius: 3px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .25); }
.flag:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.flag.on { background: var(--surface-3); color: #fff; box-shadow: inset 0 0 0 1.5px var(--accent); }
.flag:focus-visible { outline: 2px solid var(--warn); outline-offset: 1px; }

/* Painel fixo com os 6 recursos (sempre visível) */
.hud-wrap { max-width: 1240px; margin: 0 auto; padding-bottom: 10px; }
.hud { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.hud-card { --c: var(--pending); display: flex; align-items: center; gap: 10px; text-align: left; min-width: 0; cursor: pointer; min-height: 68px;
  background: var(--surface); border: 1.5px solid var(--line); border-radius: 14px; padding: 8px 12px; color: var(--top-text);
  transition: background .15s, border-color .15s, transform .15s, box-shadow .15s; }
.hud-card:hover, .hud-card.open { background: var(--surface-2); border-color: var(--accent); }
.hud-card:focus-visible { outline: 2px solid var(--warn); outline-offset: 1px; }
.hud-card.s-ok { --c: var(--ok); } .hud-card.s-warn { --c: var(--warn); } .hud-card.s-fail { --c: var(--fail); } .hud-card.s-pending { --c: var(--pending); }
.hud-card.s-fail { border-color: rgba(255, 107, 107, .6); }
.hud-ic { flex: none; width: 38px; height: 38px; border-radius: 12px; background: var(--surface-3); display: grid; place-items: center; color: #dce7ff; }
.hud-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.hud-top { display: flex; align-items: center; gap: 6px; min-width: 0; }
.hud-name { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hud-st { margin-left: auto; display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 700; color: var(--c); white-space: nowrap; }
.hud-val { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hud-bar { position: relative; display: block; height: 6px; border-radius: 3px; background: var(--pending-soft); overflow: hidden; }
.hud-bar .fl { display: block; height: 100%; background: var(--c); border-radius: 3px; transition: width .3s; }
.hud-bar .mk { position: absolute; top: 0; bottom: 0; width: 2px; background: rgba(255, 255, 255, .75); }
.hud-delta { font-size: 12px; font-weight: 700; color: var(--warn); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hud-delta:empty { display: none; }
.hud.previewing .hud-card:not(.pv) { opacity: .55; }
.hud-card.pv { transform: translateY(-2px); background: var(--surface-2); box-shadow: 0 0 0 3px rgba(127, 178, 255, .18), 0 0 16px rgba(127, 178, 255, .3); }
.hud-card.pv-ok .hud-delta { color: var(--ok); } .hud-card.pv-warn .hud-delta { color: var(--warn); } .hud-card.pv-fail .hud-delta { color: var(--fail); }
.hud-detail { max-height: 55vh; overflow: auto; margin-top: 8px; background: var(--surface); color: var(--text); border: 1.5px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; box-shadow: var(--shadow-lift); }
.hud-detail > .row-head { margin-bottom: 6px; }
.hud-d-item { border-top: 1px solid var(--line); padding-top: 8px; margin-top: 8px; }
.hud-d-item p { margin: 4px 0; }
@media (max-width: 1000px) { .hud-ic { display: none; } }
@media (max-width: 860px) { .hud { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; } }
@media (max-width: 420px) { .hud-val { font-size: 13px; } .hud-st { display: none; } }

/* Cadeia de efeitos ("ripple"): cada elo aparece em sequência */
.cascade { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 6px; font-size: 14px; margin-top: 8px; color: var(--top-muted); }
.cascade:empty { display: none; }
.cz-head { color: var(--top-text); font-weight: 600; }
.cz-head b { color: #fff; }
.cz { display: inline-flex; align-items: center; gap: 5px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 10px; padding: 3px 10px; color: var(--top-text); font-weight: 600;
  animation: cz-in .35s ease both; }
.cz.s-ok { border-color: rgba(74, 222, 128, .6); } .cz.s-warn { border-color: rgba(255, 194, 71, .75); } .cz.s-fail { border-color: var(--fail); background: var(--fail-soft); }
.cz-arrow { color: var(--warn); font-weight: 800; animation: cz-in .35s ease both; }
.cascade > :nth-child(2) { animation-delay: .1s; } .cascade > :nth-child(3) { animation-delay: .2s; } .cascade > :nth-child(4) { animation-delay: .3s; }
.cascade > :nth-child(5) { animation-delay: .4s; } .cascade > :nth-child(6) { animation-delay: .5s; } .cascade > :nth-child(7) { animation-delay: .6s; }
.cascade > :nth-child(8) { animation-delay: .7s; } .cascade > :nth-child(9) { animation-delay: .8s; } .cascade > :nth-child(n+10) { animation-delay: .9s; }
@keyframes cz-in { from { opacity: 0; transform: translateX(-6px); } to { opacity: 1; transform: none; } }

main { max-width: 1240px; margin: 0 auto; padding: 22px 16px 110px; }
.phase-head { margin-bottom: 14px; }
.phase-head h1 { font-family: var(--font-title); font-weight: 700; letter-spacing: .03em; font-size: 30px; }
.phase-head .eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }

/* Caixa "O que fazer aqui" (briefing da missão) */
.guide { display: flex; gap: 14px; background: #101c3d; border: 1px solid #2c426f; border-radius: var(--radius); padding: 14px 16px; margin-bottom: 18px; }
.guide-icon { flex: none; width: 32px; height: 32px; border-radius: 10px; background: var(--go); color: #fff; display: grid; place-items: center; font-weight: 700; font-family: var(--font-title); }
.guide strong { display: block; margin-bottom: 2px; color: #cfe0ff; }
.guide p { margin: 0 0 6px; }
.guide ul { margin: 0; padding-left: 18px; font-size: 15px; color: var(--muted); }
.guide > div { min-width: 0; flex: 1; }
.nasa { margin-top: 10px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); }
.nasa-tag { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #fff; background: linear-gradient(90deg, #7b3fe4, #12a39a); border-radius: 99px; padding: 2px 9px; margin-bottom: 6px; }
.nasa p { font-size: 15px; }
.nasa-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.seg { font-size: 12px; font-weight: 700; border-radius: 99px; padding: 1px 9px; border: 1.5px solid var(--line); background: var(--surface-2); cursor: help; }
.seg-launch { color: var(--eng); border-color: rgba(255, 154, 60, .55); } .seg-space { color: var(--sci); border-color: rgba(183, 148, 255, .55); }
.seg-ground { color: var(--ok); border-color: rgba(74, 222, 128, .5); } .seg-user { color: var(--com); border-color: rgba(63, 208, 255, .55); }
.cml { font-size: 12px; font-weight: 700; color: var(--accent); background: var(--accent-soft); border-radius: 6px; padding: 1px 8px; cursor: help; }
.st-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; white-space: nowrap; color: var(--pending); }
.st-tag.s-ok { color: var(--ok); } .st-tag.s-warn { color: var(--warn); } .st-tag.s-fail { color: var(--fail); }
/* ------------------------------------------------------------ Blocos */
.card { background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; box-shadow: var(--shadow); }
.card h2 { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.card > h2:first-child, .card .row-head h2 { margin-bottom: 6px; }
.section-note { font-size: 15px; color: var(--muted); margin: -2px 0 12px; }
.alert { border-radius: var(--radius-sm); padding: 10px 14px; margin-bottom: 16px; border: 1px solid; }
.alert.s-fail { background: var(--fail-soft); border-color: var(--fail); }
.alert.s-warn { background: var(--warn-soft); border-color: var(--warn); }
.alert.s-ok { background: var(--ok-soft); border-color: var(--ok); }
.cols { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; align-items: start; }
.cols .side { position: sticky; top: 12px; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr; } .cols .side { position: static; } }

/* Resumo (chips de status) */
.summary { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.sum { display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 99px; padding: 6px 14px 6px 8px; font-size: 14px; box-shadow: var(--shadow); }
.sum b { font-variant-numeric: tabular-nums; }
.sum .ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; }
.sum.s-ok .ic { background: var(--ok-soft); color: var(--ok); }
.sum.s-warn .ic { background: var(--warn-soft); color: var(--warn); }
.sum.s-fail .ic { background: var(--fail-soft); color: var(--fail); }
.sum.s-pending .ic { background: var(--pending-soft); color: var(--pending); }

/* ------------------------------------------------------------ Escolhas */
.slot { margin-bottom: 22px; }
.slot-head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.slot-head h3 { margin: 0; font-size: 16px; }
.slot-todo { font-size: 12px; font-weight: 600; color: var(--warn); background: var(--warn-soft); border-radius: 99px; padding: 1px 8px; }
.slot-done { font-size: 12px; font-weight: 600; color: var(--ok); background: var(--ok-soft); border-radius: 99px; padding: 1px 8px; }
.options { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.option { position: relative; text-align: left; background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 14px; cursor: pointer; display: flex; flex-direction: column; gap: 8px; box-shadow: var(--shadow); transition: border-color .15s, box-shadow .15s, transform .15s; }
.option:hover:not(:disabled) { border-color: var(--accent); box-shadow: var(--shadow-lift); transform: translateY(-1px); }
.option:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }
.option.selected { border: 2px solid var(--accent); background: #16244a; padding: 13.5px; box-shadow: 0 0 0 4px rgba(76, 195, 255, .14), 0 0 22px rgba(76, 195, 255, .3); }
.option.selected::after { content: "✓ " attr(data-chosen); text-transform: capitalize; position: absolute; top: 10px; right: 10px; z-index: 2; font-size: 12px; font-weight: 700; color: #fff; background: var(--go); border-radius: 99px; padding: 2px 9px; }
.option:disabled { cursor: not-allowed; opacity: .55; }
.option.selected:disabled { opacity: .85; }
.option-name { font-weight: 700; font-size: 17px; padding-right: 76px; }
/* Imagem 3D da peça: "palco" escuro de hangar, igual nos dois temas */
.option-thumb { display: block; margin: -14px -14px 2px; height: 132px; border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0; overflow: hidden;
  background: radial-gradient(120% 95% at 50% 18%, #33467a 0%, #18223d 55%, #0b1121 100%); position: relative; }
.option-thumb::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 34%;
  background: repeating-linear-gradient(90deg, rgba(140, 170, 255, .10) 0 1px, transparent 1px 22px), linear-gradient(180deg, transparent, rgba(124, 156, 255, .10)); pointer-events: none; }
.option-thumb img { position: relative; z-index: 1; display: block; width: 100%; height: 100%; object-fit: contain; transition: transform .25s; }
.option:hover:not(:disabled) .option-thumb img, .option.selected .option-thumb img { transform: scale(1.06); }
.option.selected .option-thumb { margin: -13.5px -13.5px 2px; box-shadow: inset 0 0 0 2px var(--accent); }
.option.has-thumb .option-name { padding-right: 0; }
.option-desc { color: var(--muted); font-size: 15px; }
.pc { display: grid; gap: 3px; font-size: 14px; }
.pc span { display: flex; gap: 6px; }
.pc .pro::before { content: "▲"; color: var(--ok); font-size: 10px; margin-top: 4px; }
.pc .con::before { content: "▼"; color: var(--warn); font-size: 10px; margin-top: 4px; }
.specs { display: grid; grid-template-columns: auto 1fr; gap: 1px 10px; font-size: 13px; margin: 0; padding-top: 8px; border-top: 1px dashed var(--line); color: var(--muted); }
.specs dt { color: var(--muted); } .specs dd { margin: 0; color: var(--text); font-variant-numeric: tabular-nums; }
.src { font-size: 11.5px; color: var(--muted); font-style: italic; }
.plain { font-size: 14px; color: var(--text); margin: 3px 0 2px; }
.verif-by { font-size: 13px; color: var(--muted); margin: 6px 0 0; }
.verif-by span { font-weight: 600; }
.owner { font-size: 12px; font-weight: 500; color: var(--muted); }
.owner.mine { color: var(--accent); font-weight: 600; }

/* Termos do glossário (dica ao passar o mouse ou focar) */
.term { border-bottom: 1px dotted currentColor; cursor: help; position: relative; }
.term:hover::after, .term:focus::after {
  content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%);
  width: max-content; max-width: 280px; background: #060b1e; border: 1px solid var(--line); color: #f2f4fa; font-size: 14px; font-weight: 400; line-height: 1.45;
  padding: 8px 10px; border-radius: 8px; box-shadow: var(--shadow-lift); z-index: 40; white-space: normal; text-align: left; letter-spacing: 0; text-transform: none;
}
.term:focus { outline: none; }

/* Status */
.badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 99px; white-space: nowrap; }
.badge.s-ok { background: var(--ok-soft); color: var(--ok); }
.badge.s-warn { background: var(--warn-soft); color: var(--warn); }
.badge.s-fail { background: var(--fail-soft); color: var(--fail); }
.badge.s-pending, .badge.s-skipped, .badge.s-na { background: var(--pending-soft); color: var(--pending); }
.tag { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--warn); margin-right: 6px; }

/* Listas com status (requisitos, verificações, métricas) */
.rows { list-style: none; margin: 0; padding: 0; }
.rows > li { padding: 10px 0; border-top: 1px solid var(--line); }
.rows > li:first-child { border-top: 0; padding-top: 0; }
.row-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.row-head .value { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; }
details { margin-top: 4px; font-size: 13px; color: var(--muted); }
summary { cursor: pointer; color: var(--accent); width: fit-content; }
.hint { font-size: 13px; margin-top: 6px; background: var(--warn-soft); border-radius: var(--radius-sm); padding: 6px 10px; }
.hint::before { content: attr(data-label) " "; font-weight: 700; }

/* Painel de recursos */
.res { margin-bottom: 14px; }
.bar { position: relative; height: 10px; background: var(--pending-soft); border-radius: 5px; margin: 5px 0; overflow: hidden; }
.bar .fill { height: 100%; background: var(--accent); border-radius: 5px; transition: width .3s; }
.res.s-ok .fill { background: var(--ok); } .res.s-warn .fill { background: var(--warn); } .res.s-fail .fill { background: var(--fail); }
.bar .mark { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--text); opacity: .45; }
.res-text { font-size: 13px; color: var(--muted); }
.legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--muted); margin-top: 4px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }

/* Tabelas */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
tfoot td { font-weight: 700; border-bottom: 0; }

/* Linha do tempo (Implement) */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.timeline li:first-child { border-top: 0; }
.timeline .when { color: var(--muted); font-size: 13px; }
@media (max-width: 560px) { .timeline li { grid-template-columns: 1fr; gap: 2px; } }

/* Need & Goals: mapa das fases */
.journey { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; counter-reset: j; }
.journey div { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 13px; }
.journey b { display: block; font-size: 14px; }
.journey b::before { counter-increment: j; content: counter(j) ". "; color: var(--accent); }
.goal-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.goal-list li { display: flex; gap: 10px; align-items: flex-start; }
.goal-list .gid { flex: none; font-size: 12px; font-weight: 700; color: var(--accent); background: var(--accent-soft); border-radius: 6px; padding: 2px 7px; }

/* Need & Goals: escolha do cliente (cenário) */
.scen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.scen { position: relative; text-align: left; display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 14px; cursor: pointer; box-shadow: var(--shadow); transition: border-color .15s, box-shadow .15s, transform .15s; }
.scen:hover:not(:disabled) { border-color: var(--accent); box-shadow: var(--shadow-lift); transform: translateY(-1px); }
.scen:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }
.scen.selected { border: 2px solid var(--accent); background: #16244a; padding: 13.5px; box-shadow: 0 0 0 4px rgba(76, 195, 255, .14), 0 0 22px rgba(76, 195, 255, .3); }
.scen:disabled { cursor: not-allowed; opacity: .6; }
.scen-ic { font-size: 26px; line-height: 1; }
.scen-title { font-weight: 700; font-size: 19px; }
.scen-cust { font-size: 12.5px; color: var(--accent); font-weight: 600; }
.scen-pitch { font-size: 13.5px; }
.scen-meta { font-size: 12px; color: var(--muted); }
.scen-on { position: absolute; top: 10px; right: 10px; font-size: 12px; font-weight: 700; color: #fff; background: var(--go); border-radius: 99px; padding: 1px 8px; }

/* Visual 3D (Implement): fundo escuro de propósito, nos dois temas */
.viz-card { padding: 0; overflow: hidden; }
.viz3d { position: relative; height: 480px; background: #04060c; color: #e6e9ef; }
.viz3d canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.viz-hud { position: absolute; pointer-events: none; text-shadow: 0 1px 3px #000; }
.viz-top { top: 12px; left: 14px; right: 40%; }
.viz-when { font-size: 12px; color: #9aa3b2; text-transform: uppercase; letter-spacing: .04em; }
.viz-title { font-size: 18px; font-weight: 700; }
.viz-text { font-size: 13px; max-width: 460px; }
.viz-flags { top: 12px; right: 14px; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.viz-flags span { background: rgba(10, 14, 24, .75); border: 1px solid #2d3440; border-radius: 99px; padding: 2px 10px; font-size: 12px; }
.viz-legend { position: absolute; left: 14px; bottom: 52px; display: flex; gap: 12px; font-size: 11px; color: #9aa3b2; pointer-events: none; flex-wrap: wrap; }
.viz-legend span::before { content: ""; display: inline-block; width: 10px; height: 3px; margin-right: 5px; vertical-align: middle; }
.lg-aoi::before { background: #ffd54a; } .lg-cov::before { background: #5cf2a0; } .lg-con::before { background: #4cff7a; }
.viz-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; gap: 6px; align-items: center; padding: 8px 10px; background: rgba(10, 14, 24, .8); flex-wrap: wrap; }
.viz-bar .btn { background: #1b2029; border-color: #2d3440; color: #e6e9ef; padding: 4px 10px; }
.viz-progress { flex: 1; min-width: 80px; height: 4px; background: #2d3440; border-radius: 2px; overflow: hidden; }
.viz-progress span { display: block; height: 100%; width: 0; background: #7aa2ff; }
@media (max-width: 560px) {
  .viz3d { height: 380px; }
  .viz-top { right: 14px; } .viz-flags { top: auto; bottom: 84px; } .viz-legend { display: none; }
  .viz-text { font-size: 12px; }
}

/* Relatório */
.score { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.score-ring { --p: 0; width: 104px; height: 104px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: conic-gradient(var(--ring, var(--accent)) calc(var(--p) * 1%), var(--pending-soft) 0); }
.score-ring span { width: 84px; height: 84px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-size: 30px; font-weight: 800; }

.why { margin: 0; padding-left: 20px; display: grid; gap: 8px; }
.why li { font-size: 14px; }

/* Sobre */
.about ul { padding-left: 20px; margin: 0 0 12px; display: grid; gap: 6px; font-size: 14px; }
.about h3 { margin-top: 14px; }
.about a { color: var(--accent); }

/* Equipe (multiplayer) */
.team .code { font-family: ui-monospace, Consolas, monospace; letter-spacing: .14em; color: var(--accent); }
.team.compact { padding: 12px 18px; }
.team.compact h2 { font-size: 16px; margin: 0; }
.team-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.team-form label { display: flex; flex-direction: column; font-size: 13px; color: var(--muted); gap: 3px; }
.team-form input { font: inherit; color: var(--text); background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; min-width: 160px; }
.team-form input:focus { outline: 2px solid var(--accent); border-color: transparent; }
.team-steps { margin: 4px 0 12px; padding-left: 20px; font-size: 14px; color: var(--muted); }
.roles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; margin: 10px 0 14px; }
.role { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px; display: flex; flex-direction: column; gap: 4px; background: var(--surface-2); }
.role.mine { border-color: var(--accent); background: var(--accent-soft); }
.people { margin: 0; padding-left: 18px; }
.seats { font-variant-numeric: tabular-nums; font-weight: 600; }
#toasts { position: fixed; right: 16px; bottom: 76px; display: flex; flex-direction: column; gap: 8px; z-index: 50; max-width: min(360px, calc(100vw - 32px)); }
.toast { background: #141a2a; color: #f2f4fa; padding: 9px 13px; border-radius: var(--radius-sm); font-size: 14px; box-shadow: var(--shadow-lift); }

/* Glossário */
.glossary { columns: 2 280px; column-gap: 24px; margin: 0; }
.glossary div { break-inside: avoid; margin-bottom: 10px; }
.glossary dt { font-weight: 700; }
.glossary dd { margin: 0; font-size: 14px; color: var(--muted); }

/* Rodapé de navegação */
.nav { position: fixed; left: 0; right: 0; bottom: 0; background: linear-gradient(180deg, rgba(10, 18, 48, .7) 0%, rgba(10, 18, 48, .96) 40%); backdrop-filter: blur(8px); border-top: 1px solid #253a6a; padding: 12px 16px; z-index: 30; }
.nav-inner { max-width: 1240px; margin: 0 auto; display: flex; align-items: center; gap: 12px; }
.nav .missing { flex: 1; font-size: 15px; color: var(--muted); }
.nav .missing.todo { color: var(--warn); font-weight: 600; }
.btn { border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--radius-sm); padding: 10px 18px; min-height: 44px; cursor: pointer; font-weight: 600; transition: background .15s, border-color .15s, box-shadow .15s; }
.btn:hover:not(:disabled) { border-color: var(--accent); }
.btn.small { padding: 4px 10px; font-size: 14px; min-height: 36px; }
.btn.primary { background: var(--go); border: 2px solid var(--go-border); color: #fff; font-weight: 700; font-size: 17px; padding: 10px 22px; box-shadow: 0 0 0 4px rgba(76, 195, 255, .14); }
.btn.primary:hover:not(:disabled) { box-shadow: 0 0 0 4px rgba(76, 195, 255, .25), 0 0 22px rgba(76, 195, 255, .45); }
/* Verde só para Lançar */
.btn.launch { background: var(--launch); border-color: var(--launch-border); box-shadow: 0 0 0 4px rgba(74, 222, 128, .15), 0 8px 22px rgba(0, 0, 0, .35); }
.btn.launch:hover:not(:disabled) { box-shadow: 0 0 0 4px rgba(74, 222, 128, .28), 0 0 22px rgba(74, 222, 128, .45); }
.btn .ico { margin-right: 2px; }
.btn:disabled { opacity: .45; cursor: default; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; }
.nav .btn { white-space: nowrap; }
@media (max-width: 560px) {
  h1 { font-size: 22px; }
  .nav-inner { flex-wrap: wrap; gap: 6px 10px; }
  .nav .missing { order: -1; flex-basis: 100%; font-size: 12px; }
  .nav .missing:empty { display: none; }
  .nav .btn.primary { flex: 1; }
  .logo span, .top-actions .chip { display: none; }
  .guide { padding: 12px; gap: 10px; }
  .guide ul { font-size: 13px; }
  main { padding-bottom: 140px; }
}

/* Acessibilidade: foco sempre visível e menos movimento quando pedido */
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .option:hover:not(:disabled), .scen:hover:not(:disabled), .hud-card.pv { transform: none; }
}

/* ------------------------------------------------ Missão no tempo */
.decision { border: 2px solid var(--warn); background: color-mix(in srgb, var(--warn-soft) 55%, var(--surface)); }
.decision-head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.decision-head h2 { margin: 0; }
.decision-ic { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--warn); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 18px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 10px; }
.choice { text-align: left; display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; cursor: pointer; box-shadow: var(--shadow); transition: border-color .15s, transform .15s; }
.choice:hover:not(:disabled) { border-color: var(--accent); transform: translateY(-1px); }
.choice:disabled { opacity: .55; cursor: not-allowed; }
.choice-title { font-weight: 700; }
.choice-text { font-size: 13px; color: var(--muted); }
.src-link { font-size: 12px; color: var(--accent); white-space: nowrap; }
.life-charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.life-chart { width: 100%; height: auto; display: block; max-width: 420px; }
.lc-title { font-size: 12px; font-weight: 600; fill: var(--text); }
.lc-axis { font-size: 10.5px; fill: var(--muted); }
.lc-box { fill: var(--surface-2); stroke: var(--line); }
.lc-ref { stroke: var(--muted); stroke-dasharray: 4 3; opacity: .7; }
.lc-mark { stroke: var(--fail); stroke-width: 1; opacity: .45; }
.lc-mlabel { font-size: 9.5px; fill: var(--fail); }
.lc-line { fill: none; stroke-width: 2; stroke: var(--accent); }
.lc-dot { fill: var(--accent); }
.lc-mem, .lc-dot.lc-mem { stroke: var(--warn); } .lc-dot.lc-mem { fill: var(--warn); }
.lc-pow { stroke: var(--ok); } .lc-dot.lc-pow { fill: var(--ok); }
.d-bad { color: var(--fail); } .d-good { color: var(--ok); }
.d-bad .src-link, .d-good .src-link { color: var(--accent); }

/* Hangar 3D (coluna direita do Conceito e do Projeto): sempre escuro */
.hangar-card { padding: 0; overflow: hidden; border-color: #2a3a66; }
.hangar3d { position: relative; height: 300px; background: radial-gradient(120% 95% at 50% 18%, #1d2c58 0%, #0d1530 60%, #080e22 100%); color: #e6e9ef; }
.hangar3d canvas { display: block; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.hangar3d canvas:active { cursor: grabbing; }
.hg-label { position: absolute; left: 12px; top: 10px; right: 12px; pointer-events: none; text-shadow: 0 1px 3px #000; display: flex; flex-direction: column; gap: 1px; }
.hg-kicker { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #8fb0ff; }
.hg-label.previewing .hg-kicker { color: #ffc83d; }
.hg-name { font-size: 16px; font-weight: 700; }
.hg-stats { font-size: 12px; color: #b9c3d9; font-variant-numeric: tabular-nums; }
.hg-hint { position: absolute; right: 10px; bottom: 8px; font-size: 11px; color: #7f8aa6; pointer-events: none; }
@media (max-width: 860px) { .cols .side .hangar-card { order: -1; } .hangar3d { height: 240px; } }

/* Simulação: telemetria estilo painel de voo, tempo e tela cheia */
.viz-tele { left: 14px; bottom: 56px; width: 230px; background: rgba(8, 12, 22, .78); border: 1px solid #2a3a66; border-radius: 10px;
  padding: 8px 10px; font-size: 12px; display: grid; gap: 3px; backdrop-filter: blur(4px); text-shadow: none; }
.tl-row, .tl-fuel { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.tl-row span, .tl-fuel span { color: #8f9bb8; }
.tl-row b, .tl-fuel b { font-variant-numeric: tabular-nums; color: #e9eefc; font-weight: 600; }
.tl-fuel i { flex: 1; height: 6px; background: #1e2840; border-radius: 3px; overflow: hidden; }
.tl-fuel em { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #ff9a3c, #ffd36a); transition: width .1s; }
.tl-fuel em.low { background: #ff6b6b; }
.tl-status { margin-top: 3px; font-weight: 700; font-size: 12px; padding: 3px 8px; border-radius: 6px; text-align: center; }
.tl-status.st-orbit { background: rgba(76, 194, 111, .18); color: #6fe08f; }
.tl-status.st-sub, .tl-status.st-decay { background: rgba(227, 179, 65, .18); color: #ffd36a; }
.tl-status.st-risk, .tl-status.st-reentry, .tl-status.st-fail { background: rgba(255, 107, 107, .2); color: #ff8a8a; }
.viz-legend { left: auto; right: 14px; }
.lg-path::before { background: #4cc26f; }
.viz-warp { display: inline-flex; align-items: center; gap: 2px; padding: 0 4px; border-left: 1px solid #2d3440; border-right: 1px solid #2d3440; }
.viz-warp-label { font-size: 11px; color: #8f9bb8; margin-right: 4px; }
.viz-bar .btn.on { background: #3461f5; border-color: #3461f5; color: #fff; }
.viz3d:fullscreen { height: 100vh; width: 100vw; border-radius: 0; }
.viz3d:-webkit-full-screen { height: 100vh; width: 100vw; }
.viz3d:fullscreen .viz-title { font-size: 24px; } .viz3d:fullscreen .viz-text { font-size: 15px; max-width: 560px; }
.viz3d:fullscreen .viz-tele { width: 270px; font-size: 13px; }
@media (max-width: 560px) { .viz-tele { width: auto; right: 14px; bottom: 92px; grid-template-columns: 1fr 1fr; column-gap: 12px; } .tl-status, .tl-fuel { grid-column: 1 / -1; } }

/* Encontro e acoplamento com a ISS */
.tl-status.st-dock { background: rgba(90, 160, 255, .2); color: #9cc4ff; }
.lg-iss::before { background: #dfe6ff; }

/* ------------------------------------------------ Cockpit (fase Design) */
/* esquerda: peças · centro: satélite + cascata · direita: checagem + equipe */
.cockpit { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, .95fr); gap: 16px; align-items: start; }
.ck-panel { background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; box-shadow: var(--shadow); }
.ck-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.ck-head h2 { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.ck-count { font-size: 13px; font-weight: 700; color: var(--muted); }
.ck-center, .ck-side { position: sticky; top: 12px; }
.ck-center .hangar-card { margin-bottom: 16px; }
.ck-center .hangar3d { height: 340px; }
.ck-empty { margin: 4px 0 0; }
.cascade.ripple { margin: 6px 0 0; font-size: 14px; color: var(--muted); }

/* Abas de peças: uma por papel, na cor do papel */
.ck-tabs { display: flex; gap: 6px; margin: 4px 0 14px; flex-wrap: wrap; }
.ck-tab { --rc: var(--dir); display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 6px 12px; border-radius: 12px; cursor: pointer;
  background: var(--surface-2); border: 1.5px solid var(--line); color: var(--muted); font-weight: 700; font-size: 15px; }
.ck-tab .ico { color: var(--rc); }
.ck-tab:hover { border-color: var(--rc); color: var(--text); }
.ck-tab.on { background: color-mix(in srgb, var(--rc) 16%, var(--surface)); border: 2px solid var(--rc); color: #fff; }
.ck-tab-n { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; padding: 1px 7px; border-radius: 99px; background: var(--pending-soft); color: var(--muted); }
.ck-tab-n.full { background: var(--ok-soft); color: var(--ok); }
.r-sci { --rc: var(--sci); } .r-eng { --rc: var(--eng); } .r-mgr { --rc: var(--mgr); } .r-com { --rc: var(--com); } .r-dir { --rc: var(--dir); }
.ck-parts .options { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.ck-parts .slot:last-child { margin-bottom: 0; }

/* Checagem da missão */
.ck-cust { margin: 0 0 8px; font-weight: 600; color: var(--text); }
.ck-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.ck-checks li { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-soft); }
.ck-ci { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--pending-soft); color: var(--pending); }
.ck-checks .s-ok .ck-ci { background: var(--ok-soft); color: var(--ok); }
.ck-checks .s-fail .ck-ci { background: var(--fail-soft); color: var(--fail); }
.ck-checks .s-fail { border-color: rgba(255, 107, 107, .5); }
.ck-ct { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.ck-ct b { font-size: 15px; }
.ck-cv { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ck-checks .s-ok .ck-cv { color: var(--ok); } .ck-checks .s-fail .ck-cv { color: var(--fail); }

/* Conselhos da equipe (e voto Go/No-Go) */
.crew { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.crew-item { --rc: var(--dir); display: flex; gap: 10px; padding: 10px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-soft); border-left: 3px solid var(--rc); }
.crew-av { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: #0c1736; border: 2px solid var(--rc); color: var(--rc); }
.crew-body { min-width: 0; flex: 1; }
.crew-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.crew-top b { color: var(--rc); font-size: 15px; }
.crew-body p { margin: 3px 0 2px; font-size: 15px; line-height: 1.4; }
.crew-goal { font-size: 12.5px; color: var(--faint); }
.vote { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 800; padding: 2px 9px; border-radius: 99px; letter-spacing: .04em; }
.vote.v-go { background: var(--ok-soft); color: var(--ok); border: 1px solid rgba(74, 222, 128, .5); }
.vote.v-nogo { background: var(--fail-soft); color: var(--fail); border: 1px solid rgba(255, 107, 107, .5); }

.ck-mel summary { font-weight: 700; color: var(--accent); }
.ck-mel[open] summary { margin-bottom: 10px; }
@media (max-width: 1180px) {
  .cockpit { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }
  .ck-side { grid-column: 2; position: static; }
  .ck-center { position: static; }
  .ck-parts { grid-row: span 2; }
}
@media (max-width: 860px) {
  .cockpit { grid-template-columns: 1fr; }
  .ck-side, .ck-parts { grid-column: auto; grid-row: auto; }
  .ck-center { order: -1; }
}
.guide-more { margin-top: 2px; font-size: 15px; }
.guide-more summary { font-weight: 600; }
.guide-more[open] summary { margin-bottom: 6px; }
.guide p { margin: 0 0 2px; }
.ck-tabs { flex-wrap: nowrap; }
.ck-tab { flex: 1 1 0; min-width: 0; justify-content: center; padding: 6px 8px; font-size: 14px; }
.ck-tab > span:not(.ck-tab-n) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Cartões compactos no cockpit: só massa, energia, volume e custo nas especificações */
.ck-parts .specs > :not(.sp-mass_kg):not(.sp-power_W):not(.sp-volume_U):not(.sp-cost_k):not(.sp-solarPower_W):not(.sp-dataRate_kbps):not(.sp-capacity_U) { display: none; }
.ck-parts .option-thumb { height: 104px; }
.ck-parts .option { padding: 12px; gap: 6px; }
.ck-parts .option-thumb { margin: -12px -12px 2px; }
.ck-parts .option.selected { padding: 11.5px; }
.ck-parts .option.selected .option-thumb { margin: -11.5px -11.5px 2px; }
.pc span { display: block; }
.pc .pro::before, .pc .con::before { margin-right: 5px; }
/* No centro do cockpit a cadeia desce em coluna: causa → efeito → efeito */
.cascade.ripple { flex-direction: column; align-items: stretch; gap: 4px; }
.cascade.ripple .cz-head { margin-bottom: 2px; }
.cascade.ripple .cz-arrow { align-self: center; transform: rotate(90deg); line-height: 1; }
.cascade.ripple .cz { justify-content: space-between; flex-wrap: wrap; border-radius: 12px; padding: 6px 10px; }
.pc > span > span { display: inline; }

/* ------------------------------------------------ Verificar e lançar */
.launch-deck, .report-deck { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.report-deck:empty { display: none; }
.gonogo .alert { margin: 6px 0 10px; }
.gng-count { display: inline-flex; align-items: center; gap: 4px; font-weight: 800; font-size: 14px; color: var(--muted); }
.gng-count .ico:first-child { color: var(--ok); } .gng-count .ico:last-child { color: var(--fail); }
.predict { border-color: rgba(127, 178, 255, .55); box-shadow: 0 0 0 3px rgba(76, 195, 255, .1), var(--shadow); }
.pred-q { font-size: 18px; font-weight: 600; margin: 4px 0 12px; }
.pred-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 10px; }
.pred-opt { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 52px; border-radius: 12px; cursor: pointer;
  background: var(--surface-2); border: 1.5px solid var(--line); color: var(--text); font-size: 16px; font-weight: 700; }
.pred-opt:hover:not(:disabled) { border-color: var(--accent); }
.pred-opt.on { background: var(--go); border: 2px solid var(--go-border); color: #fff; box-shadow: 0 0 0 4px rgba(76, 195, 255, .16); }
.verif-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 0 16px; }
.verif-grid .card h3 { font-size: 16px; }
.pred-vs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 10px; }
.pred-vs > div { background: var(--surface-2); border: 1px solid var(--line-soft); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; }
.pred-vs b { font-size: 24px; font-family: var(--font-title); }
.pred-result.s-ok { border-color: rgba(74, 222, 128, .55); } .pred-result.s-warn { border-color: rgba(255, 194, 71, .6); }
.compare h3 { font-size: 15px; margin: 6px 0 4px; }
.cmp-changes { margin: 0 0 10px; padding-left: 18px; }
.cmp-changes .ico { color: var(--warn); }
.cmp-now { font-weight: 700; }
.cmp-now.up { color: var(--ok); } .cmp-now.down { color: var(--fail); }

/* Cartas de aprendizado (leis de Senge) */
.lcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.lcard { min-height: 190px; border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start;
  background: repeating-linear-gradient(135deg, #121e3e 0 10px, #142247 10px 20px); border: 1.5px dashed #4b6296; color: var(--muted); }
.lcard .lc-q { font-size: 44px; line-height: 1; color: #4b6296; }
.lcard.on { background: linear-gradient(160deg, #2a1f5c 0%, #172a5c 100%); border: 2px solid var(--sci); color: var(--text);
  box-shadow: 0 0 0 4px rgba(183, 148, 255, .14), 0 0 24px rgba(183, 148, 255, .25); animation: card-in .5s ease both; }
.lc-n { font-size: 12px; color: var(--sci); letter-spacing: .12em; }
.lc-law { font-size: 18px; line-height: 1.25; }
.lcard p { margin: 0; font-size: 14.5px; }
.lc-by { margin-top: auto; font-size: 12px; color: var(--faint); font-style: italic; }
@keyframes card-in { from { opacity: 0; transform: rotateY(70deg) scale(.95); } to { opacity: 1; transform: none; } }
@media (max-width: 860px) { .launch-deck, .report-deck { grid-template-columns: 1fr; } .verif-grid { grid-template-columns: 1fr; } }
.report-crew .crew { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); }

/* ------------------------------------------------ Abertura (fase 1) */
.lobby { margin-bottom: 16px; padding: 18px; border-radius: var(--radius); border: 1.5px solid var(--line);
  background: radial-gradient(ellipse at 50% 140%, rgba(56, 132, 255, .3) 0, transparent 60%), var(--surface); box-shadow: var(--shadow); }
.lb-head h2 { font-size: 26px; margin: 0 0 4px; color: var(--text); letter-spacing: .03em; }
.lb-head p { color: var(--muted); margin: 0 0 14px; }
.lb-seats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lb-seat { display: flex; gap: 14px; align-items: flex-start; padding: 14px; border-radius: 14px; background: var(--surface-2); border: 1.5px solid var(--line); }
.lb-seat.on { border: 2px solid var(--accent); box-shadow: 0 0 0 4px rgba(76, 195, 255, .14); }
.lb-seat b { font-size: 18px; }
.lb-seat p { margin: 2px 0 8px; color: var(--muted); font-size: 15px; }
.lb-av { --rc: var(--dir); flex: none; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #0c1736; border: 2px solid var(--rc); color: var(--rc); }
.lb-roles { flex: none; display: grid; grid-template-columns: 28px 28px; gap: 2px; }
.lb-role { --rc: var(--dir); width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: #0c1736; border: 1.5px solid var(--rc); color: var(--rc); }
.lb-role .ico { width: 15px; height: 15px; }
.journey b::before { content: none; }
@media (max-width: 760px) { .lb-seats { grid-template-columns: 1fr; } }

/* Decisão durante a missão (alerta de clima espacial, estilo Kit) */
.decision { border: 2px solid var(--warn); background: linear-gradient(160deg, rgba(255, 194, 71, .1), var(--surface) 55%); box-shadow: 0 0 0 4px rgba(255, 194, 71, .12), var(--shadow); }
.decision-ic { background: var(--warn); color: #1a1300; }
.decision .choice { min-height: 64px; border: 1.5px solid var(--line); background: var(--surface-2); }
.decision .choice:hover:not(:disabled) { border-color: var(--warn); box-shadow: 0 0 0 3px rgba(255, 194, 71, .2); }
.choice-title { font-size: 16px; }
.choice-text { font-size: 14px; }
/* Cor de cada papel: no fim do arquivo para valer sobre os padrões dos componentes */
.r-sci { --rc: var(--sci); } .r-eng { --rc: var(--eng); } .r-mgr { --rc: var(--mgr); } .r-com { --rc: var(--com); } .r-dir { --rc: var(--dir); }
@media (max-width: 560px) {
  .ck-tab > span:not(.ck-tab-n) { display: none; }
  .top-actions .btn.small { padding: 4px 8px; }
  .ck-parts .options { grid-template-columns: 1fr; }
}
