/* Mouse, Bear & Minigun: product page and privacy policy.
   The page is dressed in the game's own UI: colours come from scripts/look.gd,
   type is the game's Russo One and Rubik, and buttons and panels are the game's
   wooden skin (button_wood, button_green, panel, panel_thin) drawn as border-images. */

:root {
  --bark: #241a12;
  --bark-mid: #3a2a1c;
  --bark-light: #54402c;
  --panel-in: #482215;
  --wood: #af511e;
  --wood-dark: #5d3311;
  --cream: #fff2d9;
  --cream-dim: #c8b394;
  --gold: #ffc63f;
  --gold-dark: #9a6f22;
  --leaf: #8fe04a;
  --blue: #4db2ff;
  --red: #ff5f4a;
  --grass: #33552c;
  --grass-near: #5c8f42;
  --ink: #161009;

  --font-display: 'Russo One', 'Rubik', system-ui, sans-serif;
  --font-body: 'Rubik', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.625rem;
  --step-3: clamp(1.875rem, 1.3rem + 2.3vw, 2.75rem);
  --step-4: clamp(2.25rem, 1.4rem + 3.4vw, 3.875rem);

  --wrap: 1180px;
  --gutter: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--bark);
  color: var(--cream);
  font: 500 var(--step-0)/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
}

a {
  color: var(--gold);
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: min(var(--wrap), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

@media (min-width: 720px) {
  :root {
    --gutter: 32px;
  }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 200;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--gold);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

/* The game's titles: cream letters in a thick dark outline with a drop under them */
.outlined {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--cream);
  letter-spacing: 0.01em;
  text-shadow:
    0.05em 0 0 var(--ink), -0.05em 0 0 var(--ink), 0 0.05em 0 var(--ink), 0 -0.05em 0 var(--ink),
    0.036em 0.036em 0 var(--ink), -0.036em 0.036em 0 var(--ink), 0.036em -0.036em 0 var(--ink), -0.036em -0.036em 0 var(--ink),
    0 0.12em 0 var(--ink);
}

/* Wooden plank buttons, cut from the game's button skin */
.plank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 2px 10px;
  border-style: solid;
  border-width: 15px 25px 18px;
  border-image: url("../media/mouse-bear-minigun/button-wood.webp") 30 50 36 fill / 15px 25px 18px stretch;
  background: none;
  color: var(--cream);
  font: 400 1.125rem/1.1 var(--font-display);
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
  text-shadow: 0 2px 0 var(--ink), 2px 0 0 var(--ink), -2px 0 0 var(--ink), 0 -1px 0 var(--ink);
  cursor: pointer;
  transition: filter 0.15s, transform 0.15s;
}

.plank--green {
  border-image-source: url("../media/mouse-bear-minigun/button-green.webp");
}

.plank:hover {
  filter: brightness(1.1);
}

.plank:active {
  transform: translateY(2px);
}

/* Top bar ---------------------------------------------------------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bark);
  border-bottom: 3px solid var(--ink);
  box-shadow: inset 0 -2px 0 var(--bark-light);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 62px;
}

.topbar-start {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.back-btn,
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  color: var(--cream);
  text-decoration: none;
  font-weight: 700;
}

.back-btn {
  padding: 0 10px 0 4px;
  border-radius: 10px;
  color: var(--cream-dim);
  font-size: var(--step--1);
}

.back-btn:hover {
  color: var(--cream);
  background: rgba(255, 242, 217, 0.06);
}

.back-btn img {
  flex: none;
  border-radius: 7px;
  box-shadow: 0 0 0 2px var(--ink);
}

.back-btn .brand-name {
  color: var(--cream);
  font-size: 1rem;
}

.back-btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand {
  min-width: 0;
  padding-left: 12px;
  border-left: 2px solid var(--bark-mid);
}

.brand img {
  flex: none;
  border-radius: 9px;
  box-shadow: 0 0 0 2px var(--ink);
}

.brand-name {
  overflow: hidden;
  font-family: var(--font-display);
  font-weight: 400;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.topbar nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 10px;
  color: var(--cream-dim);
  font-weight: 700;
  font-size: var(--step--1);
  text-decoration: none;
}

.nav-link:hover {
  color: var(--cream);
  background: rgba(255, 242, 217, 0.06);
}

.nav-link {
  white-space: nowrap;
}

/* The privacy page's back button already leads to the game page */
@media (max-width: 519px) {
  .nav-link--wide {
    display: none;
  }
}

