:root {
  --ink: #102f42;
  --deep: #071f2f;
  --sea: #1f7b83;
  --mint: #79c7b4;
  --gold: #e7b95a;
  --tomato: #d57466;
  --blue: #7eb4df;
  --paper: rgba(255, 255, 255, 0.9);
  --glass: rgba(255, 255, 255, 0.16);
  --shadow: 0 18px 70px rgba(3, 18, 28, 0.34);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background:
    radial-gradient(circle at 18% 12%, rgba(121, 199, 180, .42), transparent 26%),
    radial-gradient(circle at 80% 20%, rgba(231, 185, 90, .34), transparent 24%),
    linear-gradient(145deg, #071f2f 0%, #1f6876 48%, #a66f54 100%);
}

button {
  border: 0;
  font: inherit;
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 22px;
}

.phone-frame {
  position: relative;
  width: min(100%, 430px);
  min-height: 820px;
  overflow: hidden;
  border: 10px solid rgba(4, 19, 29, .9);
  border-radius: 38px;
  background: #eff8f5;
  box-shadow: var(--shadow);
}

.phone-frame.bomb-shake {
  animation: bombScreenShake .48s steps(4, end);
}

.world-glow {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255,255,255,.9), rgba(255,255,255,.32)),
    url("data:image/svg+xml,%3Csvg width='430' height='820' viewBox='0 0 430 820' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M-64 174C43 53 171 106 232 41c82 77 24 171 131 236 75 45 56 155-52 164-78 6-113 87-204 43C3 433-65 278-64 174Z' fill='%2379c7b4' fill-opacity='.22'/%3E%3Cpath d='M126 775c-38-99 39-173 128-153 86 19 105-74 176-65v263H112c9-15 21-30 14-45Z' fill='%23e7b95a' fill-opacity='.24'/%3E%3Cpath d='M296 8c90 46 113 144 65 217-22 34-60 46-97 30-35-16-51-52-39-88 12-36 49-58 71-159Z' fill='%237eb4df' fill-opacity='.20'/%3E%3C/svg%3E");
  pointer-events: none;
}

.screen {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: none;
  flex-direction: column;
  padding: 26px 20px;
}

.screen-active {
  display: flex;
}

.brand-lockup {
  display: flex;
  gap: 12px;
  align-items: center;
  font-weight: 900;
}

.brand-lockup span,
.stage-title span,
.top-line span,
.game-hud span,
.city-panel span,
.question-head span,
.result-card span,
.turn-panel span {
  color: rgba(16, 47, 66, .64);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.brand-lockup div {
  display: grid;
  gap: 2px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
  box-shadow: 0 10px 22px rgba(31, 123, 131, .24);
}

h1,
h2 {
  margin: 0;
  color: var(--deep);
  letter-spacing: 0;
}

.boot-screen h1 {
  margin-top: 18px;
  font-size: 42px;
  line-height: 1.06;
}

.boot-screen p {
  margin: 14px 0 30px;
  color: rgba(16, 47, 66, .72);
  font-size: 16px;
  line-height: 1.72;
}

.boot-art {
  position: relative;
  flex: 1;
  min-height: 330px;
  display: grid;
  place-items: center;
}

.map-coin {
  display: grid;
  place-items: center;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  color: rgba(255,255,255,.92);
  background:
    radial-gradient(circle at 36% 34%, rgba(255,255,255,.38), transparent 28%),
    linear-gradient(145deg, var(--sea), var(--blue) 56%, var(--gold));
  font-size: 44px;
  font-weight: 900;
  box-shadow: 0 28px 50px rgba(5, 35, 49, .24);
}

.primary-btn,
.secondary-btn,
.dice-btn,
.copy-btn {
  width: 100%;
  min-height: 56px;
  border-radius: 8px;
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(31, 123, 131, .22);
}

.secondary-btn,
.copy-btn {
  color: var(--deep);
  background: #edf8f5;
  box-shadow: none;
}

.mini-character,
.toon-character,
.map-piece {
  position: relative;
  transform-style: preserve-3d;
}

.mini-character {
  position: absolute;
  width: 102px;
  height: 128px;
  animation: float 3.2s ease-in-out infinite;
}

.bear-preview {
  left: 20px;
  top: 82px;
}

.fox-preview {
  right: 16px;
  bottom: 74px;
  animation-delay: .4s;
}

.toon-character {
  width: 112px;
  height: 142px;
  margin: 0 auto 12px;
  animation: float 3.1s ease-in-out infinite;
}

.mini-character::before,
.toon-character::before,
.map-piece::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 12px;
  width: 78px;
  height: 82px;
  border-radius: 50% 50% 45% 45%;
  transform: translateX(-50%) rotateX(8deg);
  box-shadow: inset -12px -10px 0 rgba(0,0,0,.10), 0 12px 20px rgba(5,22,33,.18);
}

.mini-character::after,
.toon-character::after,
.map-piece::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 8px;
  width: 72px;
  height: 68px;
  border-radius: 24px 24px 34px 34px;
  transform: translateX(-50%);
  box-shadow: inset -10px -10px 0 rgba(0,0,0,.08);
}

.bear::before,
.bear::after,
.bear-preview::before,
.bear-preview::after,
.map-piece.bear::before,
.map-piece.bear::after {
  background: linear-gradient(145deg, #7d5541, #d6a26b);
}

.fox::before,
.fox::after,
.fox-preview::before,
.fox-preview::after,
.map-piece.fox::before,
.map-piece.fox::after {
  background: linear-gradient(145deg, #d66b53, #f1b06c);
}

.face {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 52px;
  width: 42px;
  height: 25px;
  border-radius: 50%;
  transform: translateX(-50%);
  background: rgba(255,255,255,.68);
}

.face::before {
  content: "●  ●";
  position: absolute;
  left: 0;
  right: 0;
  top: -22px;
  color: var(--deep);
  text-align: center;
  font-size: 10px;
  letter-spacing: 10px;
}

.face::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 9px;
  width: 10px;
  height: 7px;
  border-radius: 50%;
  background: var(--deep);
}

.vest,
.scarf {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 98px;
  transform: translateX(-50%);
}

.vest {
  width: 58px;
  height: 30px;
  border-radius: 8px;
  border: 4px solid #267061;
  background: rgba(255,255,255,.82);
}

.scarf {
  width: 70px;
  height: 13px;
  border-radius: 99px;
  background: var(--tomato);
  transform: translateX(-50%) rotate(-8deg);
}

.hat {
  position: absolute;
  z-index: 5;
  left: 50%;
  top: 7px;
  width: 58px;
  height: 20px;
  border-radius: 50% 50% 8px 8px;
  transform: translateX(-50%) rotate(-8deg);
  background: var(--tomato);
}

.dice-hand {
  position: absolute;
  z-index: 5;
  right: 8px;
  top: 88px;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: white;
  border: 3px solid var(--deep);
}

#role-screen h2 {
  margin-top: 10px;
  font-size: 30px;
  line-height: 1.22;
}

