:root {
  --bg: #0b1020;
  --panel: #131b31;
  --panel2: #1c2744;
  --text: #f8fafc;
  --muted: #94a3b8;
  --border: rgba(148, 163, 184, 0.2);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, Arial, sans-serif;
  background: linear-gradient(180deg, #0b1020, #090d18);
  color: var(--text);
}
.app { max-width: 1100px; margin: 0 auto; padding: 16px; }
.header, .panel, .screen-nav {
  background: linear-gradient(180deg, #131b31, #0e1527);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 16px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.25);
}
.header { margin-bottom: 16px; }
h1, h2, h3 { margin-top: 0; }
.subtitle, .muted { color: var(--muted); }
.layout { display: grid; gap: 16px; }
.grid, .two-col { display: grid; gap: 12px; }
.grid { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.two-col { grid-template-columns: 0.95fr 1.05fr; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge {
  display: inline-block;
  padding: 7px 10px;
  background: #0f172a;
  border-radius: 999px;
  border: 1px solid var(--border);
  font-size: 12px;
}
.screen-nav {
  margin-bottom: 16px;
  display: flex;
  gap: 10px;
  padding: 10px;
}
.nav-btn {
  flex: 1;
  text-align: center;
}
.nav-btn.active {
  background: linear-gradient(180deg, #33466f, #23304f);
  border-color: rgba(129, 140, 248, 0.5);
}
button {
  width: 100%;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #23304f, #18233d);
  color: var(--text);
  padding: 12px;
  border-radius: 14px;
  cursor: pointer;
  text-align: left;
}
button:hover { filter: brightness(1.08); }
.stat {
  margin-bottom: 10px;
  background: var(--panel2);
  padding: 10px;
  border-radius: 14px;
  border: 1px solid var(--border);
}
.stat-head { display: flex; justify-content: space-between; margin-bottom: 8px; }
.bar { height: 10px; background: #0b1020; border-radius: 999px; overflow: hidden; }
.fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, #38bdf8, #818cf8); }
.event-text {
  min-height: 110px;
  white-space: pre-line;
  color: #e2e8f0;
  line-height: 1.6;
  margin-bottom: 14px;
}
.choices { display: grid; gap: 10px; }
.section-gap { margin-top: 16px; }
.hidden { display: none !important; }
.summary-item, .inv-item {
  padding: 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #16203a;
  margin-bottom: 8px;
}
.stacked-actions { display: grid; gap: 10px; }
@media (max-width: 800px) {
  .two-col { grid-template-columns: 1fr; }
  .screen-nav { position: sticky; top: 12px; z-index: 20; }
}