@media (max-width: 719px) {
  .back-label,
  .nav-link:not(:last-child) {
    display: none;
  }

  .brand {
    padding-left: 8px;
  }
}

@media (max-width: 380px) {
  .brand-name {
    display: none;
  }
}

/* Hero: the key art as the game's field, the copy in a HUD bar under it ---- */
.hero-art {
  position: relative;
  background: #4a3a2a;
}

.hero-art img {
  display: block;
  width: 100%;
  /* Leave room under the art for the tagline, so the first screen says what the game is */
  height: clamp(340px, min(54vw, 100vh - 250px), 780px);
  height: clamp(340px, min(54vw, 100svh - 250px), 780px);
  object-fit: cover;
  object-position: 50% 40%;
}

@media (max-width: 639px) {
  .hero-art img {
    height: 92vw;
    object-position: 52% 50%;
  }
}

.hero-logo-wrap {
  position: absolute;
  inset: auto 0 0;
  margin-inline: auto;
  pointer-events: none;
}

.hero-logo {
  width: clamp(230px, 40vw, 540px);
  margin: 0;
  line-height: 0;
  transform: translateY(16%);
  transform-origin: 50% 100%;
  filter: drop-shadow(0 12px 18px rgba(10, 6, 2, 0.55));
}

.hero-logo img {
  display: block;
  width: 100%;
  height: auto;
}

/* The one orchestrated moment on the page: the logo lands, as it does in the game's intro */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-logo {
    animation: logo-land 760ms cubic-bezier(0.2, 0.8, 0.3, 1) 180ms both;
  }
}

@keyframes logo-land {
  0% {
    opacity: 0;
    transform: translateY(-70%) scale(1.08);
  }
  50% {
    opacity: 1;
    transform: translateY(20%) scale(1.03, 0.93);
  }
  72% {
    transform: translateY(13%) scale(0.99, 1.02);
  }
  100% {
    transform: translateY(16%) scale(1);
  }
}

.hud {
  border-top: 4px solid var(--ink);
  background: var(--bark-mid);
  box-shadow: inset 0 3px 0 #6b4f33, inset 0 -3px 0 var(--ink);
}

.hud-inner {
  display: grid;
  gap: 28px;
  padding: clamp(64px, 9vw, 92px) 0 40px;
}

@media (min-width: 960px) {
  .hud-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 48px;
  }
}

.tagline {
  margin: 0 0 14px;
  font-size: var(--step-4);
  line-height: 1.05;
}

.lede {
  max-width: 60ch;
  margin: 0 0 22px;
  font-size: 1.1875rem;
  line-height: 1.55;
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--cream-dim);
  font-weight: 700;
  font-size: 0.9375rem;
}

.facts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.facts img,
.facts svg {
  flex: none;
  width: 22px;
  height: 22px;
}

.facts svg {
  fill: none;
  stroke: var(--gold);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.facts svg circle {
  fill: var(--gold);
  stroke: none;
}

.hud-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
}

.soon {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 9px 20px 9px 14px;
  border: 2px solid var(--gold-dark);
  border-radius: 14px;
  background: var(--bark);
  line-height: 1.2;
}

.soon svg {
  width: 28px;
  height: 28px;
  fill: var(--cream);
}

.soon span {
  color: var(--gold);
  font-weight: 700;
  font-size: var(--step--1);
}

