:root {
  --bg: #0a0d14;
  --panel: #121827;
  --panel-2: #171f33;
  --text: #e8f0ff;
  --muted: #93a4c4;
  --line: #2d3c5d;
  --accent: #7df9ff;
  --warning: #ffe17a;
  --danger: #ff5f82;
  --ok: #83ffb4;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  color: var(--text);
  background:
    radial-gradient(circle at 50% 10%, rgba(125, 249, 255, 0.08), transparent 28rem),
    linear-gradient(180deg, #080a10, #11172a 60%, #080a10);
}
button, input {
  font: inherit;
}
button {
  cursor: pointer;
  border: 1px solid var(--accent);
  color: var(--text);
  background: rgba(125, 249, 255, 0.08);
  border-radius: 10px;
  padding: 0.7rem 0.9rem;
  box-shadow: 0 0 18px rgba(125, 249, 255, 0.1);
}
button:hover { background: rgba(125, 249, 255, 0.18); }
button.secondary { border-color: var(--warning); background: rgba(255, 225, 122, 0.08); }
input {
  width: 100%;
  color: var(--text);
  background: #080d18;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.75rem;
  outline: none;
}
input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(125, 249, 255, 0.12); }
code { color: var(--warning); }
#app { max-width: 1160px; margin: 0 auto; padding: 1.2rem; }
.topbar {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
h1 { margin: 0; font-size: clamp(2.2rem, 5vw, 4.4rem); letter-spacing: 0.08em; text-shadow: 0 0 18px rgba(125, 249, 255, 0.35); }
h2, h3 { margin: 0 0 0.75rem; }
.subtitle { color: var(--muted); margin: 0.2rem 0 0; }
.team-box { min-width: 320px; }
.team-box label, .tool-card label { display: block; color: var(--muted); font-size: 0.9rem; margin-bottom: 0.4rem; }
.row { display: flex; gap: 0.6rem; align-items: center; }
.row.compact input { min-width: 0; }
.card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(18, 24, 39, 0.88);
  backdrop-filter: blur(6px);
  padding: 1rem;
  box-shadow: 0 16px 50px rgba(0,0,0,0.28);
}
.mission { margin-bottom: 1rem; }
.muted { color: var(--muted); }
.room {
  position: relative;
  height: 530px;
  border: 1px solid #384467;
  border-radius: 24px;
  overflow: hidden;
  background:
    linear-gradient(0deg, rgba(255,255,255,0.03) 1px, transparent 1px) 0 0/36px 36px,
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px) 0 0/36px 36px,
    radial-gradient(circle at 50% 90%, rgba(255,225,122,0.08), transparent 20rem),
    #0f1423;
  box-shadow: inset 0 0 80px rgba(0,0,0,0.6);
}
.room::after {
  content: "";
  position: absolute;
  left: -10%; right: -10%; bottom: 0;
  height: 145px;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.35)), repeating-linear-gradient(90deg, #1f2232 0 22px, #181b28 22px 44px);
  transform: perspective(380px) rotateX(38deg);
  transform-origin: bottom;
}
.object {
  position: absolute;
  z-index: 1;
  display: grid;
  place-items: center;
  text-align: center;
  font-weight: 800;
  letter-spacing: 0.05em;
}
.object span { display: block; font-size: 0.78rem; color: var(--warning); }
.poster {
  left: 52px;
  top: 52px;
  width: 190px;
  height: 145px;
  border-color: #ff5f82;
  background: linear-gradient(135deg, rgba(255,95,130,0.22), rgba(125,249,255,0.07)), #251827;
}
.archive {
  right: 55px;
  top: 44px;
  width: 260px;
  height: 150px;
  border-color: var(--warning);
  background: linear-gradient(180deg, rgba(255,225,122,0.22), rgba(0,0,0,0.05)), #302a1d;
}
.pc {
  left: 295px;
  top: 190px;
  width: 235px;
  height: 170px;
  border-color: #83ffb4;
  background: linear-gradient(180deg, rgba(131,255,180,0.18), rgba(0,0,0,0.05)), #13241d;
}
.flyer {
  left: 92px;
  bottom: 78px;
  width: 145px;
  height: 85px;
  transform: rotate(-8deg);
  border-color: #d7a2ff;
  background: linear-gradient(135deg, rgba(215,162,255,0.24), rgba(255,255,255,0.05)), #22152d;
}
.scanner {
  left: 315px;
  bottom: 58px;
  width: 230px;
  height: 130px;
  border-color: #7df9ff;
  background: linear-gradient(180deg, rgba(125,249,255,0.20), rgba(0,0,0,0.06)), #12252c;
}
.cabinet {
  right: 92px;
  bottom: 42px;
  width: 255px;
  height: 305px;
  border-width: 2px;
  border-color: #ff5f82;
  background:
    radial-gradient(circle at 50% 26%, rgba(255,95,130,0.4), transparent 42px),
    linear-gradient(180deg, #44203f, #17101f);
  box-shadow: 0 0 35px rgba(255,95,130,0.18);
}
.panel-grid { display: grid; grid-template-columns: 320px 1fr; gap: 1rem; margin-top: 1rem; }
ul { margin: 0; padding-left: 1.2rem; }
.log, .terminal {
  min-height: 120px;
  white-space: pre-wrap;
  color: #cde8ff;
  background: #050910;
  border: 1px solid #23314e;
  border-radius: 12px;
  padding: 0.8rem;
  overflow: auto;
}
.terminal { min-height: 165px; }
.modal.hidden, .hidden { display: none !important; }
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  display: grid;
  place-items: center;
  padding: 1rem;
  z-index: 10;
}
.modal-card {
  width: min(760px, 95vw);
  max-height: 90vh;
  overflow: auto;
  border: 1px solid var(--accent);
  border-radius: 20px;
  background: #0e1423;
  box-shadow: 0 0 70px rgba(125,249,255,0.18);
  padding: 1.1rem;
  position: relative;
}
.close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 42px;
  height: 42px;
  padding: 0;
  font-size: 1.5rem;
  border-color: var(--danger);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; margin: 0.8rem 0; }
