@font-face {
  font-family: "Lilita One";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./lilita-one-latin.d2575d4fa3.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #f1e4c9;
  --bg-top: #f6ecd8;
  --bar: #dfc391;
  --bar-line: #b78e50;
  --ink: #6f4a18;
  --muted: #9b7c4e;
  --arrow: #34210d;
  --arrow-soft: #8f7243;
  --blocked: #df2929;
  --hover: #6f8f62;
  --region-blue: #2865f4;
  --region-red: #f03535;
  --region-orange: #ee880d;
  --region-green: #0fa873;
  --region-purple: #884cff;
  --water: #55a8ee;
  --empty: rgba(105, 80, 43, 0.14);
  --display-font: "Lilita One", "Arial Rounded MT Bold", "Trebuchet MS", "Microsoft YaHei", sans-serif;
  --body-font: "Lilita One", "Microsoft YaHei", "PingFang SC", "Hiragino Sans", "Arial Rounded MT Bold", sans-serif;
  color-scheme: light;
  font-family: var(--body-font);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  background: #ead8b3;
  color: var(--ink);
}

body.game-page {
  overflow-y: auto;
}

button,
a {
  font: inherit;
}

button {
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

.mobile-game {
  --game-width: min(100vw, 820px);
  --header-height: clamp(108px, 17svh, 148px);
  --heart-height: 42px;
  --bottom-height: clamp(142px, 20svh, 190px);
  position: relative;
  display: grid;
  grid-template-rows: var(--header-height) var(--heart-height) minmax(0, 1fr) var(--bottom-height);
  width: var(--game-width);
  height: 100svh;
  min-height: 560px;
  margin: 0 auto;
  overflow: hidden;
  background:
    radial-gradient(circle at 52% 30%, rgba(255,255,255,0.16), transparent 38%),
    linear-gradient(180deg, var(--bg-top), var(--bg) 72%);
}

.game-header {
  display: grid;
  grid-template-columns: 58px 1fr 88px;
  grid-template-rows: 44% 28% 28%;
  align-items: stretch;
  height: var(--header-height);
  padding: 0;
  border-bottom: 1px solid rgba(128, 91, 45, 0.25);
  color: #d08a00;
  font-size: 22px;
  font-weight: 700;
  text-align: center;
}

.header-title {
  display: grid;
  grid-column: 2;
  grid-row: 1;
  place-items: center;
}

.header-title strong {
  font-size: 28px;
  line-height: 1;
}

.header-stats-row {
  grid-column: 1 / -1;
  grid-row: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border-top: 1px solid rgba(128, 91, 45, 0.18);
  color: #8c6122;
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
}

.stat-divider {
  width: 1px;
  height: 12px;
  background: rgba(128, 91, 45, 0.25);
}

.header-hearts-row {
  grid-column: 1 / -1;
  grid-row: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top: 1px solid rgba(128, 91, 45, 0.18);
}

.icon-button,
.tiny-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  color: #765c3d;
}

.header-left-tools {
  grid-column: 1;
  grid-row: 1;
  align-self: center;
  justify-self: start;
  position: relative;
  display: flex;
  gap: 0;
  align-items: center;
  width: max-content;
  padding-left: 0;
  z-index: 4;
}

.icon-button {
  align-self: center;
  justify-self: center;
}

.info-button,
.tiny-icon {
  position: relative;
  border-radius: 50%;
}

.info-button {
  width: 52px;
  height: 52px;
}

.audio-button {
  width: 52px;
  height: 52px;
  margin-left: 0;
  overflow: visible;
}

.speaker-wrap {
  position: relative;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
}

.speaker-icon {
  display: block;
  width: 36px;
  height: 36px;
  object-fit: contain;
  pointer-events: none;
}

.speaker-slash {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 4px;
  border-radius: 999px;
  background:
    linear-gradient(180deg, #fff0ca 0 12%, #8f2f1b 12% 88%, #fff0ca 88% 100%);
  box-shadow:
    0 0 0 1px rgba(255, 245, 216, 0.8),
    0 1px 2px rgba(70, 34, 12, 0.22);
  opacity: 0;
  pointer-events: none;
  transform-origin: center;
}

.audio-button.is-part-muted .speaker-slash {
  left: 50%;
  top: 50%;
  width: 4px;
  height: 24px;
  opacity: 1;
  transform: translate(-50%, -50%) rotate(45deg);
}

.audio-button.is-all-muted .speaker-slash {
  height: 42px;
  opacity: 1;
  transform: translate(-50%, -50%) rotate(45deg);
}

.audio-menu {
  position: absolute;
  right: 48px;
  top: 48px;
  display: grid;
  min-width: 112px;
  gap: 5px;
  padding: 8px;
  border: 1px solid rgba(128, 91, 45, 0.22);
  border-radius: 10px;
  background: rgba(255, 250, 236, 0.95);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.75),
    0 7px 18px rgba(76, 48, 14, 0.18);
  z-index: 8;
}

.audio-menu button {
  position: relative;
  display: flex;
  min-height: 30px;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  border-radius: 7px;
  background: rgba(235, 211, 160, 0.42);
  color: #765125;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}

.audio-menu button.is-muted {
  color: #a46f35;
  background: rgba(236, 217, 177, 0.62);
}

.audio-menu button.is-muted span {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
  text-decoration-color: #8f2f1b;
}

.info-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 3px solid #77542b;
  border-radius: 50%;
  color: #77542b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
  box-shadow: inset 0 -1px 0 rgba(255, 245, 216, 0.7);
}

.header-actions {
  grid-column: 3;
  grid-row: 1;
  align-self: center;
  justify-self: end;
  position: relative;
  display: flex;
  justify-content: flex-end;
  gap: 2px;
  padding-right: 4px;
  z-index: 4;
}

.tiny-icon {
  font-size: 32px;
}

.region-toggle {
  position: relative;
}

.region-toggle.is-active::after {
  content: none;
}

.region-toggle.is-active {
  background: rgba(255, 248, 231, 0.5);
  box-shadow: inset 0 0 0 2px rgba(129, 94, 43, 0.28);
}

.mobile-game.is-cleared .header-title strong,
.mobile-game.is-cleared .status-line {
  animation: clear-pulse 260ms ease-in-out 5;
}

.mobile-game.is-cleared .game-header {
  animation: clear-wash 360ms ease-in-out 3;
}

.region-toggle.is-active::before {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 50%;
  border: 2px solid rgba(118, 84, 43, 0.38);
  pointer-events: none;
}

.header-tool-icon {
  display: block;
  width: 34px;
  height: 34px;
  object-fit: contain;
  pointer-events: none;
}

.settings-icon {
  width: 34px;
  height: 34px;
}

.heart-row {
  display: flex;
  gap: 10px;
  align-items: center;
  height: 42px;
  padding: 0 14px 0 16px;
}

.heart-cluster {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}

.reward-toast-anchor {
  align-self: stretch;
  flex: 1 1 auto;
  min-width: 24px;
  pointer-events: none;
}

.heart-stack {
  display: flex;
  gap: 10px;
  align-items: center;
}

.heart-stack span {
  position: relative;
  width: 26px;
  height: 26px;
  overflow: hidden;
  color: transparent;
}

.heart-stack span::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("./heart-life.ad798668fc.svg") center / contain no-repeat;
  opacity: 0.28;
}

.heart-stack .alive::before {
  opacity: 1;
}

.shield-badge {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid rgba(35, 123, 105, 0.28);
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 22%, #fafff9 0 18%, #ddfff2 45%, #31a888 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 2px 6px rgba(21, 91, 73, 0.2);
}

.shield-badge span {
  width: 13px;
  height: 15px;
  clip-path: polygon(50% 0, 92% 18%, 82% 70%, 50% 100%, 18% 70%, 8% 18%);
  background:
    linear-gradient(135deg, #ffffff 0 22%, #9effdb 23% 48%, #0d7c6d 49% 100%);
  box-shadow: inset 0 -1px 0 rgba(0, 85, 70, 0.42);
}

.wallet-chip,
.combo-chip {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid rgba(135, 94, 37, 0.2);
  border-radius: 999px;
  font-family: var(--display-font);
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.wallet-chip {
  position: relative;
  min-width: 74px;
  padding: 0 10px 0 7px;
  background:
    linear-gradient(180deg, rgba(255, 250, 235, 0.92), rgba(250, 228, 180, 0.76));
  color: #80551c;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.66),
    0 2px 6px rgba(102, 67, 20, 0.12);
  transform-origin: left center;
}

.combo-chip {
  position: relative;
  --flame-duration: 820ms;
  --flame-frame: 29px;
  --flame-scale: 1;
  --flame-strip-offset: -232px;
  min-width: 96px;
  justify-content: flex-start;
  padding: 0 10px 0 6px;
  border-color: rgba(169, 66, 24, 0.24);
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 247, 222, 0.92), rgba(255, 247, 222, 0) 42%),
    linear-gradient(180deg, rgba(255, 226, 184, 0.94), rgba(219, 98, 48, 0.8));
  color: #8d3410;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 3px 9px rgba(128, 46, 14, 0.16);
  overflow: visible;
  isolation: isolate;
  transform-origin: right center;
}

.combo-chip.combo-tier-idle {
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 248, 226, 0.88), rgba(255, 248, 226, 0) 44%),
    linear-gradient(180deg, rgba(248, 225, 188, 0.9), rgba(214, 176, 119, 0.74));
  color: #7c5424;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.66),
    0 2px 6px rgba(94, 61, 21, 0.12);
}

.combo-chip.combo-tier-1 {
  --flame-scale: 1.02;
  min-width: 104px;
  border-color: rgba(213, 86, 31, 0.34);
}

.combo-chip .chip-icon,
.combo-chip .combo-label,
.combo-chip strong,
.combo-multiplier-badge {
  position: relative;
  z-index: 2;
}

.chip-icon {
  display: block;
  width: 26px;
  height: 26px;
  object-fit: contain;
  pointer-events: none;
}

.combo-chip .flame-icon,
.reward-toast-icon-combo::before {
  width: var(--flame-frame);
  height: var(--flame-frame);
  margin-left: -2px;
  background: url("./combo-flame-burn-sprite.004a5bda8e.webp") 0 0 / auto 100% no-repeat;
  transform: scale(var(--flame-scale));
  transform-origin: center bottom;
  filter: drop-shadow(0 0 4px rgba(255, 145, 24, 0.34));
}

.wallet-chip .coin-icon {
  width: 25px;
  height: 25px;
}

.wallet-chip strong,
.combo-chip strong {
  color: #6f3d09;
  font-size: 20px;
  line-height: 1;
  text-shadow:
    0 1px 0 rgba(255, 246, 217, 0.95),
    0 2px 0 rgba(121, 74, 15, 0.12);
}