#role-screen {
  gap: 12px;
}

#role-screen h2 {
  margin-top: 0;
}

.role-copy {
  margin: -4px 0 2px;
  color: rgba(16, 47, 66, .72);
  font-size: 14px;
  line-height: 1.6;
}

#scan-screen {
  gap: 12px;
}

.scan-topline,
.scan-copy-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.scan-topline {
  margin-top: 6px;
}

.scan-topline span {
  color: rgba(16, 47, 66, .64);
  font-size: 12px;
  font-weight: 900;
}

.scan-step {
  padding: 7px 10px;
  border: 1px solid rgba(31, 123, 131, .18);
  border-radius: 999px;
  background: rgba(255, 255, 255, .56);
}

.scan-head h2 {
  font-size: 30px;
  line-height: 1.16;
}

.scan-head p {
  max-width: 380px;
  margin: 8px 0 0;
  color: rgba(16, 47, 66, .72);
  font-size: 14px;
  line-height: 1.6;
}

.scan-device {
  position: relative;
  flex: 0 0 auto;
  min-height: 334px;
  margin-top: 10px;
  display: grid;
  place-items: center;
}

.scan-orbit {
  position: absolute;
  width: 326px;
  height: 326px;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255,255,255,0) 58%, rgba(126, 180, 223, .10) 59%, rgba(126, 180, 223, 0) 66%),
    radial-gradient(circle at 50% 40%, rgba(121, 199, 180, .16), rgba(121, 199, 180, 0) 72%);
}

.scan-face {
  position: relative;
  width: 254px;
  height: 254px;
  overflow: hidden;
  border: 3px solid rgba(119, 189, 196, .58);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 22%, rgba(255,255,255,.98), rgba(235, 248, 244, .94) 58%, rgba(206, 232, 227, .92) 100%);
  box-shadow:
    inset 0 0 0 10px rgba(255,255,255,.26),
    0 26px 52px rgba(5, 35, 49, .12);
}

.scan-face::before {
  content: "";
  position: absolute;
  inset: 16px;
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 50%;
}

.scan-face::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 146px;
  height: 146px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background:
    linear-gradient(rgba(53, 215, 198, .10), rgba(53, 215, 198, .10)) center / 100% 1px no-repeat,
    linear-gradient(90deg, rgba(53, 215, 198, .10), rgba(53, 215, 198, .10)) center / 1px 100% no-repeat;
  opacity: .8;
}

.scan-avatar {
  position: absolute;
  left: 50%;
  top: 58px;
  width: 112px;
  height: 140px;
  transform: translateX(-50%);
  opacity: .14;
}

.scan-avatar::before,
.scan-avatar::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(180deg, rgba(16, 47, 66, .22), rgba(16, 47, 66, .08));
}

.scan-avatar::before {
  top: 0;
  width: 60px;
  height: 60px;
  border-radius: 50%;
}

.scan-avatar::after {
  top: 48px;
  width: 108px;
  height: 88px;
  border-radius: 44px 44px 24px 24px;
}

.scan-pulse-ring,
.scan-spark {
  position: absolute;
  pointer-events: none;
}

.scan-pulse-ring {
  left: 50%;
  top: 50%;
  border: 1px solid rgba(83, 212, 201, .24);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.scan-pulse-ring.ring-a {
  width: 122px;
  height: 122px;
  animation: pulseRing 2.4s ease-out infinite;
}

.scan-pulse-ring.ring-b {
  width: 164px;
  height: 164px;
  border-color: rgba(255,255,255,.24);
  animation: pulseRing 2.4s ease-out infinite .8s;
}

.scan-grid {
  position: absolute;
  width: 294px;
  height: 294px;
  border-radius: 50%;
  border: 2px dashed rgba(213, 116, 102, .34);
  animation: rotate 8s linear infinite;
}

.scan-eye {
  position: absolute;
  top: 95px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--deep);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.18),
    0 0 0 5px rgba(255,255,255,.24);
  animation: blink 3.8s infinite;
}

.scan-eye.left {
  left: 76px;
}

.scan-eye.right {
  right: 76px;
}

.scan-smile {
  position: absolute;
  left: 50%;
  top: 143px;
  width: 56px;
  height: 26px;
  border-bottom: 4px solid var(--deep);
  border-radius: 0 0 60px 60px;
  transform: translateX(-50%);
  opacity: .92;
  animation: smileBob 2.2s ease-in-out infinite;
}

.scan-smile::before,
.scan-smile::after {
  content: "";
  position: absolute;
  top: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(231, 185, 90, .22);
  filter: blur(1px);
  animation: cheekGlow 1.9s ease-in-out infinite;
}

.scan-smile::before {
  left: -20px;
}

.scan-smile::after {
  right: -20px;
  animation-delay: .4s;
}

.scan-spark {
  width: 12px;
  height: 12px;
  background: rgba(255,255,255,.82);
  transform: rotate(45deg);
  box-shadow: 0 0 14px rgba(108, 231, 210, .22);
  animation: scanSparkle 1.6s ease-in-out infinite;
}

.scan-spark::before,
.scan-spark::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  background: rgba(108, 231, 210, .82);
  transform: translate(-50%, -50%);
}

.scan-spark::before {
  width: 2px;
  height: 14px;
}

.scan-spark::after {
  width: 14px;
  height: 2px;
}

.scan-spark.spark-a {
  left: 52px;
  top: 116px;
}

