:root {
  --cream: #f7e6d2;
  --cream-light: #fff6e9;
  --paper: #fffbf3;
  --paper-warm: #fff0df;
  --ink: #4b3732;
  --muted: #92736a;
  --line: #ddbeb0;
  --coral: #f26970;
  --coral-dark: #c84f59;
  --lavender: #a988c7;
  --mint: #71b9ae;
  --honey: #f2b43d;
  --green: #719b67;
  --shadow: rgba(142, 91, 70, .2);
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --hand: "LXGW WenKai", "Kaiti SC", "STKaiti", "KaiTi", serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { max-width: 100%; }
body {
  min-height: 100vh;
  max-width: 100%;
  color: var(--ink);
  font-family: var(--sans);
  background:
    linear-gradient(116deg, rgba(255,255,255,.28) 0 12%, transparent 12% 23%, rgba(255,255,255,.2) 23% 31%, transparent 31%),
    radial-gradient(circle at 88% 8%, #fff4e7 0 5%, transparent 22%),
    var(--cream);
}
.hidden { display: none !important; }

#wrap {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  padding: 14px;
}
#centerCol {
  display: flex;
  flex: 0 1 960px;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: min(960px, 100%);
  min-width: 0;
}
#phaser-root {
  width: 100%;
  max-width: 960px;
  aspect-ratio: 8 / 5;
  overflow: hidden;
  border: 1px solid rgba(185, 134, 111, .38);
  border-radius: 22px;
  background: var(--paper-warm);
  box-shadow: 0 16px 34px var(--shadow), inset 0 0 0 5px rgba(255,255,255,.28);
}
#phaser-root canvas {
  display: block;
  width: 100% !important;
  height: auto !important;
  max-width: 100%;
  border-radius: 21px;
}