.wallet-chip strong {
  min-width: 34px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.wallet-coin-roll {
  animation: reward-coin-slot 760ms cubic-bezier(0.17, 0.84, 0.32, 1) both;
}

.wallet-coin-roll.is-settled {
  animation: reward-coin-settle 220ms ease-out both;
}

.combo-chip .combo-label {
  color: rgba(126, 43, 7, 0.82);
  font-size: 11px;
  text-transform: uppercase;
}

.combo-chip.combo-tier-2,
.combo-chip.combo-tier-3,
.combo-chip.combo-tier-4,
.combo-chip.combo-tier-5 {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 0 0 2px rgba(230, 76, 22, 0.2),
    0 4px 12px rgba(139, 40, 9, 0.24);
}

.combo-chip.combo-tier-2 {
  --flame-duration: 760ms;
  --flame-scale: 1.08;
  min-width: 112px;
  border-color: rgba(220, 68, 26, 0.46);
  background:
    radial-gradient(circle at 23% 16%, rgba(255, 244, 199, 0.95), rgba(255, 244, 199, 0) 42%),
    linear-gradient(180deg, rgba(255, 174, 83, 0.98), rgba(218, 54, 25, 0.9));
}

.combo-chip.combo-tier-2 strong {
  font-size: 25px;
  color: #7f2100;
}

.combo-chip.combo-tier-3 {
  --flame-duration: 540ms;
  --flame-scale: 1.16;
  min-width: 118px;
  border-color: rgba(219, 48, 18, 0.54);
  background:
    radial-gradient(circle at 23% 16%, rgba(255, 238, 183, 0.95), rgba(255, 238, 183, 0) 42%),
    linear-gradient(180deg, rgba(255, 139, 62, 0.99), rgba(197, 37, 19, 0.94));
}

.combo-chip.combo-tier-3 strong {
  font-size: 27px;
  color: #791900;
}

.combo-chip.combo-tier-4 {
  --flame-duration: 390ms;
  --flame-scale: 1.24;
  min-width: 122px;
  border-color: rgba(198, 35, 13, 0.64);
  background:
    radial-gradient(circle at 23% 16%, rgba(255, 236, 173, 0.98), rgba(255, 236, 173, 0) 40%),
    linear-gradient(180deg, rgba(255, 116, 51, 1), rgba(172, 28, 18, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 0 0 2px rgba(226, 55, 17, 0.3),
    0 0 16px rgba(234, 83, 22, 0.36),
    0 0 24px rgba(192, 28, 8, 0.18);
}

.combo-chip.combo-tier-4 strong {
  font-size: 29px;
  color: #fff0bf;
  text-shadow:
    0 1px 0 rgba(102, 20, 0, 0.58),
    0 2px 6px rgba(99, 18, 0, 0.32);
}

.combo-chip.combo-tier-5 {
  --flame-duration: 260ms;
  --flame-scale: 1.32;
  min-width: 126px;
  border-color: rgba(159, 23, 7, 0.7);
  background:
    radial-gradient(circle at 24% 15%, rgba(255, 244, 177, 1), rgba(255, 244, 177, 0) 38%),
    linear-gradient(180deg, #ff6434 0%, #9d160d 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.84),
    0 0 0 2px rgba(235, 48, 13, 0.38),
    0 0 18px rgba(246, 72, 19, 0.44),
    0 0 30px rgba(178, 19, 5, 0.28);
}

.combo-chip.combo-tier-5 strong {
  font-size: 30px;
  color: #fff4bf;
  text-shadow:
    0 1px 0 rgba(100, 14, 0, 0.66),
    0 2px 8px rgba(88, 12, 0, 0.38);
}

.combo-chip.combo-tier-2 .combo-label,
.combo-chip.combo-tier-3 .combo-label,
.combo-chip.combo-tier-4 .combo-label,
.combo-chip.combo-tier-5 .combo-label {
  color: rgba(255, 240, 196, 0.9);
  text-shadow: 0 1px 0 rgba(99, 23, 0, 0.26);
}

.combo-multiplier-badge {
  display: inline-grid;
  min-width: 23px;
  min-height: 19px;
  place-items: center;
  padding: 0 5px 1px;
  border: 1px solid rgba(255, 236, 177, 0.44);
  border-radius: 999px;
  background: rgba(108, 18, 4, 0.48);
  color: #fff3bb;
  font-size: 11px;
  line-height: 1;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 2px 5px rgba(73, 14, 0, 0.18);
}

.combo-chip.is-bumping {
  animation: combo-number-pop 280ms ease;
}

.combo-chip.combo-tier-idle .flame-icon {
  opacity: 0.74;
  filter: drop-shadow(0 0 3px rgba(126, 64, 20, 0.22)) saturate(0.68);
}

.combo-chip.combo-tier-1 .flame-icon,
.reward-toast-card.combo-reward-tier-1 .reward-toast-icon-combo::before {
  filter: drop-shadow(0 0 4px rgba(255, 128, 31, 0.36));
}

.combo-chip.combo-tier-2 .flame-icon,
.reward-toast-card.combo-reward-tier-2 .reward-toast-icon-combo::before {
  animation: flame-burn-sheet var(--flame-duration) steps(8) infinite;
  filter: drop-shadow(0 0 5px rgba(255, 134, 26, 0.56));
}

.combo-chip.combo-tier-3 .flame-icon,
.reward-toast-card.combo-reward-tier-3 .reward-toast-icon-combo::before {
  animation: flame-burn-sheet var(--flame-duration) steps(8) infinite;
  filter: drop-shadow(0 0 7px rgba(255, 100, 17, 0.7));
}

.combo-chip.combo-tier-4 .flame-icon,
.combo-chip.combo-tier-5 .flame-icon,
.reward-toast-card.combo-reward-tier-4 .reward-toast-icon-combo::before,
.reward-toast-card.combo-reward-tier-5 .reward-toast-icon-combo::before {
  animation: flame-burn-sheet var(--flame-duration) steps(8) infinite;
  filter: drop-shadow(0 0 9px rgba(255, 82, 12, 0.82));
}

.coin-gain-float {
  position: absolute;
  right: -5px;
  top: -9px;
  min-width: 28px;
  padding: 3px 6px 4px;
  border: 1px solid rgba(170, 92, 0, 0.18);
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 252, 219, 0.98), rgba(255, 203, 84, 0.94));
  color: #a85200;
  box-shadow:
    0 2px 7px rgba(114, 67, 6, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  font-size: 12px;
  font-weight: 950;
  line-height: 1;
  text-align: center;
  pointer-events: none;
  animation: coin-gain-float 920ms ease-out both;
}

.wallet-chip.is-bumping .coin-icon {
  animation: coin-hop 320ms ease-out;
}

.wallet-chip.is-bumping strong {
  animation: coin-number-pop 300ms ease;
}

.reward-toast-layer {
  position: fixed;
  z-index: 60;
  width: min(var(--notice-max-width, 320px), calc(100vw - 18px));
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%) translateY(7px) scale(0.92);
  transform-origin: center center;
  transition:
    opacity 130ms ease,
    transform 180ms cubic-bezier(0.18, 0.9, 0.25, 1.18);
}

.reward-toast-layer.is-visible {
  opacity: 1;
  transform: translate(-50%, -50%) translateY(0) scale(1);
}

@media (max-width: 600px) {
  .reward-toast-layer {
    left: 50% !important;
    width: min(420px, calc(100vw - 20px));
    transform: translate(-50%, -50%) translateY(7px) scale(0.92);
  }
  .reward-toast-layer.is-visible {
    transform: translate(-50%, -50%) translateY(0) scale(1);
  }
}

.reward-toast-card {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  padding: 7px 9px 7px 8px;
  border: 1px solid rgba(180, 54, 18, 0.24);
  border-radius: 999px;
  background:
    radial-gradient(circle at 16% 20%, rgba(255, 247, 222, 0.96), rgba(255, 247, 222, 0) 42%),
    linear-gradient(180deg, rgba(255, 211, 150, 0.98), rgba(218, 74, 38, 0.92));
  color: #7d1d00;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 8px 18px rgba(153, 42, 6, 0.18);
  isolation: isolate;
}

.reward-toast-icon,
.reward-toast-text,
.reward-toast-badge {
  position: relative;
  z-index: 2;
}

.reward-toast-icon {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 50%;
  flex: 0 0 auto;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 3px 7px rgba(91, 32, 0, 0.2);
}

.reward-toast-icon-coin {
  background: url("./icon-coin-generated.6fcac07a31.webp") center / contain no-repeat;
}

.reward-toast-icon-gift {
  background: url("./icon-gift-generated.fbeaf4f16d.webp") center / contain no-repeat;
  box-shadow: none;
}

.reward-toast-icon-gift::before,
.reward-toast-icon-gift::after {
  content: none;
}


.reward-toast-icon-combo {
  --flame-duration: 820ms;
  --flame-frame: 29px;
  --flame-scale: 1.02;
  --flame-strip-offset: -232px;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.reward-toast-icon-combo::before {
  content: "";
  display: block;
}

.reward-toast-card.combo-reward-tier-2 .reward-toast-icon-combo {
  --flame-duration: 760ms;
  --flame-scale: 1.08;
}

.reward-toast-card.combo-reward-tier-3 .reward-toast-icon-combo {
  --flame-duration: 540ms;
  --flame-scale: 1.16;
}

.reward-toast-card.combo-reward-tier-4 .reward-toast-icon-combo {
  --flame-duration: 390ms;
  --flame-scale: 1.24;
}

.reward-toast-card.combo-reward-tier-5 .reward-toast-icon-combo {
  --flame-duration: 260ms;
  --flame-scale: 1.32;
}

.reward-toast-text {
  min-width: 0;
  display: block;
  justify-self: stretch;
  padding: 0 4px 1px;
  color: #fff4c9;
  font-size: 15px;
  font-weight: 950;
  line-height: 1.05;
  text-align: center;
  overflow-wrap: anywhere;
  -webkit-text-stroke: 0.45px rgba(105, 25, 0, 0.68);
  paint-order: stroke fill;
  text-shadow:
    0 1px 0 rgba(89, 17, 0, 0.74),
    0 2px 5px rgba(75, 12, 0, 0.34),
    0 0 7px rgba(255, 232, 140, 0.28);
}

.reward-toast-number {
  display: inline-block;
  padding-inline: 1px;
  color: #fff8c9;
  font-family: var(--display-font);
  font-size: 1.15em;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

.reward-toast-multiplier {
  color: #ffffff;
  text-shadow:
    0 1px 0 rgba(83, 10, 0, 0.64),
    0 0 9px rgba(255, 243, 149, 0.45);
}

.reward-toast-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 42px;
  min-height: 28px;
  padding: 2px 8px 3px;
  border: 1px solid rgba(255, 236, 177, 0.5);
  border-radius: 999px;
  background:
    radial-gradient(circle at 34% 18%, rgba(255, 255, 245, 0.34), rgba(255, 255, 245, 0) 48%),
    rgba(108, 18, 4, 0.5);
  color: #fff3bb;
  font-family: var(--display-font);
  font-size: 16px;
  line-height: 1;
  white-space: nowrap;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 2px 5px rgba(73, 14, 0, 0.18);
}

.reward-toast-badge .reward-toast-number {
  font-size: 1em;
}

.reward-toast-tier-1 .reward-toast-card {
  background:
    radial-gradient(circle at 16% 20%, rgba(255, 246, 220, 0.95), rgba(255, 246, 220, 0) 42%),
    linear-gradient(180deg, rgba(255, 218, 174, 0.98), rgba(220, 102, 50, 0.86));
}

.game-stage {
  position: relative;
  min-height: 0;
}

.boss-progress {
  position: absolute;
  z-index: 5;
  top: 4px;
  left: 50%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 128px;
  width: min(calc(100% - 24px), 540px);
  min-height: 58px;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border: 1px solid rgba(91, 34, 20, 0.24);
  border-radius: 12px;
  background: rgba(255, 245, 222, 0.96);
  color: #5e2419;
  box-shadow:
    0 6px 16px rgba(74, 31, 18, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
  transform: translateX(-50%);
}

.boss-progress-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
  text-align: left;
}

.boss-progress-copy > span:first-child {
  color: #ad4a20;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.boss-progress-copy strong {
  overflow: hidden;
  font-size: 18px;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.boss-progress-copy > span:last-child {
  color: #795044;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 900;
  line-height: 1.1;
}

.boss-armor {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.boss-armor-segment {
  position: relative;
  display: grid;
  min-width: 0;
  height: 30px;
  place-items: center;
  border: 1px solid #7d392a;
  border-radius: 7px;
  background: linear-gradient(180deg, #9f4a35, #6d2f27);
  color: #fff4d9;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 950;
}

.boss-armor-segment i {
  font-style: normal;
}

.boss-armor-segment.is-current {
  border-color: #d17919;
  background: linear-gradient(180deg, #ffcf58, #d57d19);
  color: #5a260d;
  box-shadow:
    0 0 0 2px rgba(216, 126, 24, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.62);
}

.boss-armor-segment.is-broken {
  border-style: dashed;
  border-color: rgba(92, 60, 48, 0.48);
  background: #d8c9b9;
  color: #6f5d52;
  box-shadow: none;
}

.boss-armor-segment.is-broken::after {
  content: "×";
  position: absolute;
  font-size: 23px;
  line-height: 1;
}

.boss-armor-segment.is-broken i {
  opacity: 0;
}

.is-boss-stage .board-wrap.shape-ascii {
  --ascii-board-size: min(calc(var(--game-width) - 20px), calc(100% - 76px), 740px);
  top: calc(50% + 34px);
}

.is-boss-transition .board-wrap {
  opacity: 0.24;
  pointer-events: none;
}

.challenge-hub-button {
  display: grid;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(139, 92, 19, 0.34);
  border-radius: 50%;
  background: linear-gradient(180deg, #fff6cf, #efc15d);
  color: #68440e;
  box-shadow: 0 2px 0 rgba(116, 74, 12, 0.2);
  font-size: 19px;
}

.challenge-hub-button:active {
  transform: translateY(1px);
  box-shadow: 0 1px 0 rgba(116, 74, 12, 0.2);
}

.is-boss-stage .header-title strong {
  max-width: 100%;
  overflow: hidden;
  font-size: clamp(19px, 5vw, 27px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.goal-pill {
  display: none;
}

.board-wrap {
  position: absolute;
  left: 50%;
  top: 4px;
  width: min(calc(100% - 20px), 560px);
  height: calc(100% - 8px);
  aspect-ratio: auto;
  overflow: hidden;
  touch-action: none;
  transform: translateX(-50%);
}

.board-wrap.shape-ascii {
  --ascii-board-size: min(calc(var(--game-width) - 20px), calc(100% - 8px), 812px);
  top: 50%;
  width: var(--ascii-board-size);
  height: var(--ascii-board-size);
  transform: translate(-50%, -50%);
}

.board-pan {
  position: absolute;
  inset: 0;
  transform-origin: center;
  transition: transform 120ms ease;
}

.board-wrap.is-zoomed .board-pan {
  transition: none;
}

.board-loading {
  display: grid;
  place-items: center;
  touch-action: none;
  pointer-events: none;
}

.board-loading-frame {
  display: grid;
  min-width: min(68%, 260px);
  min-height: 110px;
  place-items: center;
  gap: 12px;
  border-radius: 999px;
  background: rgba(251, 242, 223, 0.42);
  color: #89570a;
  font-size: 18px;
  font-weight: 950;
  box-shadow: none;
}

.board-loader {
  width: 38px;
  height: 38px;
  border: 4px solid rgba(137, 87, 10, 0.2);
  border-top-color: #d08a00;
  border-radius: 50%;
  animation: board-loader-spin 720ms linear infinite;
}

.shape-ascii svg.board {
  aspect-ratio: 1 / 1;
}

.hand-guide {
  display: none;
}

.hand-guide.is-visible {
  position: absolute;
  z-index: 2;
  display: block;
  transform: translate(-18%, -12%);
  font-size: clamp(24px, 5vw, 42px);
  filter: drop-shadow(0 2px 2px rgba(77, 47, 15, 0.22));
  pointer-events: none;
  animation: hand-tap 850ms ease-in-out infinite;
}

.board {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  outline: 0;
}

.board:focus,
.board:focus-visible {
  outline: 0;
}

.board-grid {
  pointer-events: none;
}

.board-grid line,
.board-grid rect {
  fill: none;
  stroke: rgba(0, 0, 0, 0.14);
  stroke-width: 0.75px;
  vector-effect: non-scaling-stroke;
}

.board-grid rect {
  stroke: rgba(0, 0, 0, 0.26);
  stroke-width: 1px;
}

.board-wrap.is-zoomed .board-grid line {
  stroke: rgba(0, 0, 0, 0.3);
  stroke-width: 1px;
}

.board-wrap.is-zoomed .board-grid rect {
  stroke: rgba(0, 0, 0, 0.48);
  stroke-width: 1.2px;
}

.cell {
  pointer-events: auto;
}

.tap-area {
  fill: transparent;
  stroke: transparent;
  stroke-width: 0.72;
  stroke-linecap: square;
  stroke-linejoin: miter;
  cursor: default;
  pointer-events: stroke;
}

.dot {
  fill: rgba(0, 0, 0, 0.3);
  opacity: 0;
  pointer-events: none;
}

.board.show-grid .dot {
  opacity: 0.24;
}

.board-wrap.is-zoomed .board.show-grid .dot {
  opacity: 0.36;
}

.tile {
  touch-action: none;
  cursor: default;
}

.arrow-line {
  fill: none;
  stroke: var(--arrow);
  stroke-width: 0.14;
  stroke-linecap: square;
  stroke-linejoin: miter;
  marker-end: url(#arrow-head);
  paint-order: stroke;
  cursor: default;
}

.color-regions .region-0 .arrow-line {
  stroke: var(--region-blue);
}

.color-regions .region-1 .arrow-line {
  stroke: var(--region-red);
}

.color-regions .region-2 .arrow-line {
  stroke: var(--region-orange);
}

.color-regions .region-3 .arrow-line {
  stroke: var(--region-green);
}

.color-regions .region-4 .arrow-line {
  stroke: var(--region-purple);
}

.tile.tutorial-target .arrow-line {
  stroke: var(--region-green);
  marker-end: url(#hint-head);
  filter:
    drop-shadow(0 0 0.1px rgba(15, 168, 115, 0.95))
    drop-shadow(0 0 0.35px rgba(15, 168, 115, 0.75));
  animation: tutorial-line-pulse 820ms ease-in-out infinite;
}

.tile.blocked .arrow-line {
  stroke: var(--blocked);
  marker-end: url(#blocked-head);
  animation: blocked-flash 140ms steps(2, jump-none) 6;
}

@media (hover: hover) {
  .tile:hover .arrow-line {
    stroke: var(--hover);
    marker-end: url(#hover-head);
    filter: drop-shadow(0 0 0.08px rgba(111, 143, 98, 0.9)) drop-shadow(0 0 0.22px rgba(111, 143, 98, 0.65));
    animation: hover-glow 760ms ease-in-out infinite;
  }
}

.tile.exiting {
  pointer-events: none;
  filter: drop-shadow(0 1px 1px rgba(52, 33, 13, 0.25));
}

.tile.unstoppable .arrow-line {
  stroke: #111111 !important;
  filter:
    drop-shadow(0 0 0.08px rgba(11, 17, 17, 0.95))
    drop-shadow(0 0 0.28px rgba(255, 215, 0, 0.9));
}

.bottom-panel {
  position: relative;
  display: grid;
  grid-template-rows: minmax(64px, 0.8fr) 1fr;
  height: var(--bottom-height);
  border-top: 2px solid var(--bar-line);
  background:
    linear-gradient(180deg, rgba(244, 223, 178, 0.9), rgba(213, 178, 111, 0.72)),
    var(--bar);
}

.flame-icon {
  filter: drop-shadow(0 2px 3px rgba(122, 55, 8, 0.2));
  transform-origin: 50% 76%;
}

.coin-icon {
  filter: drop-shadow(0 2px 3px rgba(120, 69, 9, 0.2));
  transform-origin: 50% 70%;
}

.tool-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 3.4vw, 32px);
  padding: 0 10px;
  transform: translateY(-28px);
  z-index: 2;
}

.round-tool {
  position: relative;
  display: grid;
  width: clamp(58px, 16vw, 86px);
  height: clamp(58px, 16vw, 86px);
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 24%, #fffefa 0 18%, #fff3d8 58%, #e7bd68 100%);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.75),
    inset 0 -5px 9px rgba(166, 99, 20, 0.12),
    0 4px 12px rgba(93, 59, 20, 0.24);
  color: #6f4a18;
  font-size: 42px;
  overflow: visible;
  transition: transform 120ms ease, box-shadow 120ms ease;
}

.round-tool[aria-pressed="true"] {
  background:
    radial-gradient(circle at 34% 24%, #fffefa 0 18%, #ffe9aa 58%, #db9a28 100%);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.82),
    inset 0 -5px 9px rgba(136, 82, 15, 0.18),
    0 0 0 3px rgba(137, 87, 10, 0.18),
    0 5px 13px rgba(93, 59, 20, 0.26);
}

.round-tool.armed {
  background:
    radial-gradient(circle at 34% 24%, #555555 0 18%, #222222 58%, #000000 100%);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.4),
    inset 0 -5px 9px rgba(0, 0, 0, 0.6),
    0 0 0 3px #ffd700,
    0 5px 15px rgba(255, 215, 0, 0.4);
  transform: scale(1.04);
}

.round-tool:active {
  transform: translateY(2px) scale(0.98);
  box-shadow:
    inset 0 2px 8px rgba(111, 69, 18, 0.16),
    0 2px 6px rgba(93, 59, 20, 0.18);
}

.tool-icon {
  display: block;
  width: 72%;
  height: 72%;
  object-fit: contain;
  pointer-events: none;
}

.tool-icon-levels,
.tool-icon-unstoppable-arrow {
  width: 70%;
  height: 70%;
}

.tool-icon-hint {
  width: 78%;
  height: 78%;
}

.tool-icon-backpack {
  width: 76%;
  height: 76%;
  transform: translateY(1px);
}

.tool-symbol {
  position: relative;
  display: block;
  width: 34px;
  height: 34px;
}

.grid-symbol {
  border: 3px solid #755426;
  background:
    linear-gradient(90deg, transparent 30%, #755426 30% 38%, transparent 38% 62%, #755426 62% 70%, transparent 70%),
    linear-gradient(0deg, transparent 30%, #755426 30% 38%, transparent 38% 62%, #755426 62% 70%, transparent 70%);
}

.zoom-symbol::before,
.zoom-symbol::after,
.zoom-mark,
.zoom-mark::after {
  content: "";
  position: absolute;
  display: block;
}

.zoom-symbol::before {
  left: 1px;
  top: 1px;
  width: 22px;
  height: 22px;
  border: 4px solid #755426;
  border-radius: 50%;
}

.zoom-symbol::after {
  right: 1px;
  bottom: 4px;
  width: 14px;
  height: 4px;
  border-radius: 4px;
  background: #755426;
  transform: rotate(45deg);
}

.zoom-mark {
  left: 10px;
  top: 12px;
  width: 10px;
  height: 4px;
  border-radius: 4px;
  background: #755426;
  z-index: 1;
}

.zoom-symbol.is-plus .zoom-mark::after {
  right: auto;
  bottom: auto;
  left: 3px;
  top: -3px;
  width: 4px;
  height: 10px;
  border-radius: 4px;
  background: #755426;
}

.hint-badge {
  position: absolute;
  right: -3px;
  top: -5px;
  display: grid;
  min-width: 22px;
  height: 22px;
  place-items: center;
  padding: 0 5px;
  border: 2px solid #fff4d7;
  border-radius: 999px;
  background: #df2929;
  color: white;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  overflow: hidden;
  perspective: 90px;
  z-index: 2;
}

.hint-badge span {
  display: block;
  min-width: 1ch;
}

.hint-badge.is-flipping span {
  animation: badge-slot-flip 620ms cubic-bezier(0.18, 0.9, 0.25, 1.18);
  transform-origin: 50% 100%;
}

.status-line {
  align-self: start;
  margin: 0;
  color: #89570a;
  font-size: clamp(24px, 7vw, 44px);
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
}

.mobile-game.is-tutorial-prompt .status-line {
  color: #0f8f5e;
  text-shadow:
    0 0 10px rgba(15, 143, 94, 0.32),
    0 2px 0 rgba(255, 244, 215, 0.84);
  animation: tutorial-status-flash 880ms ease-in-out infinite;
}

.modal-backdrop,
.sheet-backdrop {
  position: fixed;
  z-index: 20;
  inset: 0;
  display: grid;
  place-items: end center;
  background: rgba(60, 38, 12, 0.24);
}

.modal,
.level-sheet,
.settings-sheet,
.backpack-sheet,
.info-sheet {
  width: var(--game-width);
  border-radius: 14px 14px 0 0;
  background: #f6ecd8;
  box-shadow: 0 -8px 20px rgba(84, 54, 16, 0.18);
}

.modal {
  display: grid;
  gap: 14px;
  padding: 22px 18px 20px;
  text-align: center;
}

.modal-solved {
  gap: 12px;
  padding: 18px 16px calc(24px + env(safe-area-inset-bottom, 0px));
  border-radius: 0;
  height: 100svh;
  max-height: 100svh;
  overflow: auto;
  background:
    radial-gradient(circle at 50% -16%, rgba(255, 244, 162, 0.84), rgba(255, 244, 162, 0) 38%),
    linear-gradient(180deg, #fffaf0 0%, #f5e8cf 100%);
  box-shadow:
    0 -12px 30px rgba(75, 48, 18, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.modal-out {
  gap: 10px;
  padding: 24px 20px 14px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 249, 237, 0.96), rgba(255, 249, 237, 0) 44%),
    linear-gradient(180deg, #fffdf9 0%, #fbf2df 100%);
}

.bow-backdrop {
  background: rgba(24, 18, 12, 0.58);
  backdrop-filter: blur(8px) saturate(0.88);
}

.modal-bow-select {
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 0;
  height: 100dvh;
  max-height: 100dvh;
  padding: max(20px, env(safe-area-inset-top, 0px)) 14px 0;
  overflow: hidden;
  border-radius: 0;
  background:
    radial-gradient(circle at 50% -10%, rgba(255, 224, 130, 0.5), transparent 32%),
    linear-gradient(180deg, #fff9eb 0%, #f1dfbd 100%);
  box-shadow: 0 -18px 48px rgba(22, 14, 5, 0.36);
  text-align: left;
}

.bow-select-head {
  position: relative;
  padding: 4px 6px 18px;
  text-align: center;
}

.bow-close-button {
  position: absolute;
  top: -8px;
  right: -2px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(87, 61, 31, 0.1);
  color: #5c462e;
  font-size: 25px;
  font-weight: 700;
}

.bow-close-button:focus-visible {
  outline: 3px solid #176ee8;
  outline-offset: 2px;
}

.modal-bow-select .bow-select-head h2 {
  color: #20170d;
  font-family: var(--display-font);
  font-size: 30px;
  line-height: 1.05;
  letter-spacing: 0;
}

.modal-bow-select .bow-select-head p {
  max-width: 360px;
  margin: 8px auto 0;
  color: #72583a;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
}

.bow-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  align-content: start;
  padding: 2px 2px 18px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(104, 72, 33, 0.34) transparent;
}

.bow-card {
  position: relative;
  display: grid;
  grid-template-rows: 92px 1fr auto;
  min-width: 0;
  min-height: 218px;
  padding: 8px 9px 10px;
  overflow: hidden;
  border: 1px solid rgba(106, 73, 32, 0.17);
  border-radius: 8px;
  background: rgba(255, 253, 247, 0.84);
  box-shadow:
    0 3px 0 rgba(91, 61, 26, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #2a2015;
  text-align: left;
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.bow-card.is-selected {
  border-color: #0b8c74;
  box-shadow:
    0 0 0 2px rgba(11, 140, 116, 0.16),
    0 5px 0 rgba(8, 103, 87, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  transform: translateY(-2px);
}

.bow-card.is-locked {
  filter: grayscale(0.72);
  opacity: 0.66;
  cursor: not-allowed;
}

.bow-card:focus-visible {
  outline: 3px solid #176ee8;
  outline-offset: 2px;
}

.bow-art {
  display: grid;
  place-items: center;
  min-width: 0;
  border-radius: 6px;
  background:
    radial-gradient(circle, rgba(255, 232, 169, 0.7), rgba(247, 226, 184, 0.12) 70%);
}

.bow-art img {
  width: 100%;
  height: 88px;
  object-fit: contain;
  filter: drop-shadow(0 5px 4px rgba(64, 40, 12, 0.2));
}

.bow-card-copy {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding-top: 6px;
}

.bow-card-copy strong {
  padding-right: 20px;
  color: #23190e;
  font-size: 16px;
  font-weight: 950;
  line-height: 1.15;
}

.bow-effect,
.bow-requirement {
  overflow-wrap: anywhere;
  letter-spacing: 0;
}

.bow-effect {
  color: #66533d;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.32;
}

.bow-requirement {
  color: #98620d;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.25;
}

.bow-card.is-selected .bow-requirement {
  color: #087765;
}

.bow-card-status {
  position: absolute;
  top: 8px;
  right: 8px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(58, 44, 28, 0.1);
  color: #5f4b35;
  font-size: 15px;
  font-weight: 950;
}

.bow-card.is-selected .bow-card-status {
  background: #0b8c74;
  color: #fff;
}

.bow-progress {
  align-self: end;
  height: 4px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 2px;
  background: rgba(93, 69, 41, 0.13);
}

.bow-progress i {
  display: block;
  width: calc(var(--bow-progress) * 100%);
  height: 100%;
  border-radius: inherit;
  background: #d99a20;
}

.bow-start-bar {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.4fr);
  gap: 10px;
  align-items: center;
  margin-inline: -14px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(97, 67, 30, 0.15);
  background: rgba(255, 249, 235, 0.96);
  box-shadow: 0 -8px 24px rgba(60, 38, 13, 0.1);
}

.bow-current {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 5px;
  align-items: center;
  min-width: 0;
}

.bow-current img {
  width: 48px;
  height: 42px;
  object-fit: contain;
}

.bow-current span {
  overflow-wrap: anywhere;
  color: #3b2a18;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.15;
}

.modal-bow-select .bow-start-button {
  min-width: 0;
  min-height: 48px;
  padding: 8px 12px;
  border-radius: 8px;
  background: linear-gradient(180deg, #13a287, #087563);
  box-shadow:
    0 5px 0 rgba(4, 78, 67, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.26);
  color: #fff;
  font-size: 14px;
  font-weight: 950;
  line-height: 1.15;
}

@media (hover: hover) {
  .bow-card:not(:disabled):hover {
    border-color: rgba(11, 140, 116, 0.56);
    transform: translateY(-2px);
  }
}

@media (max-width: 370px) {
  .bow-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .bow-card {
    grid-template-columns: 104px minmax(0, 1fr);
    grid-template-rows: auto auto;
    min-height: 142px;
  }

  .bow-art {
    grid-row: 1 / -1;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .bow-backdrop {
    background: #493723;
    backdrop-filter: none;
  }
}

.modal h2,
.modal p {
  margin: 0;
}

.modal h2 {
  color: #171c24;
  font-size: clamp(26px, 7vw, 31px);
  font-weight: 950;
  line-height: 1.05;
}

.modal > p:not(.modal-copy):not(.share-notice) {
  color: #89570a;
  font-size: 20px;
  font-weight: 900;
}

.settlement-head {
  display: grid;
  justify-items: center;
  gap: 5px;
}

.settlement-head p {
  color: #2a1c11;
  font-size: 21px;
  font-weight: 950;
  line-height: 1.05;
}

.settlement-medal {
  position: relative;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 22%, #fffef6 0 16%, #ffe26b 42%, #e38b14 73%, #9a4c05 100%);
  box-shadow:
    0 9px 18px rgba(156, 88, 9, 0.26),
    inset 0 2px 0 rgba(255, 255, 255, 0.78);
}

.settlement-medal::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid rgba(207, 139, 28, 0.2);
  background: radial-gradient(circle, rgba(255, 222, 92, 0.28), rgba(255, 222, 92, 0) 62%);
  pointer-events: none;
}

.settlement-medal span {
  width: 27px;
  height: 27px;
  clip-path: polygon(50% 0, 61% 36%, 100% 36%, 68% 58%, 80% 100%, 50% 75%, 20% 100%, 32% 58%, 0 36%, 39% 36%);
  background: #fff9d5;
  filter: drop-shadow(0 2px 0 rgba(127, 66, 6, 0.28));
}

.settlement-reward {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  min-height: 72px;
  padding: 12px 14px;
  border: 1px solid rgba(194, 119, 10, 0.22);
  border-radius: 12px;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 243, 0.88), rgba(255, 255, 243, 0) 33%),
    linear-gradient(180deg, #ffdf62 0%, #ffb62c 100%);
  color: #8a3100;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.76),
    0 8px 18px rgba(178, 88, 0, 0.22);
}

.boss-chest-reward {
  display: flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 9px 13px;
  border: 1px solid rgba(103, 51, 17, 0.24);
  border-radius: 11px;
  background: linear-gradient(180deg, #fff0b0, #e9bd55);
  color: #64340e;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  font-weight: 950;
}

.boss-chest-icon {
  position: relative;
  display: block;
  width: 34px;
  height: 25px;
  border: 2px solid #6c3514;
  border-radius: 5px 5px 7px 7px;
  background: linear-gradient(180deg, #c85b2b 0 43%, #f2a629 43% 58%, #a84222 58%);
  box-shadow: inset 0 2px 0 rgba(255, 238, 169, 0.34);
}

.boss-chest-icon::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 8px;
  width: 7px;
  height: 8px;
  border: 1px solid #6c3514;
  border-radius: 2px;
  background: #ffe271;
}

.settlement-coin {
  width: 42px;
  height: 42px;
  filter: drop-shadow(0 4px 5px rgba(112, 61, 0, 0.2));
}

.settlement-combo {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 62px;
  padding: 11px 14px;
  border: 1px solid rgba(180, 54, 18, 0.24);
  border-radius: 12px;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 244, 210, 0.9), rgba(255, 244, 210, 0) 34%),
    linear-gradient(180deg, rgba(255, 164, 80, 0.98), rgba(205, 50, 24, 0.9));
  color: #7d1d00;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.74),
    0 8px 18px rgba(153, 42, 6, 0.18);
}

.settlement-combo-flame {
  --flame-duration: 760ms;
  display: block;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  background: url("./combo-flame-burn-sprite.004a5bda8e.webp") 0 0 / auto 100% no-repeat;
  filter: drop-shadow(0 4px 6px rgba(93, 22, 0, 0.22));
  transform-origin: center bottom;
}

.settlement-combo-copy {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.settlement-combo-copy span,
.settlement-combo-copy strong {
  display: block;
  line-height: 1;
  overflow-wrap: anywhere;
}

.settlement-combo-copy span {
  font-size: clamp(20px, 6.2vw, 30px);
  font-weight: 950;
}

.settlement-combo-copy strong {
  color: #fff0ba;
  font-size: clamp(14px, 4vw, 18px);
  font-weight: 950;
  text-shadow:
    0 1px 0 rgba(101, 22, 0, 0.5),
    0 2px 6px rgba(88, 17, 0, 0.22);
}

.combo-reward-tier-1 {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 246, 220, 0.9), rgba(255, 246, 220, 0) 34%),
    linear-gradient(180deg, rgba(255, 218, 174, 0.98), rgba(220, 102, 50, 0.82));
}

.combo-reward-tier-1 .settlement-combo-flame {
  filter: drop-shadow(0 4px 6px rgba(93, 22, 0, 0.18)) saturate(0.8);
}

.combo-reward-tier-2 .settlement-combo-flame {
  animation: flame-burn-sheet 760ms steps(8) infinite;
  filter: drop-shadow(0 0 6px rgba(255, 126, 21, 0.6));
}

.combo-reward-tier-3 {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 238, 192, 0.92), rgba(255, 238, 192, 0) 34%),
    linear-gradient(180deg, rgba(255, 139, 62, 1), rgba(196, 38, 20, 0.94));
}

.combo-reward-tier-3 .settlement-combo-flame {
  animation: flame-burn-sheet 540ms steps(8) infinite;
  filter: drop-shadow(0 0 8px rgba(255, 99, 15, 0.72));
}

.combo-reward-tier-4 {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 235, 176, 0.96), rgba(255, 235, 176, 0) 33%),
    linear-gradient(180deg, rgba(255, 113, 50, 1), rgba(170, 28, 18, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 0 16px rgba(234, 83, 22, 0.28),
    0 8px 18px rgba(153, 42, 6, 0.2);
}

.combo-reward-tier-4 .settlement-combo-flame {
  animation: flame-burn-sheet 390ms steps(8) infinite;
  filter: drop-shadow(0 0 10px rgba(255, 82, 12, 0.84));
}

.combo-reward-tier-5 {
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 243, 174, 1), rgba(255, 243, 174, 0) 32%),
    linear-gradient(180deg, #ff6434 0%, #9d160d 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    0 0 18px rgba(246, 72, 19, 0.36),
    0 8px 20px rgba(144, 28, 6, 0.24);
}

.combo-reward-tier-5 .settlement-combo-flame {
  animation: flame-burn-sheet 260ms steps(8) infinite;
  filter: drop-shadow(0 0 11px rgba(255, 72, 10, 0.9));
}

.reward-toast-card.combo-reward-tier-1 {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(255, 246, 220, 0.72), rgba(255, 246, 220, 0) 29%),
    linear-gradient(180deg, rgba(255, 218, 174, 0.98), rgba(220, 102, 50, 0.86));
}

.reward-toast-card.combo-reward-tier-2 {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(255, 242, 203, 0.72), rgba(255, 242, 203, 0) 29%),
    linear-gradient(180deg, rgba(255, 182, 112, 0.98), rgba(210, 66, 33, 0.9));
}

.reward-toast-card.combo-reward-tier-3 {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(255, 238, 192, 0.66), rgba(255, 238, 192, 0) 28%),
    linear-gradient(180deg, rgba(255, 139, 62, 1), rgba(196, 38, 20, 0.94));
}

.reward-toast-card.combo-reward-tier-4 {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(255, 235, 176, 0.6), rgba(255, 235, 176, 0) 27%),
    linear-gradient(180deg, rgba(255, 113, 50, 1), rgba(170, 28, 18, 0.96));
}

.reward-toast-card.combo-reward-tier-5 {
  background:
    radial-gradient(ellipse at 12% 8%, rgba(255, 243, 174, 0.55), rgba(255, 243, 174, 0) 27%),
    linear-gradient(180deg, #ff6434 0%, #9d160d 100%);
}

.modal-copy {
  max-width: 360px;
  justify-self: center;
  color: #5f6877;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.45;
}

.result-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #5f4019;
  font-size: 13px;
  font-weight: 900;
}

.result-strip.has-combo-multiplier {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.result-strip span,
.result-strip strong {
  display: inline-flex;
  min-width: 0;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid rgba(139, 101, 49, 0.14);
  border-radius: 11px;
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 255, 251, 0.82), rgba(255, 255, 251, 0) 44%),
    linear-gradient(180deg, rgba(255, 247, 226, 0.96), rgba(230, 207, 163, 0.86));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.68),
    0 4px 10px rgba(88, 56, 17, 0.1);
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.result-strip strong {
  color: #0f8f5e;
}

.result-icon {
  position: relative;
  display: block;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  border-radius: 50%;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.74),
    0 3px 6px rgba(83, 50, 12, 0.14);
}

.result-icon-multiplier::before,
.result-icon-multiplier::after {
  content: "";
  position: absolute;
  display: block;
}

.result-icon-coin {
  background: url("./icon-coin-generated.6fcac07a31.webp") center / contain no-repeat;
  box-shadow: 0 3px 6px rgba(83, 50, 12, 0.14);
}

.result-icon-multiplier {
  background: radial-gradient(circle at 35% 22%, #fffdf0 0 16%, #aef9e0 46%, #0e987f 100%);
}

.result-icon-multiplier::before {
  width: 13px;
  height: 13px;
  left: 5px;
  top: 5px;
  clip-path: polygon(50% 0, 62% 34%, 100% 50%, 62% 66%, 50% 100%, 38% 66%, 0 50%, 38% 34%);
  background: #fff;
}

.result-icon-multiplier::after {
  width: 7px;
  height: 7px;
  right: 4px;
  bottom: 4px;
  clip-path: polygon(50% 0, 62% 34%, 100% 50%, 62% 66%, 50% 100%, 38% 66%, 0 50%, 38% 34%);
  background: #f5fff8;
  opacity: 0.86;
}

.result-card-base {
  color: #7c4f0a;
}

.result-card-multiplier {
  color: #078468;
  background:
    radial-gradient(circle at 24% 18%, rgba(239, 255, 248, 0.88), rgba(239, 255, 248, 0) 45%),
    linear-gradient(180deg, rgba(226, 255, 245, 0.96), rgba(188, 231, 212, 0.9));
}

.reward-coins {
  position: relative;
  overflow: hidden;
  justify-self: stretch;
  color: #8b3300;
  font-size: clamp(26px, 8.5vw, 34px);
  line-height: 1;
  text-align: left;
}

.reward-coins-roll {
  animation: reward-coin-slot 1300ms cubic-bezier(0.17, 0.84, 0.32, 1) both;
}

.reward-coins-roll.is-settled {
  animation: reward-coin-settle 260ms ease-out both;
}

.combo-multiplier {
  color: #c14d00;
}

.share-heading {
  margin-top: 6px;
  color: #151922;
  font-size: 16px;
  font-weight: 950;
}

.share-buttons {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.share-buttons button {
  min-height: 43px;
  border-radius: 7px;
  color: white;
  font-size: 15px;
  font-weight: 950;
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.14);
}

.share-x,
.share-douyin {
  background: #111820;
}

.share-facebook {
  background: #2d62bf;
}

.share-reddit {
  background: #df4928;
}

.share-telegram {
  background: #2c8fc7;
}

.share-wechat {
  background: #08bf6f;
}

.share-rednote {
  background: #ff2f4f;
}

.share-kuaishou {
  background: #ff7146;
}

.share-notice {
  margin: 2px 0 -2px;
  color: #0a8b74;
  font-size: 16px;
  font-weight: 950;
  line-height: 1.3;
}

.modal-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  color: #6d7480;
  font-size: 14px;
  font-weight: 950;
}

.modal-divider::before,
.modal-divider::after {
  content: "";
  height: 1px;
  background: rgba(116, 100, 78, 0.22);
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.modal-solved .modal-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

.out-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.out-actions .continue-button:only-child,
.out-actions .restart-button:only-child {
  grid-column: 1 / -1;
}

.modal-actions button,
.sheet-head button {
  min-width: 92px;
  min-height: 38px;
  border-radius: 7px;
  background: #ead8b3;
  color: #6f4a18;
  font-weight: 800;
}

.modal-actions button {
  min-height: 46px;
  box-shadow: 0 5px 0 rgba(113, 83, 34, 0.18);
}

.modal-solved .modal-actions button {
  min-width: 0;
  min-height: 50px;
  border: 1px solid rgba(126, 87, 34, 0.13);
  border-radius: 9px;
  background:
    linear-gradient(180deg, rgba(242, 222, 179, 0.98), rgba(221, 196, 145, 0.98));
  box-shadow:
    0 5px 0 rgba(113, 83, 34, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.56);
  color: #684719;
  font-size: 15px;
  font-weight: 950;
}

.modal-actions button:disabled {
  cursor: wait;
  opacity: 0.78;
}

.modal-actions .primary {
  background: #0f8d79;
  color: white;
}

.modal-solved .modal-actions .primary {
  border-color: rgba(0, 101, 89, 0.18);
  background:
    linear-gradient(180deg, #12a88e, #087d6f);
  color: #fff;
  box-shadow:
    0 6px 0 rgba(4, 86, 77, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.24);
}

.out-actions .restart-button {
  background: #ffd24a;
  color: #05070a;
}

.level-sheet {
  max-height: 76svh;
  padding: 14px 12px 18px;
}

.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 10px;
  color: #6f4a18;
}

.sheet-head button {
  min-width: 34px;
  width: 34px;
  border-radius: 999px;
}

.level-pager {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  padding-bottom: 10px;
}

.level-pager button {
  min-height: 36px;
  border-radius: 7px;
  background: #ead8b3;
  color: #6f4a18;
  font-size: 13px;
  font-weight: 900;
}

.level-pager button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
  box-shadow: none;
}

.level-pager span {
  min-width: 68px;
  color: #6f4a18;
  font-size: 14px;
  font-weight: 950;
  text-align: center;
}

.level-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 7px;
  overflow-y: auto;
  max-height: calc(76svh - 108px);
}

.level-grid button {
  display: grid;
  min-height: 44px;
  place-items: center;
  border: 1px solid rgba(144, 102, 46, 0.2);
  border-radius: 8px;
  background: #fbf2df;
  color: #77511e;
}

.level-grid button.is-locked,
.level-grid button:disabled {
  cursor: not-allowed;
  border-color: rgba(130, 118, 99, 0.16);
  background: #e5dccd;
  color: rgba(119, 81, 30, 0.36);
  box-shadow: none;
  opacity: 0.72;
}

.level-grid button.active {
  border-color: #c47c00;
  background: #f9ddb0;
}

.level-grid button.is-boss-level {
  border-color: rgba(121, 49, 34, 0.52);
  background: #f3d0b7;
  color: #6b291e;
  box-shadow: inset 0 -3px 0 rgba(115, 47, 31, 0.12);
}

.level-grid button.is-boss-level.active {
  border-color: #9d351f;
  background: #f3b882;
  box-shadow: 0 0 0 2px rgba(157, 53, 31, 0.16);
}

.level-grid em {
  display: none;
}

.settings-sheet {
  padding: 16px 16px 18px;
}

.backpack-sheet {
  max-height: 82svh;
  overflow: auto;
  padding: 16px 16px 18px;
}

.backpack-shop {
  display: grid;
  gap: 10px;
}

.bag-shop-head {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6f4a18;
  font-size: 15px;
  font-weight: 950;
  line-height: 1;
}

.settlement-shop {
  padding: 12px;
  border: 1px solid rgba(133, 88, 35, 0.14);
  border-radius: 14px;
  background:
    radial-gradient(circle at 12% 0%, rgba(255, 255, 248, 0.84), rgba(255, 255, 248, 0) 32%),
    linear-gradient(180deg, rgba(255, 250, 238, 0.88), rgba(239, 221, 183, 0.66));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.62),
    0 5px 14px rgba(92, 61, 19, 0.08);
}

.bag-summary {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  padding: 4px 0 8px;
}

.bag-summary-old {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.bag-summary-old div {
  display: grid;
  min-height: 60px;
  place-items: center;
  border: 1px solid rgba(133, 88, 35, 0.18);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255, 250, 236, 0.94), rgba(239, 213, 158, 0.78));
  color: #7c5b2b;
  font-size: 13px;
  font-weight: 900;
}

.bag-summary-old strong {
  color: #b97804;
  font-size: 24px;
  line-height: 1;
}

.bag-skill-list {
  display: grid;
  gap: 10px;
}

.settlement-shop-unused .bag-skill-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.bag-skill-list article {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(133, 88, 35, 0.16);
  border-radius: 12px;
  background: rgba(255, 250, 236, 0.74);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

.settlement-shop-unused .bag-skill-list article {
  grid-template-columns: 36px minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 8px;
  align-items: start;
  padding: 10px;
  border-radius: 10px;
}

.settlement-shop-unused .bag-skill-list article .skill-action {
  grid-column: 1 / -1;
  justify-self: stretch;
  max-width: none;
  min-height: 34px;
}

.bag-skill-list article > div {
  min-width: 0;
}

.bag-skill-list article.is-owned {
  border-color: rgba(15, 143, 94, 0.24);
  background:
    linear-gradient(180deg, rgba(246, 255, 248, 0.88), rgba(255, 250, 236, 0.74));
}

.bag-skill-icon {
  position: relative;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 24%, #fffefa 0 15%, #fff0c0 52%, #df9b32 100%);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.8),
    0 5px 12px rgba(91, 56, 16, 0.18);
  color: #6f4a18;
  font-size: 15px;
  font-weight: 950;
  overflow: hidden;
}

.bag-skill-icon::before,
.bag-skill-icon::after,
.bag-skill-icon span,
.bag-skill-icon span::before,
.bag-skill-icon span::after {
  content: "";
  position: absolute;
  display: block;
}

.clover-icon {
  background:
    radial-gradient(circle at 30% 18%, #f8fff5 0 14%, #bdf090 38%, #2d9a4b 76%, #116333 100%);
}

.clover-icon::before,
.clover-icon::after,
.clover-icon span,
.clover-icon span::before {
  width: 15px;
  height: 15px;
  border-radius: 70% 70% 70% 18%;
  background: linear-gradient(145deg, #e9ffd8, #28a451 72%, #116333 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62);
}

.clover-icon::before {
  left: 12px;
  top: 11px;
  transform: rotate(-45deg);
}

.clover-icon::after {
  right: 12px;
  top: 11px;
  transform: rotate(45deg) scaleX(-1);
}

.clover-icon span {
  left: 12px;
  bottom: 12px;
  transform: rotate(-135deg) scaleX(-1);
}

.clover-icon span::before {
  left: 12px;
  top: 0;
  transform: rotate(90deg) scaleX(-1);
}

.clover-icon span::after {
  width: 6px;
  height: 18px;
  left: 16px;
  top: 6px;
  border-radius: 6px;
  background: #16713a;
  transform: rotate(-18deg);
}

.gift-box-icon {
  background:
    radial-gradient(circle at 30% 18%, #fffdf4 0 14%, #ffe488 40%, #d17624 78%, #8c3618 100%);
}

.gift-box-icon::before {
  width: 27px;
  height: 23px;
  left: 11px;
  top: 17px;
  border-radius: 6px;
  background: linear-gradient(180deg, #fff1a8, #df7d29);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.58);
}

.gift-box-icon::after {
  width: 31px;
  height: 8px;
  left: 9px;
  top: 13px;
  border-radius: 5px;
  background: #ffcf54;
}

.gift-box-icon span {
  width: 6px;
  height: 30px;
  left: 21px;
  top: 12px;
  border-radius: 4px;
  background: #d83a25;
}

.gift-box-icon span::before,
.gift-box-icon span::after {
  width: 11px;
  height: 8px;
  top: -2px;
  border: 3px solid #d83a25;
  border-radius: 50%;
  background: transparent;
}

.gift-box-icon span::before {
  left: -12px;
  transform: rotate(-25deg);
}

.gift-box-icon span::after {
  right: -12px;
  transform: rotate(25deg);
}

.combo-spark-icon {
  background:
    radial-gradient(circle at 32% 20%, #fff8db 0 13%, #ffd873 38%, #e9541b 76%, #92270c 100%);
}

.combo-spark-icon::before {
  width: 15px;
  height: 28px;
  left: 16px;
  top: 10px;
  border-radius: 48% 48% 54% 54%;
  background: linear-gradient(180deg, #fff8bd 0 24%, #ffb52f 25% 60%, #d73517 61% 100%);
  transform: rotate(9deg);
}

.combo-spark-icon::after {
  width: 9px;
  height: 18px;
  left: 24px;
  top: 17px;
  border-radius: 50% 50% 54% 54%;
  background: #fff7cf;
  transform: rotate(-15deg);
}

.combo-spark-icon span {
  width: 12px;
  height: 12px;
  left: 11px;
  top: 9px;
  clip-path: polygon(50% 0, 63% 35%, 100% 50%, 63% 65%, 50% 100%, 37% 65%, 0 50%, 37% 35%);
  background: #fff;
}

.chain-hammer-icon {
  background:
    radial-gradient(circle at 30% 20%, #f8fff9 0 14%, #9effd4 36%, #0f9a7d 72%, #095a58 100%);
}

.chain-hammer-icon::before {
  width: 23px;
  height: 13px;
  left: 16px;
  top: 12px;
  border-radius: 5px;
  background: linear-gradient(180deg, #dffef5, #1d7f7e);
  box-shadow: inset 0 -2px 0 rgba(4, 71, 75, 0.38);
  transform: rotate(-18deg);
}

.chain-hammer-icon::after {
  width: 7px;
  height: 25px;
  left: 20px;
  top: 21px;
  border-radius: 4px;
  background: linear-gradient(180deg, #ffd680, #8d5321);
  transform: rotate(-33deg);
  transform-origin: top center;
}

.chain-hammer-icon span {
  width: 17px;
  height: 17px;
  left: 8px;
  top: 10px;
  border: 3px solid rgba(255, 255, 255, 0.92);
  border-right-color: transparent;
  border-radius: 50%;
}

.monument-icon {
  background:
    radial-gradient(circle at 32% 20%, #fffaf0 0 14%, #ffd16e 36%, #aa6b1b 78%, #694313 100%);
}

.monument-icon::before {
  width: 24px;
  height: 28px;
  left: 12px;
  top: 12px;
  clip-path: polygon(50% 0, 86% 18%, 86% 100%, 14% 100%, 14% 18%);
  background: linear-gradient(180deg, #fff1b3, #c0771a 72%, #7b4811 100%);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.55);
}

.monument-icon::after {
  width: 32px;
  height: 6px;
  left: 8px;
  bottom: 8px;
  border-radius: 4px;
  background: #6f4212;
}

.monument-icon span {
  width: 12px;
  height: 12px;
  left: 18px;
  top: 17px;
  clip-path: polygon(50% 0, 61% 37%, 100% 37%, 68% 58%, 79% 96%, 50% 72%, 21% 96%, 32% 58%, 0 37%, 39% 37%);
  background: #fff9dc;
}

.unstoppable-bag-icon {
  background:
    radial-gradient(circle at 32% 20%, #666666 0 14%, #333333 36%, #111111 78%, #000000 100%);
}

.unstoppable-bag-icon::before {
  width: 6px;
  height: 22px;
  left: 21px;
  top: 14px;
  background: linear-gradient(180deg, #ffe680, #d4af37);
  box-shadow: 0 0 4px rgba(255, 215, 0, 0.6);
  border-radius: 2px;
}

.unstoppable-bag-icon::after {
  width: 12px;
  height: 10px;
  left: 18px;
  top: 8px;
  clip-path: polygon(50% 0, 0 100%, 100% 100%);
  background: #ffe680;
}

.unstoppable-bag-icon span {
  width: 12px;
  height: 12px;
  left: 8px;
  top: 12px;
  background: #ea4335;
  clip-path: polygon(0 0, 100% 30%, 70% 100%, 0% 70%);
  transform: rotate(-15deg);
}

.unstoppable-bag-icon span::before {
  width: 12px;
  height: 12px;
  left: 20px;
  top: -4px;
  background: #ea4335;
  clip-path: polygon(30% 0, 100% 20%, 80% 100%, 0 80%);
  transform: rotate(25deg);
}

.reward-toast-icon-unstoppable {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 2px 2px rgba(72, 22, 0, 0.28));
  overflow: visible;
}

.reward-toast-icon-unstoppable img {
  display: block;
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.shield-card-icon {
  background:
    radial-gradient(circle at 32% 18%, #fbfffb 0 14%, #caffea 38%, #13a07f 75%, #07595a 100%);
}

.shield-card-icon::before {
  width: 24px;
  height: 28px;
  left: 12px;
  top: 10px;
  clip-path: polygon(50% 0, 88% 18%, 78% 70%, 50% 100%, 22% 70%, 12% 18%);
  background: linear-gradient(135deg, #ffffff 0 18%, #8df8d0 19% 48%, #0b706d 49% 100%);
  box-shadow: inset 0 -2px 0 rgba(0, 68, 68, 0.4);
}

.shield-card-icon::after {
  width: 9px;
  height: 16px;
  left: 20px;
  top: 15px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.74);
}

.bag-skill-list strong {
  display: block;
  color: #6f4a18;
  font-size: 16px;
  font-weight: 950;
  overflow-wrap: break-word;
}

.bag-skill-title {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.skill-level-badge,
.item-count-badge {
  flex: 0 0 auto;
  padding: 3px 6px;
  border: 1px solid rgba(15, 141, 121, 0.24);
  border-radius: 999px;
  background: rgba(15, 141, 121, 0.1);
  color: #0e766a;
  font-size: 11px;
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.item-count-badge {
  border-color: rgba(185, 120, 4, 0.24);
  background: rgba(185, 120, 4, 0.1);
  color: #9a6508;
}

.bag-skill-list p {
  margin: 4px 0 0;
  color: #7b623c;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: break-word;
}

.bag-intro {
  margin: 10px 2px 12px;
  color: #7b623c;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.skill-action {
  justify-self: end;
  min-width: 74px;
  max-width: 104px;
  min-height: 40px;
  padding: 0 10px;
  border-radius: 8px;
  background: #0f8d79;
  color: white;
  box-shadow: 0 4px 0 rgba(113, 83, 34, 0.18);
  font-size: 13px;
  font-weight: 950;
  line-height: 1.05;
  text-align: center;
  white-space: normal;
}

.skill-action:disabled {
  cursor: default;
  border-color: rgba(116, 106, 92, 0.18);
  background: #d6d1c8;
  color: #756b60;
  box-shadow: none;
  opacity: 0.86;
}

.settlement-shop-unused .bag-skill-icon {
  width: 36px;
  height: 36px;
}

.info-sheet {
  max-height: 84svh;
  overflow: auto;
  padding: 16px;
}

.settings-list {
  display: grid;
  gap: 10px;
}

.settings-row {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  border: 1px solid rgba(133, 88, 35, 0.18);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255, 250, 236, 0.92), rgba(239, 213, 158, 0.78));
  color: #6f4a18;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
  font-size: 18px;
  font-weight: 900;
}

.settings-row strong {
  color: #b97804;
  font-size: 17px;
  font-weight: 900;
}

.language-menu {
  display: none;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 8px;
}

.language-menu.is-open {
  display: grid;
}

.language-menu button {
  min-height: 48px;
  border: 1px solid rgba(133, 88, 35, 0.2);
  border-radius: 12px;
  background: #fbf2df;
  color: #70501f;
  font-size: 15px;
  font-weight: 900;
}

.language-menu button.active {
  border-color: rgba(183, 126, 22, 0.68);
  background: linear-gradient(180deg, #ffd976, #e9a927);
  color: #5a3711;
  box-shadow: 0 3px 8px rgba(112, 72, 21, 0.16);
}

.volume-row {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 12px;
  align-items: center;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid rgba(133, 88, 35, 0.16);
  border-radius: 12px;
  background: rgba(255, 250, 236, 0.68);
  color: #6f4a18;
  font-weight: 900;
}

.volume-row input {
  width: 100%;
  accent-color: #b97804;
}

.seo-content {
  width: 100%;
  padding: 34px 14px 48px;
  background:
    radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.3), transparent 34%),
    linear-gradient(180deg, #ead8b3, #f5ead2 22%, #ead3a3);
}

.info-panel[hidden] {
  display: none;
}

.info-copy .seo-content,
.info-copy.seo-content {
  padding: 0;
  background: transparent;
}

.info-copy .seo-inner {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.info-copy .seo-grid {
  grid-template-columns: 1fr;
}

.info-copy .seo-content h1,
.info-copy h1 {
  font-size: 30px;
}

.info-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid rgba(127, 86, 33, 0.16);
}

.info-legal-links a {
  min-height: 36px;
  padding: 8px 12px;
  border: 1px solid rgba(127, 86, 33, 0.18);
  border-radius: 7px;
  background: rgba(255, 252, 244, 0.72);
  color: #7f5209;
  font-size: 14px;
  font-weight: 900;
}

.seo-inner {
  width: min(860px, 100%);
  margin: 0 auto;
  padding: 26px;
  border: 1px solid rgba(127, 86, 33, 0.16);
  border-radius: 14px;
  background: rgba(255, 249, 236, 0.78);
  box-shadow: 0 12px 28px rgba(91, 59, 19, 0.12);
}

.seo-content h1,
.seo-content h2,
.seo-content h3 {
  color: #6f4a18;
}

.seo-content h1 {
  margin: 4px 0 12px;
  font-size: clamp(30px, 6vw, 48px);
  line-height: 1.05;
}

.seo-content h2 {
  margin: 28px 0 10px;
  font-size: clamp(22px, 4vw, 30px);
}

.seo-content h3 {
  margin: 18px 0 6px;
  font-size: 18px;
}

.seo-lead {
  max-width: 680px;
  margin: 0;
  color: #6b4e27;
  font-size: 18px;
  line-height: 1.75;
}

.seo-content p,
.seo-content li {
  color: #6b4e27;
  line-height: 1.78;
}

.seo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.seo-card {
  padding: 16px;
  border: 1px solid rgba(127, 86, 33, 0.14);
  border-radius: 10px;
  background: rgba(255, 252, 244, 0.72);
}

.seo-card p {
  margin-bottom: 0;
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-list details {
  border: 1px solid rgba(127, 86, 33, 0.14);
  border-radius: 10px;
  background: rgba(255, 252, 244, 0.7);
}

.faq-list summary {
  cursor: pointer;
  padding: 13px 15px;
  color: #6f4a18;
  font-weight: 900;
}

.faq-list details p {
  margin: 0;
  padding: 0 15px 14px;
}

.seo-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.seo-links a {
  color: #7f5209;
  font-weight: 900;
}

.site-header,
.site-footer {
  display: none;
}

.legal-page {
  overflow: auto;
  background: var(--bg);
}

.legal-page .site-header,
.legal-page .site-footer {
  display: flex;
  width: min(860px, calc(100% - 28px));
  margin: 0 auto;
}

.legal-page .site-header {
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 0 10px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 900;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: white;
}

.language-switcher {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.language-switcher a {
  color: var(--ink);
}

.legal-shell {
  width: min(860px, calc(100% - 28px));
  margin: 12px auto 24px;
  padding: 24px;
  border-radius: 10px;
  background: rgba(255, 249, 236, 0.78);
}

.legal-shell h1 {
  margin: 4px 0 12px;
}

.legal-shell p,
.legal-shell li {
  line-height: 1.75;
}

.eyebrow {
  margin: 0;
  color: #c47c00;
  font-weight: 900;
}

.legal-page .site-footer {
  justify-content: space-between;
  padding: 8px 0 22px;
}

.legal-page .site-footer nav {
  display: flex;
  gap: 12px;
}

@keyframes badge-slot-flip {
  0% {
    opacity: 0.52;
    transform: translateY(-85%) rotateX(72deg);
  }
  48% {
    opacity: 1;
    transform: translateY(8%) rotateX(-12deg);
  }
  72% {
    transform: translateY(-3%) rotateX(6deg);
  }
  100% {
    opacity: 1;
    transform: translateY(0) rotateX(0);
  }
}

@keyframes blocked-flash {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.18;
  }
}

@keyframes hover-glow {
  0%, 100% {
    opacity: 0.72;
  }
  50% {
    opacity: 1;
  }
}

@keyframes hand-tap {
  0%, 100% {
    transform: translate(-18%, -12%) scale(1);
  }
  50% {
    transform: translate(-18%, -12%) scale(0.88);
  }
}

@keyframes tutorial-line-pulse {
  0%, 100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

@keyframes tutorial-status-flash {
  0%, 100% {
    transform: scale(1);
    opacity: 0.9;
  }
  50% {
    transform: scale(1.045);
    opacity: 1;
  }
}

@keyframes clear-pulse {
  0%, 100% {
    color: #89570a;
  }
  50% {
    color: #0f8f5e;
  }
}

@keyframes clear-wash {
  0%, 100% {
    background: transparent;
  }
  50% {
    background: rgba(135, 218, 125, 0.18);
  }
}

@keyframes flame-burn-sheet {
  to {
    background-position: var(--flame-strip-offset) 0;
  }
}

@keyframes combo-number-pop {
  0% {
    transform: translateY(0) scale(0.98);
  }
  48% {
    transform: translateY(-2px) scale(1.04);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}

@keyframes coin-hop {
  0% {
    transform: translateY(0) scale(1);
  }
  34% {
    transform: translateY(-5px) scale(1.03) rotate(-3deg);
  }
  64% {
    transform: translateY(0) scale(0.995) rotate(1.5deg);
  }
  100% {
    transform: translateY(0) scale(1) rotate(0);
  }
}

@keyframes coin-number-pop {
  0% {
    transform: scale(0.99);
  }
  42% {
    transform: scale(1.04);
    color: #c36a00;
  }
  100% {
    transform: scale(1);
  }
}

@keyframes coin-gain-float {
  0% {
    transform: translateY(3px) scale(0.84);
    opacity: 0;
  }
  18% {
    transform: translateY(-3px) scale(1.08);
    opacity: 1;
  }
  68% {
    transform: translateY(-5px) scale(1);
    opacity: 1;
  }
  100% {
    transform: translateY(-10px) scale(0.96);
    opacity: 0;
  }
}

@keyframes reward-pop {
  0% {
    transform: scale(0.86);
    opacity: 0.35;
  }
  48% {
    transform: scale(1.06);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes reward-coin-slot {
  0% {
    transform: translateY(4px) scale(0.96);
    filter: blur(0.3px) saturate(1.08);
  }
  20% {
    transform: translateY(-2px) scale(1.04);
    filter: blur(0.8px) saturate(1.3);
  }
  72% {
    transform: translateY(1px) scale(1.02);
    filter: blur(0.35px) saturate(1.18);
  }
  100% {
    transform: translateY(0) scale(1);
    filter: blur(0) saturate(1);
  }
}

@keyframes reward-coin-settle {
  0% {
    transform: scale(1);
  }
  46% {
    transform: scale(1.08);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes board-loader-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reward-toast-icon-combo::before,
  .wallet-coin-roll {
    animation: none;
  }
}

/* Challenge center, run building, and special-stage HUDs */
.rule-progress {
  position: absolute;
  z-index: 4;
  top: 8px;
  left: 50%;
  display: flex;
  width: min(calc(100% - 24px), 420px);
  min-height: 58px;
  padding: 9px 12px;
  align-items: center;
  gap: 10px;
  border: 2px solid #7b5722;
  border-radius: 14px;
  background: #fff4cf;
  color: #35230d;
  box-shadow: 0 4px 0 rgb(84 52 12 / 22%);
  transform: translateX(-50%);
}

.rule-progress-icon { font-size: 28px; }
.rule-progress > span:last-child { display: grid; min-width: 0; }
.rule-progress small { color: #8b5b16; font-size: 10px; font-weight: 800; text-transform: uppercase; }
.rule-progress strong { font-size: 15px; }
.rule-progress em { overflow: hidden; color: #684d25; font-size: 11px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.is-rule-stage .board-wrap.shape-ascii { --ascii-board-size: min(calc(100% - 36px), 330px); top: calc(50% + 30px); }

.boss-buff-choice,
.rule-bonus-reward {
  border: 1px solid #d8b76c;
  border-radius: 14px;
  background: #fff8df;
}

.rule-bonus-reward { display: flex; padding: 8px 12px; align-items: center; justify-content: center; gap: 8px; color: #744c08; }
.boss-buff-choice { margin-block: 10px; padding: 12px; }
.boss-buff-heading h2 { margin: 0; font-size: 18px; }
.boss-buff-heading p { margin: 3px 0 10px; color: #665a43; font-size: 12px; }
.boss-buff-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.boss-buff-grid button { min-height: 112px; padding: 10px 8px; border: 2px solid #ccb06f; border-radius: 12px; background: #fff; color: #302819; text-align: left; }
.boss-buff-grid button:hover { border-color: #9d6a16; background: #fff3c6; }
.boss-buff-grid button:focus-visible { outline: 3px solid #1667a8; outline-offset: 2px; }
.boss-buff-grid strong, .boss-buff-grid span:last-child { display: block; }
.boss-buff-icon { font-size: 24px; }
.boss-buff-grid strong { margin: 5px 0 3px; font-size: 13px; }
.boss-buff-grid span:last-child { color: #665a43; font-size: 11px; line-height: 1.25; }

.challenge-entry-button { display: grid; width: calc(100% - 24px); min-height: 58px; margin: 10px 12px; padding: 9px 12px; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; border: 1px solid #b78b38; border-radius: 14px; background: #fff4cf; color: #3d2b0f; text-align: left; }
.challenge-entry-button > span:first-child { font-size: 25px; }
.challenge-entry-button span:nth-child(2) { display: grid; }
.challenge-entry-button small { color: #755b2e; }
.challenge-entry-button em { font-size: 24px; font-style: normal; }

.challenge-sheet { position: relative; display: flex; width: min(100%, 680px); max-height: min(90dvh, 780px); flex-direction: column; overflow: hidden; border-radius: 22px 22px 0 0; background: #f7f2e7; color: #28231b; }
.challenge-sheet-head {
  flex: 0 0 auto;
  gap: 12px;
  padding: 12px 14px 10px;
}
.challenge-sheet-head span { display: grid; }
.challenge-sheet-head small { color: #706655; font-weight: 500; }
.challenge-sheet-head button {
  width: 44px;
  min-width: 44px;
  min-height: 44px;
  flex: 0 0 44px;
}
.challenge-scroll { overflow-y: auto; padding: 12px 14px calc(22px + env(safe-area-inset-bottom)); overscroll-behavior: contain; }
.daily-card { display: grid; padding: 16px; grid-template-columns: 1fr auto; align-items: center; gap: 14px; border: 2px solid #76551d; border-radius: 18px; background: #fff1bd; box-shadow: 0 4px 0 rgb(74 49 9 / 18%); }
.daily-card-copy > span { color: #865d15; font-size: 11px; font-weight: 800; }
.daily-card h2 { margin: 3px 0 5px; font-size: 20px; }
.daily-card p { max-width: 46ch; margin: 0 0 5px; color: #62502e; font-size: 12px; }
.daily-card .primary { min-width: 110px; min-height: 48px; }
.challenge-warning { display: block; color: #963c25; }
.challenge-section { margin-top: 14px; padding: 14px; border: 1px solid #d7cdbb; border-radius: 16px; background: #fff; }
.challenge-section-title { display: flex; margin-bottom: 10px; align-items: baseline; justify-content: space-between; gap: 8px; }
.challenge-section-title h2 { margin: 0; font-size: 17px; }
.challenge-section-title span { color: #746b5c; font-size: 11px; }
.leaderboard-section-title { display: grid; justify-content: start; gap: 3px; }
.challenge-empty { margin: 8px 0; color: #786e5c; font-size: 12px; }
.leaderboard-list { margin: 0; padding: 0; list-style: none; }
.leaderboard-list li { display: grid; min-height: 48px; padding: 5px 8px; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 9px; border-top: 1px solid #ece5d8; }
.leaderboard-list li:first-child { border-top: 0; }
.leaderboard-list li.is-top-1 { border: 1px solid #e4c66d; border-radius: 12px; background: linear-gradient(90deg, #fff8dc, #fffdf5); box-shadow: 0 2px 0 rgb(120 82 19 / 10%); }
.leaderboard-player { display: grid; min-width: 0; gap: 1px; text-align: start; }
.leaderboard-player strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-list small { color: #776d5e; font-size: 10px; font-weight: 600; }
.leaderboard-score { color: #4c3413; font-size: 14px; font-variant-numeric: tabular-nums; text-align: end; }
.leaderboard-rank { display: grid; width: 26px; height: 26px; place-items: center; border-radius: 50%; background: #eee5d4; color: #65583f; font-size: 11px; font-weight: 900; font-variant-numeric: tabular-nums; }
.is-top-1 .leaderboard-rank { background: #e7b93f; color: #4f3507; box-shadow: inset 0 1px 0 rgb(255 255 255 / 58%); }
.is-top-2 .leaderboard-rank { background: #d9d7d1; color: #4f4b43; }
.is-top-3 .leaderboard-rank { background: #d9a36d; color: #59300f; }
.run-build-list { display: flex; flex-wrap: wrap; gap: 7px; }
.run-build-list span { display: flex; padding: 7px 9px; align-items: center; gap: 6px; border-radius: 10px; background: #f4eddd; font-size: 12px; }
.run-build-list i { font-style: normal; }
.codex-grid, .rules-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.codex-grid article, .rules-list article { padding: 10px; border: 1px solid #e1d8c7; border-radius: 12px; background: #faf7f1; }
.codex-grid article:not(.is-discovered) { filter: grayscale(1); opacity: .58; }
.codex-grid article > span, .rules-list article > span { font-size: 24px; }
.codex-grid strong, .rules-list strong { display: block; font-size: 13px; }
.codex-grid p, .rules-list p { margin: 3px 0; color: #716655; font-size: 11px; line-height: 1.3; }
.codex-grid small { color: #76551d; font-weight: 700; }
.modal-daily-result { width: min(460px, calc(100% - 24px)); max-height: min(90dvh, 720px); overflow-y: auto; }
.daily-result-head { text-align: center; }
.daily-result-head > span { font-size: 42px; }
.daily-result-head h2 { margin: 2px 0; }
.daily-result-head strong { display: block; color: #8a5b08; font-size: 24px; }
.daily-share-card {
  display: grid;
  gap: 8px;
  margin: 14px 0 12px;
  padding: 16px;
  border: 1px solid #d7b876;
  border-radius: 16px;
  background: linear-gradient(145deg, #fffaf0, #f1dfb8);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 7px 18px rgba(105, 73, 20, .12);
}
.daily-share-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #72541f;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.daily-share-card > strong {
  color: #4d3210;
  font-size: 23px;
  line-height: 1.1;
}
.daily-share-card > p {
  margin: 0;
  color: #65563d;
  font-size: 13px;
  line-height: 1.45;
}
.daily-share-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}
.daily-share-stats span {
  padding: 7px 5px;
  border-radius: 9px;
  background: rgba(255, 255, 255, .66);
  color: #604514;
  font-size: 11px;
  font-weight: 900;
  text-align: center;
}
.daily-share-actions {
  display: grid;
  gap: 8px;
  text-align: center;
}
.daily-share-actions > strong {
  color: #151922;
  font-size: 16px;
}
.daily-share-button {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(0, 101, 89, .2);
  border-radius: 10px;
  background: linear-gradient(180deg, #12a88e, #087d6f);
  color: #fff;
  box-shadow: 0 5px 0 rgba(4, 86, 77, .28);
  font-weight: 900;
}

@media (max-width: 520px) {
  .challenge-sheet { max-height: 94dvh; border-radius: 20px 20px 0 0; }
  .daily-card { grid-template-columns: 1fr; }
  .daily-card .primary { width: 100%; }
  .boss-buff-grid { grid-template-columns: 1fr; }
  .boss-buff-grid button { min-height: 76px; }
  .codex-grid, .rules-list { grid-template-columns: 1fr; }
  .daily-share-card { padding: 13px; }
  .is-rule-stage .board-wrap.shape-ascii { --ascii-board-size: min(calc(100vw - 20px), calc(100% - 72px), 296px); }
}

@media (min-width: 600px) {
  body {
    background: #d6bf91;
  }

  .mobile-game {
    --header-height: clamp(104px, 13svh, 132px);
    --bottom-height: clamp(128px, 16svh, 164px);
  }

  .header-stats-row {
    font-size: 15px;
  }

  .tool-row {
    transform: translateY(-20px);
  }
}

@media (max-width: 560px) {
  .seo-grid {
    grid-template-columns: 1fr;
  }

  .seo-inner {
    padding: 20px;
  }

  .modal-out {
    padding-inline: 20px;
  }
}

@media (max-width: 390px) {
  .boss-progress {
    grid-template-columns: minmax(0, 1fr) 104px;
    width: calc(100% - 16px);
    gap: 8px;
    padding-inline: 9px;
  }

  .boss-progress-copy strong {
    font-size: 16px;
  }

  .boss-progress-copy > span:last-child {
    font-size: 11px;
  }

  .boss-armor {
    gap: 3px;
  }

  .audio-menu {
    right: 42px;
    min-width: 104px;
  }

  .heart-row {
    gap: 7px;
    padding-inline: 10px;
  }

  .reward-toast-anchor {
    min-width: 12px;
  }

  /* Width is handled by the 600px media query to allow layout to expand flat */

  .reward-toast-card {
    min-height: 38px;
    gap: 5px;
    padding: 6px 7px 6px 6px;
  }

  .reward-toast-icon {
    width: 26px;
    height: 26px;
  }

  .reward-toast-icon-unstoppable {
    width: 26px;
    height: 26px;
  }

  .reward-toast-icon-unstoppable img {
    width: 26px;
    height: 26px;
  }

  .reward-toast-text {
    padding: 0 3px 1px;
    font-size: 13px;
  }

  .reward-toast-badge {
    min-width: 34px;
    min-height: 24px;
    padding-inline: 5px;
    font-size: 14px;
  }

  .tool-row {
    gap: clamp(4px, 1.7vw, 8px);
    padding-inline: 8px;
  }

  .round-tool {
    width: clamp(50px, 15vw, 58px);
    height: clamp(50px, 15vw, 58px);
  }

  .heart-stack {
    gap: 7px;
  }

  .heart-stack span {
    width: 23px;
    height: 23px;
  }

  .heart-cluster {
    gap: 5px;
  }

  .shield-badge {
    width: 22px;
    height: 22px;
  }

  .wallet-chip,
  .combo-chip {
    min-height: 31px;
  }

  .wallet-chip {
    min-width: 66px;
    padding-right: 8px;
  }

  .combo-chip {
    min-width: 82px;
    padding-right: 8px;
  }

  .coin-gain-float {
    right: -3px;
    top: -8px;
    min-width: 24px;
    padding-inline: 5px;
    font-size: 11px;
  }

  .combo-chip .combo-label {
    display: none;
  }

  .wallet-chip strong,
  .combo-chip strong {
    font-size: 18px;
  }

  .combo-chip.combo-tier-2 strong {
    font-size: 22px;
  }

  .combo-chip.combo-tier-3 strong {
    font-size: 25px;
  }

  .combo-chip.combo-tier-4 strong,
  .combo-chip.combo-tier-5 strong {
    font-size: 28px;
  }

  .chip-icon {
    width: 23px;
    height: 23px;
  }

  .combo-chip .flame-icon {
    --flame-frame: 27px;
    --flame-strip-offset: -216px;
  }

  .result-strip {
    grid-template-columns: 1fr;
  }

  .result-strip.has-combo-multiplier {
    grid-template-columns: 1fr;
  }

  .settlement-head p {
    font-size: 19px;
  }

  .settlement-medal {
    width: 50px;
    height: 50px;
  }

  .settlement-reward {
    min-height: 64px;
    padding: 10px 12px;
  }

  .settlement-combo {
    min-height: 58px;
    padding: 10px 12px;
  }

  .settlement-combo-flame {
    width: 38px;
    height: 38px;
  }

  .settlement-coin {
    width: 36px;
    height: 36px;
  }

  .reward-coins {
    font-size: 25px;
  }

  .modal-solved .modal-actions {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .modal-copy {
    font-size: 16px;
  }

  .share-buttons {
    gap: 8px;
  }

  .share-buttons button {
    min-height: 40px;
    font-size: 14px;
  }

  .modal-actions button {
    min-height: 44px;
    font-size: 15px;
  }
}

@media (max-height: 650px) {
  .mobile-game {
    --header-height: 104px;
    --heart-height: 36px;
    --bottom-height: 126px;
  }

  .backpack-sheet {
    max-height: 96svh;
    padding: 12px 16px 14px;
  }

  .bag-summary-old div {
    min-height: 54px;
  }

  .bag-summary-old strong {
    font-size: 22px;
  }

  .bag-skill-list {
    gap: 7px;
  }

  .settlement-shop {
    padding: 10px;
  }

  .settlement-shop-unused .bag-skill-list {
    grid-template-columns: 1fr;
  }

  .bag-intro {
    margin: 8px 2px 9px;
    font-size: 13px;
  }

  .board-wrap {
    width: min(calc(100vw - 20px), 340px);
    top: 2px;
  }

  .is-boss-stage .board-wrap.shape-ascii {
    --ascii-board-size: min(calc(100vw - 20px), calc(100% - 66px), 300px);
    top: calc(50% + 30px);
  }

  .boss-progress {
    top: 2px;
    min-height: 50px;
    padding-block: 6px;
  }

  .boss-armor-segment {
    height: 27px;
  }

  .game-header {
    grid-template-rows: 42px 31px 31px;
  }

  .tool-row {
    gap: 8px;
    transform: translateY(-18px);
  }

  .round-tool {
    width: 56px;
    height: 56px;
  }

  .status-line {
    font-size: 24px;
  }

  .modal-out {
    gap: 8px;
    padding-top: 18px;
  }

  .modal h2 {
    font-size: 24px;
  }

  .modal-copy {
    font-size: 15px;
    line-height: 1.3;
  }

  .share-heading {
    margin-top: 2px;
    font-size: 14px;
  }

  .share-buttons button {
    min-height: 38px;
  }

  .modal-actions button {
    min-height: 42px;
  }

  .bag-skill-list article {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 8px 9px;
  }

  .bag-skill-icon {
    width: 40px;
    height: 40px;
  }

  .bag-skill-list strong {
    font-size: 15px;
  }

  .skill-level-badge,
  .item-count-badge {
    padding: 2px 5px;
    font-size: 10px;
  }

  .bag-skill-list p {
    margin-top: 2px;
    font-size: 11px;
    line-height: 1.18;
  }

  .skill-action {
    min-width: 58px;
    max-width: 86px;
    min-height: 36px;
    padding-inline: 5px;
    font-size: 11px;
  }
}

@media (max-width: 430px) {
  .bag-skill-list article {
    grid-template-columns: 40px minmax(0, 1fr);
    grid-template-areas:
      "icon copy"
      "icon action";
    column-gap: 9px;
    row-gap: 6px;
    align-items: center;
  }

  .bag-skill-icon {
    grid-area: icon;
  }

  .bag-skill-list article > div {
    grid-area: copy;
  }

  .skill-action {
    grid-area: action;
    justify-self: end;
    min-width: 86px;
    max-width: min(100%, 136px);
    padding-inline: 9px;
  }
}

.seo-landing-page {
  --body-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Microsoft YaHei", "PingFang SC", "Hiragino Sans", sans-serif;
  min-height: 100%;
  overflow-y: auto;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.58), transparent 32rem),
    linear-gradient(180deg, #ead7ac, #f8efdc 38rem, #ead3a3);
  font-family: var(--body-font);
}

.landing-header,
.landing-footer,
.landing-hero,
.landing-game,
.landing-content {
  width: min(1040px, calc(100% - 28px));
  margin-inline: auto;
}

.landing-header {
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.landing-language-switcher {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.landing-language-switcher a {
  padding: 6px 8px;
  border-radius: 7px;
  color: #76501e;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.landing-language-switcher a.active {
  background: #76501e;
  color: #fff9ec;
}

.landing-hero {
  padding: clamp(48px, 7vw, 76px) 0 30px;
}

.landing-hero-copy {
  max-width: 760px;
}

.landing-hero h1 {
  margin: 8px 0 18px;
  color: #5f3b0d;
  font-family: var(--display-font);
  font-size: clamp(42px, 8vw, 76px);
  line-height: 0.98;
}

.landing-hero-copy > p:not(.eyebrow) {
  max-width: 68ch;
  margin: 0;
  color: #6b4e27;
  font-size: clamp(17px, 2.5vw, 21px);
  line-height: 1.65;
}

.landing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 24px;
}

.landing-button {
  display: inline-flex;
  min-height: 46px;
  padding: 11px 17px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(111, 74, 24, 0.28);
  border-radius: 10px;
  background: rgba(255, 250, 238, 0.8);
  color: #6f4a18;
  font-weight: 800;
  text-decoration: none;
}

.landing-button.primary {
  border-color: #755019;
  background: #755019;
  color: #fff9ec;
}

.landing-text-link {
  padding: 10px 4px;
  color: #76501e;
  font-weight: 750;
}

.landing-game {
  width: min(820px, 100%);
  scroll-margin-top: 12px;
}

.game-embed {
  display: block;
  width: 100%;
  height: min(820px, calc(100dvh - 64px));
  min-height: 560px;
  margin: 0 auto;
  border: 1px solid rgba(111, 74, 24, 0.3);
  border-radius: 24px;
  background: #f1e4c9;
  box-shadow: 0 24px 60px rgba(80, 48, 8, 0.18);
}

.landing-content {
  padding: 52px 0 72px;
}

.landing-explainer {
  max-width: 760px;
}

.landing-content h2 {
  margin: 0 0 10px;
  color: #65410f;
  font-size: clamp(23px, 4vw, 32px);
  line-height: 1.15;
}

.landing-content p {
  margin: 0;
  color: #6b4e27;
  line-height: 1.72;
}

.landing-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}

.landing-card-grid article,
.landing-faq details {
  border: 1px solid rgba(111, 74, 24, 0.16);
  border-radius: 14px;
  background: rgba(255, 251, 241, 0.76);
}

.landing-card-grid article {
  padding: 19px;
}

.landing-card-grid h2 {
  font-size: 20px;
}

.landing-faq {
  display: grid;
  gap: 10px;
  margin-top: 48px;
}

.landing-faq > h2 {
  margin-bottom: 4px;
}

.landing-faq summary {
  cursor: pointer;
  padding: 15px 17px;
  color: #65410f;
  font-weight: 800;
}

.landing-faq details p {
  padding: 0 17px 16px;
}

.landing-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  padding: 24px 0 40px;
  border-top: 1px solid rgba(111, 74, 24, 0.14);
}

.landing-footer a {
  color: #76501e;
  font-weight: 700;
}

@media (max-width: 720px) {
  .landing-header {
    min-height: 64px;
    padding-inline: 14px;
  }

  .landing-language-switcher {
    max-width: 190px;
  }

  .landing-hero {
    padding-top: 48px;
  }

  .landing-actions {
    align-items: stretch;
  }

  .landing-button {
    flex: 1 1 140px;
  }

  .landing-text-link {
    flex-basis: 100%;
  }

  .game-embed {
    height: calc(100dvh - 64px);
    min-height: 560px;
    border-inline: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .landing-card-grid {
    grid-template-columns: 1fr;
  }
}

.modal-out,
.modal-solved,
.backpack-sheet,
.backpack-shop {
  --display-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Microsoft YaHei", "PingFang SC", sans-serif;
  --body-font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Microsoft YaHei", "PingFang SC", sans-serif;
  font-family: var(--body-font);
}

@media (max-width: 430px) {
  .skill-action {
    max-width: min(100%, 136px);
    padding-inline: 9px;

  }
}



@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}