.soon b {
  display: block;
  color: var(--cream);
  font: 400 1.1875rem/1.2 var(--font-display);
}

/* Sections ---------------------------------------------------------------- */
.section {
  padding: clamp(64px, 9vw, 112px) 0;
}

.section h2 {
  margin: 0 0 14px;
  font-size: var(--step-3);
  line-height: 1.12;
}

.section-lead {
  max-width: 62ch;
  margin: 0 0 40px;
  color: var(--cream-dim);
  font-size: 1.125rem;
}

/* Screenshots: framed like a phone held sideways, open in the lightbox */
.shot {
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border: 7px solid var(--ink);
  border-radius: 22px;
  background: var(--ink);
  box-shadow: 0 18px 40px rgba(8, 5, 2, 0.45);
  cursor: zoom-in;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  transition: transform 0.25s;
}

.shot:hover img {
  transform: scale(1.015);
}

.shot:focus-visible {
  outline-offset: 4px;
}

/* How a fight goes -------------------------------------------------------- */
.fight-grid {
  display: grid;
  gap: 28px;
  margin-top: 32px;
}

@media (min-width: 960px) {
  .fight-grid {
    grid-template-columns: minmax(300px, 400px) minmax(0, 1fr);
    gap: 44px;
    align-items: start;
  }

  .screen {
    position: sticky;
    top: 96px;
  }
}

.steps {
  display: grid;
  gap: 8px;
}

.step {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  width: 100%;
  padding: 16px 18px 16px 14px;
  border: 2px solid transparent;
  border-radius: 16px;
  background: none;
  color: var(--cream);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.step:hover {
  background: rgba(255, 242, 217, 0.04);
}

.step[aria-selected="true"] {
  border-color: var(--gold-dark);
  background: var(--bark-mid);
  box-shadow: inset 0 0 0 2px rgba(255, 198, 63, 0.12);
}

.step-icon {
  width: 42px;
  height: 42px;
  object-fit: contain;
  margin-top: 2px;
}

.step-body {
  display: block;
}

.step-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 400 var(--step-1)/1.25 var(--font-display);
}

.step-num {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--ink);
  font: 800 0.875rem/1 var(--font-body);
}

.step-text {
  display: block;
  margin-top: 6px;
  color: var(--cream-dim);
  font-size: 1rem;
  line-height: 1.55;
}

.screen {
  display: grid;
  gap: 20px;
}

/* On phones the screenshot rides above the steps while they scroll past, so picking
   a step always shows its picture */
@media (max-width: 959px) {
  .js .screen {
    order: -1;
    position: sticky;
    top: 65px;
    z-index: 5;
    padding: 6px 0 10px;
    background: var(--bark);
  }
}

.screen-panel[hidden] {
  display: none;
}

/* Eleven animals: a forest field with the game's shop bar ------------------ */
.field {
  position: relative;
  background:
    radial-gradient(ellipse 70% 60% at 50% 35%, rgba(92, 143, 66, 0.55), transparent 70%),
    var(--grass);
  border-block: 4px solid var(--ink);
}

.field .section-lead {
  color: #e2d5bb;
}

