.stage canvas { transform: none; left: 0; top: 0; }
.stage.is-blur canvas { filter: blur(14px); }
.fever-rim { position: absolute; inset: 0 var(--vx, 0px); pointer-events: none; opacity: 0; transition: opacity .3s; box-shadow: inset 0 0 0 6px var(--c-gold), inset 0 0 40px 10px rgba(255, 200, 61, .8); }
.stage.is-fever .fever-rim { opacity: 1; animation: rim .7s infinite alternate; }
@keyframes rim { to { opacity: .55; } }
.hud { pointer-events: none; }
.eta { position: absolute; z-index: 9; left: calc(14px + var(--safe-left) + var(--vx, 0px)); top: calc(57px + var(--safe-top)); font-size: 12px; font-weight: 900; color: #fff; -webkit-text-stroke: 4px var(--c-ink); paint-order: stroke fill; pointer-events: none; }
.chip--film.is-low { background: #ffe27a; }
.pops, .prints { position: absolute; inset: 0; z-index: 9; pointer-events: none; overflow: hidden; }
.pop b { display: block; }
.mini { position: absolute; width: 86px; padding: 4px 4px 12px; background: #fffdf7; border: 2px solid var(--c-ink); border-radius: 3px; box-shadow: 0 3px 0 rgba(59, 47, 47, .5); transform-origin: 50% 50%; }
.mini canvas { display: block; width: 100%; height: auto; border: 1px solid var(--c-ink); }
.quip { position: absolute; z-index: 9; left: calc(106px + var(--safe-left) + var(--vx, 0px)); bottom: calc(8px + var(--safe-bottom)); max-width: calc(100% - 118px - 2 * var(--vx, 0px)); padding: 4px 10px; border: 2px solid var(--c-ink); border-radius: 12px; background: rgba(255, 253, 247, .94); font-size: 12px; font-weight: 800; line-height: 1.3; opacity: 0; transition: opacity .15s; pointer-events: none; }
.quip.is-on { opacity: 1; }
.count { position: absolute; z-index: 13; inset: 0; display: grid; place-items: center; font: 900 110px/1 var(--font-num); color: #fff; -webkit-text-stroke: 16px var(--c-ink); paint-order: stroke fill; pointer-events: none; }
.count span { animation: pop .2s ease; }

.title-sound { position: absolute; z-index: 3; top: calc(12px + var(--safe-top)); right: calc(12px + var(--safe-right)); }
.title-head { text-align: center; }
.title-menu .back-to-games { margin-top: 2px; }
.time-card .lock { font-size: 10px; white-space: nowrap; }
.time-card.is-locked { opacity: 1; }

.screen--develop { cursor: pointer; }
.develop-slot { min-height: 0; display: grid; place-items: center; }
.print { box-sizing: border-box; }
.print__cap { align-items: center; }
.print__cap span:first-child { display: grid; gap: 2px; }
.print__cap em { font-style: normal; font-size: 13px; font-weight: 700; color: var(--c-ink-sub); }
.develop-foot { display: flex; align-items: center; gap: 18px; }
.develop-hint { font-size: 13px; font-weight: 800; opacity: .85; }

.screen--best::before { content: ""; position: absolute; inset: 0; background: #17090c; pointer-events: none; animation: undim 1.1s ease both; z-index: 2; }
@keyframes undim { from { opacity: 1; } to { opacity: 0; } }
.frame { animation-delay: .5s; }
.nameplate { animation-delay: 1s; }
.nameplate__name span { opacity: 0; animation: letter .25s ease both; }
@keyframes letter { from { opacity: 0; translate: 0 8px; } to { opacity: 1; translate: 0 0; } }
.nameplate p { animation: letter .4s ease both; }
.best-next { opacity: 0; pointer-events: none; transition: opacity .3s; }
.best-next.is-on { opacity: 1; pointer-events: auto; }

.screen--result { padding: 0; gap: 0; justify-content: flex-start; overflow: hidden; background: repeating-linear-gradient(90deg, #efe0bd 0 40px, #f4e7c9 40px 80px); }
.result-top { flex: 1 1 0; min-height: 0; width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: calc(22px + var(--safe-top)) 16px 12px; }
.result-top .frame { --fw: min(82vw, 420px); width: var(--fw); max-width: none; min-width: 0; padding: 12px; animation: none; }
.result-top .who { padding: 3px 14px; border: 3px solid var(--c-ink); border-radius: 999px; background: var(--c-paper); font-weight: 900; font-size: 15px; white-space: nowrap; }
.result-sheet { flex: none; width: min(100%, 520px); max-height: 56%; overflow-y: auto; touch-action: pan-y; padding: 12px 18px calc(8px + var(--safe-bottom)); border-radius: 24px 24px 0 0; border-bottom: 0; box-shadow: 0 -4px 0 rgba(59, 47, 47, .18); display: grid; gap: 6px; justify-items: center; animation: sheet .45s .15s cubic-bezier(.2, 1.1, .4, 1) both; }
@keyframes sheet { from { transform: translateY(100%); } }
.result-line { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; }
.result-score { font-size: 42px; -webkit-text-stroke-width: 6px; }
.result-rank { font-size: 15px; padding: 5px 12px; white-space: nowrap; }
.result-next { text-align: center; font-size: 14px; }
.result-notes { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 6px; font-size: 12px; font-weight: 800; }
.result-notes:empty { display: none; }
.result-notes span { padding: 2px 8px; border-radius: 999px; background: var(--c-cream); border: 2px solid var(--c-line); }
.result-notes .is-new { background: #ffe9a8; border-color: var(--c-gold-deep); }
.result-sheet .actions { gap: 6px; margin-top: 2px; }
.result-sheet .btn { min-height: 46px; padding-block: 6px; white-space: nowrap; }
.result-sheet .btn--small { min-height: 38px; font-size: 14px; }

[data-screen="album"], [data-screen="zukan"] { z-index: 30; }
.zukan-cell { font-family: inherit; color: inherit; overflow: hidden; }
.zukan-cell img, .zukan-cell canvas { pointer-events: none; }
.zukan-cell .nm { display: block; white-space: nowrap; }
.album .zukan-cell { font-size: 12px; }
.zukan-badge { padding: 4px 14px; border: 3px solid var(--c-ink); border-radius: 999px; background: var(--c-gold); font-weight: 900; }
.zukan-head { grid-column: 1 / -1; font-size: 13px; font-weight: 900; color: var(--c-ink-sub); }
.photo-card { text-align: center; display: grid; gap: 8px; }
.photo-card img, .photo-card canvas { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border: 3px solid var(--c-ink); border-radius: 6px; background: #dceccb; }
.photo-card h2 { margin: 0; }
.photo-card p { margin: 0; font-size: 14px; font-weight: 600; line-height: 1.6; }
.photo-card .meta { font-size: 12px; font-weight: 800; color: var(--c-ink-sub); }
.share-card { display: grid; gap: 10px; }
.share-card img { display: block; justify-self: center; max-width: 100%; max-height: calc(100dvh - 220px); border: 3px solid var(--c-ink); border-radius: 8px; -webkit-touch-callout: default; -webkit-user-select: auto; user-select: auto; }
.share-card .row { flex-wrap: nowrap; } .share-card .row .btn { flex: 1; padding-inline: 6px; white-space: nowrap; }
.stack { display: grid; gap: 8px; }
.btn { white-space: nowrap; }
@media (max-width: 374px) { .chip small { display: none; } .title-menu .row .btn { padding-inline: 6px; font-size: 14px; } }
@media (max-height: 700px) {
  .result-top { padding-top: calc(20px + var(--safe-top)); padding-bottom: 8px; gap: 4px; }
  .result-sheet { max-height: 60%; padding-top: 8px; gap: 4px; }
  .result-score { font-size: 34px; }
  .frame { max-width: calc((100dvh - 300px) * 1.2); }
  .tagline { margin-top: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .print.is-developing, .frame, .nameplate, .nameplate p, .nameplate__name span, .result-sheet, .screen--best::before { animation-delay: 0s !important; }
}
.combo { top: calc(82px + var(--safe-top)); }
.chip--score { flex-direction: column; gap: 1px; line-height: 1; }
.chip--score small { display: block; }
.chip--film.is-bump { animation: bump .32s 2; }
@keyframes bump { 50% { transform: scale(1.25); } }
.combo { left: auto; right: calc(12px + var(--safe-right) + var(--vx, 0px)); top: calc(58px + var(--safe-top)); transform: rotate(-2deg); font-size: 18px; -webkit-text-stroke-width: 5px; }
.flash { inset: auto; box-shadow: 0 0 0 3000px rgba(255, 255, 255, .13); }
.flash.is-on { animation: flash2 .14s ease-out; }
@keyframes flash2 { from { opacity: .9; } to { opacity: 0; } }
.pop--top { font-size: 42px; }
.pop--top small { font-size: 18px; }
.banner { top: calc(64px + var(--safe-top)); left: calc(14px + var(--vx, 0px)); right: calc(14px + var(--vx, 0px)); padding: 6px; font-size: 20px; border-width: 3px; border-radius: 999px; white-space: nowrap; }
.develop-title { font-size: 32px; display: flex; align-items: baseline; gap: 12px; }
.develop-title small { font-size: 14px; }
.develop-wait { font-size: 24px; font-weight: 900; animation: letter .3s ease both; }
.screen--develop:has(.develop-wait:not([hidden])) { background: #17090c; }
.print.is-developing .print__score { animation: letter .25s 1s ease both; }
.screen--best::before { animation: burst 1s ease both; }
@keyframes burst { 0% { background: #fff; opacity: 1; } 15% { background: #17090c; opacity: 1; } 100% { background: #17090c; opacity: 0; } }
.screen--best { padding-left: 8px; padding-right: 8px; }
.screen--best .frame { width: min(96vw, 620px); max-width: calc((100dvh - 320px) * 1.28); padding: 10px; }
.frame canvas { border-width: 4px; }
.result-top { padding: calc(20px + var(--safe-top)) 7px 8px; gap: 6px; }
.result-top .frame { padding: 8px; max-width: none; }
.stamps { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; font-size: 11px; font-weight: 800; }
.stamps b { width: 100%; font-size: 13px; }
.stamps span { padding: 2px 8px; border: 2px solid var(--c-line); border-radius: 999px; color: var(--c-ink-sub); }
.stamps .is-on { background: var(--c-gold); border-color: var(--c-gold-deep); color: var(--c-ink); }
@media (max-width: 374px) { .chip--score small { display: block; } }
@media (max-height: 700px) { .result-top { padding-top: 18px; } .result-notes { gap: 2px 4px; font-size: 11px; } .result-notes span { padding: 1px 6px; border-width: 1px; } .result-sheet .btn { min-height: 40px; font-size: 16px; } .result-sheet .btn--small { min-height: 34px; font-size: 13px; --btn-depth: 3px; } .result-sheet .actions { gap: 3px; } }
@media (max-width: 374px) { .chip small { display: block; font-size: 9px; } .chip--time { gap: 3px; } }
@media (max-height: 700px) { .banner { top: calc(52px + var(--safe-top)); padding: 2px; font-size: 16px; } }