.source-box {
  color: var(--ok);
  background: #020500;
  border: 1px solid #235c38;
  border-radius: 12px;
  padding: 0.8rem;
  white-space: pre-wrap;
}
.bad { color: var(--danger); }
.good { color: var(--ok); }
.warn { color: var(--warning); }
.game-arena {
  position: relative;
  height: 320px;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: radial-gradient(circle at center, rgba(125,249,255,0.08), transparent 12rem), #050910;
  margin-top: 1rem;
}
.coin {
  position: absolute;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 2px solid var(--warning);
  background: radial-gradient(circle at 35% 30%, #fff7bd, #f2a900 55%, #6d4200);
  box-shadow: 0 0 18px rgba(255,225,122,0.45);
}
.glitch {
  position: absolute;
  width: 42px;
  height: 42px;
  background: repeating-linear-gradient(45deg, rgba(255,95,130,0.8) 0 4px, rgba(125,249,255,0.4) 4px 8px);
  opacity: 0.55;
}
.console-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.tool-card label { margin: 0.55rem 0; }
.checkbox { display: flex !important; gap: 0.55rem; align-items: center; }
.checkbox input { width: auto; }
.final-card { border-color: var(--warning); }
.waterfall {
  margin-top: 0.8rem;
  min-height: 130px;
  border: 1px solid #244f5b;
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(125,249,255,0.12), transparent 2px) 0 0/100% 13px,
    linear-gradient(90deg, rgba(255,255,255,0.04), transparent 1px) 0 0/24px 100%,
    #03070d;
  color: var(--warning);
  display: grid;
  place-items: center;
  font-size: clamp(1.3rem, 4vw, 2.4rem);
  letter-spacing: 0.16em;
  text-shadow: 0 0 10px rgba(255,225,122,0.65);
  overflow: hidden;
}
.waterfall::before, .waterfall::after {
  content: "";
  position: absolute;
}
@media (max-width: 850px) {
  .topbar, .row, .panel-grid, .console-grid { grid-template-columns: 1fr; display: grid; }
  .team-box { min-width: 0; }
  .room { height: 760px; }
  .poster { left: 28px; top: 30px; }
  .archive { right: 28px; top: 210px; }
  .pc { left: 28px; top: 210px; }
  .flyer { left: 45px; bottom: 165px; }
  .scanner { left: 28px; bottom: 30px; }
  .cabinet { right: 28px; bottom: 42px; }
}
