

@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("fonts/AtkinsonHyperlegible-Regular.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: block;
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("fonts/AtkinsonHyperlegible-Bold.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: block;
}

:root {
  --page: #fbf6f2;          
  --ink: #2a1f24;
  --ink-soft: #6d5a62;
  --accent: #f6c6d4;         
  --accent-deep: #b3386a;    
  --accent-dark: #8a2550;
  --card: #ffffff;
  --line: #ead9df;
  --good: #2f8f5b;
  --good-bg: #dff3e6;
  --oops: #c0621a;
  --oops-bg: #fde9d6;
  --locked: #e9e1e4;
  --font: "Atkinson Hyperlegible", system-ui, -apple-system, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  font-size: 24px;
  line-height: 1.3;
  -webkit-text-size-adjust: 100%;
  -webkit-user-select: none; user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  overflow: hidden;
}
button {
  font: inherit; color: inherit; border: 0; background: none; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
button:focus-visible { outline: 4px solid var(--accent-deep); outline-offset: 3px; }

#app {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  grid-template-columns: minmax(0, 1fr);
  height: 100%;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}


#bar {
  display: flex; align-items: center; gap: 16px;
  padding-block: 10px 6px;
  min-height: 64px;
}
#title { font-weight: 700; font-size: 30px; letter-spacing: 0.2px; display: flex; align-items: center; gap: 10px; }
#title .paw { width: 34px; height: 34px; fill: var(--accent-deep); }
#status { margin-left: auto; color: var(--ink-soft); font-size: 22px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.chip {
  padding: 8px 18px; border-radius: 999px; background: var(--card);
  border: 2px solid var(--line); font-size: 22px; font-weight: 700; white-space: nowrap;
}
.chip:active { background: var(--accent); }
#sound, #parents { min-width: 64px; }

#parents.holding { background: var(--accent); transition: background 1.5s linear; }

#screen { min-height: 0; position: relative; }
.scroll { height: 100%; overflow-y: auto; -webkit-overflow-scrolling: touch; padding-bottom: 24px; }


.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 72px; padding: 0 30px; border-radius: 22px;
  background: var(--card); border: 3px solid var(--line);
  font-size: 28px; font-weight: 700;
}
.btn.primary { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; }
.btn.primary:active { background: var(--accent-dark); }
.btn:active { transform: translateY(2px); }
.btn small { font-weight: 400; font-size: 22px; opacity: 0.85; }
.muted { color: var(--ink-soft); }
h2 { font-size: 32px; margin: 0; text-wrap: balance; }


.home {
  height: 100%;
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 32px;
  align-items: center; padding-block: 8px 20px;
}
.home .hero { position: relative; }
.home .hero .frame { aspect-ratio: 4 / 3; }
.home .hero .caption { margin-top: 10px; color: var(--ink-soft); font-size: 22px; }
.home .menu { display: flex; flex-direction: column; gap: 18px; }
.home .menu .btn { width: 100%; min-height: 96px; font-size: 34px; justify-content: flex-start; padding: 0 28px; }
.home .menu .btn .ico { font-size: 40px; width: 52px; text-align: center; }
.home .today { font-size: 26px; }
.home .today b { color: var(--accent-deep); }