.scan-spark.spark-b {
  right: 46px;
  top: 82px;
  animation-delay: .35s;
}

.scan-spark.spark-c {
  right: 60px;
  bottom: 68px;
  animation-delay: .7s;
}

.scanner-line {
  position: absolute;
  left: 24px;
  right: 24px;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, rgba(53, 215, 198, .04), rgba(53, 215, 198, .94), rgba(53, 215, 198, .04));
  box-shadow: 0 0 18px rgba(53, 215, 198, .42);
  animation: scan 2s ease-in-out infinite;
}

.scan-percent {
  position: absolute;
  left: 50%;
  bottom: 12px;
  min-width: 58px;
  padding: 1px 8px 2px;
  transform: translateX(-50%);
  color: var(--deep);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: .01em;
  text-align: center;
  background: linear-gradient(180deg, rgba(255,255,255,.44), rgba(255,255,255,.18));
  border: 1px solid rgba(255,255,255,.62);
  border-radius: 8px;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.42),
    0 8px 16px rgba(16, 47, 66, .06);
  backdrop-filter: blur(6px);
  text-shadow: 0 1px 0 rgba(255,255,255,.34);
}

.scan-side-note {
  position: absolute;
  right: -2px;
  top: 96px;
  width: 132px;
  padding: 12px 12px 12px 14px;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 16px;
  background: rgba(255,255,255,.72);
  box-shadow: 0 16px 28px rgba(12, 52, 64, .08);
  backdrop-filter: blur(8px);
}

.scan-side-note::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 22px;
  width: 16px;
  height: 16px;
  border-left: 1px solid rgba(255,255,255,.8);
  border-bottom: 1px solid rgba(255,255,255,.8);
  background: rgba(255,255,255,.72);
  transform: rotate(45deg);
}

.scan-side-note strong {
  display: block;
  color: var(--deep);
  font-size: 13px;
  line-height: 1.3;
}

.scan-side-note p {
  margin: 6px 0 0;
  color: rgba(16, 47, 66, .72);
  font-size: 11px;
  line-height: 1.5;
}

.scan-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.scan-stats span {
  padding: 11px 8px;
  border: 1px solid rgba(255,255,255,.76);
  border-radius: 8px;
  color: rgba(16, 47, 66, .66);
  background: rgba(255,255,255,.62);
  font-size: 12px;
  font-weight: 900;
  text-align: center;
  box-shadow: 0 10px 22px rgba(12, 52, 64, .06);
  transition: background .22s ease, color .22s ease, transform .22s ease, box-shadow .22s ease;
}

.scan-stats span.active {
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
  box-shadow: 0 12px 24px rgba(31, 123, 131, .18);
  transform: translateY(-2px);
}

.scan-copy {
  padding: 18px;
  border: 1px solid rgba(255,255,255,.76);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 14px 28px rgba(12, 52, 64, .08);
}

.scan-copy-head strong {
  font-size: 18px;
}

.scan-copy-head span {
  padding: 5px 10px;
  border-radius: 999px;
  color: #b74b35;
  background: rgba(231, 185, 90, .16);
  font-size: 12px;
  font-weight: 900;
}

.scan-copy p {
  margin: 8px 0 0;
  color: rgba(16, 47, 66, .68);
  font-size: 14px;
  line-height: 1.55;
}

.scan-progress {
  height: 8px;
  margin-top: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(16, 47, 66, .08);
}

.scan-progress b {
  display: block;
  width: 12%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--mint), var(--sea), var(--gold));
  box-shadow: 0 0 16px rgba(31, 123, 131, .28);
  transition: width .45s ease;
}

.top-line,
.game-hud,
.city-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sound-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  color: white;
  background: linear-gradient(135deg, var(--sea), #5d9b9e);
  font-weight: 900;
  box-shadow: 0 10px 20px rgba(31, 123, 131, .18);
}

.role-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 0;
}

.role-card,
.turn-panel,
.game-hud,
.city-panel,
.result-card,
.lead-box {
  border: 1px solid rgba(255,255,255,.64);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 12px 32px rgba(12, 52, 64, .12);
}

.role-card {
  position: relative;
  min-height: 264px;
  padding: 16px 12px 18px;
  border: 2px solid transparent;
  color: var(--ink);
  text-align: center;
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(244, 251, 249, .9)),
    var(--paper);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease, background .22s ease;
}

.role-card.selected {
  border-color: rgba(87, 169, 171, .72);
  background:
    linear-gradient(180deg, #fcfffe, #eef8f5),
    var(--paper);
  box-shadow: 0 18px 34px rgba(12, 52, 64, .14);
  transform: translateY(-2px);
}

.role-card.selected::before {
  content: "已选择";
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 5px 8px;
  border-radius: 999px;
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
  font-size: 11px;
  font-weight: 900;
}

.role-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 30px rgba(12, 52, 64, .12);
}

.role-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
}

.role-card span {
  color: rgba(16, 47, 66, .62);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.55;
}

.turn-panel {
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(241, 249, 246, .88)),
    var(--paper);
}

.role-actions {
  display: grid;
  gap: 12px;
  margin-top: auto;
}

.turn-select {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.turn-btn {
  min-height: 52px;
  border-radius: 8px;
  color: var(--deep);
  background: rgba(226, 241, 239, .9);
  font-weight: 900;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.turn-btn.selected {
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
  box-shadow: 0 12px 24px rgba(31, 123, 131, .18);
}

.turn-btn:hover {
  transform: translateY(-1px);
}

#enter-map {
  margin-top: 0;
  box-shadow: 0 16px 28px rgba(31, 123, 131, .18);
}

.game-hud {
  padding: 12px;
}

.game-hud strong {
  display: block;
  margin-top: 2px;
  font-size: 17px;
}

.map-wrap {
  position: relative;
  flex: 1;
  min-height: 0;
  margin: 12px 0;
}

.travel-map {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 18px 32px rgba(5, 22, 33, .22));
}

.route-path {
  fill: none;
  stroke: rgba(255,255,255,.78);
  stroke-width: 7;
  stroke-linecap: round;
  stroke-dasharray: 9 12;
}

