/*
 * The pre-game briefing. Sits over the whole page rather than over the stage, because
 * it is read before anything is happening and wants the room — and because the stage is
 * only as wide as the level's map, which on the first level is very small indeed.
 */
.briefing {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(7, 5, 14, 0.9);
  backdrop-filter: blur(6px);
}

.briefing--hidden {
  display: none;
}

.briefing__panel {
  width: min(940px, 100%);
  max-height: min(88vh, 900px);
  display: flex;
  flex-direction: column;
  padding: 26px 28px 22px;
  border-radius: 18px;
  background: var(--panel);
  box-shadow:
    0 30px 70px -30px rgba(0, 0, 0, 0.95),
    inset 0 0 0 1px rgba(255, 255, 255, 0.09);
}

.briefing__title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 700;
  line-height: 1.1;
}

.briefing__meta {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}

.briefing__meta:empty {
  display: none;
}

.briefing__contents {
  margin: 0 0 8px;
  font-size: 16px;
  color: var(--ink-quiet);
}

.briefing__contents:empty {
  display: none;
}

.briefing__intro {
  margin: 0 0 12px;
  font-size: 18.5px;
  line-height: 1.55;
  color: var(--ink-quiet);
}

.briefing__grid {
  list-style: none;
  margin: 0 0 18px;
  padding: 2px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  /* The first level shows two cards; without this they stretch across 860px each. */
  justify-content: start;
  gap: 10px;
  overflow-y: auto;
  /* Sixteen cards rarely fit a short window, so make the scroll obvious rather than
     leaving a half-clipped card that reads as a rendering fault. */
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.28) transparent;
}

.briefing__grid::-webkit-scrollbar {
  width: 10px;
}

.briefing__grid::-webkit-scrollbar-thumb {
  border: 3px solid transparent;
  border-radius: 999px;
  background-clip: content-box;
  background-color: rgba(255, 255, 255, 0.28);
}

.briefing__card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
}

.briefing__art {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
}

.briefing__body {
  min-width: 0;
}

.briefing__name {
  margin: 0 0 2px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  color: var(--ink);
}

.briefing__danger {
  margin: 0 0 3px;
  font-size: 16.5px;
  line-height: 1.4;
  color: #ffb0b0;
}

.briefing__how {
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
  color: var(--ink-quiet);
}

/* Points sit in the corner: informative, never competing with the name. */
.briefing__points {
  position: absolute;
  top: 8px;
  right: 10px;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: var(--good);
}

.briefing__action {
  align-self: flex-start;
  padding: 15px 34px;
  border: 0;
  border-radius: 10px;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  color: var(--backdrop-deep);
  background: var(--accent);
  cursor: pointer;
  transition: transform 120ms ease, filter 120ms ease;
}

.briefing__action:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.briefing__action:focus-visible {
  outline: 3px solid var(--good);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .briefing__action { transition: none; }
}

/*
 * The peluche is not a danger, so it does not get the red treatment — it is the one
 * thing on the screen that helps you.
 */
.briefing__card--friendly {
  box-shadow: inset 0 0 0 1px var(--good);
}

.briefing__card--friendly .briefing__how {
  color: var(--good);
}