.roster {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.units {
  display: grid;
  gap: 22px;
}

.unit {
  display: grid;
  gap: 18px 32px;
  padding: 10px;
  border-style: solid;
  border-width: 22px;
  border-image: url("../media/mouse-bear-minigun/panel.webp") 36 fill / 22px stretch;
  filter: drop-shadow(0 16px 28px rgba(10, 18, 6, 0.45));
}

.unit[hidden] {
  display: none;
}

@media (min-width: 720px) {
  .unit {
    grid-template-columns: clamp(180px, 22vw, 250px) minmax(0, 1fr);
    padding: 16px 20px 16px 16px;
  }
}

.unit-portrait {
  display: block;
  width: min(100%, 250px);
  height: auto;
  aspect-ratio: 1;
  border: 4px solid var(--gold-dark);
  border-radius: 18px;
  box-shadow: 0 0 0 3px var(--ink);
}

.js .unit:not([hidden]) .unit-portrait {
  animation: portrait-pop 260ms ease-out;
}

@media (prefers-reduced-motion: reduce) {
  .js .unit:not([hidden]) .unit-portrait {
    animation: none;
  }
}

@keyframes portrait-pop {
  from {
    transform: scale(0.94);
  }
  to {
    transform: scale(1);
  }
}

.unit-text {
  max-width: 64ch;
}

.unit h3 {
  margin: 0;
  font: 400 var(--step-2)/1.15 var(--font-display);
  text-shadow: 0 2px 0 var(--ink);
}

.unit-role {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 16px;
  margin: 4px 0 14px;
  color: var(--gold);
  font-weight: 700;
}

.unit-cost,
.slot-cost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--cream);
  font-weight: 800;
}

.unit-cost::before,
.slot-cost::before {
  content: "";
  width: 22px;
  height: 22px;
  background: url("../media/mouse-bear-minigun/coin.webp") center / contain no-repeat;
}

.unit-joke {
  margin: 0 0 12px;
  color: var(--cream);
  font-weight: 700;
  font-size: 1.125rem;
  line-height: 1.45;
  quotes: "\201C" "\201D";
}

html[lang="ru"] .unit-joke {
  quotes: "\00AB" "\00BB";
}

.unit-joke::before {
  content: open-quote;
}

.unit-joke::after {
  content: close-quote;
}

.unit-text p:not([class]) {
  margin: 0 0 16px;
  color: var(--cream-dim);
}

.unit-unlock {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding-top: 14px;
  border-top: 2px dashed rgba(200, 179, 148, 0.25);
  color: var(--cream);
  font-weight: 700;
  font-size: 0.9375rem;
}

.unit-unlock::before {
  content: "";
  flex: none;
  width: 20px;
  height: 26px;
  background: url("../media/mouse-bear-minigun/lock.webp") center / contain no-repeat;
}

.unit-unlock--start::before {
  background-image: url("../media/mouse-bear-minigun/shield-blue.webp");
}

/* The shop bar: same order, prices and look as the bar under the field in the game */
.shopbar {
  display: none;
}

/* On phones the bar comes first, so the picker is in reach before the long card;
   on wide screens it sits under the card, where the shop sits under the field in the game. */
.js .shopbar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px 8px;
  padding: 10px 8px 6px;
  border-style: solid;
  border-width: 16px;
  border-image: url("../media/mouse-bear-minigun/panel-thin.webp") 24 fill / 16px stretch;
  filter: drop-shadow(0 14px 22px rgba(10, 18, 6, 0.45));
}

.shopbar-group {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--cream-dim);
  font-weight: 700;
  font-size: 0.8125rem;
}

.shopbar-group--won {
  margin-top: 6px;
}

/* One row on wide screens: the starting four, a dashed divider, then the seven won
   by fighting. The won slots get explicit columns: left to auto-placement, the first
   of them would drop into the divider column. */
@media (min-width: 900px) {
  .js .shopbar {
    grid-template-columns: repeat(4, minmax(0, 1fr)) 14px repeat(7, minmax(0, 1fr));
    order: 2;
  }

  .js .shopbar::before {
    content: "";
    grid-row: 1 / 3;
    grid-column: 5;
    justify-self: center;
    width: 0;
    border-left: 2px dashed rgba(200, 179, 148, 0.3);
  }

  .shopbar-group {
    grid-row: 1;
    grid-column: 1 / 5;
  }

  .shopbar-group--won {
    grid-column: 6 / -1;
    margin-top: 0;
  }

  .slot {
    grid-row: 2;
  }

  #tab-owl { grid-column: 6; }
  #tab-skunk { grid-column: 7; }
  #tab-squirrel { grid-column: 8; }
  #tab-hedgehog { grid-column: 9; }
  #tab-mole { grid-column: 10; }
  #tab-beaver { grid-column: 11; }
  #tab-fox { grid-column: 12; }
}

