/* Ватрушка: игровой экран, окна, результат */
/* ---------- HUD ---------- */
#scr-game { touch-action: none; }
.fitwrap.hud { pointer-events: none; }
.hud-top { position: absolute; left: 8px; right: 8px; top: 8px; display: flex; align-items: flex-start; gap: 8px; }
.hud-left { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; width: 104px; flex-shrink: 0; }
.hud-score {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 38px;
  padding: 0 12px 0 5px;
  border-radius: 19px;
  background: var(--navy);
  border: 3px solid #fff;
  color: #fff;
  font-size: 21px;
  font-weight: 900;
  box-shadow: 0 3px 0 rgba(11, 42, 91, .4);
}
.hud-score .ic { width: 26px; height: 26px; }
.hud-mid {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding-top: 2px;
}
.hud-track {
  max-width: 100%;
  padding: 2px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .88);
  border: 2px solid var(--navy);
  font-size: 11px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hud-prog { position: relative; width: 100%; height: 14px; }
.hud-prog-in {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  border: 3px solid var(--navy);
  background: #fff;
  overflow: hidden;
}
#hud-prog-fill {
  width: 100%;
  height: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--grn), var(--yel), var(--pink));
}
#hud-prog-me {
  position: absolute;
  top: -4px;
  width: 22px;
  height: 22px;
  margin-left: -11px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--navy2) 0 30%, var(--sky) 32% 100%);
  border: 3px solid var(--navy);
}
#hud-prog-chase {
  position: absolute;
  top: -3px;
  width: 20px;
  height: 20px;
  margin-left: -10px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--red);
  display: none;
  animation: pulse .5s ease-in-out infinite;
}
.hud-prog .fin { position: absolute; right: -6px; top: -14px; width: 20px; height: 20px; }
.hud-lives { display: flex; gap: 3px; }
.hud-lives .life { width: 22px; height: 22px; filter: grayscale(1); opacity: .35; }
.hud-lives .life.on { filter: none; opacity: 1; }
.pausebtn { pointer-events: auto; background: linear-gradient(180deg, #ff7aa8, #ff3d7f); }
.hud-mission {
  position: absolute;
  left: 8px;
  top: 96px;
  max-width: 250px;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px 3px 4px;
  border-radius: 13px;
  background: rgba(255, 255, 255, .9);
  border: 2px solid var(--navy);
  font-size: 11px;
  font-weight: 800;
}
.hud-mission .ic { width: 18px; height: 18px; }
.hud-mission span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hud-mission b { flex-shrink: 0; color: var(--pink); font-weight: 900; }
.hud-mission.done { background: #d9ffe9; border-color: #0a7a4a; }
.hud-mission.done b { color: #0a7a4a; }
.hud-mission.fail { opacity: .55; }
.hud-powers { position: absolute; left: 8px; top: 130px; display: flex; flex-direction: column; gap: 7px; }
.pchip {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid var(--navy);
  background: var(--c);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 0 rgba(11, 42, 91, .4), inset 0 3px 0 rgba(255, 255, 255, .5);
  animation: popIn .25s ease-out;
}
.pchip .ic { width: 28px; height: 28px; }
.pchip i {
  position: absolute;
  left: 3px;
  right: 3px;
  bottom: -9px;
  height: 7px;
  border-radius: 4px;
  background: var(--navy);
  overflow: hidden;
  border: 1px solid var(--navy);
}
.pchip i b { display: block; width: 100%; height: 100%; background: var(--yel); transform-origin: 0 50%; }
.hud-combo {
  position: absolute;
  left: 50%;
  top: 146px;
  transform: translateX(-50%);
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.hud-combo.show { display: flex; }
.cm-row { display: flex; align-items: baseline; gap: 8px; }
#hud-mult {
  font-size: 46px;
  line-height: 1;
  font-weight: 900;
  font-style: italic;
  color: var(--yel);
  text-shadow: 0 3px 0 var(--navy), 3px 0 0 var(--navy), -3px 0 0 var(--navy), 0 -3px 0 var(--navy), 2px 2px 0 var(--navy), -2px 2px 0 var(--navy), 0 7px 0 rgba(11, 42, 91, .3);
  display: inline-block;
}
.hud-combo[data-m="3"] #hud-mult, .hud-combo[data-m="4"] #hud-mult { color: var(--org); }
.hud-combo[data-m="5"] #hud-mult, .hud-combo[data-m="6"] #hud-mult { color: var(--pink); }
.hud-combo[data-m="7"] #hud-mult, .hud-combo[data-m="8"] #hud-mult {
  color: #ff5cf0;
  animation: pulse .4s ease-in-out infinite;
}
#hud-cpts {
  font-size: 24px;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 2px 0 var(--navy), 2px 0 0 var(--navy), -2px 0 0 var(--navy), 0 -2px 0 var(--navy);
}
.cm-bar {
  width: 130px;
  height: 9px;
  border-radius: 5px;
  border: 2px solid var(--navy);
  background: rgba(255, 255, 255, .8);
  overflow: hidden;
}
#hud-ctimer {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--pink), var(--yel));
}
.hud-bank { position: absolute; left: 0; right: 0; top: 330px; text-align: center; font-size: 38px; font-weight: 900; font-style: italic; color: #fff; opacity: 0; pointer-events: none;
  text-shadow: 0 3px 0 var(--pink), 3px 0 0 var(--navy), -3px 0 0 var(--navy), 0 -3px 0 var(--navy), 0 8px 0 rgba(11, 42, 91, .3); }
.hud-bank.show { animation: bank 1.25s ease-out forwards; }
@keyframes bank { 0% { transform: scale(.4); opacity: 0; } 18% { transform: scale(1.25); opacity: 1; } 70% { transform: translateY(-20px) scale(1); opacity: 1; } 100% { transform: translateY(-150px) scale(.5); opacity: 0; } }
.hud-pops {
  position: absolute;
  left: 0;
  right: 0;
  top: 206px;
  height: 112px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 2px;
  overflow: hidden;
}
.pop {
  display: flex;
  align-items: baseline;
  gap: 7px;
  white-space: nowrap;
  animation: popFeed 1.25s ease-out forwards;
  flex-shrink: 0;
}
.pop b {
  font-size: 18px;
  font-weight: 900;
  font-style: italic;
  color: #fff;
  text-shadow: 0 2px 0 var(--navy), 2px 0 0 var(--navy), -2px 0 0 var(--navy), 0 -2px 0 var(--navy), 1px 1px 0 var(--navy), -1px 1px 0 var(--navy);
}
.pop span {
  font-size: 15px;
  font-weight: 900;
  color: var(--yel);
  text-shadow: 0 2px 0 var(--navy), 1px 0 0 var(--navy), -1px 0 0 var(--navy), 0 -1px 0 var(--navy);
}
@keyframes popFeed { 0% { transform: scale(.4); opacity: 0; } 14% { transform: scale(1.18); opacity: 1; } 24% { transform: scale(1); } 78% { opacity: 1; } 100% { opacity: 0; } }
.pop.trick b { color: #8ff7ff; font-size: 21px; }
.pop.clean b { color: #9dffb5; }
.pop.gold b { color: var(--yel); font-size: 21px; }
.pop.near b { color: #ffc2f0; }
.pop.air b { color: #cfe4ff; }
.pop.power b { color: #b6ffcf; font-size: 21px; }
.pop.warn b { color: #ffd9a8; }
.pop.bad b { color: #ff8a8a; font-size: 21px; }
.hud-count { position: absolute; left: 0; right: 0; top: 36%; text-align: center; font-size: 78px; font-weight: 900; font-style: italic; color: var(--yel); opacity: 0;
  text-shadow: 0 5px 0 var(--navy), 5px 0 0 var(--navy), -5px 0 0 var(--navy), 0 -5px 0 var(--navy), 4px 4px 0 var(--navy), -4px 4px 0 var(--navy), 4px -4px 0 var(--navy), -4px -4px 0 var(--navy), 0 12px 0 var(--pink); }
.hud-count.show { animation: count .85s ease-out forwards; }
@keyframes count { 0% { transform: scale(2.4) rotate(-8deg); opacity: 0; } 25% { transform: scale(1) rotate(-4deg); opacity: 1; } 75% { opacity: 1; } 100% { transform: scale(.8) rotate(-4deg); opacity: 0; } }
.hud-warn {
  position: absolute;
  left: 50%;
  top: 326px;
  transform: translateX(-50%);
  display: none;
  align-items: center;
  gap: 6px;
  padding: 5px 14px 5px 8px;
  border-radius: 18px;
  background: var(--red);
  border: 3px solid #fff;
  color: #fff;
  font-size: 17px;
  font-weight: 900;
  white-space: nowrap;
  box-shadow: 0 4px 0 rgba(11, 42, 91, .4);
}
.hud-warn.show { display: flex; animation: blink .32s steps(2) infinite; }
@keyframes blink { 50% { background: var(--org); } }
.hud-swipe {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 200px;
  display: none;
  align-items: center;
  justify-content: center;
  gap: 14px;
}
.hud-swipe.show { display: flex; }
.hud-swipe .ic { width: 62px; height: 62px; animation: swipe 1s ease-in-out infinite; }
@keyframes swipe { 0%, 100% { transform: translateX(-46px) rotate(-12deg); } 50% { transform: translateX(46px) rotate(12deg); } }
.sw-arrow { width: 0; height: 0; border: 16px solid transparent; }
.sw-arrow.l { border-right-color: #fff; filter: drop-shadow(0 0 0 var(--navy)) drop-shadow(-3px 0 0 var(--navy)); }
.sw-arrow.r { border-left-color: #fff; filter: drop-shadow(3px 0 0 var(--navy)); }
.hud-hint {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 84px;
  display: none;
  align-items: center;
  gap: 8px;
  padding: 9px 12px 9px 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .95);
  border: 3px solid var(--navy);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.25;
  box-shadow: 0 5px 0 rgba(11, 42, 91, .35);
}
.hud-hint.show { display: flex; animation: popIn .3s ease-out; }
.hud-hint .ic { width: 30px; height: 30px; }
.hud-speed {
  position: absolute;
  left: 10px;
  bottom: 12px;
  display: flex;
  align-items: baseline;
  gap: 4px;
  padding: 3px 12px;
  border-radius: 16px;
  background: var(--navy);
  border: 3px solid #fff;
  color: #fff;
}
.hud-speed b { font-size: 24px; font-weight: 900; font-style: italic; min-width: 34px; text-align: right; }
.hud-speed span { font-size: 11px; font-weight: 800; opacity: .85; }
#hud-danger { position: absolute; inset: 0; pointer-events: none; opacity: 0; z-index: 1;
  background: radial-gradient(ellipse at 50% 55%, rgba(255, 255, 255, 0) 42%, rgba(255, 255, 255, .85) 100%); box-shadow: inset 0 0 0 6px rgba(242, 58, 58, .75), inset 0 0 60px 24px rgba(242, 58, 58, .5); }
#flash { position: absolute; inset: 0; pointer-events: none; opacity: 0; z-index: 2; }
#flash.go.hit {
  background: radial-gradient(ellipse, rgba(242, 58, 58, 0) 30%, rgba(242, 58, 58, .85));
  animation: flash .45s ease-out;
}
#flash.go.white { background: #fff; animation: flash .55s ease-out; }
@keyframes flash { 0% { opacity: .9; } 100% { opacity: 0; } }
.fitwrap.hud { z-index: 3; }

/* ---------- Окна ---------- */
.overlay { background: rgba(11, 42, 91, .66); }
.panel {
  position: relative; width: 334px; display: flex; flex-direction: column; gap: 10px; padding: 16px 14px 16px; border-radius: 26px; border: 4px solid var(--navy);
  background: linear-gradient(180deg, #ffffff, #eaf6ff); box-shadow: 0 9px 0 rgba(4, 18, 44, .55); animation: popIn .26s cubic-bezier(.3, 1.4, .5, 1);
}
.p-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 44px;
  font-size: 22px;
  font-weight: 900;
  font-style: italic;
  text-align: center;
}
.p-title .ic { width: 30px; height: 30px; }
.p-title i { font-style: normal; font-size: 13px; font-weight: 800; color: #3b5687; white-space: nowrap; }
.p-text { font-size: 15px; font-weight: 700; text-align: center; line-height: 1.35; color: #24437a; }
.p-note { font-size: 11px; font-weight: 700; text-align: center; color: #4a6596; line-height: 1.3; }
.panel.pass { border-top-width: 16px; border-top-color: var(--acc, var(--pink)); padding-top: 10px; }
.pass-hole {
  width: 64px;
  height: 13px;
  border-radius: 7px;
  background: var(--navy);
  margin: 0 auto 2px;
  box-shadow: inset 0 3px 0 rgba(0, 0, 0, .4);
}
.pass-sub {
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  color: #3b5687;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 40px;
}
.pass-title {
  text-align: center;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 900;
  font-style: italic;
  color: var(--navy);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.perf { height: 0; border-top: 3px dashed #9db7dd; margin: 2px -14px; position: relative; }
.perf::before, .perf::after {
  content: '';
  position: absolute;
  top: -11px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #25417a;
}
.perf::before { left: -12px; } .perf::after { right: -12px; }
.mrow {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px 7px 7px;
  border-radius: 14px;
  border: 2px dashed var(--navy);
  background: #fff;
  font-size: 13px;
  font-weight: 800;
}
.mrow .ic { width: 24px; height: 24px; }
.mrow > span { flex: 1; min-width: 0; line-height: 1.2; }
.mrow > b { display: flex; align-items: center; gap: 3px; flex-shrink: 0; color: var(--pink); font-weight: 900; }
.mrow > b .ic { width: 18px; height: 18px; }
.mrow > b i { font-style: normal; }
.mrow.done { background: #d9ffe9; border-style: solid; border-color: #0a7a4a; }
.mrow.done > b { color: #0a7a4a; }
.mrow.now { animation: bump .4s ease-out .9s both; }
.brief-stars { display: flex; justify-content: center; }
.brief-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.brief-grid div {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 2px;
  border-radius: 13px;
  background: #dff0ff;
  border: 2px solid var(--navy);
  min-width: 0;
}
.brief-grid span { font-size: 10px; font-weight: 800; color: #3b5687; }
.brief-grid b { font-size: 17px; font-weight: 900; }
.brief-thr { display: flex; justify-content: space-around; gap: 6px; }
.brief-thr span { display: flex; align-items: center; gap: 1px; font-size: 14px; font-weight: 900; }
.brief-thr .ic { width: 18px; height: 18px; }
.brief-thr b { margin-left: 4px; }
.brief-chase {
  display: none;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  border-radius: 14px;
  background: #ffe6d6;
  border: 2px solid var(--red);
  font-size: 12px;
  font-weight: 800;
  color: #9c1f1f;
}
.brief-chase .ic { width: 26px; height: 26px; }

/* рейтинг */
.lb-mine {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 14px;
  border-radius: 14px;
  background: var(--navy);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.lb-mine b { font-size: 20px; font-weight: 900; color: var(--yel); }
#lb-list { overflow-y: auto; max-height: 320px; display: flex; flex-direction: column; gap: 6px; }
.lb-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 14px;
  border: 2px solid var(--navy);
  background: #fff;
  font-size: 14px;
  font-weight: 800;
  flex-shrink: 0;
}
.lb-medal { width: 30px; text-align: center; flex-shrink: 0; font-weight: 900; color: #3b5687; }
.lb-medal.gold, .lb-medal.silver, .lb-medal.bronze {
  height: 30px;
  line-height: 26px;
  border-radius: 50%;
  border: 2px solid var(--navy);
  color: var(--navy);
}
.lb-medal.gold { background: radial-gradient(circle at 35% 30%, #fff7c2, #ffc21a); }
.lb-medal.silver { background: radial-gradient(circle at 35% 30%, #ffffff, #b4c0d6); }
.lb-medal.bronze { background: radial-gradient(circle at 35% 30%, #ffd9b0, #e08a3c); }
.lb-avatar {
  position: relative;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(180deg, #7fd4ff, #1e7bff);
  color: #fff;
  font-weight: 900;
  border: 2px solid var(--navy);
}
.lb-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lb-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-score { flex-shrink: 0; font-weight: 900; color: var(--pink); }
.lb-empty { text-align: center; padding: 20px; font-size: 14px; font-weight: 800; color: #3b5687; }
.lb-row.top-1 { background: linear-gradient(90deg, #fff6c2, #fff); }
.lb-row.top-2 { background: linear-gradient(90deg, #eef2f8, #fff); }
.lb-row.top-3 { background: linear-gradient(90deg, #ffe9d4, #fff); }
.lb-row.me { border-color: var(--pink); box-shadow: 0 0 0 3px rgba(255, 61, 127, .35); }

/* награды */
.ach-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 2px;
  border-radius: 11px;
  background: #dff0ff;
  border: 2px solid var(--navy);
  min-width: 0;
}
.stat span {
  font-size: 9px;
  font-weight: 800;
  color: #3b5687;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.stat b {
  font-size: 13px;
  font-weight: 900;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#ach-list { overflow-y: auto; max-height: 300px; display: flex; flex-direction: column; gap: 6px; }
.arow {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 14px;
  border: 2px solid var(--navy);
  background: #fff;
  flex-shrink: 0;
}
.amedal {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--navy);
  background: #dbe3ef;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.amedal .ic { width: 26px; height: 26px; filter: grayscale(1); opacity: .6; }
.arow.done { background: linear-gradient(90deg, #fff6c2, #fff); }
.arow.done .amedal { background: radial-gradient(circle at 35% 30%, #fff7c2, #ffc21a); }
.arow.done .amedal .ic { filter: none; opacity: 1; }
.ainfo { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.ainfo b { font-size: 14px; font-weight: 900; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ainfo span {
  font-size: 11px;
  font-weight: 700;
  color: #3b5687;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ainfo i {
  display: block;
  height: 6px;
  border-radius: 3px;
  background: #d6e3f5;
  overflow: hidden;
  border: 1px solid var(--navy);
  margin-top: 2px;
}
.ainfo em { display: block; height: 100%; background: linear-gradient(90deg, var(--grn), var(--yel)); }
.arew { display: flex; align-items: center; gap: 2px; font-size: 13px; font-weight: 900; flex-shrink: 0; }
.arew .ic { width: 20px; height: 20px; }

/* настройки */
.set-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px 6px 10px;
  border-radius: 15px;
  border: 2px solid var(--navy);
  background: #fff;
  font-size: 16px;
  font-weight: 800;
}
.set-row span { flex: 1; }
.set-row .ic { width: 28px; height: 28px; }
.tgl {
  position: relative;
  width: 66px;
  height: 40px;
  border-radius: 20px;
  border: 3px solid var(--navy);
  background: #c5cfde;
  transition: background .15s;
  flex-shrink: 0;
}
.tgl i {
  position: absolute;
  left: 3px;
  top: 3px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--navy);
  transition: transform .15s;
  box-shadow: 0 2px 0 rgba(11, 42, 91, .3);
}
.tgl.on { background: var(--grn); }
.tgl.on i { transform: translateX(26px); }
.help-list { display: flex; flex-direction: column; gap: 6px; }
.hrow {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 9px;
  border-radius: 14px;
  border: 2px solid var(--navy);
  background: #fff;
}
.hges {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(180deg, #d6ebff, #7fc0ff);
  border: 2px solid var(--navy);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hges i { display: block; width: 24px; height: 5px; border-radius: 3px; background: var(--navy); position: relative; }
.hges i::after {
  content: '';
  position: absolute;
  right: -4px;
  top: -5.500px;
  border: 8px solid transparent;
  border-left-color: var(--navy);
  border-right-width: 0;
}
.hges.tap i { width: 16px; height: 16px; border-radius: 50%; background: var(--pink); border: 3px solid var(--navy); }
.hges.tap i::after { display: none; }
.hinfo { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.hinfo b { font-size: 15px; font-weight: 900; }
.hinfo span { font-size: 11px; font-weight: 700; color: #3b5687; }
.hpts { font-size: 15px; font-weight: 900; color: var(--pink); flex-shrink: 0; }

/* пауза, оживление, подарок, финал */
.pause-track {
  text-align: center;
  font-size: 16px;
  font-weight: 900;
  color: #24437a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pause-score {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 14px;
  border-radius: 14px;
  background: var(--navy);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.pause-score b { font-size: 22px; font-weight: 900; color: var(--yel); }
.daily-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 5px 2px;
  border-radius: 13px;
  border: 2px solid var(--navy);
  background: #eaf2fb;
  font-size: 12px;
  font-weight: 900;
  opacity: .7;
}
.day b { font-size: 10px; font-weight: 800; color: #3b5687; }
.day .ic { width: 26px; height: 26px; }
.day.got { background: #d9ffe9; opacity: 1; }
.day.now {
  background: linear-gradient(180deg, #fff6c2, var(--yel));
  opacity: 1;
  animation: pulse 1s ease-in-out infinite;
}
.day:last-child { grid-column: span 2; }
.finale-art { position: relative; height: 110px; display: flex; align-items: flex-end; justify-content: center; }
.finale-art .ic { width: 120px; height: 110px; }
.finale-art .ic.t {
  position: absolute;
  width: 52px;
  height: 52px;
  top: 0;
  left: 50%;
  margin-left: -8px;
  animation: logoBob 1s ease-in-out infinite;
}

/* результат */
.res-reason {
  text-align: center;
  font-size: 14px;
  font-weight: 800;
  color: #b02020;
  padding: 5px 10px;
  border-radius: 12px;
  background: #ffe3e3;
  border: 2px solid var(--red);
}
.res-stars { justify-content: center; height: 70px; align-items: center; }
.res-score { position: relative; display: flex; align-items: center; justify-content: center; }
.res-score > b {
  font-size: 46px;
  line-height: 1;
  font-weight: 900;
  font-style: italic;
  color: var(--navy);
  text-shadow: 0 4px 0 var(--yel);
}
.res-record {
  position: absolute;
  right: 0;
  top: -8px;
  display: none;
  align-items: center;
  gap: 3px;
  padding: 2px 9px 2px 3px;
  border-radius: 13px;
  background: var(--pink);
  border: 2px solid var(--navy);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  transform: rotate(8deg);
}
.res-record .ic { width: 20px; height: 20px; }
.res-lines { display: grid; grid-template-columns: 1fr 1fr; gap: 3px 10px; }
.rline {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  font-size: 12px;
  font-weight: 800;
  color: #24437a;
  min-width: 0;
}
.rline span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rline b { font-weight: 900; color: var(--navy); flex-shrink: 0; }
.res-coins {
  align-self: center;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 3px 14px 3px 6px;
  border-radius: 17px;
  background: linear-gradient(180deg, #fff6c2, var(--yel));
  border: 3px solid var(--navy);
  font-size: 13px;
  font-weight: 800;
}
.res-coins b { font-size: 20px; font-weight: 900; }
.res-coins .ic { width: 26px; height: 26px; }
.res-ach { display: none; flex-wrap: wrap; gap: 5px; justify-content: center; }
.achip {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px 2px 3px;
  border-radius: 12px;
  background: #fff;
  border: 2px solid var(--vio);
  font-size: 11px;
  font-weight: 900;
  color: #4a2fc9;
  max-width: 100%;
}
.achip .ic { width: 18px; height: 18px; }
.achip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.res-hint { text-align: center; font-size: 12px; font-weight: 800; color: #3b5687; }
.panel.lose .pass-title { color: #b02020; }
#res-again.primary { background: linear-gradient(180deg, #ff7aa8 0%, #ff3d7f 55%, #ff7a1a 100%); }

/* ---------- Подготовка трассы и тост ---------- */
#veil {
  position: absolute;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #1e8bff, #7fcbff 55%, #eaf6ff);
}
#veil.show { display: flex; }
.veil-in { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.veil-in .ic { width: 84px; height: 84px; animation: spin 1.4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
#veil-text {
  font-size: 22px;
  font-weight: 900;
  font-style: italic;
  color: #fff;
  text-shadow: 0 3px 0 var(--navy), 2px 0 0 var(--navy), -2px 0 0 var(--navy), 0 -2px 0 var(--navy);
}
.veil-bar {
  width: 200px;
  height: 16px;
  border-radius: 9px;
  border: 3px solid var(--navy);
  background: #fff;
  overflow: hidden;
}
#veil-fill {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  transition: transform .15s;
  background: linear-gradient(90deg, var(--pink), var(--yel));
}
#toast {
  position: absolute;
  left: 50%;
  bottom: 88px;
  transform: translate(-50%, 20px);
  max-width: 88%;
  padding: 9px 16px;
  border-radius: 18px;
  background: var(--navy);
  border: 3px solid var(--yel);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  z-index: 95;
  transition: opacity .2s, transform .2s;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Вызов на лету и вступление ---------- */
.hud-quest {
  position: absolute;
  right: 8px;
  top: 96px;
  width: 150px;
  display: none;
  flex-direction: column;
  gap: 3px;
  padding: 5px 8px 6px;
  border-radius: 14px;
  background: rgba(122, 92, 255, .94);
  border: 2px solid #fff;
  color: #fff;
  box-shadow: 0 3px 0 rgba(11, 42, 91, .4);
}
.hud-quest.show { display: flex; animation: popIn .3s ease-out; }
.hq-row { display: flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 800; line-height: 1.15; }
.hq-row .ic { width: 18px; height: 18px; }
.hq-row span { flex: 1; min-width: 0; }
.hq-row b { flex-shrink: 0; font-weight: 900; color: var(--yel); }
.hq-bar { height: 6px; border-radius: 3px; background: rgba(11, 42, 91, .5); overflow: hidden; }
.hq-bar i { display: block; width: 100%; height: 100%; transform-origin: 0 50%; background: var(--yel); }
.hud-quest em {
  position: absolute;
  right: 6px;
  bottom: -10px;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
  color: var(--navy);
  background: var(--yel);
  border: 2px solid var(--navy);
  border-radius: 9px;
  padding: 0 6px;
}
.intro-art {
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  border: 3px solid var(--navy);
  background: radial-gradient(circle at 50% 40%, #ffffff, #7fcbff 70%, #1e8bff);
}
.intro-art .ic { width: 96px; height: 96px; }
.intro-dots { display: flex; justify-content: center; gap: 7px; }
.intro-dots i { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--navy); background: #d6e3f5; }
.intro-dots i.on { background: var(--pink); width: 26px; border-radius: 6px; }
.link.center { align-self: center; }
.panel .row .btn { font-size: 15px; gap: 5px; padding: 6px 6px; }
.panel .row .btn .ic { width: 22px; height: 22px; }
.panel .btn.wide.sm { font-size: 14px; }