.city-dot circle {
  fill: white;
  stroke: var(--tomato);
  stroke-width: 4;
}

.city-dot.active circle {
  fill: var(--gold);
  stroke: white;
}

.city-dot text {
  fill: white;
  font-size: 12px;
  font-weight: 900;
  paint-order: stroke;
  stroke: rgba(7, 31, 47, .75);
  stroke-width: 3px;
}

.landmark {
  font-size: 16px;
  font-weight: 900;
}

.map-piece {
  position: absolute;
  left: 91px;
  top: 324px;
  width: 56px;
  height: 70px;
  transform: translate(-50%, -50%) scale(.42);
  animation: pieceFloat 3s ease-in-out infinite;
  transition: left .65s ease, top .65s ease;
  pointer-events: none;
  filter: drop-shadow(0 12px 12px rgba(5, 22, 33, .28));
}

.city-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) 168px;
  gap: 18px;
  align-items: stretch;
  padding: 20px 16px;
  min-height: 188px;
}

.city-panel div {
  min-width: 0;
}

.city-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.city-panel strong {
  display: block;
  margin: 7px 0 8px;
  font-size: 22px;
  line-height: 1.08;
}

.city-panel p {
  margin: 0;
  color: rgba(16, 47, 66, .68);
  font-size: 14px;
  line-height: 1.6;
}

.city-tip {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(16, 47, 66, .16);
  color: rgba(16, 47, 66, .56);
  font-size: 12px;
  font-weight: 800;
}

.dice-btn {
  width: 100%;
  min-height: 50px;
  font-size: 16px;
}

.question-head {
  margin-top: 46px;
}

.question-head h2 {
  margin: 10px 0;
  font-size: 28px;
  line-height: 1.23;
}

.question-head p {
  margin: 0;
  color: rgba(16, 47, 66, .62);
  font-weight: 800;
}

.answer-list {
  display: grid;
  gap: 12px;
  margin-top: 28px;
}

.answer-btn {
  min-height: 76px;
  padding: 16px;
  border-radius: 8px;
  color: var(--deep);
  background: rgba(255,255,255,.88);
  text-align: left;
  font-weight: 900;
  line-height: 1.45;
  box-shadow: 0 10px 24px rgba(12, 52, 64, .10);
}

.answer-btn:active {
  color: white;
  background: linear-gradient(135deg, var(--sea), var(--gold));
}

.result-card {
  margin-top: 54px;
  padding: 20px;
}

.result-card h2 {
  margin: 10px 0 12px;
  font-size: 32px;
  line-height: 1.15;
}

.result-route {
  display: flex;
  align-items: stretch;
  gap: 12px;
  margin: 14px 0 14px;
}

.result-stop {
  flex: 1 1 0;
  padding: 16px 14px;
  border: 1px solid rgba(255,255,255,.82);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.96), rgba(243, 249, 247, .9)),
    rgba(255,255,255,.9);
  box-shadow: 0 12px 24px rgba(12, 52, 64, .08);
}

.result-stop em {
  display: block;
  color: rgba(16, 47, 66, .58);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.result-stop strong {
  display: block;
  margin-top: 8px;
  color: var(--deep);
  font-size: 28px;
  line-height: 1.08;
}

.result-card p {
  margin: 0;
  color: rgba(16, 47, 66, .72);
  line-height: 1.68;
}

.score-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.score-tags span {
  padding: 8px 10px;
  border-radius: 99px;
  color: white;
  background: var(--sea);
  font-size: 12px;
  font-weight: 900;
}

.lead-box {
  display: grid;
  grid-template-columns: 144px 1fr;
  gap: 16px;
  align-items: center;
  margin-top: auto;
  padding: 16px;
}

.qr-code {
  width: 144px;
  height: 144px;
  padding: 10px;
  border-radius: 12px;
  background: white;
  box-shadow: 0 12px 24px rgba(12, 52, 64, .10);
}

.qr-code img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 6px;
  object-fit: contain;
}

.lead-box strong {
  display: block;
  color: var(--deep);
  font-size: 17px;
  line-height: 1.36;
}

.lead-box p {
  margin: 7px 0 10px;
  color: rgba(16, 47, 66, .66);
  font-size: 12px;
  line-height: 1.45;
}

.copy-btn {
  min-height: 40px;
  white-space: nowrap;
  font-size: 14px;
}

.secondary-btn {
  margin-top: 12px;
}

@keyframes rotate {
  to { transform: rotate(360deg); }
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotateX(0deg); }
  50% { transform: translateY(-8px) rotateX(4deg); }
}

@keyframes pieceFloat {
  0%, 100% { transform: translate(-50%, -50%) scale(.42); }
  50% { transform: translate(-50%, calc(-50% - 8px)) scale(.42); }
}

@keyframes scan {
  0%, 100% { top: 54px; opacity: .45; }
  50% { top: 186px; opacity: 1; }
}

@keyframes cameraFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

@keyframes lensPulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(108, 231, 210, .14), 0 0 14px rgba(93, 224, 206, .62); }
  50% { box-shadow: 0 0 0 6px rgba(108, 231, 210, .18), 0 0 20px rgba(93, 224, 206, .78); }
}

@keyframes pulseRing {
  0% { opacity: .15; transform: translate(-50%, -50%) scale(.92); }
  50% { opacity: .42; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.08); }
}

@keyframes blink {
  0%, 44%, 48%, 100% { transform: scaleY(1); }
  46% { transform: scaleY(.16); }
}

@keyframes smileBob {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(2px); }
}

@keyframes cheekGlow {
  0%, 100% { opacity: .2; transform: scale(.9); }
  50% { opacity: .55; transform: scale(1.15); }
}

@keyframes scanSparkle {
  0%, 100% { opacity: .28; transform: rotate(45deg) scale(.72); }
  50% { opacity: .88; transform: rotate(45deg) scale(1.08); }
}