.slot {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  min-width: 0;
  padding: 6px 2px 6px;
  border: 0;
  border-radius: 12px;
  background: none;
  color: var(--cream);
  font: inherit;
  cursor: pointer;
  transition: transform 0.15s;
}

.slot img {
  display: block;
  width: 100%;
  max-width: 96px;
  height: auto;
  aspect-ratio: 1;
  border: 3px solid #7a4a24;
  border-radius: 12px;
  box-shadow: 0 0 0 2px var(--ink);
}

.slot:hover img {
  border-color: #b8783c;
}

.slot[aria-selected="true"] {
  transform: translateY(-4px);
}

.slot[aria-selected="true"] img {
  border-color: var(--gold);
  box-shadow: 0 0 0 2px var(--ink), 0 0 18px rgba(255, 198, 63, 0.55);
}

.slot--won::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 6%;
  width: 16px;
  height: 22px;
  background: url("../media/mouse-bear-minigun/lock.webp") center / contain no-repeat;
  filter: drop-shadow(0 1px 0 var(--ink));
}

.slot-name {
  overflow: hidden;
  max-width: 100%;
  margin-top: 4px;
  font-weight: 700;
  font-size: 0.8125rem;
  line-height: 1.2;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.slot-cost {
  gap: 4px;
  color: var(--gold);
  font-size: 0.8125rem;
  line-height: 1.2;
}

.slot-cost::before {
  width: 14px;
  height: 14px;
}

/* Comic ------------------------------------------------------------------- */
/* Panels are art without words; captions, speech and sound effects are live text laid
   over them at per-panel positions (--x, --y in %), sized from the panel's own width. */
/* A comic page is read as one object, so this section is centred, unlike the rest */
.comic-sec {
  text-align: center;
}

.comic-sec .section-lead,
.comic-end {
  margin-inline: auto;
}

.comic-sec .section-lead {
  margin-bottom: 32px;
}

.comic {
  display: grid;
  gap: 12px;
  max-width: 960px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
  text-align: left;
}

@media (min-width: 720px) {
  .comic {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .panel--wide {
    grid-column: 1 / -1;
  }
}

.panel {
  position: relative;
  container-type: inline-size;
  overflow: hidden;
  border: 5px solid var(--ink);
  border-radius: 6px;
  background: var(--ink);
  box-shadow: 0 10px 24px rgba(8, 5, 2, 0.45);
}

.panel img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}

.panel--wide img {
  aspect-ratio: 3 / 2;
  object-position: var(--pos, 50% 50%);
}

@media (min-width: 720px) {
  .panel--wide img {
    aspect-ratio: 16 / 9;
  }
}

.cap,
.say,
.sfx {
  position: absolute;
  left: var(--x, 3%);
  top: var(--y, 3%);
  margin: 0;
}

.cap,
.say {
  max-width: var(--w, 44%);
  color: var(--ink);
  font-weight: 700;
  font-size: 13px;
  font-size: clamp(11px, 3.4cqi, 17px);
  line-height: 1.3;
}

.panel--wide .cap,
.panel--wide .say {
  font-size: clamp(11px, 2.2cqi, 18px);
}

.cap {
  padding: 0.5em 0.75em;
  border: 3px solid var(--ink);
  background: #ffe9a8;
  box-shadow: 3px 3px 0 var(--ink);
}

.say {
  padding: 0.55em 0.9em;
  border: 3px solid var(--ink);
  border-radius: 1.4em;
  background: #fffaf0;
  text-align: center;
}

/* The tail points down at the speaker; --tx moves it along the bubble, .say--up flips it */
.say::after {
  content: "";
  position: absolute;
  bottom: -0.62em;
  left: var(--tx, 30%);
  width: 1em;
  height: 1em;
  border-right: 3px solid var(--ink);
  border-bottom: 3px solid var(--ink);
  background: inherit;
  transform: rotate(45deg) skew(12deg, 12deg);
}

.say--up::after {
  top: -0.62em;
  bottom: auto;
  transform: rotate(225deg) skew(12deg, 12deg);
}

.sfx {
  color: #ff9a2e;
  font-family: var(--font-display);
  font-size: clamp(20px, 9cqi, 64px);
  line-height: 1;
  letter-spacing: 0.02em;
  transform: rotate(var(--r, -8deg));
  text-shadow:
    0.06em 0 0 var(--ink), -0.06em 0 0 var(--ink), 0 0.06em 0 var(--ink), 0 -0.06em 0 var(--ink),
    0.045em 0.045em 0 var(--ink), -0.045em 0.045em 0 var(--ink), 0.045em -0.045em 0 var(--ink), -0.045em -0.045em 0 var(--ink),
    0 0.12em 0 var(--ink);
}

.sfx--gold {
  color: var(--gold);
}

.sfx--sm {
  font-size: clamp(18px, 7cqi, 48px);
}

/* A wide panel on a phone is short, so its caption grows sideways instead of down */
@container (max-width: 520px) {
  .panel--wide .cap {
    max-width: 58%;
  }
}

.comic-end {
  max-width: 60ch;
  margin: 24px auto 0;
  color: var(--cream-dim);
}

/* Modes ------------------------------------------------------------------- */
.mode-pair {
  display: grid;
  gap: 24px;
}

.mode-pair + .mode-pair {
  margin-top: 24px;
}

@media (min-width: 900px) {
  .mode-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
  }
}

