/* ---------- 決着・リザルト（手帳とマーカー） ---------- */
.result-screen .bg { filter: saturate(.85) brightness(1.04); }
.result-screen .veil { position: absolute; inset: 0; background: rgba(255, 253, 249, .62); }

/* 紙吹雪 */
.confetti { position: absolute; inset: 0; pointer-events: none; }
.confetti i { position: absolute; display: block; border: 2px solid var(--line); opacity: .9; animation: confettiBob 4s ease-in-out infinite alternate; }
.confetti i.sq { width: 18px; height: 18px; border-radius: 3px; }
.confetti i.dot { width: 16px; height: 16px; border-radius: 50%; }
.confetti i.bar { width: 30px; height: 10px; border-radius: 5px; }
@keyframes confettiBob { to { translate: 0 14px; } }

/* 見出し */
.result-head { position: absolute; top: 34px; left: 120px; }
.result-head .big {
  display: inline-block; font: 700 128px/1 var(--latin); letter-spacing: .08em; color: var(--paper);
  -webkit-text-stroke: 6px var(--line); paint-order: stroke fill;
  text-shadow: 8px 9px 0 var(--hl-c);
  padding: 0 22px;
  background: linear-gradient(transparent 62%, var(--hl-soft) 62% 94%, transparent 94%);
}
.result-screen.is-win { --hl-c: var(--lemon); --hl-soft: var(--pink-soft); }
.result-screen.is-lose { --hl-c: var(--sky); --hl-soft: var(--lilac-soft); }
.result-head .sub { margin: 6px 0 0 26px; font-size: 30px; color: var(--ink); }

/* 順位 */
.ranks { position: absolute; top: 250px; left: 120px; width: 1080px; display: flex; flex-direction: column; gap: 26px; }
.rankrow {
  height: 168px; position: relative; display: flex; align-items: center; gap: 26px; padding-right: 40px;
  background: var(--paper); border: var(--bw) solid var(--line); border-radius: var(--radius); box-shadow: var(--pop);
  animation: slideIn .5s ease both;
}
@keyframes slideIn { from { transform: translateX(-120px); opacity: 0; } }
.rankrow .no {
  position: relative; align-self: stretch; width: 150px; flex: none;
  display: flex; align-items: center; justify-content: center; gap: 2px;
  background: color-mix(in srgb, var(--c) 26%, #fff);
  border-right: var(--bw) solid var(--line); border-radius: calc(var(--radius) - 3px) 0 0 calc(var(--radius) - 3px);
  color: var(--ink);
}
.rankrow .no .n { font: 700 84px/1 var(--latin); }
.rankrow .no small { font: 700 28px var(--latin); align-self: flex-end; margin-bottom: 38px; }
.rankrow .face { flex: none; border-radius: 50%; overflow: hidden; border: var(--bw) solid var(--line); background: color-mix(in srgb, var(--c) 14%, #fff); box-shadow: 3px 4px 0 rgba(58,49,80,.14); }
.rankrow .face > div { border-radius: 50%; }
.rankrow .nm { flex: 1; min-width: 0; color: var(--ink); }
.rankrow .nm .who { white-space: nowrap; font: 900 40px var(--round); letter-spacing: .06em; display: flex; align-items: center; gap: 14px; }
.rankrow .nm .you { font: 700 16px var(--latin); letter-spacing: .14em; padding: 3px 12px; border-radius: 999px; border: 2px solid var(--line); background: var(--sky-soft); }
.rankrow .nm .sub { flex-wrap: wrap; row-gap: 8px; margin-top: 6px; font: 700 18px var(--round); color: var(--ink-2); display: flex; align-items: center; gap: 12px; }
.rankrow .nm .sub .grade { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rankrow .chip.goal { flex: none; white-space: nowrap; background: var(--mint-soft); color: var(--ink); }
.rankrow .tot { color: var(--ink); text-align: right; white-space: nowrap; }
.rankrow .tot .lbl { display: block; font: 700 16px var(--round); color: var(--ink-2); letter-spacing: .2em; }
.rankrow .tot .num { font-size: 52px; }
.rankrow .tot small { font: 700 20px var(--round); margin-left: 4px; }

/* 1位：少し大きく、王冠とリボン */
.rankrow.first { height: 200px; margin-right: -30px; box-shadow: var(--pop-lg); }
.rankrow.first .no { width: 170px; background: color-mix(in srgb, var(--c) 34%, #fff); }
.rankrow.first .no .n { font-size: 104px; }
.rankrow.first .nm .who { font-size: 46px; }
.rankrow.first .tot .num { font-size: 62px; }
.crown { position: absolute; top: -34px; left: 50%; width: 76px; height: 52px; translate: -50% 0; rotate: -8deg; }
.crown::before, .crown::after {
  content: ''; position: absolute; inset: 0;
  clip-path: polygon(0 100%, 0 18%, 25% 55%, 50% 0, 75% 55%, 100% 18%, 100% 100%);
}
.crown::before { background: var(--line); }
.crown::after { inset: 6px 5px 3px; background: var(--lemon); clip-path: polygon(0 100%, 0 26%, 25% 62%, 50% 10%, 75% 62%, 100% 26%, 100% 100%); }
.rankrow .ribbon {
  position: absolute; right: 26px; top: -18px; padding: 4px 18px; font-size: 18px; font-weight: 700; letter-spacing: .2em;
  color: var(--ink); background: var(--pink-soft); border: 2px solid var(--line); border-radius: 6px; rotate: 3deg;
}

/* 主人公立ち絵（白縁つきなのでそのまま） */
.result-side { position: absolute; right: 0; bottom: 0; height: 990px; }
.result-side img { height: 100%; display: block; }

/* 判定メモ */
.result-verdict {
  position: absolute; left: 1250px; top: 250px; width: 350px; padding: 34px 24px 24px;
  text-align: center; color: var(--ink); rotate: -1.5deg;
  background: linear-gradient(var(--line-soft) 1.5px, transparent 1.5px) 0 18px / 100% 40px, var(--paper);
}
.result-verdict .vt { font: 700 16px var(--latin); letter-spacing: .24em; color: var(--ink-2); }
.result-verdict .vmain { margin-top: 10px; font: 700 25px/1.6 var(--round); }
.result-verdict .vmain b { white-space: nowrap; font-weight: 900; background: linear-gradient(transparent 60%, var(--hl-c) 60% 92%, transparent 92%); }
.result-verdict .vchibi { margin: 14px auto 6px; width: 150px; height: 150px; border-radius: 50%; background: color-mix(in srgb, var(--c) 22%, #fff); border: 2px dashed var(--line-soft); display: grid; place-items: end center; overflow: hidden; }
.result-verdict .vchibi img { height: 140px; display: block; }
.result-verdict .vnote { list-style: none; margin: 12px 0 0; padding: 0; text-align: left; font: 500 18px/1.6 var(--hand); color: var(--ink); }
.result-verdict .vnote li::before { content: '・'; }
.result-verdict .vnote .num { font-size: 20px; }

.result-actions { position: absolute; left: 120px; bottom: 60px; display: flex; gap: 22px; }
.result-actions .btn { display: inline-flex; align-items: center; gap: 8px; }
.result-actions .bico { width: 40px; height: 40px; margin: -8px 0 -8px -12px; }
