/* The stage is a fixed 1920 × 1080 box; engine/stage.js scales it to fit.
   Sizes here are stage pixels. Nothing a learner must read goes below 28px. */

html,
body.stage-page {
  height: 100%;
  overflow: hidden;
}

.stage {
  position: absolute;
  top: 0;
  left: 0;
  width: 1920px;
  height: 1080px;
  transform-origin: 0 0;
  overflow: hidden;
  background: var(--coal);
  font-size: 32px;
  line-height: 1.35;
}

.scene {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: 56px 64px;
  animation: scene-in 250ms ease;
}

@keyframes scene-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Scene header: number, title, beat, and the heat strip under them.
   Built by engine/frame.js. */

.scene-top {
  display: flex;
  align-items: baseline;
  gap: 28px;
}

.scene-num {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 52px;
  color: var(--flame);
}

.scene-title {
  margin: 0;
  font-size: 56px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.scene-beat {
  margin: 0 0 0 auto;
  font-family: var(--font-mono);
  font-size: 28px;
  color: var(--ash);
  text-transform: uppercase;
  white-space: nowrap;
}

.scene-beat b {
  color: var(--bone);
  font-weight: 800;
}

.scene .heat {
  flex: none;
  height: 14px;
  margin: 22px 0 44px;
}

.scene-body {
  position: relative;
  flex: 1;
  min-height: 0;
}

/* Shared parts for scenes */

.label {
  margin: 0 0 14px;
  font-family: var(--font-mono);
  font-size: 28px;
  color: var(--ash);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Cast-iron plate with four rivets: dots big enough to survive a compressed share. */
.plate {
  --rivet: var(--iron-2) 7px, transparent 8px;
  background:
    radial-gradient(circle at 20px 20px, var(--rivet)),
    radial-gradient(circle at calc(100% - 20px) 20px, var(--rivet)),
    radial-gradient(circle at 20px calc(100% - 20px), var(--rivet)),
    radial-gradient(circle at calc(100% - 20px) calc(100% - 20px), var(--rivet)),
    var(--iron);
  border-bottom: 8px solid var(--edge);
  border-radius: 6px;
  padding: 28px 44px;
}

.note {
  margin: 0 0 24px;
  font-size: 34px;
  line-height: 1.35;
  color: var(--ash);
}

.note b {
  color: var(--bone);
}

/* Placeholder for scenes not built yet */

.placeholder-point {
  margin: 40px 0 0;
  max-width: 1500px;
  font-size: 64px;
  font-weight: 700;
  line-height: 1.2;
}

.placeholder-tag {
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 10px 22px;
  border: 3px dashed var(--ash-dim);
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 28px;
  color: var(--ash);
}

/* Error card: the deck says what is wrong instead of showing a blank screen */

.fatal {
  justify-content: center;
}

.fatal-label {
  margin: 0 0 24px;
  font-family: var(--font-mono);
  font-size: 32px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--alarm);
}

.fatal-message {
  margin: 0;
  font-size: 44px;
  white-space: pre-wrap;
}

/* Short notices such as "Press R again to reset this scene".
   Sits outside the stage, so it is not scaled. */

.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translate(-50%, 16px);
  padding: 12px 24px;
  border-radius: 6px;
  background: var(--iron-2);
  font-size: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}