.mode {
  display: flex;
  flex-direction: column;
  padding: 10px 12px 14px;
  border-style: solid;
  border-width: 16px;
  border-image: url("../media/mouse-bear-minigun/panel-thin.webp") 24 fill / 16px stretch;
}

.mode h3 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 8px;
  font: 400 var(--step-2)/1.2 var(--font-display);
  text-shadow: 0 2px 0 var(--ink);
}

.mode h3 img {
  width: 30px;
  height: auto;
}

.mode p {
  margin: 0 0 20px;
  color: var(--cream-dim);
}

.mode .shot {
  margin-top: auto;
}

.mode--duo {
  justify-content: flex-end;
}

.duo-art {
  display: block;
  width: min(100%, 300px);
  height: auto;
  margin: -6px auto 8px;
}

/* Rules ------------------------------------------------------------------- */
.rules {
  background: var(--bark-mid);
  border-block: 4px solid var(--ink);
}

.rules-grid {
  display: grid;
  gap: 40px;
  align-items: center;
}

@media (min-width: 960px) {
  .rules-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: 56px;
  }
}

.rule-list {
  display: grid;
  gap: 20px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.rule-list li {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  color: var(--cream-dim);
}

.rule-list img {
  width: 34px;
  height: auto;
  margin-top: 2px;
}

.rule-list b {
  color: var(--cream);
}

/* Privacy band ------------------------------------------------------------ */
.privacy-band {
  display: grid;
  gap: 8px 36px;
  align-items: center;
  padding: 0 6px 18px;
  border-style: solid;
  border-width: 22px;
  border-image: url("../media/mouse-bear-minigun/panel.webp") 36 fill / 22px stretch;
}

.privacy-art {
  display: block;
  width: 168px;
  height: auto;
  margin: -96px auto 0;
  filter: drop-shadow(0 10px 14px rgba(8, 5, 2, 0.5));
}

.privacy-copy h2 {
  margin-bottom: 10px;
}

.privacy-copy p {
  max-width: 56ch;
  margin: 0 0 22px;
  color: var(--cream-dim);
}

@media (min-width: 720px) {
  .privacy-band {
    grid-template-columns: 200px minmax(0, 1fr);
    padding: 16px 28px 24px 12px;
  }

  .privacy-art {
    width: 200px;
    margin: -110px 0 -10px;
  }
}

/* Details ----------------------------------------------------------------- */
.details dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 20px;
  margin: 28px 0 0;
}