@media (max-width: 520px) {
  .app-shell {
    padding: 0;
  }

  .phone-frame {
    width: 100%;
    min-height: 100vh;
    border: 0;
    border-radius: 0;
  }

  .screen {
    padding: 22px 17px;
  }

  .boot-screen h1 {
    font-size: 38px;
  }

  .scan-head h2 {
    font-size: 28px;
  }

  .scan-device {
    min-height: 318px;
  }

  .scan-face {
    width: 228px;
    height: 228px;
  }

  .scan-orbit {
    width: 302px;
    height: 302px;
  }

  .scan-grid {
    width: 268px;
    height: 272px;
  }

  .scan-side-note {
    right: -2px;
    top: 98px;
    width: 108px;
    padding: 10px 10px 10px 12px;
  }

  .scan-side-note strong {
    font-size: 12px;
  }

  .scan-side-note p {
    font-size: 10px;
  }

  .scan-stats {
    gap: 8px;
  }

  .role-card {
    min-height: 252px;
    padding: 14px 10px 16px;
  }

  .dice-btn {
    flex-basis: 96px;
  }
}

/* Refined pixel-art pass */
.pixel-character {
  position: relative;
  width: 116px;
  height: 150px;
  margin: 0 auto 12px;
  image-rendering: pixelated;
  animation: pixelBob 1.6s steps(2, end) infinite;
  filter: drop-shadow(0 12px 0 rgba(7, 31, 47, .16));
}

.bear-preview,
.fox-preview {
  position: absolute;
  width: 106px;
  height: 136px;
}

.bear-preview {
  left: 18px;
  top: 82px;
}

.fox-preview {
  right: 12px;
  bottom: 70px;
}

.pixel-character::before,
.map-piece::before {
  content: "";
  position: absolute;
  left: 28px;
  top: 18px;
  width: 60px;
  height: 52px;
  border: 5px solid #172432;
  border-radius: 0;
  background: #c47e67;
  box-shadow:
    -16px 6px 0 -4px #c47e67,
    16px 6px 0 -4px #c47e67,
    0 52px 0 8px #c47e67;
}

.pixel-character::after,
.map-piece::after {
  content: "";
  position: absolute;
  left: 30px;
  top: 80px;
  width: 56px;
  height: 46px;
  border: 5px solid #172432;
  background: #f7fbfb;
  box-shadow:
    -18px 16px 0 -7px #c47e67,
    18px 16px 0 -7px #c47e67,
    -12px 50px 0 -8px #c47e67,
    12px 50px 0 -8px #c47e67;
}

.pixel-character.fox::before,
.fox-preview::before,
.map-piece.fox::before {
  left: 26px;
  top: 16px;
  width: 64px;
  height: 54px;
  background: #f28b1d;
  box-shadow:
    -20px -12px 0 -7px #f28b1d,
    20px -12px 0 -7px #f28b1d,
    -18px 20px 0 -8px #fff5e8,
    18px 20px 0 -8px #fff5e8,
    0 54px 0 7px #f28b1d;
}

.pixel-character.fox::after,
.fox-preview::after,
.map-piece.fox::after {
  left: 31px;
  top: 82px;
  width: 54px;
  height: 46px;
  background: #e9c8a7;
  box-shadow:
    -24px 8px 0 -6px #e9c8a7,
    25px 8px 0 -8px #e9c8a7,
    0 44px 0 -5px #e76875,
    38px 18px 0 -6px #f28b1d;
}

