@font-face {
  font-family: Pixel;
  src: url("/assets/pixel.woff2") format("woff2");
  font-display: swap;
}
:root {
  font-family: Arial, Helvetica, sans-serif;
  color: #173e35;
  background: #f6f8f2;
  --ink: #173e35;
  --green: #c6ed86;
  --line: #d6ded5;
  --paper: #fff;
  --muted: #506259;
  letter-spacing: 0;
  color-scheme: light;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
summary {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.6;
}
a {
  color: inherit;
  text-underline-offset: 4px;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 3px solid #08768a;
  outline-offset: 4px;
}
::selection {
  background: #c6ed86;
  color: #173e35;
}
input {
  caret-color: #173e35;
}
body::-webkit-scrollbar {
  width: 10px;
}
body::-webkit-scrollbar-thumb {
  background: #768e7d;
}
h1,
h2,
h3,
p {
  margin: 0;
}
p {
  line-height: 1.6;
}
svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.topbar {
  height: 94px;
  padding: 0 5%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 800;
}
.brand svg {
  width: 38px;
  height: 42px;
}
.edition {
  font-size: 14px;
  color: var(--muted);
}
.icon-button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 4px;
}
.icon-button:hover {
  background: #e6ecdf;
}
main {
  min-height: calc(100svh - 155px);
}
footer {
  padding: 20px 5%;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}