@media (min-width: 900px) {
  .details dl {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0 32px;
  }
}

.details dl div {
  padding: 14px 0;
  border-top: 2px solid var(--bark-mid);
}

.details dt {
  color: var(--cream-dim);
  font-size: var(--step--1);
}

.details dd {
  margin: 2px 0 0;
  font-weight: 700;
}

/* Finale ------------------------------------------------------------------ */
.finale {
  padding: 24px 0 clamp(72px, 10vw, 120px);
  text-align: center;
}

.finale-art {
  display: block;
  width: min(100%, 360px);
  height: auto;
  margin: 0 auto 12px;
}

.finale h2 {
  margin: 0 0 10px;
  font-size: var(--step-3);
  line-height: 1.12;
}

.finale p {
  margin: 0;
  color: var(--cream-dim);
}

/* Footer ------------------------------------------------------------------ */
.footer {
  border-top: 3px solid var(--ink);
  background: #1c140d;
  color: var(--cream-dim);
  font-size: var(--step--1);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding: 24px 0 calc(24px + env(safe-area-inset-bottom));
}

.footer p {
  margin: 0;
}

.footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer a {
  display: inline-block;
  padding: 10px 0;
  color: var(--cream);
}

/* Privacy policy page ---------------------------------------------------- */
.wrap--doc {
  width: min(820px, 100% - 2 * var(--gutter));
}

.policy-head {
  padding: 40px 0 8px;
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  color: var(--cream-dim);
  font-size: var(--step--1);
}

.crumbs li + li::before {
  content: "/";
  margin-right: 10px;
  color: var(--bark-light);
}

.crumbs a {
  color: var(--cream-dim);
}

.policy-head h1 {
  margin: 0 0 8px;
  font-size: var(--step-4);
  line-height: 1.05;
}

.meta {
  margin: 0;
  color: var(--cream-dim);
}

.policy-body {
  padding: 28px 0 clamp(64px, 9vw, 104px);
}

.summary {
  display: grid;
  gap: 4px 28px;
  align-items: center;
  margin-bottom: 28px;
  padding: 4px 14px 14px;
  border-style: solid;
  border-width: 22px;
  border-image: url("../media/mouse-bear-minigun/panel.webp") 36 fill / 22px stretch;
}

.summary img {
  display: block;
  width: 130px;
  height: auto;
  margin: -64px auto 0;
  filter: drop-shadow(0 10px 14px rgba(8, 5, 2, 0.5));
}

.summary h2 {
  margin: 0 0 6px;
  font-size: var(--step-2);
  line-height: 1.2;
}

.summary p {
  margin: 0;
  color: var(--cream-dim);
}

@media (min-width: 640px) {
  .summary {
    grid-template-columns: 150px minmax(0, 1fr);
    padding: 12px 20px 14px 8px;
  }

  .summary img {
    width: 150px;
    margin: -76px 0 -8px;
  }
}

.glance {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  margin: 0 0 36px;
  padding: 0;
  list-style: none;
}