.pixel-face {
  position: absolute;
  z-index: 4;
  left: 38px;
  top: 37px;
  width: 40px;
  height: 22px;
  background:
    linear-gradient(#172432 0 0) 6px 5px / 10px 6px no-repeat,
    linear-gradient(#172432 0 0) 25px 5px / 10px 6px no-repeat,
    linear-gradient(#fff 0 0) 17px 13px / 8px 7px no-repeat;
}

.fox .pixel-face,
.fox-preview .pixel-face,
.map-piece.fox .pixel-face {
  left: 37px;
  background:
    linear-gradient(#e76875 0 0) 6px 4px / 9px 12px no-repeat,
    linear-gradient(#e76875 0 0) 25px 4px / 9px 12px no-repeat,
    linear-gradient(#172432 0 0) 17px 15px / 8px 6px no-repeat;
}

.pixel-vest {
  position: absolute;
  z-index: 5;
  left: 24px;
  top: 76px;
  width: 68px;
  height: 58px;
  border-left: 14px solid #9ea68f;
  border-right: 14px solid #9ea68f;
  background:
    linear-gradient(#d65c51 0 0) 23px 20px / 22px 16px no-repeat;
}

.pixel-hat {
  position: absolute;
  z-index: 6;
  left: 32px;
  top: 6px;
  width: 54px;
  height: 20px;
  background: #e76875;
  box-shadow: -8px 8px 0 -2px #e76875;
}

.pixel-scarf {
  position: absolute;
  z-index: 6;
  left: 32px;
  top: 76px;
  width: 58px;
  height: 16px;
  background: #e76875;
  box-shadow: 20px 12px 0 -4px #e76875;
}

.pixel-camera {
  position: absolute;
  z-index: 7;
  left: 42px;
  top: 106px;
  width: 32px;
  height: 22px;
  border: 4px solid #172432;
  background: #e9edf0;
  box-shadow: inset 10px 5px 0 -4px #172432;
}

.pixel-dice-hand {
  position: absolute;
  z-index: 7;
  right: 7px;
  top: 83px;
  width: 24px;
  height: 24px;
  border: 4px solid #172432;
  background:
    radial-gradient(circle, #172432 0 2px, transparent 3px) 3px 3px / 8px 8px,
    #fff;
}

.map-piece {
  width: 56px;
  height: 72px;
  transform: translate(-50%, -50%) scale(.36);
}

.map-piece .pixel-face,
.map-piece .pixel-vest,
.map-piece .pixel-hat,
.map-piece .pixel-scarf,
.map-piece .pixel-camera {
  transform: scale(.9);
  transform-origin: top left;
}

.region {
  stroke: rgba(255,255,255,.86);
  stroke-width: 2.2;
  filter: drop-shadow(0 10px 12px rgba(4, 19, 29, .18));
}

.europe-shape,
.italy-shape,
.balkans-shape,
.nordic-shape {
  fill: url(#europeLand);
}

.russia-shape {
  fill: url(#russiaLand);
}

.lake-shape {
  fill: #75c7e8;
  stroke: rgba(255,255,255,.9);
}

.sea-line {
  fill: none;
  stroke: rgba(255,255,255,.18);
  stroke-width: 3;
}

.sea-line.thin {
  stroke-width: 2;
}

.border-line {
  fill: none;
  stroke: rgba(16,47,66,.20);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-dasharray: 4 5;
}

.route-path {
  fill: none;
  stroke: rgba(255,255,255,.82);
  stroke-width: 6;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1 12;
}

.city-dot circle {
  fill: #fff9e8;
  stroke: #d65c51;
  stroke-width: 3.5;
  filter: drop-shadow(0 3px 2px rgba(7,31,47,.25));
}

.city-dot.active circle {
  fill: #ffd45e;
  stroke: #fff;
}

.landmark {
  font-size: 13px;
}

.city-dot text:not(.landmark) {
  font-size: 11px;
}

.dice-stage {
  display: grid;
  grid-template-rows: auto auto auto;
  gap: 14px;
  justify-items: stretch;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.78);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.96), rgba(243, 249, 247, .9)),
    rgba(255,255,255,.9);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.82),
    0 14px 24px rgba(12, 52, 64, .08);
}

.dice-frame {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 104px;
  margin-bottom: 2px;
}

.dice-frame::before {
  content: "";
  position: absolute;
  width: 106px;
  height: 106px;
  border-radius: 24px;
  background: radial-gradient(circle, rgba(231, 185, 90, .28), rgba(231, 185, 90, 0) 72%);
  opacity: .78;
}

.dice-feedback {
  display: grid;
  gap: 4px;
  min-height: 52px;
  text-align: center;
}

.dice-feedback strong {
  margin: 0;
  font-size: 19px;
  line-height: 1.05;
}

.dice-feedback span {
  color: rgba(16, 47, 66, .58);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
}

.dice-cube {
  position: relative;
  width: 78px;
  height: 78px;
  border: 4px solid #172432;
  border-radius: 16px;
  background:
    linear-gradient(135deg, #fff 0 52%, #e8f0ef 53%),
    #fff;
  box-shadow:
    0 9px 0 #b7c7c6,
    0 18px 26px rgba(7,31,47,.22);
  transform: rotateX(10deg) rotateZ(-7deg);
  transition: transform .18s ease, box-shadow .18s ease;
}

.dice-cube span {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #172432;
  opacity: 0;
}

.dice-cube span:nth-child(1) { left: 14px; top: 14px; }
.dice-cube span:nth-child(2) { left: 34px; top: 14px; }
.dice-cube span:nth-child(3) { right: 14px; top: 14px; }
.dice-cube span:nth-child(4) { left: 14px; top: 34px; }
.dice-cube span:nth-child(5) { left: 34px; top: 34px; }
.dice-cube span:nth-child(6) { right: 14px; top: 34px; }
.dice-cube span:nth-child(7) { left: 14px; bottom: 14px; }
.dice-cube span:nth-child(8) { left: 34px; bottom: 14px; }
.dice-cube span:nth-child(9) { right: 14px; bottom: 14px; }

.dice-cube[data-face="1"] span:nth-child(5),
.dice-cube[data-face="2"] span:nth-child(1),
.dice-cube[data-face="2"] span:nth-child(9),
.dice-cube[data-face="3"] span:nth-child(1),
.dice-cube[data-face="3"] span:nth-child(5),
.dice-cube[data-face="3"] span:nth-child(9),
.dice-cube[data-face="4"] span:nth-child(1),
.dice-cube[data-face="4"] span:nth-child(3),
.dice-cube[data-face="4"] span:nth-child(7),
.dice-cube[data-face="4"] span:nth-child(9),
.dice-cube[data-face="5"] span:nth-child(1),
.dice-cube[data-face="5"] span:nth-child(3),
.dice-cube[data-face="5"] span:nth-child(5),
.dice-cube[data-face="5"] span:nth-child(7),
.dice-cube[data-face="5"] span:nth-child(9),
.dice-cube[data-face="6"] span:nth-child(1),
.dice-cube[data-face="6"] span:nth-child(3),
.dice-cube[data-face="6"] span:nth-child(4),
.dice-cube[data-face="6"] span:nth-child(6),
.dice-cube[data-face="6"] span:nth-child(7),
.dice-cube[data-face="6"] span:nth-child(9) {
  opacity: 1;
}

.dice-cube.rolling {
  animation: diceShake .72s steps(7, end);
}

.dice-btn {
  flex: initial;
  min-height: 42px;
  font-size: 15px;
}

.dice-btn:disabled {
  cursor: wait;
  opacity: .74;
}

.dice-stage.result .dice-cube {
  transform: rotateX(10deg) rotateZ(-7deg) scale(1.05);
  box-shadow:
    0 9px 0 #b7c7c6,
    0 0 0 10px rgba(231, 185, 90, .12),
    0 20px 30px rgba(7,31,47,.24);
}

.dice-stage.result .dice-feedback strong {
  color: #b74b35;
}

@keyframes pixelBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

@keyframes diceShake {
  0% { transform: translate(0, 0) rotateZ(-7deg) scale(1); }
  14% { transform: translate(-8px, -8px) rotateZ(22deg) scale(1.07); }
  28% { transform: translate(8px, -4px) rotateZ(-24deg) scale(.96); }
  42% { transform: translate(-5px, 7px) rotateZ(34deg) scale(1.08); }
  56% { transform: translate(7px, 4px) rotateZ(-18deg) scale(.98); }
  72% { transform: translate(-3px, -6px) rotateZ(16deg) scale(1.05); }
  100% { transform: translate(0, 0) rotateX(10deg) rotateZ(-7deg) scale(1); }
}

@keyframes resultPulse {
  0%, 100% { transform: scale(1); opacity: .86; }
  50% { transform: scale(1.06); opacity: 1; }
}

@keyframes diceGlow {
  0%, 100% { opacity: .52; transform: scale(.94); }
  50% { opacity: 1; transform: scale(1.08); }
}

@media (max-width: 520px) {
  .city-panel {
    grid-template-columns: 1fr 136px;
    gap: 12px;
    min-height: 188px;
    padding: 16px 14px;
  }

  .city-panel strong {
    font-size: 20px;
  }

  .city-panel p {
    font-size: 13px;
  }

  .dice-stage {
    padding: 8px;
    gap: 10px;
  }

  .dice-frame {
    min-height: 94px;
  }

  .dice-feedback {
    min-height: 48px;
  }

  .dice-feedback strong {
    font-size: 16px;
  }

  .dice-feedback span {
    font-size: 10px;
  }

  .dice-btn {
    min-height: 42px;
    font-size: 15px;
  }

  .dice-cube {
    width: 72px;
    height: 72px;
  }

  .dice-cube span:nth-child(1) { left: 12px; top: 12px; }
  .dice-cube span:nth-child(2) { left: 31px; top: 12px; }
  .dice-cube span:nth-child(3) { right: 12px; top: 12px; }
  .dice-cube span:nth-child(4) { left: 12px; top: 31px; }
  .dice-cube span:nth-child(5) { left: 31px; top: 31px; }
  .dice-cube span:nth-child(6) { right: 12px; top: 31px; }
  .dice-cube span:nth-child(7) { left: 12px; bottom: 12px; }
  .dice-cube span:nth-child(8) { left: 31px; bottom: 12px; }
  .dice-cube span:nth-child(9) { right: 12px; bottom: 12px; }

  .result-route {
    gap: 8px;
  }

  .result-stop {
    padding: 12px 10px;
  }

  .result-stop strong {
    font-size: 20px;
  }
}

/* User-supplied pixel assets */
.asset-character {
  position: absolute;
  z-index: 2;
  width: 148px;
  height: 148px;
  border-radius: 8px;
  object-fit: cover;
  image-rendering: pixelated;
  box-shadow: 0 18px 32px rgba(7, 31, 47, .18);
  animation: assetBob 2.2s steps(3, end) infinite;
}

.asset-map-preview {
  width: 230px;
  height: 172px;
  border: 5px solid rgba(255,255,255,.86);
  border-radius: 8px;
  object-fit: cover;
  image-rendering: pixelated;
  box-shadow: 0 22px 46px rgba(7, 31, 47, .22);
  transform: rotate(-2deg);
}

.asset-character.bear-preview {
  left: 10px;
  top: 70px;
  object-position: 50% 40%;
}

.asset-character.fox-preview {
  right: 8px;
  bottom: 62px;
  object-position: 50% 44%;
  animation-delay: .35s;
}

.role-asset {
  display: block;
  width: 128px;
  height: 142px;
  margin: 6px auto 12px;
  padding: 8px;
  border-radius: 14px;
  object-fit: cover;
  image-rendering: pixelated;
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(244, 249, 248, .9));
  box-shadow:
    0 12px 0 rgba(7,31,47,.10),
    inset 0 1px 0 rgba(255,255,255,.72);
}

.bear-asset {
  object-position: 50% 40%;
}

.fox-asset {
  object-position: 50% 42%;
}

.map-wrap {
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 8px;
}

.map-board {
  position: relative;
  width: 100%;
  aspect-ratio: 1448 / 1086;
  overflow: hidden;
  border: 4px solid #7d5a35;
  border-radius: 8px;
  background: #1a8bb4;
  box-shadow: 0 18px 34px rgba(7, 31, 47, .24);
}

.travel-map-image,
.travel-map-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.travel-map-image {
  z-index: 1;
  object-fit: cover;
  image-rendering: pixelated;
}

.travel-map-overlay {
  z-index: 2;
  pointer-events: none;
}

.travel-map-overlay .route-path {
  fill: none;
  stroke: rgba(255, 246, 205, .92);
  stroke-width: 9;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 18 14;
  filter: drop-shadow(0 3px 0 rgba(94, 58, 28, .55));
}

.travel-map-overlay .city-dot circle {
  fill: #fff6cd;
  stroke: #c45739;
  stroke-width: 5;
  filter: drop-shadow(0 4px 0 rgba(94, 58, 28, .46));
}

.travel-map-overlay .city-dot.active circle {
  fill: #ffcf4d;
  stroke: white;
  stroke-width: 7;
}

.travel-map-overlay .landmark {
  fill: #5a3822;
  font-size: 18px;
  font-weight: 900;
  paint-order: stroke;
  stroke: #fff6cd;
  stroke-width: 3px;
}

.map-piece {
  z-index: 5;
  width: 54px;
  height: 54px;
  padding: 3px;
  border: 4px solid #fff6cd;
  border-radius: 50%;
  background: #fff7df;
  transform: translate(-50%, -88%);
  animation: tokenHop 1.4s steps(2, end) infinite;
}

.map-piece::before,
.map-piece::after {
  content: none;
}

.map-piece img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  image-rendering: pixelated;
}

.map-piece.bear img {
  object-position: 50% 34%;
}

.map-piece.fox img {
  object-position: 50% 36%;
}

.bomb-burst {
  position: absolute;
  z-index: 7;
  width: 96px;
  height: 96px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.28);
  filter: drop-shadow(0 0 18px rgba(255, 0, 0, .18));
}

.bomb-burst::before,
.bomb-burst::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
}

.bomb-burst::before {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 32%, rgba(255,255,255,.30), rgba(255,255,255,0) 24%),
    radial-gradient(circle at 50% 58%, #2f3942 0 42%, #0e1419 43% 100%);
  transform: translate(-50%, -50%);
  box-shadow:
    inset -4px -6px 0 rgba(0,0,0,.22),
    0 10px 14px rgba(0,0,0,.28),
    0 0 0 8px rgba(255, 0, 0, .08),
    0 0 22px rgba(255, 0, 0, .26);
}

.bomb-burst::after {
  width: 18px;
  height: 18px;
  border-radius: 999px 999px 0 999px;
  border: 4px solid #2a3138;
  border-bottom: 0;
  border-left: 0;
  transform: translate(6px, -30px) rotate(-14deg);
  box-shadow: 12px -10px 0 -5px #ff0000;
}

.bomb-burst i {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 44px;
  border-radius: 999px;
  background: linear-gradient(180deg, #fff4f4, #ff1f1f 34%, #ff0000 58%, rgba(255, 0, 0, 0));
  transform-origin: center 42px;
  box-shadow:
    0 0 12px rgba(255, 255, 255, .24),
    0 0 24px rgba(255, 0, 0, .62);
}

.bomb-burst i:nth-child(1) { transform: translate(-50%, -50%) rotate(0deg); }
.bomb-burst i:nth-child(2) { transform: translate(-50%, -50%) rotate(45deg); }
.bomb-burst i:nth-child(3) { transform: translate(-50%, -50%) rotate(90deg); }
.bomb-burst i:nth-child(4) { transform: translate(-50%, -50%) rotate(135deg); }

.bomb-burst.show {
  animation: bombBoom .9s ease-out forwards;
}

.bomb-burst.show i {
  animation: bombSparkBurst .9s ease-out forwards;
}

.dice-art {
  position: relative;
  z-index: 1;
  width: 82px;
  height: 82px;
  border: 4px solid #7d5a35;
  border-radius: 12px;
  object-fit: cover;
  object-position: 50% 8%;
  image-rendering: pixelated;
  background: #fff4dc;
  box-shadow:
    0 7px 0 #c7a574,
    0 15px 22px rgba(7,31,47,.22);
}

.dice-art.rolling {
  animation: diceShake .72s steps(7, end);
}

.dice-stage.rolling .dice-feedback strong {
  color: #b74b35;
  animation: resultPulse .72s steps(4, end) infinite;
}

.dice-stage.rolling .dice-frame::before {
  animation: diceGlow .72s ease-in-out infinite;
}

.arrival-toast {
  position: absolute;
  z-index: 6;
  left: 50%;
  bottom: 14px;
  width: min(88%, 310px);
  padding: 13px 15px;
  border: 4px solid #7d5a35;
  border-radius: 8px;
  color: #5a3822;
  background: rgba(255, 246, 205, .96);
  box-shadow:
    0 7px 0 #c7a574,
    0 18px 26px rgba(7,31,47,.28);
  transform: translate(-50%, 130%);
  opacity: 0;
  pointer-events: none;
  transition: transform .28s steps(3, end), opacity .28s ease;
}

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

.arrival-toast span {
  color: #b74b35;
  font-size: 12px;
  font-weight: 900;
}

.arrival-toast strong {
  display: block;
  margin: 3px 0 4px;
  font-size: 22px;
  line-height: 1;
}

.arrival-toast p {
  margin: 0;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.analysis-card {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 18px;
  text-align: center;
}

.analysis-card > span {
  color: #b74b35;
  font-size: 13px;
  font-weight: 900;
}

.analysis-card h2 {
  margin: 16px 0 10px;
  font-size: 30px;
  line-height: 1.16;
}

.analysis-card p {
  max-width: 320px;
  margin: 0;
  color: rgba(16,47,66,.72);
  font-weight: 800;
  line-height: 1.62;
}

.dance-stage {
  position: relative;
  display: grid;
  place-items: center;
  width: 260px;
  height: 260px;
  margin: 24px auto 8px;
  border: 5px solid #7d5a35;
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 78%, rgba(231,185,90,.36), transparent 34%),
    linear-gradient(180deg, #fff7df, #e7f3ed);
  box-shadow:
    0 9px 0 #c7a574,
    0 24px 38px rgba(7,31,47,.20);
  overflow: hidden;
}

.dance-stage::before {
  content: "";
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 38px;
  height: 20px;
  border-radius: 50%;
  background: rgba(90,56,34,.18);
}

.dance-avatar {
  position: relative;
  z-index: 2;
  width: 180px;
  height: 200px;
  object-fit: cover;
  object-position: 50% 38%;
  image-rendering: pixelated;
  animation: danceWiggle .72s steps(4, end) infinite;
  filter: drop-shadow(0 12px 0 rgba(90,56,34,.18));
}

.dance-stage i {
  position: absolute;
  width: 18px;
  height: 18px;
  background: #e76875;
  transform: rotate(45deg);
  animation: sparkle 1.2s steps(4, end) infinite;
}

.dance-stage i:nth-of-type(1) {
  left: 28px;
  top: 58px;
}

.dance-stage i:nth-of-type(2) {
  right: 38px;
  top: 76px;
  background: #e7b95a;
  animation-delay: .25s;
}

.dance-stage i:nth-of-type(3) {
  right: 64px;
  bottom: 52px;
  background: #79c7b4;
  animation-delay: .5s;
}

.loading-dots {
  display: flex;
  gap: 9px;
  margin-top: 20px;
}

.loading-dots b {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #b74b35;
  animation: dotPulse 1s steps(2, end) infinite;
}

.loading-dots b:nth-child(2) {
  animation-delay: .2s;
}

.loading-dots b:nth-child(3) {
  animation-delay: .4s;
}

@keyframes assetBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@keyframes tokenHop {
  0%, 100% { transform: translate(-50%, -88%); }
  50% { transform: translate(-50%, -100%); }
}

@keyframes danceWiggle {
  0% { transform: translateY(0) rotate(-4deg) scaleX(1); }
  25% { transform: translateY(-10px) rotate(5deg) scaleX(.96); }
  50% { transform: translateY(0) rotate(-6deg) scaleX(1.03); }
  75% { transform: translateY(-7px) rotate(6deg) scaleX(.98); }
  100% { transform: translateY(0) rotate(-4deg) scaleX(1); }
}

@keyframes sparkle {
  0%, 100% { transform: rotate(45deg) scale(.6); opacity: .45; }
  50% { transform: rotate(45deg) scale(1.1); opacity: 1; }
}

@keyframes dotPulse {
  0%, 100% { transform: translateY(0); opacity: .42; }
  50% { transform: translateY(-6px); opacity: 1; }
}

@keyframes bombBoom {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.24); }
  15% { opacity: 1; transform: translate(-50%, -50%) scale(1.12); }
  55% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.45); }
}

@keyframes bombSparkBurst {
  0% { opacity: 0; }
  18% { opacity: 1; height: 54px; }
  100% { opacity: 0; height: 66px; }
}

@keyframes bombScreenShake {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-5px, 4px); }
  40% { transform: translate(5px, -4px); }
  60% { transform: translate(-4px, -2px); }
  80% { transform: translate(4px, 3px); }
  100% { transform: translate(0, 0); }
}