.welcome {
  position: relative;
  min-height: 640px;
  display: grid;
  grid-template-columns: 1fr 390px;
  align-items: center;
  padding: 48px 6%;
  gap: 40px;
  overflow: hidden;
  background: #b5ddd1;
}
.world {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}
.welcome-copy {
  position: relative;
  align-self: start;
  padding-top: 12px;
  max-width: 580px;
  pointer-events: none;
}
.welcome h1 {
  font-family: Pixel, monospace;
  font-size: 52px;
  line-height: 1.24;
  font-weight: 400;
  text-wrap: balance;
  max-width: 570px;
}
.welcome-copy p {
  max-width: 405px;
  margin-top: 20px;
  font-size: 18px;
  color: #173e35;
  background: #b5ddd1;
  padding: 6px 0;
}
.start-panel {
  position: relative;
  background: #fff;
  padding: 28px;
  border: 1px solid #173e35;
  border-radius: 6px;
  box-shadow: 0 12px 30px #173e3520;
}
.start-panel h2 {
  font-size: 23px;
  margin-bottom: 8px;
}
.subtle {
  font-size: 14px;
  color: var(--muted);
}
.avatars {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 22px 0;
}
.avatar-option {
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 8px;
  background: #f3f5ee;
  border: 2px solid transparent;
  border-radius: 4px;
  padding: 10px 4px;
  font-size: 12px;
  color: var(--ink);
}
.avatar-option[aria-pressed="true"] {
  border-color: var(--ink);
  background: #e4f3d1;
}
.avatar-option:hover {
  background: #e4f3d1;
}
.sprite {
  width: 56px;
  height: 72px;
  image-rendering: pixelated;
}
.uniforms {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: -10px 0 18px;
}
.uniform-option {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 6px 8px;
  background: #f3f5ee;
  border: 2px solid transparent;
  border-radius: 4px;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.25;
  text-align: left;
}
.uniform-option small {
  display: block;
  color: var(--muted);
  font-size: 11px;
}
.uniform-option[aria-pressed="true"] {
  border-color: var(--ink);
  background: #e4f3d1;
}
.uniform-option:hover {
  background: #e4f3d1;
}
.swatch {
  flex: 0 0 18px;
  height: 22px;
  border: 1px solid #173e35;
  border-radius: 4px;
  background: linear-gradient(90deg, transparent 58%, #f85000 58% 70%, #fdb31e 70% 82%, #15bed6 82% 94%, transparent 94%) 0 5px / 100% 3px no-repeat;
}
.swatch-blanca {
  background-color: #f2f4f1;
}
.swatch-marino {
  background-color: #1f2f55;
}
.swatch-gris {
  background-color: #8d949a;
}
.field {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin: 14px 0;
}
.field input {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  border: 1px solid #899d91;
  border-radius: 3px;
  background: #fff;
  color: var(--ink);
}
.field small {
  font-weight: 400;
  color: var(--muted);
}
.consent {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 12px;
  line-height: 1.5;
  margin: 18px 0;
}
.consent input {
  accent-color: #173e35;
  min-width: 17px;
  height: 17px;
  margin: 1px 0;
}
.primary,
.secondary {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 20px;
  border-radius: 4px;
  font-weight: 700;
  border: 1px solid var(--ink);
  text-decoration: none;
}
.primary {
  background: var(--ink);
  color: #fff;
}
.primary:hover {
  background: #285849;
}
.secondary {
  background: transparent;
  color: var(--ink);
}
.secondary:hover {
  background: #e7eedf;
}
.wide {
  width: 100%;
}
.error {
  color: #a32b29;
  font-size: 14px;
  line-height: 1.5;
  margin: 12px 0;
}
.journey-note {
  padding: 24px 6%;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}
.journey-note span {
  font-size: 14px;
}
.journey-note strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
}
.play {
  max-width: 1400px;
  margin: auto;
  padding: 30px 4% 42px;
}
.play-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}
.play-top h1 {
  font-size: 23px;
}
.progress {
  display: flex;
  gap: 5px;
  margin-top: 10px;
}
.progress i {
  width: 38px;
  height: 5px;
  background: #d5dfd0;
}
.progress i.done {
  background: #29754c;
}
.score {
  flex-shrink: 0;
  white-space: nowrap;
  font-family: Pixel, monospace;
  font-size: 17px;
  text-align: right;
}
.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 30px;
  align-items: start;
}
.scene {
  position: relative;
  height: 480px;
  overflow: hidden;
  background: #b5ddd1;
  border-radius: 4px;
}
.scene canvas {
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}
.scene-label {
  position: absolute;
  left: 18px;
  top: 18px;
  background: #fff;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
}
.hotspot {
  position: absolute;
  left: 50%;
  top: 52%;
  transform: translate(-50%, -50%);
  background: #fff;
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: 4px;
  padding: 14px 18px;
  font-weight: 700;
  box-shadow: 0 6px 20px #173e3540;
  animation: float 2.4s ease-in-out infinite;
}
.hotspot:hover {
  background: var(--green);
}
.scene-caption {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}
.mission {
  padding: 8px 0;
}
.mission h2 {
  font-size: 28px;
  line-height: 1.15;
  margin-bottom: 16px;
}
.mission > p {
  margin-bottom: 20px;
}
.message {
  background: #fff;
  border: 1px solid #b8c9bc;
  border-radius: 4px;
  padding: 20px;
  margin: 20px 0;
  white-space: pre-line;
  line-height: 1.6;
  font-size: 15px;
}
.choices {
  display: grid;
  gap: 10px;
}
.choice {
  display: flex;
  align-items: center;
  gap: 13px;
  text-align: left;
  min-height: 66px;
  border: 1px solid #a4b7a8;
  border-radius: 4px;
  background: #fff;
  color: var(--ink);
  padding: 14px;
  font-size: 15px;
  line-height: 1.35;
}
.choice:hover {
  background: #edf5e1;
  border-color: var(--ink);
}
.choice .choice-number {
  display: grid;
  place-items: center;
  flex: 0 0 25px;
  height: 25px;
  background: #e9efe5;
  border-radius: 50%;
  font-size: 12px;
  font-weight: bold;
}
.feedback {
  border-top: 3px solid #30774f;
  padding: 22px 0;
  margin-top: 18px;
}
.feedback h3 {
  font-size: 22px;
  margin-bottom: 12px;
}
.feedback p {
  margin-bottom: 20px;
}
.feedback.learn {
  border-color: #a76829;
}
.floor {
  background: #1b222b;
  border-radius: 4px;
  padding: 10px;
}
.floor:focus-visible {
  outline: 3px solid #08768a;
  outline-offset: 4px;
}
.floor-hud {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px 8px;
  color: #e8edf0;
  font-family: Pixel, monospace;
  font-size: 15px;
}
.floor-hud b {
  color: var(--green);
  font-weight: 400;
}
.floor canvas {
  display: block;
  margin: 0 auto;
  max-width: 100%;
  height: auto;
  image-rendering: pixelated;
  cursor: pointer;
}
.map-stage {
  position: relative;
  overflow: hidden;
}
.minimap-wrap {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 7px 9px 9px;
  color: #e8edf0;
  background: #1b222bea;
  border: 1px solid #b9cfb4;
  pointer-events: none;
}
.minimap-wrap span {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  font-weight: 700;
}
.floor .minimap {
  display: block;
  width: 104px;
  height: 60px;
  image-rendering: pixelated;
  cursor: default;
}
.floor .minimap svg { display: block; width: 100%; height: 100%; stroke: none; }
.floor-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 12px;
}
.keys {
  flex: 1 1 260px;
  font-size: 13px;
  color: var(--muted);
}
.act {
  flex: 1 0 190px;
  max-width: 100%;
}
.act:disabled {
  cursor: default;
}
.pad {
  display: none;
  grid-template-columns: repeat(3, 48px);
  grid-template-rows: repeat(2, 48px);
  gap: 4px;
  flex: 0 0 auto;
}
.pad button {
  background: #e9efe5;
  border: 1px solid #a4b7a8;
  border-radius: 4px;
  color: var(--ink);
  font-size: 16px;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
}
.pad .up {
  grid-column: 2;
}
.pad .left {
  grid-row: 2;
}
.pad .down {
  grid-row: 2;
}
.pad .right {
  grid-row: 2;
}
.shortcuts {
  margin-top: 20px;
}
.shortcuts-title {
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
#shortcuts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.shortcut {
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid #a4b7a8;
  border-radius: 4px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
}
.shortcut:hover {
  border-color: var(--ink);
}
.shortcut.done {
  background: #e4f3d1;
  border-color: #29754c;
}
.place {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.mission .subtle {
  margin-top: 12px;
}
.mission .ask {
  font-weight: 700;
  margin: 18px 0 10px;
}
.mission .leave {
  margin-top: 18px;
}
.mail {
  display: grid;
  gap: 6px;
  background: #fff;
  border: 1px solid #b8c9bc;
  border-radius: 4px;
  padding: 16px 18px;
  margin: 14px 0 8px;
  font-size: 15px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.incident-prop {
  overflow: hidden;
  margin: 18px 0 10px;
  border: 2px solid #344b45;
  border-radius: 8px;
  background: #f8fbf5;
}
.prop-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 15px;
  color: #fff;
  background: #173e35;
  font-family: Pixel, monospace;
  font-size: 15px;
}
.prop-body {
  padding: 20px;
}
.prop-body strong {
  display: block;
  font-size: 16px;
}
.prop-body p {
  margin-top: 17px;
  padding: 15px;
  border: 1px solid #b8c9bc;
  background: #fff;
  line-height: 1.55;
}
.prop-body small {
  display: block;
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}
.prop-prompt {
  margin: 22px 0 10px;
  font-size: 16px;
}
.prop-body .choices { gap: 8px; }
.prop-body .choice { min-height: 58px; }
.prop-body .choice-number { flex-basis: 25px; }
.prop-body .reveal {
  margin-top: 20px;
  min-height: 48px;
}
.incident-prop.phone {
  border-radius: 22px;
  background: #202a35;
  color: #fff;
}
.phone .prop-head {
  background: #202a35;
  border-bottom: 1px solid #5c7080;
}
.phone .prop-body {
  padding: 26px 20px;
}
.phone .prop-body p {
  max-width: 30ch;
  margin-left: auto;
  border-radius: 16px 16px 3px 16px;
  color: #173e35;
}
.phone .prop-body small {
  color: #d6e3df;
}
.phone .prop-prompt { color: #fff; }
.phone .choice {
  background: #dce8e6;
  color: #173e35;
  border-color: #9ab6ae;
}
.phone .choice:hover { background: #c6ed86; }
.phone .reveal {
  background: #c6ed86;
  color: #173e35;
}
.usb .prop-head { background: #46505b; }
.usb .prop-body { background: #ecece4; }
.usb .choice { background: #fffef7; border-color: #a5aaa2; }
.wifi .prop-body { background: #e8f0ef; }
.wifi .prop-body p { border-radius: 8px; }
.wifi .choice { background: #fff; border-color: #95b6bb; }
.password .prop-head { background: #314c6d; }
.password .prop-body { background: #eef3f8; }
.password .choice { background: #fff; }
.choices.phone .choice { border-radius: 12px; }
.choices.wifi .choice { border-radius: 8px; }
.choices.password .choice { border-color: #7890a8; }
@media (max-width: 720px) {
  .minimap-wrap { right: 7px; bottom: 7px; padding: 5px; }
  .minimap-wrap span { display: none; }
  .floor .minimap { width: 78px; height: 45px; }
}
.clue {
  display: inline;
  background: none;
  border: 0;
  border-bottom: 2px dotted #8aa093;
  padding: 0 2px;
  color: inherit;
  text-align: left;
  line-height: inherit;
}
.clue:hover {
  background: #f1f5ec;
}
.clue.found {
  background: #ffe0da;
  border-bottom-color: #a32b29;
}
.clue.fine {
  background: #e4f3d1;
  border-bottom-color: #29754c;
}
.clue-count {
  font-size: 14px;
  color: var(--muted);
}
.floor-caption {
  margin: 8px 0 0;
  padding: 8px 2px 0;
  border-top: 1px solid #3a4654;
  color: #e8edf0;
  font-size: 15px;
  line-height: 1.45;
}
.beats {
  display: grid;
  gap: 8px;
  margin: 14px 0;
  padding-left: 22px;
  line-height: 1.5;
}
.mission .skip {
  margin-top: 6px;
}
.consequence {
  margin: 16px 0 4px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.consequence h3 {
  font-size: 18px;
}
.consequence .beats {
  margin-bottom: 0;
}
.feedback .actions {
  margin-top: 4px;
}
.end .tower {
  display: block;
  width: 100%;
  height: 280px;
  margin: 8px 0 26px;
  border-radius: 4px;
  image-rendering: pixelated;
}
@media (hover: none), (pointer: coarse) {
  .pad {
    display: grid;
  }
  .keys {
    display: none;
  }
}
.end {
  max-width: 1000px;
  margin: auto;
  padding: 50px 6%;
}
.end h1 {
  font-family: Pixel, monospace;
  font-size: 36px;
  line-height: 1.4;
  margin: 18px 0;
}
.end-banner {
  background: #dcefcc;
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 28px;
  margin-bottom: 30px;
}
.end-banner .sprite {
  width: 84px;
  height: 108px;
}
.end-banner strong {
  font-size: 32px;
  display: block;
  margin-bottom: 8px;
}
.lessons {
  margin: 28px 0;
}
.lessons details {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.lessons summary {
  font-weight: 700;
  cursor: pointer;
}
.lessons p {
  padding-top: 12px;
  color: var(--muted);
}
.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.admin {
  max-width: 1100px;
  padding: 40px 5%;
  margin: auto;
}
.admin h1 {
  margin-bottom: 24px;
}
.admin .field {
  max-width: 440px;
}
.stats {
  display: flex;
  gap: 45px;
  padding: 30px 0;
  flex-wrap: wrap;
}
.stats strong {
  font-size: 30px;
  display: block;
}
.table-wrap {
  overflow: auto;
  margin: 22px 0;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;
  text-align: left;
}
td,
th {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
th {
  background: #e9efe5;
}
.loading {
  padding: 80px 6%;
  font-size: 20px;
}
.privacy {
  font-size: 12px;
  color: var(--muted);
  margin-top: 12px;
}
.empty {
  padding: 30px 0;
  color: var(--muted);
}
@keyframes float {
  50% {
    translate: 0 -6px;
  }
}
@media (min-width: 1500px) {
  .welcome {
    min-height: 710px;
    padding-left: 10%;
    padding-right: 10%;
  }
  .welcome-copy {
    padding-top: 30px;
  }
}
@media (max-width: 1000px) {
  .welcome {
    grid-template-columns: 1fr 350px;
    padding: 35px 4%;
    gap: 20px;
  }
  .welcome h1 {
    font-size: 38px;
  }
  .game-layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}
@media (max-width: 720px) {
  .topbar {
    height: 76px;
    padding: 0 5%;
  }
  .edition {
    display: none;
  }
  .welcome {
    display: block;
    padding: 30px 5%;
    min-height: auto;
  }
  .welcome-copy {
    padding: 0 0 170px;
  }
  .welcome h1 {
    font-size: 34px;
    max-width: 430px;
  }
  .welcome-copy p {
    font-size: 16px;
    max-width: 340px;
  }
  .start-panel {
    max-width: 440px;
    margin: 0 auto;
    padding: 23px;
  }
  .welcome > .world {
    height: 440px;
  }
  .journey-note {
    flex-wrap: wrap;
    gap: 20px;
  }
  .journey-note span {
    flex: 1 1 130px;
    font-size: 12px;
  }
  .journey-note strong {
    font-size: 14px;
  }
  footer {
    font-size: 11px;
    flex-wrap: wrap;
  }
  .play {
    padding: 24px 5%;
  }
  .play-top h1 {
    font-size: 18px;
  }
  .game-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .scene {
    height: 265px;
  }
  .mission h2 {
    font-size: 26px;
  }
  .scene-caption {
    margin-top: 10px;
  }
  .mission-index {
    display: none;
  }
  .score {
    font-size: 13px;
  }
  .end {
    padding: 25px 5%;
  }
  .end h1 {
    font-size: 27px;
  }
  .end-banner {
    padding: 20px;
    gap: 18px;
  }
  .end-banner strong {
    font-size: 26px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    scroll-behavior: auto !important;
  }
}
/* El recorrido es una unica pantalla: mundo, controles y decisiones comparten el marco. */
body.in-game {
  overflow: hidden;
  background: #1b222b;
}
body.in-game .topbar {
  height: 54px;
  padding: 0 24px;
  color: #e8edf0;
  background: #172029;
  border-color: #34434d;
}
body.in-game .brand { font-size: 11px; }
body.in-game .brand svg { width: 29px; height: 32px; }
body.in-game .edition { color: #d3dfdc; }
body.in-game .icon-button { border-color: #52646b; color: #e8edf0; }
body.in-game main { height: calc(100dvh - 54px); min-height: 0; }
body.in-game footer { display: none; }
body.in-game .play,
body.in-game .game-layout { width: 100%; height: 100%; max-width: none; padding: 0; display: block; }
body.in-game .floor {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 0;
  padding: 0;
  background: #1b222b;
}
body.in-game .map-stage {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: #1b222b;
}
body.in-game .floor-map { max-width: none; }
body.in-game .play-top {
  position: absolute;
  z-index: 3;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 72px;
  margin: 0;
  padding: 10px 24px;
  color: #e8edf0;
  background: #172029ed;
  border-bottom: 1px solid #52646b;
}
body.in-game .play-top h1 { font-size: 17px; color: #e8edf0; }
body.in-game .progress { margin-top: 6px; }
body.in-game .progress i { background: #51605f; height: 4px; width: 30px; }
body.in-game .progress i.done { background: #c6ed86; }
body.in-game .floor-hud { display: flex; flex-direction: column; gap: 2px; padding: 0; text-align: center; }
body.in-game .floor-hud b { color: #c6ed86; }
body.in-game .score { color: #e8edf0; }
body.in-game .minimap-wrap { z-index: 3; right: 20px; top: 84px; bottom: auto; }
body.in-game .floor-controls {
  position: absolute;
  z-index: 3;
  left: 20px;
  bottom: 20px;
  display: flex;
  align-items: center;
  max-width: min(600px, calc(100% - 40px));
  margin: 0;
  padding: 11px;
  background: #172029ed;
  border: 1px solid #52646b;
  border-radius: 6px;
}
body.in-game .keys { color: #e8edf0; font-size: 13px; }
body.in-game .touch-keys { display: none; }
body.in-game .act { flex: 0 1 230px; min-height: 48px; white-space: normal; }
body.in-game .shortcuts {
  position: absolute;
  z-index: 4;
  right: 20px;
  bottom: 20px;
  max-width: min(470px, calc(100% - 40px));
  margin: 0;
  color: #e8edf0;
  background: #172029ed;
  border: 1px solid #52646b;
  border-radius: 6px;
}
body.in-game .shortcuts summary { padding: 13px 16px; cursor: pointer; font-weight: 700; }
body.in-game #shortcuts { padding: 0 12px 12px; }
body.in-game .shortcut { min-height: 40px; }
body.in-game .floor[data-mode]:not([data-mode="explore"]) .floor-controls,
body.in-game .floor[data-mode]:not([data-mode="explore"]) .shortcuts,
body.in-game .floor[data-mode]:not([data-mode="explore"]) .minimap-wrap { display: none; }
body.in-game .floor[data-mode]:not([data-mode="explore"])::before {
  content: "";
  position: absolute;
  z-index: 4;
  inset: 72px 0 0;
  background: #111b23a8;
  pointer-events: none;
}
body.in-game .floor[data-mode="watch"]::before { background: transparent; }
body.in-game .mission[hidden] { display: none; }
body.in-game .mission {
  position: absolute;
  z-index: 5;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 24px 28px;
  color: #173e35;
  background: #f6f8f2;
  border: 2px solid #a4b7a8;
  border-radius: 8px;
  box-shadow: 0 12px 35px #0c1519a3;
}
body.in-game .mission > h2 { font-size: clamp(23px, 2vw, 31px); margin-bottom: 8px; }
body.in-game .mission > p { margin-bottom: 10px; }
body.in-game .mission .leave { margin-top: 8px; }
body.in-game .floor[data-mode="incident"] .mission {
  top: 50%;
  right: 24px;
  bottom: auto;
  width: min(900px, 70vw);
  max-height: calc(100% - 110px);
  transform: translateY(-50%);
}
body.in-game .email-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
body.in-game .email-inspect,
body.in-game .email-decide { min-width: 0; }
body.in-game .mail { margin-top: 8px; padding: 12px; font-size: 14px; line-height: 1.45; }
body.in-game .clue-count { margin: 8px 0; }
body.in-game .email-wait { padding: 20px; background: #e9efe5; line-height: 1.45; }
body.in-game .incident-prop { margin: 14px 0 0; }
body.in-game .prop-body { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 18px; align-items: start; padding: 18px; }
body.in-game .prop-body p { margin-top: 12px; padding: 12px; font-size: 14px; }
body.in-game .prop-body small { margin-top: 8px; }
body.in-game .prop-body .choice { min-height: 54px; padding: 10px; font-size: 14px; }
body.in-game .prop-prompt { margin: 0 0 10px; }
body.in-game .floor[data-mode="talk"] .mission {
  left: 50%;
  bottom: 25px;
  width: min(760px, calc(100% - 48px));
  transform: translateX(-50%);
}
body.in-game .floor[data-mode="watch"] .mission {
  left: 50%;
  bottom: 20px;
  width: min(950px, calc(100% - 48px));
  min-height: 140px;
  transform: translateX(-50%);
  color: #e8edf0;
  background: #172029f2;
  border-color: #52646b;
}
body.in-game .floor[data-mode="watch"] .mission h2,
body.in-game .floor[data-mode="watch"] .mission .place { color: #e8edf0; }
body.in-game .floor[data-mode="watch"] .beats { margin: 10px 0; }
body.in-game .floor[data-mode="watch"] .skip {
  position: absolute;
  right: 20px;
  top: 20px;
  color: #e8edf0;
  background: #23333b;
  border-color: #a4b7a8;
}
body.in-game .floor[data-mode="watch"] .skip:hover { background: #345048; }
body.in-game .floor[data-mode="result"] .mission {
  left: 50%;
  top: 50%;
  width: min(1060px, calc(100% - 48px));
  max-height: calc(100% - 130px);
  transform: translate(-50%, -50%);
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 32px;
  align-items: start;
}
body.in-game .floor[data-mode="result"] .mission > .place,
body.in-game .floor[data-mode="result"] .mission > h2 { grid-column: 1 / -1; }
body.in-game .floor[data-mode="result"] .consequence,
body.in-game .floor[data-mode="result"] .feedback { margin-top: 6px; }
@media (max-width: 1000px) {
  body.in-game .floor[data-mode="incident"] .mission { width: min(650px, 70vw); }
  body.in-game .floor-controls { max-width: 55%; }
}
@media (max-width: 720px) {
  body.in-game .topbar { padding: 0 14px; }
  body.in-game .play-top { height: 66px; min-height: 66px; gap: 8px; padding: 7px 12px; }
  body.in-game .play-top h1 { font-size: 14px; }
  body.in-game .progress i { width: 20px; }
  body.in-game .floor-hud { font-size: 11px; }
  body.in-game .score { font-size: 11px; }
  body.in-game .map-stage { inset: 66px 0 0; display: block; }
  body.in-game .floor-map { position: absolute; top: 0; left: 50%; margin: 0; transform: translateX(-50%); }
  body.in-game .minimap-wrap { top: 75px; right: 8px; }
  body.in-game .floor-controls {
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: none;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 8px 12px;
    padding: 8px;
  }
  body.in-game .floor-controls .keys { display: block; grid-column: 1 / -1; font-size: 12px; }
  body.in-game .desktop-keys { display: none; }
  body.in-game .touch-keys { display: inline; }
  body.in-game .pad { display: grid; }
  body.in-game .pad { grid-column: 1; grid-row: 2; }
  body.in-game .act { grid-column: 2; grid-row: 2; width: 100%; align-self: stretch; }
  body.in-game .shortcuts { right: 10px; bottom: 184px; }
  body.in-game .floor[data-mode]:not([data-mode="explore"])::before { inset: 66px 0 0; }
  body.in-game .mission,
  body.in-game .floor[data-mode="incident"] .mission,
  body.in-game .floor[data-mode="result"] .mission,
  body.in-game .floor[data-mode="talk"] .mission {
    left: 0;
    right: 0;
    top: min(32vh, 270px);
    bottom: 0;
    width: auto;
    max-height: none;
    transform: none;
    display: block;
    padding: 18px;
    border-radius: 16px 16px 0 0;
  }
  body.in-game .mission > h2 { font-size: 23px; }
  body.in-game .email-layout,
  body.in-game .prop-body { display: block; }
  body.in-game .email-decide { margin-top: 14px; }
  body.in-game .prop-decision { margin-top: 18px; }
  body.in-game .floor[data-mode="watch"] .mission {
    left: 0;
    right: 0;
    bottom: 0;
    width: auto;
    min-height: 0;
    max-height: 35vh;
    transform: none;
    padding: 14px 18px;
    border-radius: 12px 12px 0 0;
  }
  body.in-game .floor[data-mode="watch"] .skip { position: static; margin-top: 4px; }
}
@media print {
  .topbar,
  footer,
  .actions,
  .icon-button {
    display: none;
  }
  .end {
    padding: 0;
  }
  .lessons details p {
    display: block;
  }
}