.frame {
  position: relative; width: 100%; max-width: 100%; aspect-ratio: 4 / 3;
  border-radius: 22px; overflow: hidden; background: var(--accent);
  box-shadow: 0 2px 0 var(--line), 0 10px 30px rgba(120, 40, 70, 0.12);
}
.frame img, .frame svg.dog { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.tiles {
  position: absolute; inset: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: repeat(3, 1fr);
}
.tile {
  background: var(--tile, #f6c6d4);
  border: 2px solid rgba(255, 255, 255, 0.85);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.45s cubic-bezier(.3,1.6,.6,1), opacity 0.45s ease;
}
.tile svg { width: 38%; height: 38%; fill: rgba(255, 255, 255, 0.75); }
.tile.gone { transform: scale(0.2) rotate(25deg); opacity: 0; pointer-events: none; }
.credit { font-size: 15px; color: var(--ink-soft); margin-top: 6px; line-height: 1.25; overflow-wrap: anywhere; }


.play {
  height: 100%;
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(330px, 1fr); gap: 28px;
  padding-block: 6px 14px; align-items: start;
}
.play .left { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.play .left .credit:empty, .play .left > div:empty { display: none; }
.paws { display: flex; gap: 6px; flex-wrap: wrap; }
.paws svg { width: 30px; height: 30px; fill: var(--locked); transition: fill 0.3s; }
.paws svg.on { fill: var(--accent-deep); }
.timer { height: 18px; border-radius: 9px; background: var(--locked); overflow: hidden; }
.timer i { display: block; height: 100%; background: var(--accent-deep); width: 100%; transition: width 0.25s linear; }
.timer.low i { background: var(--oops); }

.panel { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.sum {
  font-size: 96px; line-height: 1; font-weight: 700; text-align: center;
  font-variant-numeric: tabular-nums; letter-spacing: 1px; padding-top: 4px;
}
.sum .x { color: var(--accent-deep); margin: 0 0.12em; }
.answer {
  height: 92px; border-radius: 20px; background: var(--card); border: 3px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: 64px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.answer.empty::after { content: "?"; color: var(--line); }
.answer.ok { border-color: var(--good); background: var(--good-bg); color: var(--good); }
.answer.no { border-color: var(--oops); background: var(--oops-bg); animation: shake 0.4s; }
@keyframes shake { 20%, 60% { transform: translateX(-10px); } 40%, 80% { transform: translateX(10px); } }

.pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pad button {
  height: 74px; border-radius: 18px; background: var(--card); border: 3px solid var(--line);
  font-size: 40px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.pad button:active { background: var(--accent); }
.pad .ok { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; font-size: 32px; }
.pad .ok:active { background: var(--accent-dark); }
.pad .del { font-size: 32px; }

.pad .ok.wide { grid-column: 1 / -1; }
.sum.text { font-size: 64px; letter-spacing: 0; }
.sum.text.long { font-size: 46px; }
.feedback .big.text { font-size: 36px; }
.feedback .worked { font-size: 22px; line-height: 1.4; }
.hintbox .rule { font-size: 21px; line-height: 1.4; padding: 6px 4px; text-align: left; }
.topics { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.topics .btn { font-size: 22px; min-height: 56px; padding: 0 18px; }
.panel .row { display: flex; gap: 10px; }
.panel .row .btn { flex: 1; min-height: 60px; font-size: 24px; }

.feedback {
  border-radius: 22px; background: var(--oops-bg); padding: 18px 20px;
  display: flex; flex-direction: column; gap: 12px; align-items: center; text-align: center;
}
.feedback .big { font-size: 46px; font-weight: 700; font-variant-numeric: tabular-nums; }
.feedback .big b { color: var(--oops); }
.dots { display: grid; gap: 5px; justify-content: center; }
.dots span { width: var(--d, 18px); height: var(--d, 18px); border-radius: 50%; background: var(--accent-deep); }
.dots span.gap-c { margin-left: 8px; }
.dots span.gap-r { margin-top: 8px; }
.hintbox { border-radius: 18px; background: var(--card); border: 3px dashed var(--line); padding: 8px 12px; text-align: center; }
.hintbox .muted { font-size: 18px; margin-bottom: 6px; }


.reveal .panel { gap: 16px; }
.reveal .found { font-size: 24px; color: var(--accent-deep); font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; }
.reveal .breed { font-size: 48px; line-height: 1.05; font-weight: 700; text-wrap: balance; overflow-wrap: anywhere; }
.reveal .breed.long { font-size: 38px; }
.reveal .fact { font-size: 26px; line-height: 1.35; }
.badge { display: inline-block; padding: 6px 16px; border-radius: 999px; background: var(--accent); font-weight: 700; font-size: 22px; }
.badge.gold { background: #ffe08a; }
.progressline { display: flex; flex-direction: column; gap: 6px; font-size: 22px; }
.bar { height: 14px; border-radius: 7px; background: var(--locked); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent-deep); }
.reveal .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.pop { animation: pop 0.6s cubic-bezier(.3,1.6,.6,1); }
@keyframes pop { from { transform: scale(0.85); opacity: 0.3; } to { transform: none; opacity: 1; } }


.album { display: flex; flex-direction: column; gap: 26px; padding-top: 6px; }
.album .head { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.album .series h3 { margin: 0 0 10px; font-size: 28px; display: flex; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.album .series h3 .muted { font-size: 22px; font-weight: 400; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
@media (min-width: 1000px) { .cards { grid-template-columns: repeat(8, minmax(0, 1fr)); } }   
.card { display: flex; flex-direction: column; gap: 6px; text-align: left; min-width: 0; }
.card .thumb { position: relative; aspect-ratio: 4 / 3; border-radius: 14px; overflow: hidden; background: var(--locked); max-width: 100%; }
.card .thumb img, .card .thumb svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card .thumb .q { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 48px; font-weight: 700; color: #fff; }
.card .nm { font-size: 18px; font-weight: 700; line-height: 1.2; overflow-wrap: anywhere; }
.card.locked .nm { color: var(--ink-soft); font-weight: 400; }
.card .count { position: absolute; right: 6px; bottom: 6px; background: rgba(255,255,255,0.9); border-radius: 999px; padding: 0 9px; font-size: 16px; font-weight: 700; }

.sheet {
  position: absolute; inset: 0; z-index: 5; background: var(--page);
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 28px; padding-block: 6px 14px;
}
.sheet .more { display: flex; gap: 10px; flex-wrap: wrap; }
.sheet .more button { width: 120px; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; position: relative; border: 3px solid transparent; }
.sheet .more button.sel { border-color: var(--accent-deep); }
.sheet .more img, .sheet .more svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }


.center { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; text-align: center; padding: 20px; }
.center .huge { font-size: 120px; font-weight: 700; line-height: 1; color: var(--accent-deep); font-variant-numeric: tabular-nums; }

.play.check .left { justify-content: center; align-items: center; gap: 20px; }
.play.check .left .huge { font-size: 96px; font-weight: 700; line-height: 1; color: var(--accent-deep); font-variant-numeric: tabular-nums; }
.play.check .left .bar { width: 80%; }
.center p { max-width: 30em; margin: 0; font-size: 28px; }
.center .actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.minis { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.minis .thumb { width: 120px; aspect-ratio: 4/3; border-radius: 12px; overflow: hidden; position: relative; }
.minis img, .minis svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.toast {
  position: absolute; left: 50%; top: 18px; transform: translateX(-50%); z-index: 6;
  background: var(--accent-deep); color: #fff; border-radius: 999px; padding: 10px 26px; font-weight: 700;
  font-size: 26px; white-space: nowrap; animation: pop 0.5s; max-width: 94%; overflow: hidden; text-overflow: ellipsis;
}


.home .menu .btn.boss-btn { background: #3b2350; border-color: #3b2350; color: #ffe08a; }
.home .menu .btn.boss-btn:active { background: #2a1838; }
.king-intro, .king { position: relative; display: inline-flex; flex-direction: column; align-items: center; line-height: 1; }
.king-intro .crown { font-size: 64px; margin-bottom: -18px; }
.king-intro .face { font-size: 140px; }
.arena {
  position: relative; width: 100%; aspect-ratio: 16 / 10; border-radius: 22px; overflow: hidden;
  background: radial-gradient(ellipse at 50% 30%, #6a3f8c 0%, #3b2350 60%, #241433 100%);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 30px rgba(60, 20, 80, 0.25);
}
.king .crown { font-size: 72px; margin-bottom: -22px; animation: bob 2.4s ease-in-out infinite; }
.king .face { font-size: 190px; filter: drop-shadow(0 8px 0 rgba(0, 0, 0, 0.25)); }
.king.hit { animation: hit 0.45s; }
@keyframes bob { 50% { transform: translateY(-8px) rotate(-4deg); } }
@keyframes hit { 15% { transform: translateX(-18px) rotate(-8deg); filter: brightness(1.8); } 45% { transform: translateX(14px) rotate(6deg); } 75% { transform: translateX(-6px); } }
.boss.phase2 .arena { background: radial-gradient(ellipse at 50% 30%, #a3324a 0%, #5a1a32 60%, #2e0d1c 100%); }
.boss.phase2 .king .face { animation: rage 0.9s ease-in-out infinite; }
.boss.phase3 .arena { background: radial-gradient(ellipse at 50% 30%, #e0702a 0%, #7a1f1f 55%, #2a0a0a 100%); }
.boss.phase3 .king .face { animation: rage 0.5s ease-in-out infinite; }
@keyframes rage { 50% { transform: scale(1.06) rotate(2deg); } }
.attacker {
  position: absolute; left: 4%; bottom: 6%; width: 34%; z-index: 3;
  animation: lunge 0.9s cubic-bezier(.3,1.3,.6,1) forwards;
}
.attacker .thumb { position: relative; aspect-ratio: 4 / 3; border-radius: 16px; overflow: hidden; border: 4px solid #fff; background: var(--accent); }
.attacker .thumb img, .attacker .thumb svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.attacker .woof {
  position: absolute; right: -14px; top: -26px; background: #fff; color: var(--accent-dark); border-radius: 999px;
  padding: 4px 14px; font-weight: 700; font-size: 26px; white-space: nowrap;
}
.attacker.big .woof { background: #ffe08a; font-size: 30px; }
@keyframes lunge { 0% { transform: translateX(-120%) rotate(-10deg); opacity: 0; } 35% { transform: translateX(70%) rotate(4deg); opacity: 1; } 75% { transform: translateX(60%); opacity: 1; } 100% { transform: translateX(-120%); opacity: 0; } }
.float { position: absolute; top: 18%; right: 14%; font-size: 44px; font-weight: 700; z-index: 4; animation: rise 1.1s ease-out forwards; }
.float.dmg { color: #fff; text-shadow: 0 3px 0 #b3386a; }
.float.heal { color: #9fffb8; text-shadow: 0 3px 0 #1d5e36; }
@keyframes rise { from { transform: translateY(20px); opacity: 0; } 20% { opacity: 1; } to { transform: translateY(-50px); opacity: 0; } }
.banner {
  position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; background: rgba(20, 5, 15, 0.7); color: #fff; text-align: center; padding: 20px; animation: pop 0.5s;
}
.banner .big { font-size: 54px; font-weight: 700; color: #ffe08a; }
.hp { display: flex; align-items: center; gap: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.hp .heart { font-size: 30px; }
.hpbar { flex: 1; height: 26px; border-radius: 13px; background: var(--locked); overflow: hidden; }
.hpbar i { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, #d8334a, #ff6b81); transition: width 0.4s ease; }
.hpnum { min-width: 4.2em; text-align: right; }
.victory .crown-big { font-size: 130px; line-height: 1; }
.parade { position: relative; width: 100%; height: 110px; overflow: hidden; }
.parade .thumb {
  position: absolute; left: 0; top: 10px; width: 120px; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden;
  transform: translateX(-140px); animation: run 4.5s linear infinite; border: 3px solid #fff;
}
.parade img, .parade svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
@keyframes run { 0% { transform: translateX(-140px) translateY(0); } 25% { transform: translateX(25vw) translateY(-8px); } 50% { transform: translateX(50vw) translateY(0); } 75% { transform: translateX(75vw) translateY(-8px); } 100% { transform: translateX(105vw) translateY(0); } }


.parents { display: flex; flex-direction: column; gap: 28px; padding-top: 6px; max-width: 1100px; }
.parents section { display: flex; flex-direction: column; gap: 12px; }
.parents p { margin: 0; font-size: 20px; max-width: 46em; }
.grid-wrap { overflow-x: auto; }
table.heat { border-collapse: separate; border-spacing: 4px; font-variant-numeric: tabular-nums; }
table.heat th { font-size: 18px; color: var(--ink-soft); width: 46px; height: 34px; }
table.heat td { width: 46px; height: 40px; border-radius: 8px; text-align: center; font-size: 15px; font-weight: 700; }
.s-new { background: #f0ecee; color: #b9adb2; }
.s-weak { background: #f4a3a3; }
.s-mid { background: #ffe08a; }
.s-strong { background: #9fd8b0; }
.legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 18px; align-items: center; }
.legend i { display: inline-block; width: 22px; height: 22px; border-radius: 6px; vertical-align: -4px; margin-right: 6px; }
table.days { border-collapse: collapse; font-size: 20px; font-variant-numeric: tabular-nums; }
table.days th, table.days td { padding: 6px 16px 6px 0; text-align: left; border-bottom: 1px solid var(--line); }
.photogrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.photogrid .ph { display: flex; flex-direction: column; gap: 6px; font-size: 16px; min-width: 0; }
.photogrid .ph .thumb { position: relative; aspect-ratio: 4/3; border-radius: 12px; overflow: hidden; background: var(--locked); }
.photogrid .ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photogrid .ph.hidden img { opacity: 0.25; filter: grayscale(1); }
.photogrid .ph .chip { font-size: 16px; padding: 6px 12px; align-self: flex-start; }
.tricky { display: flex; gap: 10px; flex-wrap: wrap; }
.tricky span { background: var(--oops-bg); border-radius: 12px; padding: 4px 14px; font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }

@media (max-width: 820px) {
  body { font-size: 20px; overflow: auto; }
  .home, .play, .sheet { grid-template-columns: minmax(0, 1fr); height: auto; }
  .sum { font-size: 72px; }
  .home .menu .btn { min-height: 76px; font-size: 28px; }
  #bar { gap: 10px; }
  #title { font-size: 24px; }
  #title .paw { width: 26px; height: 26px; }
  #status { display: none; }
  #parents { margin-left: auto; min-width: 0; }
  #sound { min-width: 0; }
  .chip { padding: 6px 12px; font-size: 18px; }
  #app { height: auto; min-height: 100%; }
  table.heat { border-spacing: 3px; }
  table.heat th, table.heat td { width: 30px; height: 30px; font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .tile, .paws svg, .timer i { transition: none; }
  .pop, .answer.no, .toast { animation: none; }
  .king .crown, .king .face, .king.hit, .float, .banner, .attacker { animation: none !important; }
  .parade .thumb { animation: none; position: static; transform: none; display: inline-block; margin: 0 4px; }
}


.quit { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.quit .btn { min-height: 48px; font-size: 22px; padding: 0 20px; }
.play .below { display: flex; align-items: center; gap: 14px; }
.play .below .paws, .play .below .timer { flex: 1; min-width: 0; }
.hp { flex-wrap: wrap; }
.below .quit.asking, .hp .quit.asking { flex-basis: 100%; }
.quit.asking { background: var(--card); border: 3px solid var(--line); border-radius: 18px; padding: 12px 16px; font-size: 22px; align-items: stretch; }
.quit.asking .actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-start; }


.home .menu .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.home .menu .pair .btn { min-height: 80px; font-size: 26px; padding: 0 16px; }
.home .menu .pair .btn .ico { font-size: 32px; width: 40px; }
.players { max-width: 560px; margin: 0 auto; }
.players .menu { display: flex; flex-direction: column; gap: 12px; width: 100%; }
.players .menu .btn { width: 100%; min-height: 70px; font-size: 28px; justify-content: flex-start; padding: 0 24px; }
.players form { display: flex; flex-direction: column; gap: 16px; width: 100%; }
.players input { font: inherit; font-size: 30px; padding: 14px 18px; border-radius: 18px; border: 3px solid var(--line); background: var(--card); color: var(--ink); }
#player { max-width: 14em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
table.records td, table.records th { padding-right: 22px; }
table.records tr.me td { font-weight: 700; }
.duel .left { align-items: center; text-align: center; }
.duel .duel-name { font-size: 30px; font-weight: 700; }
.duel .below { width: 100%; }
.player-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; font-size: 22px; }
.player-row .chip.danger { background: var(--oops-bg); border-color: var(--oops); }
@media (max-width: 820px) {
  #bar.with-player #title { font-size: 0; gap: 0; }      
  #bar.with-player #player { margin-left: auto; }
}


@media (max-width: 600px) {
  .home .menu .pair { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .home .menu .pair .btn { min-height: 64px; font-size: 24px; }
  .play { gap: 8px; padding-block: 2px 8px; }
  .play .left { gap: 6px; position: relative; }
  .play .left .frame { width: auto; height: clamp(80px, 21svh, 280px); margin: 0 auto; }
  .boss .arena { width: auto; height: clamp(100px, 22svh, 260px); margin: 0 auto; }
  .boss .king .face { font-size: clamp(60px, 11svh, 150px); }
  .boss .king .crown { font-size: clamp(28px, 5svh, 60px); margin-bottom: -10px; }
  .boss-harmaa .arena .wheel { height: 92%; }
  .paws { gap: 3px; }
  .paws svg { width: 17px; height: 17px; }
  .quit .btn { min-height: 42px; font-size: 18px; padding: 0 14px; }
  .hp { gap: 8px; }
  .hp .heart { font-size: 22px; }
  .hpbar { height: 18px; }
  .timer { height: 14px; }
  .panel { gap: 8px; }
  .sum { font-size: clamp(34px, 6.4svh, 64px); padding-top: 0; }
  .sum.text { font-size: clamp(28px, 4.6svh, 44px); }
  .sum.text.long { font-size: clamp(22px, 3.6svh, 34px); }
  .answer { height: clamp(42px, 6.6svh, 72px); font-size: clamp(32px, 5svh, 48px); border-radius: 16px; }
  .pad { gap: 6px; }
  .pad button { height: clamp(38px, 6.2svh, 64px); font-size: clamp(24px, 3.8svh, 34px); border-radius: 14px; }
  .pad .ok, .pad .del { font-size: clamp(20px, 3.2svh, 28px); }
  .panel .row .btn { min-height: 40px; font-size: 20px; }
  .play .hintbox { position: absolute; top: 0; left: 0; right: 0; z-index: 6; max-height: clamp(80px, 21svh, 280px);
                   overflow: auto; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18); }
  .feedback { padding: 10px 12px; gap: 8px; }
  .feedback .big { font-size: 32px; }
  .duel .duel-name { font-size: 22px; }
  .duel .left .huge, .play.check .left .huge { font-size: clamp(48px, 9svh, 96px); }
}

@media (max-width: 600px) and (min-height: 700px) {
  .pad { gap: 8px; }
  .pad button { height: clamp(48px, 7.6svh, 80px); font-size: clamp(28px, 4.2svh, 38px); }
  .answer { height: clamp(50px, 7.4svh, 80px); }
  .panel .row .btn { min-height: 50px; }
}
