/* Module "doom" (2.92.0, src/modules/doom): the cheat line in the room chat and the game's own page (public/doom/). Pages
   only get this file when the module is on (src/routes/pages.js). */

/* Pixel font for Doom's message, delivered locally (the page policy allows no foreign fonts for it), SIL OFL 1.1:
   public/fonts/PressStart2P-OFL.txt. Only loaded when a cheat line is shown. */
@font-face { font-family: "Press Start 2P"; src: url("/fonts/PressStart2P-Regular.ttf") format("truetype"); font-display: swap; }

/* Variant A of the design "IDDQD": Doom's "DEGREELESSNESS MODE ON" in red pixels, a red line on the left, a faint red
   gradient, below small name and time */
.msg.doom-cheat { flex-direction: column; align-items: flex-start; gap: 4px; margin-left: -8px; padding: 6px 8px;
  border-left: 2px solid #d81d1d; background: linear-gradient(90deg, rgba(216, 29, 29, .14), transparent 70%); }
.doom-cheat-px { font: 10.5px/1.6 "Press Start 2P", var(--data); color: #ff4a3a; text-shadow: 2px 2px 0 #3a0000; letter-spacing: .04em; overflow-wrap: anywhere; }
.doom-cheat-who { font: .66rem/1.2 var(--data); color: var(--ui-dim); }

/* The game's page: black, the game fills the window */
.doom-page { margin: 0; height: 100vh; overflow: hidden; background: #000; color: #ddd; font: 13px/1.4 system-ui, sans-serif; }
.doom-stage { position: fixed; inset: 0; display: grid; place-items: center; }
/* 4:3 like the original (320x200 stretched): no letterbox inside the canvas, otherwise the mouse positions would be off */
.doom-stage canvas { display: block; width: min(100vw, 133.33vh); height: min(100vh, 75vw); image-rendering: pixelated; outline: none; background: #000; }
.doom-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 2; display: flex; gap: 12px; align-items: center; padding: 6px 12px;
  background: rgba(0, 0, 0, .7); transition: opacity .4s; }
.doom-bar.gone { opacity: 0; pointer-events: none; }
.doom-bar a { margin-left: auto; color: #e8c37a; }
.doom-load { position: fixed; inset: 0; z-index: 3; display: grid; place-content: center; gap: 12px; text-align: center; background: #000; }
.doom-load[hidden] { display: none; }
.doom-load b { font: 14px/1.6 "Press Start 2P", monospace; color: #e33; text-shadow: 3px 3px 0 #300; }
.doom-load progress { width: min(320px, 70vw); accent-color: #d81d1d; }
.doom-load small { color: #999; }
.doom-licenses { overflow: auto; height: auto; min-height: 100vh; }
.doom-licenses main { max-width: 720px; margin: 0 auto; padding: 24px 16px; }
.doom-licenses h1 { font-size: 1.2rem; }
.doom-licenses li { margin-bottom: 8px; }
.doom-licenses a { color: #e8c37a; }