/* Buttons */
.btn {
  display: inline-block;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 14px;
  padding: 10px 22px;
  color: #fffaf4;
  font: 700 15px var(--sans);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  background: linear-gradient(160deg, #f78588, var(--coral));
  box-shadow: 0 4px 0 var(--coral-dark), 0 7px 14px rgba(178,78,83,.16);
  transition: transform .12s ease, filter .15s ease, box-shadow .12s ease;
}
.btn:hover { filter: brightness(1.04) saturate(1.05); transform: translateY(-1px); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--coral-dark); }
.btn.big { padding: 12px 24px; font-size: 16px; }
.btn.small { padding: 7px 12px; border-radius: 10px; font-size: 12px; box-shadow: 0 3px 0 var(--coral-dark); }
.btn.danger { background: linear-gradient(160deg, #d9817d, #bd5f5b); box-shadow: 0 3px 0 #8e4542; }
.btn.selected { outline: 3px solid rgba(242,180,61,.55); outline-offset: 2px; }
/* 次要按钮：描边纸感，不跟主按钮抢。用在「算了，下次一定」这类退出选项上 */
.btn.ghost {
  background: var(--paper, #fffbf3);
  color: var(--muted, #92736a);
  border: 1.5px solid var(--line, #ddbfb1);
  box-shadow: 0 3px 0 rgba(201,158,136,.28);
}
.btn.ghost:hover { background: var(--paper-warm, #fff0df); color: var(--ink, #4b3732); }
.btn.ghost:active { box-shadow: 0 1px 0 rgba(201,158,136,.28); }
/* 设置里的开关 */
.switch-row { display: flex; align-items: center; justify-content: space-between;
  padding: 13px 2px; border-bottom: 1px dashed var(--line); cursor: pointer;
  font: 700 15px var(--sans); color: var(--ink); }
.switch-row:last-of-type { border-bottom: 0; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch { width: 48px; height: 27px; border-radius: 14px; background: #e2cdc2;
  position: relative; transition: background .16s ease; flex: none; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 21px; height: 21px;
  border-radius: 50%; background: #fffbf3; box-shadow: 0 1px 3px rgba(120,80,60,.3);
  transition: transform .16s ease; }
.switch-row input:checked + .switch { background: var(--coral); }
.switch-row input:checked + .switch::after { transform: translateX(21px); }
.switch-row input:focus-visible + .switch { outline: 2px solid var(--coral-dark); outline-offset: 2px; }

/* 打赏档位：五档横排，大图标在上、名字与价格在下。
 * 标签都是 3~4 个字，横排放得下；窄屏自动折行。 */
.tip-amounts { display: flex; flex-wrap: wrap; gap: 9px; margin: 18px 0 6px; }
.tip-chip {
  flex: 1 1 92px; min-width: 92px;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  padding: 14px 6px 11px; border-radius: 16px; cursor: pointer;
  border: 1.5px solid var(--line); background: var(--paper);
  color: var(--muted); font-family: var(--sans);
  transition: background .14s ease, color .14s ease, border-color .14s ease, transform .12s ease;
}
.tip-chip:hover { background: var(--paper-warm); color: var(--ink); transform: translateY(-2px); }
.tip-ico { display: block; width: 44px; height: 44px; flex: none; }
.tip-ico svg { width: 100%; height: 100%; display: block; }
.tip-name { font-size: 13px; font-weight: 700; letter-spacing: .01em; white-space: nowrap; }
.tip-price { font-size: 11.5px; opacity: .72; font-variant-numeric: tabular-nums; }
.tip-chip.on {
  background: linear-gradient(160deg, #f78588, var(--coral));
  border-color: var(--coral-dark); color: #fffaf4;
  box-shadow: 0 3px 0 var(--coral-dark);
}
.tip-chip.on .tip-price { opacity: .95; }
#modalTip .modal-btns { justify-content: space-between; }
.tip-title { display: flex; align-items: center; gap: 10px; }
.tip-gift { display: inline-block; width: 26px; height: 26px; color: var(--coral); flex: none; }
.tip-gift svg { width: 100%; height: 100%; display: block; }

/* Game side panels */
#leftPanel, #rightPanel {
  position: relative;
  width: 220px;
  flex: none;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 20px;
  color: var(--ink);
  background: rgba(255,251,243,.94);
  box-shadow: 5px 8px 0 rgba(201,158,136,.18), 0 14px 28px rgba(142,91,70,.12);
}
#leftPanel::before, #rightPanel::before {
  content: "";
  position: absolute;
  inset: 5px;
  z-index: -1;
  border: 1px dashed rgba(221,190,176,.62);
  border-radius: 15px;
}
#leftPanel h3, #rightPanel h3 {
  margin: 9px 0 8px;
  color: var(--coral-dark);
  font: 700 17px var(--hand);
  letter-spacing: .06em;
}
#leftPanel h3 small, #rightPanel h3 small { margin-left: 5px; color: #b79a8f; font: 700 8px var(--sans); letter-spacing: .16em; }
#leftPanel > h3:first-child, #rightPanel > h3:first-child { margin-top: 1px; }

#toolList { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
#poseList { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
#toolList .tool-btn, #poseList .pose-btn {
  display: block;
  width: 100%;
  position: relative;
  min-width: 0;
  margin-bottom: 0;
  padding: 8px 5px 7px;
  border: 1px solid #ead5c9;
  border-radius: 12px;
  color: var(--ink);
  font: 700 11px var(--sans);
  text-align: center;
  cursor: pointer;
  background: linear-gradient(145deg, #fffdf8, #fff3e6);
  box-shadow: 0 3px 8px rgba(125,79,61,.06);
  transition: transform .12s, border-color .12s, background .12s;
}
#toolList .tool-btn { min-height: 78px; }
#poseList .pose-btn { min-height: 67px; }
.tool-icon { display: block; width: 40px; height: 40px; margin: 0 auto 4px; color: #79645d; }
.pose-icon { display: block; width: 34px; height: 34px; margin: 0 auto 3px; color: var(--lavender); }
.pose-icon .soft { stroke: var(--coral); opacity: .8; }
.control-name { display: block; overflow: hidden; font-size: 9px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.lock-mark { position: absolute; top: 5px; right: 6px; color: var(--honey); font-size: 7px; }
#toolList .tool-btn:hover, #poseList .pose-btn:hover { transform: translateY(-2px); border-color: #e8a4a3; }
#toolList .tool-btn.selected, #poseList .pose-btn.selected {
  border-color: var(--coral);
  color: #fff;
  background: linear-gradient(145deg, #f5898d, var(--coral));
  box-shadow: 0 4px 0 var(--coral-dark);
}
#toolList .tool-btn.selected .tool-icon, #poseList .pose-btn.selected .pose-icon { color: #fff; filter: drop-shadow(0 2px 2px rgba(82,50,45,.2)); }
#poseList .pose-btn.selected .pose-icon .soft { stroke: #fff0da; }
#poseList .pose-btn.locked { opacity: .48; cursor: not-allowed; filter: grayscale(.28); }
.file-face-btns { display: flex; gap: 7px; }
.file-face-btns .btn { flex: 1; padding: 6px 4px; font-size: 10px; }

.stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 3px;
  border-bottom: 1px dashed var(--line);
  color: var(--muted);
  font-size: 12px;
}
.stat span small { display: block; margin-top: 2px; font-size: 8px; color: #b1958c; }
.stat b { color: var(--lavender); font-size: 13px; font-variant-numeric: tabular-nums; }
.stat:nth-of-type(2) b { color: var(--mint); }
.stat:nth-of-type(3) b { color: var(--coral); font-size: 11px; letter-spacing: 1px; }
.stat b.t-warn { color: #d58923; }
.stat b.t-danger { color: var(--coral-dark); font-weight: 800; animation: tickPulse .7s ease-in-out infinite; }
.stat-meter-row { display: grid; grid-template-columns: 1fr auto; }
.meter { grid-column: 1 / -1; display: block; height: 4px; overflow: hidden; border-radius: 3px; background: #eadbd2; }
.meter em { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #eba373, var(--coral)); transition: width .2s ease; }
.stat-meter-row.joy .meter em { background: linear-gradient(90deg, #eba373, #7fbf85); }
#todoPanel { display: none; }
@keyframes tickPulse { 0%, 100% { opacity: 1; } 50% { opacity: .38; } }

#todoPanel { margin-top: 11px; padding: 9px 10px; border-radius: 13px; background: #fff0df; }
#todoPanel h3 { margin: 0 0 5px; color: var(--mint); font-size: 15px; }
#todoList { list-style: none; }
#todoList li { padding: 3px 0; color: var(--muted); font-size: 10px; }
#todoList li::before { content: "○"; margin-right: 6px; color: var(--coral); }
#todoList li.ok { color: var(--green); text-decoration: line-through; opacity: .68; }
#todoList li.ok::before { content: ""; margin: 0; }
#btnQuitGame { width: 100%; margin-top: 12px; }

/* Nail navigation */
#nailBar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  max-width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: rgba(255,251,243,.94);
  box-shadow: 0 7px 18px rgba(142,91,70,.12);
}
#nailDots { display: flex; gap: 5px; }
.nail-dot {
  width: 34px;
  height: 44px;
  border: 1px solid #e2c7ba;
  border-radius: 10px 10px 13px 13px;
  color: var(--muted);
  font: 700 9px var(--sans);
  cursor: pointer;
  background: linear-gradient(#fffdf8, #f8e7d8);
  box-shadow: 0 2px 0 #d8b6a5;
}
.nail-dot .mini-nail { display: block; width: 15px; height: 20px; margin: 3px auto 1px; border: 1.5px dashed currentColor; border-radius: 8px 8px 5px 5px; background: rgba(255,255,255,.35); }
.nail-dot small { display: block; font-size: 7px; transform: scale(.88); white-space: nowrap; }
.nail-dot.cur .mini-nail, .nail-dot.done .mini-nail { border-style: solid; border-color: rgba(255,255,255,.9); }
.nail-dot.cur { border-color: var(--coral); color: #fff; background: var(--coral); box-shadow: 0 3px 0 var(--coral-dark); }
.nail-dot.done { border-color: var(--green); color: #fff; background: var(--green); box-shadow: 0 2px 0 #52764b; }
.nail-dot.offside { opacity: .34; }
#hotkeyHint { color: var(--muted); font-size: 10px; letter-spacing: .04em; }

/* Modal paper cards */
.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(75,55,50,.48);
  backdrop-filter: blur(6px);
}
.modal-box {
  position: relative;
  width: 570px;
  max-width: 94vw;
  max-height: 88vh;
  overflow-y: auto;
  padding: 28px 30px;
  border: 2px solid var(--line);
  border-radius: 24px;
  color: var(--ink);
  background:
    linear-gradient(112deg, rgba(255,255,255,.45), transparent 32%),
    var(--paper);
  box-shadow: 0 20px 50px rgba(75,55,50,.28), inset 0 0 0 6px #fff5e8;
}
.modal-box::after {
  content: "♡";
  position: absolute;
  top: 18px;
  right: 24px;
  color: var(--coral);
  font: 700 26px var(--hand);
}
.modal-box h2 { margin-bottom: 11px; color: var(--coral-dark); font: 700 29px var(--hand); }
.modal-sub, .tip-note { margin-bottom: 7px; color: var(--muted); font-size: 13px; line-height: 1.65; }
.tip-note { padding: 12px; border-radius: 12px; background: var(--paper-warm); }
.modal-btns { display: flex; flex-wrap: wrap; gap: 12px; justify-content: flex-end; align-items: flex-start; margin-top: 20px; }
.records-list { font-size: 13px; }
.records-list table, .settle-table { width: 100%; border-collapse: collapse; }
.records-list th, .records-list td, .settle-table td { padding: 9px 6px; border-bottom: 1px dashed var(--line); text-align: left; }
.records-list th { color: var(--lavender); font-family: var(--hand); font-size: 16px; }
.records-list .empty { padding: 28px 0; color: var(--muted); text-align: center; }
.clear-confirm { color: var(--coral-dark); font-weight: 700; text-align: right; }
.fail h2 { color: var(--coral-dark); }
.fail p { color: var(--muted); line-height: 1.75; }
.fail-btns { justify-content: center; }
.settle-table { margin: 8px 0 14px; font-size: 14px; }
.settle-table td:last-child { color: var(--lavender); font-weight: 700; text-align: right; }
.settle-total { margin: 14px 0; color: var(--coral-dark); font: 700 22px var(--hand); line-height: 1.7; text-align: center; }
.settle-foot { display: block; color: var(--muted); font: 400 12px var(--sans); }
.modal-box.settle { width: 760px; padding: 26px 28px; overflow-x: hidden; }
.modal-box.settle::after { content: "SERVICE COMPLETE"; top: 22px; color: var(--line); font: 800 9px var(--sans); letter-spacing: .18em; }
.modal-box.settle > h2 { max-width: 610px; font-size: 22px; line-height: 1.45; }
.result-hero { position: relative; display: grid; grid-template-columns: 118px 1fr 108px; gap: 18px; min-height: 152px; padding: 14px; overflow: hidden; border: 1px solid #e6cbbd; border-radius: 20px; background: linear-gradient(135deg, #fff0df, #fffaf2 58%, #f1e8f5); }
.result-character { align-self: end; height: 138px; overflow: hidden; border-radius: 55px 55px 18px 18px; background: linear-gradient(#f3cfc4, #eeb9a8); box-shadow: inset 0 0 0 1px rgba(255,255,255,.55); }
.result-character img { width: 100%; height: 154px; object-fit: contain; object-position: center top; transform: translateY(4px); }
.result-copy { min-width: 0; padding-top: 6px; }
.result-kicker { color: var(--coral-dark); font-size: 8px; font-weight: 800; letter-spacing: .17em; }
.result-copy h3 { margin: 6px 0 3px; color: var(--ink); font: 800 25px var(--hand); }
.result-copy h3 small { margin-left: 8px; color: var(--muted); font: 500 10px var(--sans); }
.result-copy p { color: var(--muted); font-size: 10px; }
.nail-result-grid { display: grid; grid-template-columns: repeat(5, 28px); gap: 6px; margin-top: 13px; }
.nail-result-grid span { display: grid; place-items: center; width: 28px; height: 32px; border-radius: 9px; background: rgba(255,255,255,.62); }
.nail-result-grid i { width: 12px; height: 19px; border: 2px solid #d3b5a6; border-radius: 7px 7px 4px 4px; }
.nail-result-grid .good i { border-color: var(--green); background: #b7d8af; }
.nail-result-grid .ok i { border-color: #c58d27; background: #f7d485; }
.nail-result-grid .bad i { border-color: var(--coral-dark); background: #eea2a2; }
.nail-result-grid .none i { border-style: dashed; opacity: .45; }
.score-seal { align-self: center; display: grid; place-items: center; width: 98px; height: 118px; border: 2px solid var(--coral); border-radius: 48% 48% 44% 44%; color: var(--coral-dark); background: rgba(255,251,243,.8); box-shadow: inset 0 0 0 5px rgba(242,105,112,.09), 0 7px 0 rgba(200,79,89,.12); transform: rotate(2deg); }
.score-seal small { margin-top: 9px; font-size: 7px; letter-spacing: .2em; }
.score-seal strong { margin: -8px 0 -12px; font: 800 48px/1 var(--hand); }
.score-seal em { margin-bottom: 8px; font: 800 16px var(--sans); font-style: normal; }
.score-seal em b { margin-left: 2px; font-size: 8px; }
.result-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 12px 0; }
.result-cards > div { min-width: 0; padding: 12px 14px; border: 1px solid #ead5c9; border-radius: 14px; background: #fffaf4; }
.result-cards span, .result-cards small { display: block; color: var(--muted); font-size: 9px; }
.result-cards strong { display: block; margin: 5px 0 3px; overflow: hidden; color: var(--lavender); font: 800 19px var(--hand); text-overflow: ellipsis; white-space: nowrap; }
.result-cards > div:nth-child(2) strong { color: var(--mint); font-size: 15px; }
.result-cards > div:nth-child(3) strong { color: var(--coral); }
.modal-box.settle .settle-total { display: grid; grid-template-columns: 1fr auto; align-items: center; margin: 0; padding: 13px 16px; border-radius: 14px; color: var(--coral-dark); background: #fff0df; text-align: right; }
.modal-box.settle .settle-total > span { color: var(--muted); font: 700 11px var(--sans); text-align: left; }
.modal-box.settle .settle-foot { grid-column: 1 / -1; margin-top: 2px; text-align: right; }
.tip-ledger { display: grid; gap: 7px; margin-top: 9px; padding: 12px 16px 13px; border: 1px solid #ead5c9; border-radius: 14px; background: #fffaf4; font-variant-numeric: tabular-nums; }
.tip-ledger-earn { display: flex; align-items: baseline; gap: 9px; color: var(--muted); font-size: 12px; font-weight: 700; }
.tip-ledger-earn strong { color: var(--honey-dark, #c98519); font: 800 24px var(--sans); letter-spacing: -.01em; }
.tip-ledger-row { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; }
.tip-ledger-bar { color: var(--green); font-size: 20px; line-height: 1.2; letter-spacing: .06em; white-space: nowrap; }
.tip-ledger-gap { display: flex; align-items: baseline; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.tip-ledger-gap strong { color: var(--coral-dark); font: 900 34px/1.05 var(--sans); letter-spacing: -.035em; text-shadow: 0 2px 0 rgba(242,180,61,.15); }
.tip-ledger-goal { color: var(--muted); font-size: 11.5px; letter-spacing: .02em; }
.share-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; color: var(--muted); font-size: 13px; }
.rc-msg { min-height: 20px; color: var(--green); font-size: 13px; text-align: center; }

/* Compact desktop / tablet: canvas remains the focus, controls become horizontal cards. */
@media (max-width: 1469px) {
  #wrap {
    display: grid;
    grid-template-columns: minmax(0, 960px);
    grid-template-areas: "tools" "game" "stats";
    gap: 10px;
  }
  #centerCol { grid-area: game; width: 100%; justify-self: center; }
  #leftPanel, #rightPanel { width: 100%; padding: 9px 11px; }
  #leftPanel { grid-area: tools; }
  #rightPanel { grid-area: stats; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
  #leftPanel h3, #rightPanel h3 { margin: 2px 0 5px; font-size: 14px; }
  #toolList { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 5px; }
  #toolList .tool-btn { display: flex; align-items: center; justify-content: center; gap: 3px; min-width: 0; min-height: 42px; padding: 4px; overflow: hidden; white-space: nowrap; }
  #toolList .tool-icon { flex: none; width: 28px; height: 28px; margin: 0; }
  #toolList .control-name { font-size: 8px; }
  #fileFaceRow { align-items: center; gap: 7px; margin-top: 7px; }
  #fileFaceRow:not(.hidden) { display: flex; }
  #fileFaceRow h3 { flex: none; margin: 0; }
  #fileFaceRow .file-face-btns { flex: 1; }
  #poseList { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  #poseList .pose-btn { min-width: 0; min-height: 42px; margin: 0; padding: 4px; text-align: center; }
  #poseList .pose-icon { width: 26px; height: 26px; }
  #rightPanel > h3 { display: none; }
  #rightPanel .stat { min-width: 0; flex-direction: column; gap: 2px; padding: 5px; border: 1px solid #ead5c9; border-radius: 9px; text-align: center; }
  #rightPanel .stat-meter-row { display: grid; grid-template-columns: 1fr auto; text-align: left; }
  #rightPanel .stat span small { display: none; }
  #todoPanel { grid-column: 1 / -1; margin-top: 2px; }
  #todoList { display: flex; flex-wrap: wrap; gap: 4px 15px; }
  #btnQuitGame { grid-column: 1 / -1; margin-top: 2px; }
  #nailBar { width: 100%; }
}

@media (max-width: 620px) {
  #wrap { padding: 6px; gap: 7px; }
  #phaser-root { border-radius: 14px; }
  #phaser-root canvas { border-radius: 13px; }
  #leftPanel, #rightPanel { padding: 7px; border-radius: 14px; }
  #toolList { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  #toolList .tool-btn { min-height: 32px; font-size: 9px; padding: 3px; }
  #toolList .tool-btn svg { width: 19px; height: 19px; }
  #poseList .pose-btn { padding: 5px 2px; font-size: 9px; }
  #rightPanel { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  #rightPanel .stat { padding: 4px 2px; font-size: 9px; }
  #rightPanel .stat b { font-size: 10px; }
  #nailBar { flex-wrap: wrap; padding: 7px; }
  #nailDots { order: -1; width: 100%; justify-content: center; gap: 3px; }
  .nail-dot { width: 29px; height: 38px; font-size: 9px; }
  .nail-dot .mini-nail { width: 12px; height: 16px; }
  #nailBar .btn.small { padding: 5px 8px; font-size: 10px; }
  .modal-box { padding: 22px 18px; }
  .modal-btns { justify-content: center; }
  .share-row .btn { padding: 5px 8px; }
  .result-hero { grid-template-columns: 72px 1fr 64px; gap: 9px; min-height: 118px; padding: 9px; }
  .result-character { height: 102px; }
  .result-character img { height: 112px; }
  .result-copy h3 { font-size: 18px; }
  .result-copy p { display: none; }
  .nail-result-grid { grid-template-columns: repeat(5, 19px); gap: 3px; margin-top: 8px; }
  .nail-result-grid span { width: 19px; height: 22px; border-radius: 6px; }
  .nail-result-grid i { width: 8px; height: 14px; }
  .score-seal { width: 60px; height: 78px; }
  .score-seal strong { font-size: 31px; }
  .score-seal em { font-size: 11px; }
  .result-cards { gap: 5px; }
  .result-cards > div { padding: 9px 6px; }
  .result-cards strong { font-size: 14px; }
  .tip-chip { flex: 1 1 30%; min-width: 0; padding: 11px 4px 9px; }
  .tip-ico { width: 36px; height: 36px; }
  .tip-name { font-size: 12px; }
  .tip-ledger { padding: 9px 10px 10px; }
  .tip-ledger-bar { font-size: 16px; }
  .tip-ledger-row { align-items: flex-start; flex-direction: column; gap: 4px; }
  .tip-ledger-gap strong { align-self: flex-end; font-size: 28px; }
}