.glance li {
  padding: 14px 16px;
  border: 2px solid var(--bark-mid);
  border-radius: 14px;
  color: var(--cream-dim);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.glance b {
  display: block;
  margin-bottom: 2px;
  color: var(--cream);
  font: 400 1.0625rem/1.3 var(--font-display);
}

.lang-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.lang-tabs [role="tab"] {
  min-height: 44px;
  padding: 0 18px;
  border: 2px solid var(--bark-light);
  border-radius: 12px;
  background: none;
  color: var(--cream-dim);
  font: 700 0.9375rem var(--font-body);
  cursor: pointer;
}

.lang-tabs [role="tab"][aria-selected="true"] {
  border-color: var(--gold-dark);
  background: var(--bark-mid);
  color: var(--cream);
}

.lang-tabs {
  display: none;
}

.js .lang-tabs {
  display: flex;
}

.policy {
  padding-top: 20px;
}

.js .policy[hidden] {
  display: none;
}

.policy + .policy {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 2px solid var(--bark-mid);
}

.js .policy + .policy {
  margin-top: 0;
  padding-top: 20px;
  border-top: 0;
}

.policy h2 {
  margin: 0 0 6px;
  font-size: var(--step-2);
  line-height: 1.2;
}

.policy h3 {
  margin: 36px 0 10px;
  font: 400 var(--step-1)/1.3 var(--font-display);
  color: var(--gold);
}

.policy-date {
  margin: 0 0 22px;
  color: var(--cream-dim);
}

.policy p,
.policy li {
  color: #eadcc0;
}

.policy p {
  margin: 0 0 14px;
}

.policy ul {
  margin: 0 0 16px;
  padding-left: 1.25em;
}

.policy li {
  margin-bottom: 8px;
}

.policy li::marker {
  color: var(--gold);
}

.policy strong {
  color: var(--cream);
}

.policy code {
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--bark-mid);
  font-size: 0.9em;
}

.table-wrap {
  overflow-x: auto;
  margin: 4px 0 18px;
  border: 2px solid var(--bark-mid);
  border-radius: 14px;
}

.policy table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 0.9375rem;
  line-height: 1.45;
}

.policy th,
.policy td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--bark-mid);
  text-align: left;
  vertical-align: top;
}

.policy th {
  background: var(--bark-mid);
  color: var(--cream);
  font-weight: 700;
}

.policy td {
  color: #eadcc0;
}

.policy tr:last-child td {
  border-bottom: 0;
}

/* Phones: each table row becomes a small card, every value under its column name */
@media (max-width: 639px) {
  .table-wrap {
    overflow: visible;
  }

  .policy table {
    min-width: 0;
  }

  .policy thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .policy tr,
  .policy td {
    display: block;
  }

  .policy tr + tr {
    border-top: 2px solid var(--bark-mid);
  }

  .policy td {
    padding: 10px 14px 0;
    border-bottom: 0;
  }

  .policy td:last-child {
    padding-bottom: 12px;
  }

  .policy td::before {
    content: attr(data-label);
    display: block;
    color: var(--gold);
    font-weight: 700;
    font-size: 0.8125rem;
  }
}

/* Lightbox (markup built by gallery.js) ---------------------------------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  background: rgba(20, 14, 9, 0.96);
}

.lightbox[hidden] {
  display: none;
}

.no-scroll {
  overflow: hidden;
}

.lb-stage {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px 16px 8px;
}

.lb-stage picture {
  display: contents;
}

.lb-stage img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  border: 6px solid var(--ink);
  border-radius: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

.lb-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  width: min(760px, 100% - 32px);
  margin: 0 auto;
  padding: 12px 0 calc(16px + env(safe-area-inset-bottom));
}

.lb-text {
  flex: 1;
  min-width: 0;
  text-align: center;
}

.lb-text b {
  display: block;
  font: 400 1.125rem/1.3 var(--font-display);
}

.lb-text span {
  display: block;
  color: var(--cream-dim);
  font-size: var(--step--1);
}

.lb-count {
  position: absolute;
  top: 22px;
  left: 20px;
  color: var(--cream-dim);
  font-weight: 700;
  font-size: var(--step--1);
}

.lb-btn {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 2px solid var(--bark-light);
  border-radius: 50%;
  background: var(--bark-mid);
  color: var(--cream);
  font-size: 1.125rem;
  cursor: pointer;
}

.lb-btn:hover {
  border-color: var(--gold-dark);
}

.lb-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.lb-close {
  position: absolute;
  top: 12px;
  right: 12px;
}
