@layer legacy {
:root {
  --serif: 'Findd Royal', Georgia, 'Songti SC', serif;
  --sans: 'Microsoft YaHei', 'PingFang SC', system-ui, sans-serif;
  --radius: 18px;
  --hidden-photo-edge: color-mix(in srgb, var(--gold) 65%, transparent);
  --hidden-photo-glow: color-mix(in srgb, var(--gold) 17%, transparent);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 280px; }
body { margin: 0; padding: env(safe-area-inset-top,0px) env(safe-area-inset-right,0px) env(safe-area-inset-bottom,0px) env(safe-area-inset-left,0px); min-height: 100svh; color: var(--ink); background: var(--paper); font: 14px/1.6 var(--sans); -webkit-font-smoothing: antialiased; isolation: isolate; }
body::before { content: ''; position: fixed; inset: 0; z-index: -2; background-image: var(--scene-overlay), var(--scene-art); background-size: cover; background-position: center; pointer-events: none; }
body::after { content: ''; position: fixed; inset: 12px; z-index: -1; border: 1px solid var(--line); border-radius: 4px; pointer-events: none; }
h1, h2, p, figure { margin: 0; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
button { cursor: pointer; color: inherit; border: 0; background: none; -webkit-tap-highlight-color: transparent; transition: transform .2s, box-shadow .2s, background .2s, opacity .2s; }
button:disabled { cursor: not-allowed; opacity: .48; }
button:focus-visible, input:focus-visible, .picture-svg:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
button:active:not(:disabled) { transform: translateY(2px); }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.site-header { position: relative; max-width: 1280px; min-height: 86px; margin: auto; padding: 14px 40px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 13px; padding: 0; min-height: 44px; }
.brand-mark { display: block; width: 34px; height: 34px; border: 3px double var(--gold); border-radius: 50%; position: relative; box-shadow: inset 0 0 0 3px var(--panel-solid), 0 2px 5px #32271725; }
.brand-mark::before { content: '✧'; position: absolute; inset: 0; display: grid; place-items: center; color: var(--gold); font: 26px var(--serif); }
.brand-mark::after { content: ''; position: absolute; width: 15px; height: 5px; background: var(--gold); border-radius: 2px; bottom: -5px; left: -10px; transform: rotate(-48deg); }
.brand-mark span { display: none; }
.brand-name { font: 30px/1.1 var(--serif); letter-spacing: 4px; text-align: left; }
.brand-name b { font-weight: 400; }
.brand-name > span { display: block; font: 8px/1 var(--sans); letter-spacing: 5px; margin-top: 7px; }
.theme-switcher { display: flex; align-items: center; gap: 5px; border: 1px solid var(--line); padding: 4px; border-radius: 32px; background: var(--panel); backdrop-filter: blur(18px); }
.theme-switcher-label { display: none; }
.theme-option { min-height: 44px; min-width: 44px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 15px; border: 1px solid transparent; border-radius: 25px; font-size: 12px; }
.theme-option .icon { width: 17px; height: 17px; }
.header-actions { display: flex; gap: 10px; }
.text-button { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: var(--muted); padding: 8px; font-size: 12px; }
.text-button:hover { color: var(--wine); }
.header-actions .text-button { width: 44px; border: 1px solid var(--gold); border-radius: 50%; background: var(--panel); box-shadow: inset 0 0 0 3px var(--paper), 0 3px 10px #0001; }
.header-actions .text-button > span { position: absolute; clip: rect(0,0,0,0); width: 1px; height: 1px; overflow: hidden; }
.eyebrow { font: 10px/1.4 var(--sans); letter-spacing: 2px; color: var(--muted); }
.primary-button, .secondary-button { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 16px; min-height: 54px; padding: 12px 25px; border: 1px solid var(--gold); border-radius: 12px; font: 21px/1.25 var(--serif); overflow-wrap: anywhere; }
.primary-button::after { content: ''; position: absolute; inset: 4px; border: 1px solid #e9cd945e; border-radius: 8px; pointer-events: none; }
.primary-button:hover:not(:disabled), .secondary-button:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 24px #24150d29; }
.primary-button:disabled, .secondary-button:disabled { transform: none; }
.wide { width: 100%; }
.subtle-text { color: var(--muted); font-size: 11px; line-height: 1.7; }
.site-footer { max-width: 1220px; margin: auto; display: flex; justify-content: space-between; gap: 12px; padding: 14px 44px 19px; color: var(--muted); font-size: 8px; letter-spacing: 1.5px; }
.game-view { max-width: 1060px; margin: auto; padding: 14px 28px 0; }
.game-heading { display: grid; grid-template-columns: 44px minmax(0,1fr) 44px; align-items: center; gap: 16px; max-width: 840px; margin: 0 auto 10px; }
.game-heading > .text-button { min-width: 44px; width: 44px; height: 44px; border: 1px solid var(--gold); border-radius: 50%; background: var(--panel); }
.game-heading > .text-button > span { position: absolute; clip: rect(0,0,0,0); width: 1px; height: 1px; overflow: hidden; }
.level-banner { text-align: center; padding: 2px 15px; min-width: 0; }
.level-banner .eyebrow { font-size: 8px; letter-spacing: 2px; }
.game-heading h1 { font: 32px/1.35 var(--serif); letter-spacing: 3px; overflow-wrap: anywhere; }
.level-description { color: var(--muted); font-size: 10px; margin-top: 3px; }
#level-subtitle { display: none; }
.game-hud { max-width: 840px; margin: 0 auto 8px; padding: 9px 16px 7px; border: 1px solid var(--gold); border-radius: 16px; background: var(--panel); box-shadow: inset 0 0 0 3px var(--paper); backdrop-filter: blur(16px); }
.hud-stats { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.hud-mistakes { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--muted); }
.hud-miss-icon { color: var(--wine); font: 24px/1 var(--serif); }
#mistake-count { font: 20px var(--serif); color: var(--ink); }
.hud-level { font: 18px/1.2 var(--serif); color: var(--wine); text-align: center; }
#challenge-pause { justify-self: end; min-height: 44px; min-width: 108px; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 5px 12px; border: 1px solid var(--gold); border-radius: 24px; background: var(--panel-solid); }
#challenge-time { font: 22px/1 var(--serif); font-variant-numeric: tabular-nums; }
#challenge-pause > span { font-size: 10px; }
#challenge-pause .icon { width: 18px; height: 18px; }
.hud-discoveries { display: flex; justify-content: center; align-items: center; gap: 22px; margin-top: 4px; }
.progress-block { display: flex; align-items: center; gap: 7px; }
.progress-block > p { font: 22px/1 var(--serif); white-space: nowrap; }
.progress-total { font-size: 16px; color: var(--muted); }
.progress-label { color: var(--muted); font-size: 10px; }
.progress-emblem { width: 20px; height: 20px; color: var(--gold); }
.progress-dots { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.progress-dot { display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid var(--gold); border-radius: 50%; color: var(--muted); background: var(--panel-solid); font-size: 13px; }
.hud-clock-note { color: var(--muted); font-size: 9px; text-align: center; margin-top: 3px; line-height: 1.4; }
.board-toolbar { max-width: 840px; display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: 0 auto 7px; color: var(--muted); font-size: 10px; }
.board-toolbar > div { display: flex; border: 1px solid var(--line); border-radius: 10px; padding: 2px; background: var(--panel); }
.board-toolbar button { min-height: 40px; padding: 5px 14px; border-radius: 7px; font-size: 11px; }
.image-board { position: relative; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; width: 100%; max-width: min(100%, calc(max(170px, 100svh - 430px) * var(--picture-double-ratio,1.6) + 34px)); margin: auto; }
.image-card { min-width: 0; padding: 0 7px 7px; border: 1px solid var(--gold); border-radius: 17px 17px 9px 9px; background: var(--panel-solid); box-shadow: inset 0 0 0 3px var(--paper), 0 10px 32px #0002; }
.image-card figcaption { display: flex; align-items: center; justify-content: space-between; gap: 4px; min-height: 42px; color: var(--muted); font-size: 10px; }
.image-card figcaption > span { display: flex; align-items: center; gap: 8px; min-width: 0; }
.image-card figcaption b { display: grid; place-items: center; width: 27px; height: 28px; border: 1px solid var(--line); border-radius: 10px 2px; font: 19px var(--serif); color: var(--gold); }
.zoom-button { display: flex; justify-content: center; align-items: center; gap: 5px; min-width: 44px; min-height: 44px; padding: 5px; color: var(--wine); font-size: 10px; }
.zoom-button .icon { width: 18px; height: 18px; }
.picture-frame { position: relative; border-radius: 9px 9px 3px 3px; overflow: hidden; background: var(--panel-soft); line-height: 0; touch-action: pan-x pan-y pinch-zoom; }
.picture-svg { display: block; width: 100%; height: auto; cursor: crosshair; touch-action: pan-x pan-y pinch-zoom; -webkit-user-select: none; user-select: none; }
.image-board .picture-frame[data-scale]:not([data-scale="1.000"]),
.image-board .picture-frame[data-scale]:not([data-scale="1.000"]) .picture-svg { touch-action: none; }
.picture-svg:focus-visible { outline-offset: -5px; }
.board-divider { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); color: var(--gold); pointer-events: none; }
.board-divider .icon { width: 13px; }
.game-view[data-layout="stack"] .image-board { grid-template-columns: minmax(0,1fr); max-width: min(100%,560px); gap: 14px; }
.game-view[data-layout="stack"] .board-divider { display: none; }
.game-view[data-clock-paused="true"] .picture-svg { visibility: hidden; }
.found-mark { fill: transparent; stroke-width: 3; pointer-events: none; animation: mark-in .3s ease-out; transform-box: fill-box; transform-origin: center; }
.found-number { font: 600 21px var(--sans); paint-order: stroke; stroke-width: 4; stroke-linejoin: round; pointer-events: none; }
.hint-mark { stroke-width: 1.8px; vector-effect: non-scaling-stroke; stroke-dasharray: 6 4; pointer-events: none; animation: hint-pulse 1.8s ease-in-out infinite; }
.miss-mark { fill: none; stroke: #fff; stroke-width: 3; opacity: .8; pointer-events: none; }
.keyboard-cursor { stroke: #fff; fill: #0002; stroke-width: 2; filter: drop-shadow(0 0 2px #222); }
.board-instruction { display: flex; align-items: center; justify-content: center; gap: 7px; color: var(--muted); text-align: center; font-size: 9px; margin: 9px 0 13px; }
.instruction-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--sage); }
.tool-dock { position: relative; z-index: 4; display: flex; align-items: stretch; gap: 14px; max-width: 670px; margin: auto; padding: 10px; border: 1px solid var(--gold); border-radius: 20px; background: var(--panel); backdrop-filter: blur(18px); box-shadow: 0 8px 24px #0002, inset 0 0 0 3px var(--paper); }
.tool-dock-label, .tool-copy small { display: none; }
.tool-button { position: relative; flex: 1; min-width: 0; min-height: 58px; display: flex; justify-content: center; align-items: center; gap: 12px; padding: 8px 12px; border: 1px solid var(--gold); border-radius: 13px; }
.tool-icon { display: grid; place-items: center; flex: none; }
.tool-icon .icon { width: 32px; height: 32px; }
.tool-copy b { font: 18px/1.2 var(--serif); overflow-wrap: anywhere; }
.tool-count { position: absolute; top: -8px; right: 7px; min-width: 23px; height: 23px; border: 1px solid var(--gold); border-radius: 50%; display: grid; place-items: center; font: 16px/1 var(--serif); background: var(--panel-solid); }
.tool-note { text-align: center; color: var(--muted); font-size: 8px; margin: 9px 0 4px; }
.continue-wrap { text-align: center; }
.continue-wrap .primary-button { margin-bottom: 15px; min-height: 44px; font-size: 18px; }
.loading-panel { min-height: 280px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; color: var(--muted); }
.loading-spinner { width: 28px; height: 28px; border: 2px solid var(--line); border-top-color: var(--wine); border-radius: 50%; animation: spin .8s linear infinite; }
.loading-panel.has-error .loading-spinner { display: none; }
body[data-view="game"] .site-footer { display: none; }
body[data-mode="replay"] #skip-button, body[data-mode="challenge"] #skip-button { display: none; }

.collection-view { max-width: 1130px; margin: auto; padding: 20px 35px 40px; }
.collection-topline { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.collection-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin: 18px 0 30px; }
.collection-heading h1 { font: 36px/1.4 var(--serif); }
.collection-heading h1 em { color: var(--wine); font-style: normal; display: block; }
.collection-heading p { font-size: 12px; color: var(--muted); margin-top: 10px; }
.collection-heading strong { font-size: 12px; color: var(--wine); padding: 12px 16px; border: 1px solid var(--gold); border-radius: 8px; background: var(--panel); max-width: 300px; }
.collection-cards { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
.collection-card { min-width: 0; position: relative; padding: 7px; border: 1px solid var(--gold); border-radius: 65px 65px 12px 12px; background: var(--panel-solid); box-shadow: 0 10px 24px #0002, inset 0 0 0 3px var(--paper); overflow: hidden; }
.collection-card > img { width: 100%; aspect-ratio: 4/5; object-fit: contain; border-radius: 58px 58px 4px 4px; background: var(--panel-soft); }
.collection-card[data-locked="true"] > img { filter: saturate(.3); opacity: .45; }
.collection-card-body { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; padding: 18px 10px 9px; }
.collection-card h2 { grid-column: 1 / -1; font: 21px/1.35 var(--serif); text-align: center; }
.star-rating { color: var(--gold); letter-spacing: 6px; font-size: 27px; text-align: center; }
.collection-card .star-rating, .collection-detail, .collection-play { grid-column: 1 / -1; }
.collection-detail { font-size: 10px; color: var(--muted); text-align: center; }
.collection-card button { width: 100%; min-height: 48px; padding: 9px 8px; font-size: 15px; }
.collection-card .collection-play { font-size: 20px; }
.collection-card[data-collected="true"] { box-shadow: 0 10px 24px #0002, inset 0 0 0 3px var(--gold); }
.collection-hidden-reward { grid-column: 1 / -1; display: grid; gap: 8px; min-width: 0; margin-top: 3px; padding: 14px; border: 1px dashed var(--hidden-photo-edge); border-radius: 12px; background: linear-gradient(135deg, var(--hidden-photo-glow), transparent 80%); }
.collection-hidden-reward > strong { font: 17px/1.4 var(--serif); }
.hidden-photo-hint { font-size: 11px; line-height: 1.7; overflow-wrap: anywhere; }
.collection-hidden-reward[data-unlocked="true"] { border-style: solid; box-shadow: inset 0 0 18px var(--hidden-photo-glow); }
.collection-hidden-reward .collection-hidden-art { min-width: 0; margin-top: 2px; background: var(--hidden-photo-glow); }
.collection-hidden-art:hover:not(:disabled) { box-shadow: 0 5px 18px var(--hidden-photo-glow); }
.hidden-photo-rule { font-weight: 600; }
.hidden-photo-unlocked, .hidden-photo-placeholder { padding: 12px 14px; border: 1px solid var(--hidden-photo-edge); border-radius: 12px; background: linear-gradient(135deg, var(--hidden-photo-glow), transparent); font-size: 12px; line-height: 1.7; overflow-wrap: anywhere; }
.hidden-photo-unlocked { margin-bottom: 18px; }
.collection-rules { border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin-top: 27px; font-size: 11px; color: var(--muted); background: var(--panel); }
.collection-rules h2 { color: var(--wine); font: 22px var(--serif); margin-bottom: 10px; }
.collection-rules p + p { margin-top: 8px; }
.modal { width: 460px; max-width: calc(100vw - 28px); max-height: calc(100svh - 32px); border: 1px solid var(--gold); border-radius: 23px; padding: 40px 30px 28px; color: var(--ink); background: var(--panel-solid); box-shadow: 0 30px 100px #0007, inset 0 0 0 5px var(--paper), inset 0 0 0 6px var(--line); overflow: auto; }
.modal[open] { animation: appear .22s ease; }
.modal::backdrop, .zoom-modal::backdrop { background: var(--backdrop); backdrop-filter: blur(9px); }
.modal h2 { font: 30px/1.4 var(--serif); color: var(--wine); margin: 13px 0 18px; overflow-wrap: anywhere; }
.modal p:not(.eyebrow, .star-rating) { color: var(--muted); font-size: 12px; line-height: 1.9; }
.modal-close { position: absolute; right: 10px; top: 10px; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; display: grid; place-items: center; background: var(--panel-solid); }
.help-steps { list-style: none; margin: 23px 0; padding: 0; }
.help-steps li { display: flex; gap: 18px; margin-bottom: 18px; }
.help-steps li > span { font: 25px var(--serif); color: var(--gold); }
.help-steps b { font-weight: 500; }
.help-steps p { margin-top: 4px; }
.help-footnote { border-top: 1px solid var(--line); padding-top: 15px; margin-bottom: 22px; }
.result-modal, .pause-modal { text-align: center; }
.result-symbol, .finish-emblem { display: grid; place-items: center; width: 70px; height: 70px; margin: 0 auto 23px; border: 3px double var(--gold); border-radius: 50%; background: var(--panel-soft); color: var(--gold); }
.result-symbol .icon, .finish-emblem .icon { width: 34px; height: 34px; }
.result-dots { display: flex; justify-content: center; gap: 8px; margin: 23px 0; }
.result-dots span { width: 8px; height: 8px; border-radius: 50%; background: var(--sage); }
.result-dots span.revealed { background: var(--gold); }
#result-stars { margin: 12px 0; font-size: 39px; }
.reward-caption { margin-top: 12px; }
.result-modal > .text-button, .pause-modal > .text-button { margin: 14px auto 0; }
.pause-modal::backdrop { background: var(--paper); }
.pause-modal > p:not(.eyebrow) { margin: 20px 0; }
.confirm-actions { display: flex; gap: 14px; margin-top: 28px; }
.confirm-actions button { flex: 1; min-width: 0; padding: 10px; font-size: 18px; }
.sound-control { padding: 16px 0; border-bottom: 1px solid var(--line); }
.sound-toggle { display: flex; align-items: center; justify-content: space-between; gap: 15px; cursor: pointer; min-height: 48px; }
.sound-toggle small { display: block; color: var(--muted); font-size: 10px; }
.sound-toggle input { appearance: none; flex: none; position: relative; margin: 0; width: 48px; height: 28px; border: 1px solid var(--gold); border-radius: 25px; background: var(--panel-soft); cursor: pointer; }
.sound-toggle input::after { content: ''; position: absolute; width: 20px; height: 20px; top: 3px; left: 3px; border-radius: 50%; background: var(--muted); transition: transform .2s; }
.sound-toggle input:checked { background: var(--wine); }
.sound-toggle input:checked::after { transform: translateX(20px); background: var(--accent-text); }
.volume-label { display: flex; justify-content: space-between; font-size: 11px; margin-top: 14px; color: var(--muted); }
.sound-control input[type="range"] { width: 100%; height: 44px; margin: 0; accent-color: var(--wine); cursor: pointer; }
#sound-preview { margin-top: 18px; }
.sound-footnote { margin-top: 15px; }
.art-modal { width: 680px; padding: 22px; }
.art-modal header { position: relative; margin-bottom: 17px; padding-right: 54px; }
.art-modal .modal-close { top: 0; right: 0; }
.art-modal h2 { margin: 4px 0 0; }
.art-modal > img { width: auto; max-height: 68svh; max-width: 100%; object-fit: contain; margin: auto; border: 1px solid var(--gold); border-radius: 8px; }
.art-modal > p { text-align: center; margin-top: 12px; }
.finish-view { max-width: 960px; margin: auto; padding: 40px 32px; text-align: center; }
.finish-view h1 { font: 37px/1.5 var(--serif); margin: 17px 0 13px; }
.finish-view h1 em { display: block; font-style: normal; color: var(--wine); }
.finish-view > p { font-size: 12px; color: var(--muted); }
.finish-stats { display: flex; justify-content: center; margin: 26px 0; }
.finish-stats > div { display: flex; flex-direction: column; min-width: 140px; }
.finish-stats > div + div { border-left: 1px solid var(--line); }
.finish-stats strong { color: var(--wine); font: 34px var(--serif); }
.finish-stats span { color: var(--muted); font-size: 11px; margin-top: 5px; }
.finish-chapters { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); max-width: 670px; gap: 16px; margin: 0 auto 27px; }
.finish-chapter { padding: 7px; border: 1px solid var(--gold); border-radius: 11px; background: var(--panel-solid); }
.finish-chapter img { width: 100%; aspect-ratio: 4/5; object-fit: contain; border-radius: 5px; }
.finish-chapter > div { display: flex; align-items: center; justify-content: space-between; gap: 5px; padding: 10px 2px 2px; font-size: 11px; }
.finish-chapter small { color: var(--sage); font-size: 9px; }
.finish-chapter small.skipped { color: var(--gold); }
#finish-collection { margin: 0 8px 12px; }
.finish-view > .text-button { display: flex; margin: 12px auto 0; }
.zoom-modal { width: min(1200px,calc(100vw - 24px)); max-width: calc(100vw - 24px); height: calc(100svh - 24px); max-height: calc(100svh - 24px); padding: 0; border: 1px solid var(--gold); border-radius: 17px; color: var(--ink); background: var(--paper); overflow: hidden; }
.zoom-modal[open] { display: flex; flex-direction: column; }
.zoom-header { position: relative; flex: none; min-height: 76px; display: flex; align-items: center; justify-content: space-between; padding: 12px 67px 12px 20px; border-bottom: 1px solid var(--line); }
.zoom-header h2 { font: 23px/1.3 var(--serif); }
.zoom-header p { color: var(--muted); font-size: 11px; margin-top: 4px; }
.zoom-controls { flex: none; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--panel); }
.zoom-controls button { min-width: 44px; min-height: 44px; border: 1px solid var(--gold); border-radius: 8px; padding: 5px 12px; background: var(--panel-solid); }
#zoom-in, #zoom-out { font-size: 23px; }
#zoom-scale { min-width: 52px; text-align: center; font-variant-numeric: tabular-nums; }
#zoom-time, #zoom-mistakes { font-size: 11px; color: var(--muted); }
.zoom-pair { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; padding: 12px; }
.zoom-panel { display: flex; flex-direction: column; min-width: 0; min-height: 0; border: 1px solid var(--gold); border-radius: 9px; background: var(--panel-soft); overflow: hidden; }
.zoom-panel figcaption { flex: none; display: flex; align-items: center; gap: 8px; min-height: 32px; padding: 4px 10px; font-size: 11px; background: var(--panel); }
.zoom-panel figcaption b { font: 18px var(--serif); color: var(--gold); }
.zoom-viewport { flex: 1; min-width: 0; min-height: 0; border-radius: 0; touch-action: none; }
.zoom-viewport .picture-svg { width: 100%; height: 100%; touch-action: none; cursor: grab; }
.zoom-viewport .picture-svg:active { cursor: grabbing; }
.zoom-aim { fill: #0002; stroke: #fff; stroke-width: 2; vector-effect: non-scaling-stroke; pointer-events: none; filter: drop-shadow(0 0 2px #000); }
.zoom-footer { flex: none; min-height: 37px; text-align: center; padding: 7px 12px; font-size: 10px; color: var(--muted); }
.toast { position: fixed; z-index: 20; bottom: 110px; left: 50%; transform: translate(-50%,10px); max-width: calc(100vw - 30px); padding: 12px 22px; border: 1px solid var(--gold); border-radius: 12px; background: var(--panel-solid); color: var(--ink); box-shadow: 0 5px 22px #0003; font-size: 12px; text-align: center; pointer-events: none; opacity: 0; transition: opacity .2s,transform .2s; }
.toast.visible { opacity: 1; transform: translate(-50%,0); }
@keyframes appear { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes mark-in { from { opacity: 0; transform: scale(1.25); } to { opacity: 1; transform: scale(1); } }
@keyframes hint-pulse { 50% { opacity: .55; } }
@keyframes spin { to { transform: rotate(360deg); } }
@media (min-width: 761px) {
  .game-view { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); column-gap: 24px; }
  .game-view > * { grid-column: 1 / -1; }
  .game-view > .game-heading { grid-column: 1; width: 100%; align-self: center; }
  .game-view > .game-hud { grid-column: 2; width: 100%; }
  .game-view .board-toolbar { width: 100%; max-width: none; }
  .game-view .image-board { max-width: min(100%, calc(max(140px,100svh - 451px) * var(--picture-double-ratio,1.6) + 34px)); }
}
@media (max-width: 1000px) and (min-width: 761px) {
  .site-header { padding-inline: 28px; }
  .collection-cards { gap: 15px; }
}
@media (max-width: 760px) {
  body::after { inset: 5px; }
  .site-header { min-height: 64px; padding: 9px 15px; gap: 9px; }
  .brand { gap: 0; min-width: 55px; }
  .brand-mark { display: none; }
  .brand-name { font-size: 24px; letter-spacing: 2px; }
  .brand-name > span { font-size: 6px; letter-spacing: 3px; margin-top: 5px; }
  .theme-switcher { margin-left: auto; gap: 0; padding: 0; background: var(--panel); }
  .theme-option { padding: 6px; width: 44px; }
  .theme-option > span { position: absolute; clip: rect(0,0,0,0); width: 1px; height: 1px; overflow: hidden; }
  .theme-option .icon { width: 18px; height: 18px; }
  .header-actions { gap: 5px; }
  .header-actions .text-button { width: 44px; height: 44px; }
  .site-footer { padding: 10px 22px 15px; font-size: 7px; letter-spacing: .8px; }
  .game-view { padding: 8px 12px 0; }
  .game-heading { gap: 7px; margin-bottom: 7px; }
  .level-banner { padding: 0 4px; }
  .level-banner .eyebrow { font-size: 7px; letter-spacing: 1px; }
  .game-heading h1 { font-size: 26px; letter-spacing: 1px; }
  .level-description { display: none; }
  .game-hud { padding: 5px 10px; margin-bottom: 5px; border-radius: 12px; }
  .hud-stats { gap: 6px; }
  .hud-mistakes { font-size: 10px; gap: 4px; }
  .hud-level { font-size: 16px; }
  #mistake-count { font-size: 18px; }
  #challenge-pause { min-width: 97px; padding: 4px 8px; gap: 5px; }
  #challenge-time { font-size: 20px; }
  .hud-discoveries { gap: 17px; margin-top: 1px; }
  .progress-block { gap: 5px; }
  .progress-emblem { width: 17px; }
  .progress-block > p { font-size: 20px; }
  .progress-label { font-size: 9px; }
  .progress-total { font-size: 14px; }
  .progress-dot { width: 22px; height: 22px; font-size: 12px; }
  .progress-dots { gap: 6px; }
  .hud-clock-note { font-size: 8px; }
  .board-toolbar { margin-bottom: 5px; gap: 8px; }
  #board-tip { max-width: 38%; font-size: 9px; line-height: 1.4; }
  .board-toolbar button { min-height: 44px; font-size: 10px; padding: 4px 10px; }
  .image-board { gap: 10px; max-width: min(100%, calc(max(110px, 100svh - 412px) * var(--picture-double-ratio,1.6) + 26px)); }
  .image-card { padding: 0 5px 5px; border-radius: 13px 13px 7px 7px; }
  .image-card figcaption { min-height: 40px; font-size: 8px; }
  .image-card figcaption > span { gap: 4px; }
  .image-card figcaption > span > span { line-height: 1.2; overflow-wrap: anywhere; }
  .image-card figcaption b { width: 22px; height: 25px; font-size: 17px; flex: none; }
  .zoom-button > span { display: none; }
  .zoom-button { padding: 3px; }
  .board-divider { display: none; }
  .board-instruction { margin: 7px 0 12px; font-size: 8px; }
  .tool-dock { padding: 8px 6px 6px; gap: 9px; border-radius: 15px; }
  .tool-button { min-height: 52px; padding: 5px; gap: 5px; border-radius: 11px; }
  .tool-icon .icon { width: 24px; height: 24px; }
  .tool-copy b { font-size: 14px; }
  .tool-count { width: 21px; min-width: 21px; height: 21px; font-size: 15px; top: -8px; right: 5px; }
  .tool-note { margin: 8px 0; font-size: 8px; }
  .game-view[data-layout="stack"] .tool-dock { position: sticky; bottom: calc(8px + env(safe-area-inset-bottom,0px)); }
  .collection-view { padding: 12px 18px 25px; overflow: hidden; }
  .collection-topline .eyebrow { font-size: 8px; letter-spacing: 1px; }
  .collection-heading { display: block; margin: 8px 0 16px; text-align: center; }
  .collection-heading h1 { font-size: 26px; line-height: 1.3; }
  .collection-heading p { font-size: 10px; margin-top: 6px; }
  .collection-heading strong { display: inline-block; max-width: 100%; margin-top: 10px; font-size: 10px; padding: 6px 12px; }
  .collection-cards { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 5px 5px 18px; margin-inline: -5px; scrollbar-width: thin; scrollbar-color: var(--gold) transparent; }
  .collection-card { flex: 0 0 88%; scroll-snap-align: center; border-radius: 50px 50px 12px 12px; }
  .collection-card > img { height: clamp(180px, 35svh, 300px); aspect-ratio: auto; border-radius: 43px 43px 4px 4px; }
  .collection-card-body { padding: 15px 8px 6px; gap: 10px; }
  .collection-card h2 { font-size: 21px; }
  .collection-card button { font-size: 14px; }
  .collection-card .collection-play { font-size: 21px; }
  .collection-rules { padding: 16px; margin-top: 15px; }
  .modal { padding: 38px 24px 24px; }
  .modal h2 { font-size: 26px; }
  .primary-button, .secondary-button { font-size: 19px; }
  .sound-control { padding: 11px 0; }
  .finish-view { padding: 30px 18px; }
  .finish-view h1 { font-size: 28px; }
  .finish-stats > div { min-width: 0; flex: 1; }
  .finish-stats span { font-size: 9px; }
  .finish-chapters { gap: 8px; }
  .finish-chapter { padding: 4px; }
  .finish-chapter > div { display: block; font-size: 9px; }
  .finish-chapter small { display: block; }
  .zoom-header { padding: 10px 64px 10px 14px; min-height: 72px; }
  .zoom-header h2 { font-size: 18px; }
  .zoom-header p { font-size: 9px; line-height: 1.4; }
  .zoom-pair { gap: 8px; padding: 8px; }
  .zoom-controls { gap: 5px; padding: 6px 8px; }
  .zoom-controls button { padding-inline: 9px; }
  .zoom-panel figcaption { font-size: 9px; line-height: 1.2; }
  .zoom-footer { font-size: 9px; }
}
@media (max-width: 760px) and (orientation: portrait) {
  .zoom-modal[data-portrait="false"] .zoom-pair { grid-template-columns: minmax(0,1fr); grid-template-rows: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 760px) and (max-height: 740px) {
  .site-header { min-height: 58px; padding-block: 6px; }
  .game-view { padding-top: 5px; }
  .game-heading { margin-bottom: 5px; }
  .game-heading h1 { font-size: 24px; }
  .hud-clock-note, .tool-note { position: absolute; clip: rect(0,0,0,0); width: 1px; height: 1px; overflow: hidden; }
  .game-hud { padding-block: 3px; }
  .image-board { max-width: min(100%, calc(max(110px,100svh - 393px) * var(--picture-double-ratio,1.6) + 24px)); }
  .board-instruction { margin: 5px 0 10px; }
  .tool-dock { padding-block: 7px 5px; }
  .tool-button { min-height: 48px; }
}
@media (max-width: 360px) {
  .site-header { padding-inline: 9px; gap: 5px; }
  .header-actions { gap: 3px; }
  .brand-name { font-size: 21px; }
  .brand { min-width: 48px; }
  .game-view { padding-inline: 9px; }
  .game-heading h1 { font-size: 22px; }
  .hud-level { font-size: 14px; }
  .hud-mistakes { font-size: 9px; }
  .tool-dock { gap: 7px; padding-inline: 5px; }
  .tool-copy b { font-size: 13px; }
  .tool-icon .icon { width: 21px; height: 21px; }
  .tool-button { gap: 3px; }
}
@media (max-height: 480px) and (orientation: landscape) {
  .zoom-header { min-height: 48px; padding-block: 5px; }
  .zoom-header h2 { font-size: 17px; }
  .zoom-header p { font-size: 9px; margin: 0; }
  .zoom-header .modal-close { top: 2px; }
  .zoom-controls { padding-block: 3px; }
  .zoom-pair { padding: 6px; gap: 8px; }
  .zoom-footer { min-height: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}




:root {
  --home-available-height: calc(100svh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
  --home-width: min(calc(100cqw - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)), max(320px, calc(var(--home-available-height) * .4625813449)));
  --home-height: calc(var(--home-width) * 1844 / 853);
  --home-top: calc(env(safe-area-inset-top, 0px) + max(0px, (var(--home-available-height) - var(--home-height)) / 2));
  --home-rose: #a62c49;
  --home-ink: #7d342c;
  --home-gold: #d9a75c;
}
body[data-view="home"] { padding: 0; background: #261e1b; container-type: inline-size; }
body[data-view="home"]::before {
  background: linear-gradient(#271b245c,#211917b8), url('assets/ui-ref-home-scene.png') center / cover;
  filter: blur(15px); transform: scale(1.06);
}
body[data-view="home"]::after, body[data-view="home"] .site-footer { display: none; }
body[data-view="home"] main { min-height: 100svh; padding: env(safe-area-inset-top, 0px) env(safe-area-inset-right, 0px) env(safe-area-inset-bottom, 0px) env(safe-area-inset-left, 0px); display: grid; place-items: center; }
.home-view {
  position: relative; isolation: isolate; overflow: hidden; display: block;
  width: var(--home-width); height: var(--home-height); min-height: 0;
  max-width: none; margin: 0; padding: 0; color: var(--home-ink);
  box-shadow: 0 0 90px #0008; container-type: inline-size;
}
.home-scene { position: absolute; inset: 0; z-index: -1; background: url('assets/ui-ref-home-scene.png') center / 100% 100% no-repeat; }
body[data-view="home"] .site-header {
  position: absolute; top: var(--home-top); left: calc((100% - var(--home-width) + env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) / 2); transform: none; z-index: 5;
  width: var(--home-width); max-width: none; height: var(--home-height); min-height: 0;
  padding: 0; margin: 0; border: 0; display: block; pointer-events: none; container-type: inline-size;
}
body[data-view="home"] .site-header button { pointer-events: auto; }
body[data-view="home"] .brand,
body[data-view="home"] .header-actions .text-button,
body[data-view="home"] .theme-option,
body[data-view="home"] #start-button,
body[data-view="home"] #collection-button,
.home-nav button {
  position: absolute; display: block; min-width: 0; min-height: 0; margin: 0; padding: 0;
  border: 0; border-radius: 0; box-shadow: none; filter: none; transform: none;
  background-size: 100% 100%; background-position: center; background-repeat: no-repeat;
  transition: filter .18s, opacity .18s; text-shadow: none;
}
body[data-view="home"] .brand:hover,
body[data-view="home"] .header-actions .text-button:hover,
body[data-view="home"] .theme-option:hover,
body[data-view="home"] #start-button:hover:not(:disabled),
body[data-view="home"] #collection-button:hover:not(:disabled),
.home-nav button:hover:not(:disabled) { filter: brightness(1.06); transform: none; box-shadow: none; }
body[data-view="home"] button:active:not(:disabled) { filter: brightness(.94); transform: none; }
body[data-view="home"] .brand {
  left: calc(100cqw * 48 / 853); top: calc(100cqw * 50 / 853);
  width: calc(100cqw * 311 / 853); height: calc(100cqw * 151 / 853);
  display: grid; place-items: center; background: #fff8ecb8;
  border: 1px solid #d7a878; border-radius: 46% 46% 42% 42% / 44% 44% 48% 48%;
  box-shadow: 0 3px 12px #683f3b27, inset 0 0 0 3px #fff8efb5;
  color: #aa2440;
}
body[data-view="home"] .brand > .brand-mark { display: none; }
body[data-view="home"] .brand > .brand-name {
  position: static; width: auto; height: auto; margin: 0; padding: 0; overflow: visible;
  clip: auto; border: 0; text-align: center; white-space: nowrap;
  font: calc(100cqw * 46 / 853)/1.1 var(--serif); letter-spacing: -.04em;
}
body[data-view="home"] .brand-name > span {
  margin-top: calc(100cqw * 8 / 853); color: #9b654b;
  font: calc(100cqw * 16 / 853)/1 var(--sans); letter-spacing: .16em;
}
body[data-view="home"] .theme-option > *,
body[data-view="home"] .header-actions .text-button > * {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); border: 0;
}
body[data-view="home"] .header-actions, body[data-view="home"] .theme-switcher { display: contents; }
body[data-view="home"] #sound-button { left: calc(100cqw * 623 / 853); top: calc(100cqw * 52 / 853); width: calc(100cqw * 86 / 853); height: calc(100cqw * 85 / 853); background-image: url('assets/ui-ref-home-sound.png'); }
body[data-view="home"] #help-button { left: calc(100cqw * 731 / 853); top: calc(100cqw * 52 / 853); width: calc(100cqw * 86 / 853); height: calc(100cqw * 85 / 853); background-image: url('assets/ui-ref-home-help.png'); }
body[data-view="home"] .theme-switcher::before {
  content: ''; position: absolute; left: calc(100cqw * 559 / 853); top: calc(100cqw * 151 / 853); width: calc(100cqw * 260 / 853); height: calc(100cqw * 76 / 853);
  background: url('assets/ui-ref-home-theme-tray.png') center / 100% 100% no-repeat;
}
body[data-view="home"] .theme-option-pink { left: calc(100cqw * 565 / 853); top: calc(100cqw * 157 / 853); width: calc(100cqw * 88 / 853); height: calc(100cqw * 66 / 853); background-image: url('assets/ui-ref-home-theme-pink.png'); }
body[data-view="home"] .theme-option-gold { left: calc(100cqw * 659 / 853); top: calc(100cqw * 161 / 853); width: calc(100cqw * 70 / 853); height: calc(100cqw * 60 / 853); background-image: url('assets/ui-ref-home-theme-gold.png'); }
body[data-view="home"] .theme-option-neon { left: calc(100cqw * 737 / 853); top: calc(100cqw * 161 / 853); width: calc(100cqw * 71 / 853); height: calc(100cqw * 60 / 853); background-image: url('assets/ui-ref-home-theme-neon.png'); }
body[data-view="home"] .theme-option[aria-pressed="true"] { box-shadow: none; }
body[data-view="home"] .theme-option:not(.theme-option-pink)[aria-pressed="true"] { border-radius: 38%; outline: 2px solid #fff1a9; outline-offset: 1px; }
body[data-view="home"] .theme-option-pink[aria-pressed="false"] { filter: saturate(.5); }
.home-chapter-title {
  position: absolute; left: 15.59203%; top: 53.90456%; width: 73.50528%; height: 9.49024%;
  display: grid; place-items: center; margin: 0; padding: 0 14% 1.4%; transform: none;
  background: url('assets/ui-ref-home-chapter-title-blank.png') center / 100% 100% no-repeat;
  font: 8.6cqw/1.15 var(--serif); font-weight: 400; text-align: center; letter-spacing: 0; color: #8d3e30;
  overflow-wrap: anywhere;
}
:root:lang(zh-Hans) .home-view[data-chapter="cafe"] .home-chapter-title {
  background-image: url('assets/ui-ref-home-chapter-title.png'); color: transparent;
}
.home-chapters { position: absolute; inset: 0; margin: 0; padding: 0; display: block; list-style: none; pointer-events: none; }
.home-chapters::before, .home-chapters li::before, .home-chapters li::after { display: none; }
.home-chapters li {
  position: absolute; top: 62.74403%; height: 5.96529%; display: grid; place-items: center;
  padding: 0 0 .7%; border: 0; border-radius: 0; box-shadow: none; transform: none;
  background-size: 100% 100%; background-repeat: no-repeat; font: 5.4cqw/1 var(--serif); color: transparent;
}
.home-chapters li:nth-child(1) { left: 22.39156%; width: 14.41970%; background-image: url('assets/ui-ref-home-chapter-one.png'); }
.home-chapters li:nth-child(2) { left: 43.49355%; width: 13.48183%; background-image: url('assets/ui-ref-home-chapter-two.png'); }
.home-chapters li:nth-child(3) { left: 63.30598%; width: 14.06799%; background-image: url('assets/ui-ref-home-chapter-three.png'); }
.home-view:not([data-chapter="cafe"]) .home-chapters li:first-child { filter: saturate(.25); }
.home-chapters li[data-current="true"]:not(:first-child) { filter: sepia(.3) saturate(2); outline: 2px solid #c94060; outline-offset: -1.7cqw; border-radius: 50%; }
.hero-copy, .start-actions, .collection-entry { display: contents; }
.hero-copy h1, .hero-description, .hero-ribbon, .hero-facts, .hero-art, #save-caption, #collection-caption {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.hero-art { pointer-events: none; }
body[data-view="home"] #start-button {
  left: 11.60610%; top: 69.36009%; width: 76.90504%; height: 8.78525%;
  background-image: url('assets/ui-ref-home-start-blank.png'); color: #fff3da;
  font: 7.8cqw/1 var(--serif); letter-spacing: 0; padding: 0 14% 0 27%;
}
body[data-view="home"] #start-button::before,
body[data-view="home"] #start-button::after,
body[data-view="home"] #collection-button::before,
body[data-view="home"] #collection-button::after,
body[data-view="home"] #start-button > .icon,
body[data-view="home"] #collection-button > .icon { display: none; }
:root:lang(zh-Hans) body[data-view="home"] .home-view[data-action="start"] #start-button { background-image: url('assets/ui-ref-home-start.png'); color: transparent; }
body[data-view="home"] #collection-button {
  left: 21.10199%; top: 78.47072%; width: 57.56155%; height: 6.56182%;
  background-image: url('assets/ui-ref-home-collection-blank.png'); color: #823b2d;
  font: 4.8cqw/1.1 var(--serif); letter-spacing: 0; padding: 0 10% 0 23%;
}
:root:lang(zh-Hans) body[data-view="home"] #collection-button { background-image: url('assets/ui-ref-home-collection.png'); color: transparent; }
body[data-view="home"] #home-restart { position: absolute; top: 63.5%; right: 5%; width: 11%; min-height: 0; height: 4.8%; padding: 0; font-size: 2.5cqw; color: #894c45; }
body[data-view="home"] #retry-catalog { position: absolute; left: 12%; top: 69%; width: 76%; height: 9%; min-height: 0; background: #fff0def0; color: #92374a; border-radius: 30px; font-size: 4cqw; }
.home-bottom {
  position: absolute; left: 23.56389%; top: 85.41215%; width: 52.05158%; height: 2.38612%;
  padding: 0; margin: 0; display: grid; place-items: center; text-align: center;
  background: url('assets/ui-ref-home-savor-blank.png') center / 100% 100% no-repeat;
  font: 3cqw/1.2 var(--serif); color: #a34840; letter-spacing: 0;
}
.home-bottom::before, .home-bottom::after { display: none; }
:root:lang(zh-Hans) .home-bottom { background-image: url('assets/ui-ref-home-savor.png'); color: transparent; }
.home-nav { position: absolute; inset: 0; display: block; min-height: 0; pointer-events: none; }
.home-nav::after, .home-nav button[aria-current]::after { display: none; }
.home-nav button { pointer-events: auto; color: #994637; font: 3.8cqw/1 var(--serif); }
.home-nav button > [data-i18n] { position: absolute; left: 0; right: 0; top: 67%; }
.home-nav-icon { display: none; }
#home-nav-home { left: 20.51583%; top: 89.42516%; width: 22.97773%; height: 8.13449%; background-image: url('assets/ui-ref-home-nav-home-blank.png'); }
#home-nav-collection { left: 58.49941%; top: 89.58785%; width: 16.06096%; height: 7.15835%; background-image: url('assets/ui-ref-home-nav-collection-blank.png'); }
:root:lang(zh-Hans) #home-nav-home { background-image: url('assets/ui-ref-home-nav-home.png'); color: transparent; }
:root:lang(zh-Hans) #home-nav-collection { background-image: url('assets/ui-ref-home-nav-collection.png'); color: transparent; }
:root:not(:lang(zh)) .home-chapter-title { font-size: 6.5cqw; }
:root:not(:lang(zh)) body[data-view="home"] #start-button { font-size: 6.5cqw; padding-left: 25%; }
:root:not(:lang(zh)) body[data-view="home"] #collection-button { font-size: 3.8cqw; }
:root:not(:lang(zh)) .home-bottom { font-size: 2.6cqw; }
:root:not(:lang(zh)) .home-nav button { font-size: 2.6cqw; }
:root:not(:lang(zh)) .home-nav button > [data-i18n] { top: 64%; }
#home-view:has(#start-button:disabled) #save-caption {
  top: 62.4%; left: 18%; width: 64%; height: auto; padding: 8px 12px; margin: 0; clip: auto; white-space: normal;
  color: #8d3e30; background: #fff1dee8; border-radius: 12px; font-size: 3cqw; z-index: 2;
}
body[data-view="game"] #pause-dialog .site-header {
  position: static; transform: none; width: 100%; max-width: none; min-height: 44px; height: auto;
  padding: 12px 0 0; margin: 10px 0 0; display: flex; flex-wrap: wrap; justify-content: center;
  border: 0; border-top: 1px solid var(--line); gap: 8px; background: none; box-shadow: none;
}
body[data-view="game"] #pause-dialog .brand { min-width: 44px; }
body[data-view="game"] #pause-dialog .brand-name { font-size: 19px; letter-spacing: 1px; }
body[data-view="game"] #pause-dialog .brand-name > span,
body[data-view="game"] #pause-dialog .brand-mark { display: none; }
body[data-view="game"] #pause-dialog .theme-switcher { margin: 0; border: 0; background: none; padding: 0; gap: 0; backdrop-filter: none; }
body[data-view="game"] #pause-dialog .theme-option { width: 44px; min-width: 44px; height: 44px; min-height: 44px; padding: 6px; }
body[data-view="game"] #pause-dialog .theme-option > span { position: absolute; clip: rect(0,0,0,0); width: 1px; height: 1px; overflow: hidden; }
body[data-view="game"] #pause-dialog .header-actions { gap: 4px; }
body[data-view="game"] #pause-dialog .header-actions .text-button { width: 44px; height: 44px; min-height: 44px; }
#pause-dialog .board-toolbar { display: flex; position: static; flex-direction: column; width: 100%; max-width: none; margin: 15px 0 8px; padding: 0; gap: 6px; }
#pause-dialog #restart-button { margin-bottom: 10px; }
@media (prefers-reduced-motion: reduce) { body[data-view="home"] button { transition: none; } }

.home-atmosphere { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.home-sunlight { position: absolute; inset: -12% -20% 20% -10%; background: radial-gradient(ellipse at 75% 18%, #fff6c833, #ffe6ac0a 35%, transparent 62%); mix-blend-mode: screen; opacity: 0; }
.coffee-steam { position: absolute; left: 22%; top: 42%; width: 3%; height: 7%; border-left: 1.1px solid #fffbe0; border-radius: 50%; filter: blur(1.3px); opacity: 0; }
.coffee-steam:nth-child(3) { left: 25%; top: 41%; height: 8%; }
.coffee-steam:nth-child(4) { left: 28%; top: 43%; height: 6%; }
body[data-view="home"] .home-sunlight { animation: cafe-light 9s ease-in-out infinite; }
body[data-view="home"] .coffee-steam { animation: cafe-steam 5.6s ease-out infinite; }
body[data-view="home"] .coffee-steam:nth-child(3) { animation-delay: 1.8s; }
body[data-view="home"] .coffee-steam:nth-child(4) { animation-delay: 3.6s; }
body:not([data-view="home"]) .home-atmosphere { display: none; }
@keyframes cafe-light { 0%, 100% { opacity: .1; } 50% { opacity: .6; } }
@keyframes cafe-steam { 0% { opacity: 0; transform: translate(0, 2cqw) scaleX(.6); } 25% { opacity: .26; } 70% { opacity: .12; } 100% { opacity: 0; transform: translate(-1.6cqw, -4cqw) scaleX(1.5); } }

.tutorial-coach { position: relative; z-index: 8; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 8px; width: 100%; max-width: 880px; min-height: 52px; margin: 12px auto; padding: 7px 9px; border: 1px solid var(--gold); border-radius: 12px; box-shadow: 0 4px 18px #0004; }
.tutorial-message { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; gap: 8px; }
#tutorial-step { display: grid; place-items: center; width: 26px; height: 26px; border: 1px solid var(--gold); border-radius: 50%; font: 11px/1 var(--serif); white-space: nowrap; }
#tutorial-copy { font-size: clamp(9px, 2.9cqw, 12px); line-height: 1.45; text-align: left; overflow-wrap: anywhere; }
#tutorial-dismiss { align-self: stretch; max-width: 70px; min-height: 32px; padding: 4px 3px; font-size: 10px; line-height: 1.3; text-decoration: underline; text-underline-offset: 3px; }
.game-view:has(#tutorial-coach:not([hidden])) .board-instruction { visibility: hidden; }
.game-view[data-layout="stack"] .tutorial-coach { position: relative; left: auto; top: auto; order: 2; margin: 3cqw auto 0; }
.game-view[data-layout="stack"]:has(#tutorial-coach:not([hidden])) .board-instruction { display: none; }
.game-view .tool-rule { position: absolute; top: calc(100% + 2cqw); left: 0; width: 100%; padding: 3px 4px; border-radius: 8px; font: clamp(9px, 2.5cqw, 11px)/1.25 var(--sans); text-align: center; text-shadow: none; pointer-events: none; }
.tool-rules { display: grid; gap: 9px; margin: 16px 0; padding: 13px; border: 1px solid var(--line); border-radius: 12px; text-align: left; }
.tool-rules > p { display: flex; align-items: start; gap: 9px; }
.tool-rules .icon { flex: none; width: 17px; height: 17px; margin-top: 3px; }
#pause-dialog .tool-rules p { font-size: 11px; line-height: 1.65; }
#tutorial-replay { min-height: 44px; margin-bottom: 8px; font-size: 14px; }

.result-modal { width: 560px; max-width: calc(100vw - 24px); max-height: calc(100svh - 24px); padding: 26px; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.result-book { display: grid; grid-template-columns: minmax(0,.85fr) minmax(0,1fr); align-items: center; gap: 23px; perspective: 1000px; }
.result-artwork { position: relative; min-width: 0; padding: 7px 0 10px; }
.result-photo-mat { position: relative; padding: 7px 7px 18px; border: 1px solid var(--gold); border-radius: 4px; transform: rotate(-3deg); transform-origin: left center; box-shadow: 4px 8px 20px #0004; }
.result-photo-mat::before { content: ''; position: absolute; inset: 4px -5px -5px 4px; z-index: -1; border: 1px solid var(--gold); border-radius: 3px; transform: rotate(4deg); }
#result-art { display: block; width: 100%; height: auto; max-height: 270px; aspect-ratio: 4 / 5; object-fit: contain; border-radius: 1px; }
.keepsake-stamp { display: inline-grid; place-items: center; width: 38px; height: 38px; flex: none; border: 3px double currentColor; border-radius: 50%; transform: rotate(-16deg); }
.result-artwork > .keepsake-stamp { position: absolute; right: -9px; bottom: 0; }
.keepsake-stamp .icon { width: 22px; height: 22px; }
.result-story { min-width: 0; text-align: left; }
.result-story .eyebrow { font-size: 8px; letter-spacing: 1.8px; line-height: 1.6; }
.result-story #result-title { margin: 7px 0 6px; font-size: 27px; line-height: 1.2; }
.result-story #result-chapter { font: 17px/1.35 var(--serif); }
.result-story #result-stars { margin: 8px 0; font-size: 29px; line-height: 1.2; letter-spacing: 4px; text-align: left; }
.result-story #result-description, .result-story #result-reward { font-size: 11px; line-height: 1.65; }
.result-story #result-reward { margin-top: 7px; }
.result-letter { position: relative; margin: 19px 0 0; padding: 17px 20px 18px; border: 1px solid var(--gold); border-radius: 7px; text-align: left; }
.letter-caption { display: block; margin-bottom: 7px; font-size: 9px; letter-spacing: 2px; }
.result-letter #result-keepsake { font: 15px/1.8 var(--serif); overflow-wrap: anywhere; }
.result-summary { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); margin: 18px 0 0; padding: 13px 0; border-block: 1px solid var(--line); }
.result-summary > div { min-width: 0; padding: 0 8px; }
.result-summary > div + div { border-left: 1px solid var(--line); }
.result-summary dt { font-size: 10px; line-height: 1.4; overflow-wrap: anywhere; }
.result-summary dd { margin: 6px 0 0; font: 23px/1.2 var(--serif); font-variant-numeric: tabular-nums; }
.result-modal .result-dots { gap: 7px; margin: 14px 0; }
.result-modal .result-dots span { width: 6px; height: 6px; }
.result-next-chapter { display: grid; grid-template-columns: 42px minmax(0,1fr) 19px; align-items: center; gap: 12px; margin: 0 0 16px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; text-align: left; }
#result-next-preview { width: 42px; height: 52px; object-fit: contain; border: 1px solid var(--gold); border-radius: 3px; }
.result-next-chapter span { display: block; margin-bottom: 4px; font-size: 9px; letter-spacing: 1px; }
#result-next-title { display: block; font: 17px/1.3 var(--serif); overflow-wrap: anywhere; }
.result-next-chapter > .icon { width: 18px; height: 18px; }
.result-modal #next-button { min-height: 48px; padding: 9px 18px; font-size: 19px; }
.result-modal #inspect-button { min-height: 44px; margin-top: 5px; font-size: 12px; }
.result-modal[open] .result-photo-mat { animation: album-turn .7s cubic-bezier(.2,.7,.2,1) both; }
.result-modal[open] .result-letter { animation: letter-open .55s .1s ease-out both; }
@keyframes album-turn { from { opacity: 0; transform: rotate(-3deg) rotateY(-28deg) translateX(-8px); } to { opacity: 1; transform: rotate(-3deg) rotateY(0) translateX(0); } }
@keyframes letter-open { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.chapter-journey { margin: -6px 0 26px; }
.chapter-trail-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 12px; }
.chapter-trail-heading h2 { font: 22px/1.3 var(--serif); }
#chapter-progress { font-size: 11px; }
.chapter-trail { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.chapter-trail > li { display: flex; min-width: 0; }
.chapter-stop { position: relative; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 100%; min-width: 0; min-height: 82px; padding: 11px 8px; border: 1px solid var(--line); border-radius: 12px; font: 15px/1.35 var(--serif); text-align: center; overflow-wrap: anywhere; }
.chapter-stop strong, .chapter-stop b { font-size: 22px; line-height: 1.2; font-weight: 400; }
.chapter-stop small { font: 9px/1.4 var(--sans); }
.chapter-stop[data-current="true"] { border-width: 2px; }
.chapter-stop[data-locked="true"] { opacity: .5; }
.collection-letter { position: relative; grid-column: 1 / -1; display: block; margin: 5px 0 0; padding: 16px 15px; border: 1px solid var(--gold); border-radius: 6px; font: 14px/1.8 var(--serif); text-align: left; overflow-wrap: anywhere; }
.collection-letter > .keepsake-stamp { float: right; width: auto; min-width: 56px; height: auto; min-height: 26px; margin: 1px 0 7px 10px; padding: 4px 8px; border-radius: 5px; font: 10px/1.3 var(--serif); transform: rotate(-5deg); }
#art-dialog #art-letter { max-width: 520px; margin: 20px auto 0; padding: 20px 23px; font: 16px/1.85 var(--serif); text-align: left; }

.discovery-flight { position: fixed; z-index: 50; left: 0; top: 0; width: 22px; height: 28px; pointer-events: none; clip-path: polygon(50% 0, 94% 30%, 83% 71%, 50% 100%, 17% 71%, 6% 30%); }
.discovery-flight::before, .discovery-flight::after { content: ''; position: absolute; inset: 0; clip-path: polygon(50% 0, 67% 35%, 50% 100%, 33% 35%); }
.discovery-flight::after { clip-path: polygon(6% 30%, 33% 35%, 50% 100%, 17% 71%); }
@media (max-width: 420px) {
  .result-modal { padding: 19px 17px 15px; border-radius: 17px; }
  .result-book { grid-template-columns: minmax(84px,.7fr) minmax(0,1fr); gap: 17px; }
  .result-story #result-title { font-size: 23px; }
  .result-story #result-chapter { font-size: 15px; }
  .result-story .eyebrow { font-size: 7px; letter-spacing: 1px; }
  .result-story #result-stars { font-size: 25px; }
  .result-letter { padding: 14px 15px; }
  .result-letter #result-keepsake { font-size: 14px; }
  .result-summary > div { padding-inline: 4px; }
  .result-summary dt { font-size: 9px; }
  .result-summary dd { font-size: 21px; }
  .chapter-trail { gap: 7px; }
  .chapter-stop { min-height: 80px; padding: 10px 5px; font-size: 12px; }
  .chapter-stop strong, .chapter-stop b { font-size: 18px; }
  .tutorial-coach { padding: 3px 6px; gap: 5px; }
  .tutorial-message { gap: 6px; }
  #tutorial-step { width: 23px; height: 23px; font-size: 10px; }
  #tutorial-dismiss { max-width: 58px; font-size: 9px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-atmosphere, .discovery-flight, .game-view .success-effect { display: none !important; }
  .result-modal[open] .result-photo-mat, .result-modal[open] .result-letter { animation: none; }
}
.chapter-stop-number { display: grid; place-items: center; width: 31px; height: 31px; border: 1px solid var(--gold); border-radius: 50%; font: 17px/1 var(--serif); }
.chapter-stop .chapter-stop-title { font-size: 15px; line-height: 1.3; }
@media (max-width:420px) { .chapter-stop .chapter-stop-title { font-size: 13px; } }

.challenge-best { grid-column: 1 / -1; padding: 8px 11px; border: 1px solid var(--line); border-radius: 8px; color: var(--wine); background: var(--panel-soft); font: 11px/1.5 var(--sans); text-align: center; overflow-wrap: anywhere; }
:root {
  --coin-light: #fff1bc;
  --coin-dark: #94621d;
  --frame-rose: #c98494;
  --frame-moon: #809bad;
  --frame-gilded: #bf963f;
}
.wallet-entry { position: absolute; z-index: 5; top: 88px; right: max(16px, calc((100vw - 1200px) / 2)); }
body[data-view="game"] .wallet-entry { display: none; }
.wallet-chip { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 16px 6px 7px; border: 1px solid var(--gold); border-radius: 28px; color: var(--ink); background: var(--panel-solid); box-shadow: 0 4px 16px #49361520; }
.wallet-chip:hover { transform: translateY(-2px); box-shadow: 0 6px 20px #49361530; }
.coin-mark { display: inline-grid; place-items: center; flex: none; width: 30px; height: 30px; border: 3px double var(--coin-dark); border-radius: 50%; background: linear-gradient(135deg, var(--coin-light), #e8bb5e); color: #765020; font: bold 17px var(--serif); box-shadow: inset 0 0 0 2px #fff6; }
.wallet-modal { width: min(600px, calc(100vw - 24px)); text-align: left; }
.wallet-modal h2 { margin-top: 10px; padding-right: 28px; }
.wallet-modal h3 { margin: 20px 0 10px; font: 19px/1.4 var(--serif); }
.wallet-total { display: flex; align-items: center; gap: 10px; margin: 14px 0; }
.wallet-total strong { font: 42px/1.2 var(--serif); font-variant-numeric: tabular-nums; }
.wallet-description { color: var(--muted); font-size: 12px; line-height: 1.7; margin: 8px 0; overflow-wrap: anywhere; }
.wallet-frames { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.wallet-frame { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); text-align: center; }
.wallet-frame h3 { font-size: 16px; margin: 12px 0; overflow-wrap: anywhere; }
.wallet-frame button { min-height: 44px; width: 100%; padding: 8px; font-size: 14px; }
.frame-sample { height: 86px; border: 8px double var(--gold); border-radius: 5px; background: linear-gradient(145deg, #fff5d633, #bda57d22), url('assets/cafe-a.png') center 24% / cover; box-shadow: 0 5px 12px #0002; }
.wallet-frame[data-frame="rose"] .frame-sample { border-color: var(--frame-rose); border-radius: 18px 4px; }
.wallet-frame[data-frame="moon"] .frame-sample { border-color: var(--frame-moon); border-style: ridge; border-radius: 18px; }
.wallet-frame[data-frame="gilded"] .frame-sample { border-color: var(--frame-gilded); border-width: 10px; box-shadow: 0 0 0 2px var(--coin-dark), 0 6px 14px #0003; }
body[data-frame="rose"] :is(#art-image, .result-photo-mat, .collection-card > img) { border: 8px double var(--frame-rose); border-radius: 18px 4px; }
body[data-frame="moon"] :is(#art-image, .result-photo-mat, .collection-card > img) { border: 8px ridge var(--frame-moon); border-radius: 18px; }
body[data-frame="gilded"] :is(#art-image, .result-photo-mat, .collection-card > img) { border: 10px double var(--frame-gilded); box-shadow: 0 0 0 2px var(--coin-dark), 0 6px 14px #0003; }
.wallet-ledger-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wallet-ledger { list-style: none; padding: 0; margin: 0; }
.wallet-ledger li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.wallet-ledger b[data-credit="true"] { color: var(--wine); }
.coin-reward { margin: 0 0 12px; padding: 8px 12px; background: var(--panel); border: 1px solid var(--gold); border-radius: 12px; font-size: 12px; color: var(--wine); }
.tool-button[data-paid="true"] .tool-count { width: auto; max-width: 100%; height: auto; min-height: 24px; padding: 3px 7px; border-radius: 12px; font: 11px/1.3 var(--sans); }
#wallet-status { color: var(--wine); font-size: 12px; }
@media (max-width: 600px) {
  .wallet-entry { top: 72px; right: 14px; }
  .wallet-chip { font-size: 12px; }
  .wallet-modal { padding: 22px 16px; }
  .wallet-frames { gap: 10px; }
  .wallet-frame { padding: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .wallet-chip { transition: none; }
}
body[data-view="home"] .wallet-entry {
  top: calc((100svh - var(--home-width) * 1844 / 853) / 2 + var(--home-width) * .28);
  left: calc((100% - var(--home-width)) / 2 + var(--home-width) * .04);
  right: auto;
}

.wallet-modal :is(h2, h3, strong), #purchase-dialog :is(h2, button) { font-family: var(--sans); }
.wallet-modal h2 { font-size: 25px; }
.wallet-modal h3 { font-size: 17px; }

body[data-view="home"] { background: #18080f; }
body[data-view="home"]::before {
  background: linear-gradient(#1b0711be, #1b0711ee), url('assets/night-a.png') center / cover;
  filter: blur(16px);
}
.home-view {
  color: #ffe9cd;
  background: #260a14;
  box-shadow: 0 0 80px #050106bb;
}
.home-scene {
  background: linear-gradient(180deg, #1c0814ad 0%, #25091210 18%, #280c1833 42%, #280a15ee 59%, #210810 100%),
    url('assets/night-a.png') center top / 100% 64% no-repeat, #240913;
}
.home-view::before {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(circle at 83% 6%, #f9c57f23 0 1px, transparent 2px),
    radial-gradient(circle at 12% 12%, #ffe9af66 0 1px, transparent 2px),
    radial-gradient(circle at 91% 72%, #ffe4a444 0 2px, transparent 3px),
    linear-gradient(180deg, transparent 0 61%, #671a3030 77%, transparent 100%);
}
.home-view::after {
  content: ''; position: absolute; right: -7%; top: 59.5%; width: 30%; height: 13%;
  background: url('assets/ui-moon-gold.png') center / contain no-repeat;
  pointer-events: none; opacity: .8;
}
body[data-view="home"] .brand {
  left: 4%; top: 2%; width: 43%; height: 7%; display: grid; place-items: center;
  border: 0; border-radius: 0; background: none; box-shadow: none; color: #ffe4ad;
  filter: drop-shadow(0 2px 6px #1c020f);
}
body[data-view="home"] .brand > .brand-name { font: 4.8cqw/1.1 var(--serif); letter-spacing: .02em; text-align: left; }
body[data-view="home"] .brand-name > span { margin-top: .8cqw; color: #ffd2a0; font: 1.8cqw/1.2 var(--sans); letter-spacing: .15em; }
body[data-view="home"] #sound-button,
body[data-view="home"] #help-button,
body[data-view="home"] .theme-option {
  display: grid; place-items: center; width: 9.2%; height: 4.7%;
  border: 1px solid #e8b77e; border-radius: 50%;
  background: radial-gradient(circle at 35% 25%, #713543, #250c19 72%);
  color: #ffdaa2; box-shadow: inset 0 0 0 2px #edbe7e22, 0 3px 10px #0e030ba8;
}
body[data-view="home"] #sound-button { left: 66%; top: 2%; }
body[data-view="home"] #help-button { left: 77.2%; top: 2%; }
body[data-view="home"] .theme-switcher::before { display: none; }
body[data-view="home"] .theme-option-pink { left: 88.4%; top: 2%; }
body[data-view="home"] .theme-option-gold { left: 76%; top: 7.5%; width: 8%; height: 4%; }
body[data-view="home"] .theme-option-neon { left: 86%; top: 7.5%; width: 8%; height: 4%; }
body[data-view="home"] .theme-option > .icon,
body[data-view="home"] .header-actions .text-button > .icon {
  position: static; width: 5cqw; height: 5cqw; min-width: 0; min-height: 0;
  margin: 0; padding: 0; overflow: visible; clip: auto; border: 0;
  color: #ffdaa2; stroke-width: 1.8;
}
body[data-view="home"] .theme-option[aria-pressed="true"] { outline: 2px solid #ffe5af; outline-offset: 2px; }
body[data-view="home"] .wallet-entry { left: calc((100% - var(--home-width) + env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) / 2 + var(--home-width) * .045); top: calc(var(--home-top) + var(--home-width) * .205); }
body[data-view="home"] .wallet-chip {
  min-height: 44px; height: calc(var(--home-width) * .125); padding: 0 calc(var(--home-width) * .04) 0 6px;
  border: 1px solid #efbd80; border-radius: 50px; color: #ffebcf;
  background: linear-gradient(110deg, #3a101ddd, #5b1a29e8);
  box-shadow: inset 0 0 0 2px #fff0c01a, 0 5px 16px #12020b8c;
  font: clamp(14px, calc(var(--home-width) * .045), 22px)/1 var(--serif);
}
body[data-view="home"] .wallet-chip .coin-mark { width: 32px; height: 32px; font-size: 18px; }
body[data-view="home"] .home-chapter-title,
:root:lang(zh-Hans) .home-view[data-chapter="cafe"] .home-chapter-title {
  left: 8%; top: 47%; width: 84%; height: 15%; padding: 2% 8% 1%;
  border: 1px solid #f3bc7c; border-radius: 22% 22% 17% 17% / 25% 25% 18% 18%;
  background: radial-gradient(ellipse at 50% 8%, #8f3e47a8, transparent 67%), linear-gradient(160deg, #4a1425ea, #250b18f2);
  box-shadow: inset 0 0 0 3px #e4ad6830, 0 0 22px #f5a7632b, 0 15px 30px #16030bcc;
  color: #ffe3af; font: 9cqw/1.1 var(--serif); text-shadow: 0 2px 10px #eaa27773;
}
.home-chapter-title::before { content: '✧  CHAPTER  ✧'; display: block; margin-bottom: 2cqw; color: #f5cfa1; font: 2.8cqw/1.1 var(--serif); letter-spacing: .2em; }
.home-chapters li,
.home-chapters li:nth-child(1), .home-chapters li:nth-child(2), .home-chapters li:nth-child(3) {
  top: 63.5%; width: 12%; height: 6%; padding: 0;
  border: 1px solid #d89c6e; border-radius: 50%;
  background: linear-gradient(135deg, #672939, #2b0c1a); color: #f6d3aa;
  box-shadow: inset 0 0 0 2px #f6c28920, 0 5px 15px #11040c;
  font: 6cqw/1 var(--serif);
}
.home-chapters li:nth-child(1) { left: 23%; }
.home-chapters li:nth-child(2) { left: 44%; }
.home-chapters li:nth-child(3) { left: 65%; }
.home-chapters li[data-current="true"]:not(:first-child),
.home-chapters li[data-current="true"] {
  border: 2px solid #ffe2a2; outline: 2px solid #c6475b; outline-offset: 2px;
  background: radial-gradient(circle at 50% 10%, #b94a5a, #5c172e 76%);
  color: #fff0cc; box-shadow: 0 0 18px #e8736c9a, inset 0 0 0 2px #ffdd9b55;
}
.home-view:not([data-chapter="cafe"]) .home-chapters li:first-child { filter: none; }
body[data-view="home"] #start-button,
:root:lang(zh-Hans) body[data-view="home"] .home-view[data-action="start"] #start-button {
  left: 11%; top: 71.5%; width: 78%; height: 8.8%; padding: 0 10%;
  border: 2px solid #ffe0a4; border-radius: 999px;
  background: radial-gradient(ellipse at 50% -10%, #d9626d, transparent 68%), linear-gradient(160deg, #9f1936, #520b24);
  box-shadow: inset 0 0 0 4px #ffbe8b2b, 0 0 19px #f1937985, 0 8px 24px #17020ba8;
  color: #ffe9be; font: 7cqw/1 var(--serif); text-shadow: 0 2px 8px #eaa4857d;
}
body[data-view="home"] #start-button::after { display: block; inset: 4px; border-radius: 999px; }
body[data-view="home"] #start-button > .icon { display: block; position: absolute; right: 9%; top: 50%; transform: translateY(-50%); width: 7cqw; height: 7cqw; }
body[data-view="home"] #collection-button,
:root:lang(zh-Hans) body[data-view="home"] #collection-button {
  left: 20%; top: 81.5%; width: 60%; height: 6.7%; padding: 0 11%;
  border: 1px solid #e4ae76; border-radius: 999px;
  background: linear-gradient(140deg, #4d1827, #260c18);
  box-shadow: inset 0 0 0 2px #f0bd7d2d, 0 6px 18px #12020ba8;
  color: #ffe2bb; font: 4.5cqw/1 var(--serif);
}
body[data-view="home"] #collection-button > .icon { display: block; position: absolute; left: 10%; top: 50%; transform: translateY(-50%); width: 5cqw; height: 5cqw; }
body[data-view="home"] .home-bottom { top: 88.6%; background: none; color: #d9a77f; font-size: 2.6cqw; }
:root:lang(zh-Hans) .home-bottom { background: none; color: #d9a77f; }
.home-nav { background: linear-gradient(180deg, transparent 87%, #2d0c1a 94%, #190811); }
.home-nav button, #home-nav-home, #home-nav-collection,
:root:lang(zh-Hans) #home-nav-home, :root:lang(zh-Hans) #home-nav-collection {
  top: 90%; height: 9%; width: 36%; border-top: 1px solid #c98b6d;
  background: linear-gradient(180deg, #4b1828bb, #220a17); color: #dbad9b;
  font: 3.7cqw/1 var(--serif);
}
#home-nav-home { left: 10%; border-radius: 55% 12% 0 0; }
#home-nav-collection { left: 54%; border-radius: 12% 55% 0 0; }
.home-nav button[aria-current="page"] { color: #ffe4ac; text-shadow: 0 0 8px #f3ad76; }
.home-nav .home-nav-icon { display: block; position: absolute; left: 50%; top: 16%; width: 8cqw; height: 8cqw; transform: translateX(-50%); stroke-width: 1.8; }
.home-nav button > [data-i18n] { top: 67%; }
body[data-view="game"] { background: radial-gradient(ellipse at 50% 0, #5d2031, #210912 58%, #16060d); }
body[data-view="game"]::before {
  background: radial-gradient(circle at 12% 17%, #f6ad7220, transparent 24%),
    radial-gradient(circle at 88% 62%, #aa36502b, transparent 28%),
    linear-gradient(160deg, #2b0b17, #13050c);
}
body[data-view="game"]::after { border-color: #a6695d88; }
body[data-view="game"] .game-view { max-width: 920px; padding: 18px 22px 32px; }
body[data-view="game"] .game-heading { grid-template-columns: 52px minmax(0,1fr) 52px; max-width: 880px; margin-bottom: 12px; }
body[data-view="game"] .game-heading > .text-button {
  width: 52px; height: 52px; border: 1px solid #f1bd7c;
  background: linear-gradient(145deg, #582031, #260a18);
  color: #ffe0aa; box-shadow: inset 0 0 0 2px #ffda9b25, 0 3px 12px #0b0208;
}
body[data-view="game"] .game-heading > .text-button .icon { width: 24px; height: 24px; }
body[data-view="game"] .level-banner .eyebrow { color: #e9bd9b; font-size: 12px; letter-spacing: .2em; }
body[data-view="game"] .game-heading h1 { color: #ffe5b5; font-size: clamp(30px, 6vw, 46px); letter-spacing: .14em; text-shadow: 0 2px 13px #e99e7770; }
body[data-view="game"] .level-description { color: #e2b9ab; font-size: 13px; }
body[data-view="game"] .game-hud {
  max-width: 880px; padding: 12px 17px; margin-bottom: 16px;
  border: 1px solid #e9b77a; border-radius: 20px;
  background: linear-gradient(140deg, #4c1827ed, #260b18ed);
  box-shadow: inset 0 0 0 2px #f2c18b27, 0 10px 26px #0b020b94;
}
body[data-view="game"] .hud-mistakes, body[data-view="game"] .progress-label,
body[data-view="game"] .hud-clock-note { color: #eac9b0; font-size: 12px; }
body[data-view="game"] .hud-level { color: #ffe4ab; font-size: 21px; }
body[data-view="game"] #challenge-pause {
  border: 1px solid #ecc084; background: #230916; color: #ffe6bb;
  box-shadow: inset 0 0 0 2px #ffe6b31c;
}
body[data-view="game"] #challenge-time { font-size: 24px; }
body[data-view="game"] .progress-block > p { color: #ffe5bc; font-size: 26px; }
body[data-view="game"] .progress-dot { border-color: #f0bc7b; color: #ffddaa; background: #240913; }
body[data-view="game"] .progress-dot.revealed { background: #e7ab6f; color: #2a0b16; box-shadow: 0 0 10px #efb476; }
body[data-view="game"] .image-board { max-width: min(100%, calc(max(180px, 100svh - 280px) * var(--picture-double-ratio, 1.6) + 48px)); gap: 16px; }
body[data-view="game"] .image-card {
  padding: 0 6px 6px; border: 2px solid #e5ac74; border-radius: 20px;
  background: #2a0c18; box-shadow: inset 0 0 0 3px #e2ab6730, 0 10px 28px #0b030bb0;
}
body[data-view="game"] .image-card figcaption { min-height: 38px; color: #f6d2ac; font-size: 12px; }
body[data-view="game"] .image-card figcaption b { color: #ffe0aa; border-color: #dfac76; }
body[data-view="game"] .picture-frame { border-radius: 12px; }
body[data-view="game"] .zoom-button { color: #ffd9a4; }
body[data-view="game"] .board-instruction { color: #f5cead; font-size: 12px; }
body[data-view="game"] .instruction-dot { width: 7px; height: 7px; background: #ffc782; box-shadow: 0 0 8px #ffc782; }
body[data-view="game"] .tool-dock {
  max-width: 880px; margin-top: 12px; border: 1px solid #e9af77; border-radius: 22px;
  background: linear-gradient(150deg, #3c1222ed, #210917f2);
  box-shadow: inset 0 0 0 2px #ffe1ae24, 0 10px 28px #080108a6;
}
body[data-view="game"] .tool-button {
  min-height: 68px; border: 1px solid #dca470; border-radius: 16px;
  color: #ffe4bc; background: linear-gradient(145deg, #592136, #2b0c1b);
  box-shadow: inset 0 1px 0 #ffe3bb36, 0 4px 12px #0d030b;
}
body[data-view="game"] #hint-button {
  border-color: #ffd493; background: radial-gradient(circle at 50% 0, #d7666d, transparent 74%), linear-gradient(150deg, #9d1c3c, #530f2a);
  box-shadow: inset 0 0 0 2px #ffe1a62b, 0 0 16px #d35a5a80;
}
body[data-view="game"] .tool-icon .icon { width: 34px; height: 34px; stroke-width: 1.9; color: #ffd99e; }
body[data-view="game"] #hint-button .game-item,
body[data-view="game"] #reveal-button .game-item,
body[data-view="game"] #skip-button .game-item {
  --item-fill: #f4c985;
  color: #ffe0a8;
  filter: drop-shadow(0 0 5px #efba7280);
}
body[data-view="game"] .tool-copy b { font-size: 21px; }
body[data-view="game"] .tool-count { color: #2f0b16; border-color: #f7d79e; background: #ffdfa3; font-weight: bold; }
body[data-view="game"] .tool-rule { color: #e8b99c; }
body[data-view="game"] .tool-note { color: #dab09f; font-size: 10px; }
body[data-view="game"] .tutorial-coach { color: #ffe8ca; background: #421726; }
body[data-view="collection"] .collection-view,
body[data-view="finish"] .finish-view { color: #ffe7c6; }
body[data-view="collection"] .collection-card,
body[data-view="finish"] .finish-chapter {
  border-color: #e6ad77; background: #381321;
  box-shadow: inset 0 0 0 2px #ffdea324, 0 12px 25px #0801097d;
}
body[data-view="collection"] .chapter-stop,
body[data-view="collection"] .collection-rules { border-color: #b77c61; background: #391523d9; }
body[data-view="collection"] .chapter-stop[data-current="true"] { border-color: #ffd493; box-shadow: 0 0 17px #d6645c66; }
body[data-view="collection"] .collection-heading h1,
body[data-view="finish"] .finish-view h1 { color: #ffe4b4; }
body[data-view="collection"]::before,
body[data-view="finish"]::before {
  background: radial-gradient(ellipse at 50% 0, #6b263558, transparent 50%), linear-gradient(#240b17, #12050c);
}
body[data-view="collection"] .site-header {
  background: #2c0d1bdc; border-bottom-color: #b67c62;
}
body[data-view="collection"] .collection-view {
  background: linear-gradient(155deg, #341222eb, #1e0915f2);
  border: 1px solid #9f6758; border-radius: 22px;
  box-shadow: 0 14px 38px #08020790;
}
body[data-view="collection"] .collection-heading p,
body[data-view="collection"] .collection-rules,
body[data-view="collection"] .collection-detail { color: #e4baa5; }
body .modal { background: linear-gradient(155deg, #4b1b2b, #240b18); border-color: #e3aa75; color: #ffe8c9; }
body .modal h2 { color: #ffe0ac; }
body .modal p:not(.eyebrow, .star-rating) { color: #eac6b4; }
body .zoom-modal { background: #200916; color: #ffe7c7; }
@media (min-width: 761px) {
  body[data-view="game"] .game-view { display: grid; }
  body[data-view="game"] .game-view > .game-heading,
  body[data-view="game"] .game-view > .game-hud { width: 100%; min-width: 0; }
  body[data-view="game"] .game-heading h1 { font-size: clamp(26px, 3vw, 36px); }
}
@media (max-width: 760px) {
  body[data-view="collection"] .theme-switcher,
  body[data-view="collection"] .wallet-entry { display: none; }
  body[data-view="collection"] .site-header { padding: 10px 18px; }
  body[data-view="collection"] .brand { min-width: 0; }
  body[data-view="collection"] .brand-name { font-size: 18px; letter-spacing: .01em; }
  body[data-view="collection"] .brand-name > span { font-size: 7px; letter-spacing: .14em; }
  body[data-view="collection"] .collection-view { margin: 8px; padding: 16px 12px 25px; }
  body[data-view="game"] .game-view { padding: 10px 10px 25px; }
  body[data-view="game"] .game-heading { grid-template-columns: 44px minmax(0,1fr) 44px; gap: 7px; }
  body[data-view="game"] .game-heading > .text-button { width: 44px; height: 44px; }
  body[data-view="game"] .game-heading h1 { font-size: 26px; }
  body[data-view="game"] .level-banner .eyebrow { font-size: 9px; }
  body[data-view="game"] .game-hud { padding: 8px 9px; }
  body[data-view="game"] .hud-level { font-size: 15px; }
  body[data-view="game"] .hud-mistakes { font-size: 10px; }
  body[data-view="game"] #challenge-pause { min-width: 94px; }
  body[data-view="game"] #challenge-time { font-size: 18px; }
  body[data-view="game"] .image-card figcaption { min-height: 34px; font-size: 10px; }
  body[data-view="game"] .tool-button { min-height: 58px; padding: 5px; gap: 5px; }
  body[data-view="game"] .tool-icon .icon { width: 24px; height: 24px; }
  body[data-view="game"] .tool-copy b { font-size: 15px; }
  body[data-view="game"] .board-instruction { font-size: 10px; }
  body[data-view="game"] .image-board {
    gap: 8px;
    padding: 7px; border: 1px solid #e5ac74; border-radius: 20px;
    background: #2a0c18; box-shadow: inset 0 0 0 2px #e2ab6730, 0 10px 28px #0b030bb0;
  }
  body[data-view="game"] .game-view[data-layout="stack"] .image-board {
    max-width: min(100%, 560px);
  }
  body[data-view="game"] .image-card {
    padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none;
  }
  body[data-view="game"] .image-card figcaption { min-height: 30px; }
  body[data-view="game"] .picture-frame { border-radius: 9px; }
  body[data-view="game"] .game-view[data-layout="stack"] .tool-dock { position: relative; bottom: auto; }
}

body[data-view="game"] .tool-button { display: grid; grid-template-columns: auto minmax(0, auto); align-content: center; }
body[data-view="game"] .tool-dock { width: 100%; max-width: 480px; padding: 7px; gap: 10px; border-radius: 16px; }
body[data-view="game"] .tool-button { min-height: 48px; padding: 5px 8px; gap: 3px 7px; border-radius: 11px; }
body[data-view="game"] .tool-icon .icon { width: 24px; height: 24px; }
body[data-view="game"] .tool-copy b { font-size: 15px; }
body[data-view="game"] .tool-rule { position: static; grid-column: 1 / -1; padding: 2px 4px; font-size: 10px; }
.hud-mistakes, .hud-level, .progress-block { min-width: 0; }
.hud-mistakes { flex-wrap: wrap; gap: 3px 6px; }
.hud-discoveries { flex-wrap: wrap; gap: 8px 18px; }
body[data-view="home"] #home-restart { right: 2%; width: 17%; min-height: 44px; font-size: max(12px, 2.5cqw); }
body[data-view="home"] .theme-option { min-width: 32px; min-height: 32px; }
body[data-view="home"] .header-actions .text-button { min-width: 44px; min-height: 44px; }
body[data-view="home"] #sound-button { left: auto; right: 56px; top: 14px; width: 44px; height: 44px; }
body[data-view="home"] #help-button { left: auto; right: 8px; top: 14px; width: 44px; height: 44px; }
body[data-view="home"] .theme-option-pink { left: auto; right: 108px; top: 14px; width: 32px; height: 32px; }
body[data-view="home"] .theme-option-gold { left: auto; right: 56px; top: 70px; width: 32px; height: 32px; }
body[data-view="home"] .theme-option-neon { left: auto; right: 8px; top: 70px; width: 32px; height: 32px; }
body[data-view="collection"] .site-header,
body[data-view="finish"] .site-header { flex-wrap: wrap; }
.modal, .zoom-modal { max-width: calc(100vw - 24px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)); max-height: calc(100svh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); }

@media (max-width: 760px) and (orientation: portrait) {
  body[data-view="game"] .image-board { max-width: 100%; }
}
@media (max-width: 360px) {
  body[data-view="game"] .hud-stats { grid-template-columns: minmax(0, 1fr) auto; }
  body[data-view="game"] .hud-level { grid-column: 1 / -1; grid-row: 1; }
  body[data-view="game"] .tool-copy b { font-size: 13px; }
}
@media (min-width: 600px) and (orientation: landscape) and (max-height: 900px) {
  body[data-view="game"] .game-view[data-layout="compare"] {
    --game-rail-width: clamp(190px, 22vw, 240px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--game-rail-width);
    grid-template-rows: auto auto auto 1fr auto;
    grid-template-areas: "board heading" "board hud" "board tools" "board note" "instruction continue";
    gap: 10px 20px;
    max-width: 1400px;
    min-height: calc(100svh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
    padding: 12px 18px;
    align-items: start;
  }
  body[data-view="game"] .game-view[data-layout="compare"] > .game-heading {
    grid-area: heading; grid-template-columns: 44px minmax(0, 1fr) 44px;
    gap: 4px; margin: 0; align-self: start;
  }
  body[data-view="game"] .game-view[data-layout="compare"] .game-heading > .text-button { width: 44px; height: 44px; }
  body[data-view="game"] .game-view[data-layout="compare"] .level-banner { padding: 0; }
  body[data-view="game"] .game-view[data-layout="compare"] .game-heading h1 { font-size: 20px; letter-spacing: .02em; }
  body[data-view="game"] .game-view[data-layout="compare"] .level-banner .eyebrow { font-size: 9px; letter-spacing: .02em; }
  body[data-view="game"] .game-view[data-layout="compare"] .level-description { display: none; }
  body[data-view="game"] .game-view[data-layout="compare"] > .game-hud { grid-area: hud; margin: 0; padding: 8px; border-radius: 14px; }
  body[data-view="game"] .game-view[data-layout="compare"] .hud-stats { grid-template-columns: minmax(0, 1fr) auto; gap: 5px; }
  body[data-view="game"] .game-view[data-layout="compare"] .hud-level { display: none; }
  body[data-view="game"] .game-view[data-layout="compare"] .hud-mistakes { font-size: 10px; }
  body[data-view="game"] .game-view[data-layout="compare"] #challenge-pause { min-width: 72px; padding: 4px; }
  body[data-view="game"] .game-view[data-layout="compare"] #challenge-time { font-size: 18px; }
  body[data-view="game"] .game-view[data-layout="compare"] .hud-discoveries { gap: 6px; }
  body[data-view="game"] .game-view[data-layout="compare"] .progress-block > p { font-size: 20px; }
  body[data-view="game"] .game-view[data-layout="compare"] .progress-label,
  body[data-view="game"] .game-view[data-layout="compare"] .hud-clock-note { font-size: 10px; }
  body[data-view="game"] .game-view[data-layout="compare"] .progress-dots { gap: 4px; }
  body[data-view="game"] .game-view[data-layout="compare"] .progress-dot { width: 20px; height: 20px; }
  body[data-view="game"] .game-view[data-layout="compare"] > .image-board {
    grid-area: board; align-self: center;
    max-width: min(100%, calc(max(150px, 100svh - 108px) * var(--picture-double-ratio, 1.6) + 44px));
    gap: 12px; padding: 0; border: 0; background: none; box-shadow: none;
  }
  body[data-view="game"] .game-view[data-layout="compare"] .image-card figcaption { white-space: nowrap; }
  body[data-view="game"] .game-view[data-layout="compare"] > .loading-panel { grid-area: board; align-self: center; }
  body[data-view="game"] .game-view[data-layout="compare"] > .board-instruction { grid-area: instruction; margin: 0; font-size: 10px; align-self: center; }
  body[data-view="game"] .game-view[data-layout="compare"] > .tool-dock { grid-area: tools; flex-direction: column; margin: 0; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-button { flex: none; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-rule { grid-column: 2; font-size: 9px; padding: 0; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-icon { grid-row: 1 / 3; }
  body[data-view="game"] .game-view[data-layout="compare"] > .tool-note { grid-area: note; position: static; width: auto; height: auto; clip: auto; margin: 0; font-size: 9px; }
  body[data-view="game"] .game-view[data-layout="compare"] > .continue-wrap { grid-area: continue; }
  body[data-view="game"] .game-view[data-layout="compare"] .continue-wrap .primary-button { margin: 0; padding: 7px 10px; font-size: 14px; }
  body[data-view="game"] .game-view[data-layout="compare"] > .tutorial-coach { grid-area: instruction; margin: 0; min-height: 44px; }
}
@media (min-width: 600px) and (orientation: landscape) and (max-height: 420px) {
  body[data-view="game"] .game-view[data-layout="compare"] > .tool-dock { flex-direction: row; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-button { flex: 1; grid-template-columns: minmax(0, 1fr); padding: 5px 2px; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-icon { grid-row: auto; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-copy b { font-size: 12px; }
  body[data-view="game"] .game-view[data-layout="compare"] .tool-rule { grid-column: 1; }
  body[data-view="game"] .game-view[data-layout="compare"] .hud-clock-note { display: none; }
  body[data-view="game"] .game-view[data-layout="compare"] .progress-dots { display: none; }
  body[data-view="game"] .game-view[data-layout="compare"] > .tool-note { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
}
@media (min-width: 600px) and (max-width: 760px) and (orientation: landscape) {
  body[data-view="game"] .game-view[data-layout="compare"] > .image-board {
    max-width: min(100%, calc(max(150px, 100svh - 108px) * var(--picture-double-ratio, 1.6) + 12px));
  }
}
@media (min-width: 600px) and (orientation: landscape) {
  :root {
    --home-width: min(1100px, calc(100cqw - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)));
    --home-height: clamp(360px, var(--home-available-height), 760px);
  }
  .home-scene {
    background: linear-gradient(90deg, #24091300 28%, #240913 51%), url('assets/night-a.png') left top / auto 100% no-repeat, #240913;
  }
  .home-view::after { right: 2%; top: 37%; width: 12%; height: 18%; }
  body[data-view="home"] .brand { left: 4%; top: 4%; width: 35%; height: 10%; }
  body[data-view="home"] .brand > .brand-name { font-size: clamp(20px, 2.6cqw, 29px); }
  body[data-view="home"] #sound-button { left: auto; right: 94px; top: 22px; width: 48px; height: 48px; }
  body[data-view="home"] #help-button { left: auto; right: 32px; top: 22px; width: 48px; height: 48px; }
  body[data-view="home"] .header-actions .text-button > .icon { width: 24px; height: 24px; }
  body[data-view="home"] .theme-option { top: 76px; width: 36px; height: 36px; min-height: 36px; left: auto; }
  body[data-view="home"] .theme-option-pink { right: 124px; }
  body[data-view="home"] .theme-option-gold { right: 78px; }
  body[data-view="home"] .theme-option-neon { right: 32px; }
  body[data-view="home"] .theme-option > .icon { width: 20px; height: 20px; }
  body[data-view="home"] .wallet-entry { top: calc(var(--home-top) + 90px); }
  body[data-view="home"] .wallet-chip { height: 44px; padding: 0 16px 0 6px; font-size: 16px; }
  body[data-view="home"] .home-chapter-title,
  :root:lang(zh-Hans) .home-view[data-chapter="cafe"] .home-chapter-title {
    left: 48%; top: max(116px, 28%); width: 46%; height: 22%; padding: 8px 18px;
    font-size: clamp(28px, 4cqw, 44px);
  }
  .home-chapter-title::before { margin-bottom: 10px; font-size: 12px; }
  .home-chapters li,
  .home-chapters li:nth-child(1), .home-chapters li:nth-child(2), .home-chapters li:nth-child(3) {
    top: 53%; width: 44px; height: 44px; font-size: 22px;
  }
  .home-chapters li:nth-child(1) { left: 55%; }
  .home-chapters li:nth-child(2) { left: 68%; }
  .home-chapters li:nth-child(3) { left: 81%; }
  body[data-view="home"] #start-button,
  :root:lang(zh-Hans) body[data-view="home"] .home-view[data-action="start"] #start-button,
  :root:not(:lang(zh)) body[data-view="home"] #start-button {
    left: 49%; top: 65%; width: 44%; height: 12%; padding: 0 45px; font-size: clamp(23px, 3cqw, 32px);
  }
  body[data-view="home"] #start-button > .icon { width: 26px; height: 26px; }
  body[data-view="home"] #collection-button,
  :root:lang(zh-Hans) body[data-view="home"] #collection-button,
  :root:not(:lang(zh)) body[data-view="home"] #collection-button {
    left: 54%; top: 80%; width: 34%; height: 10%; min-height: 44px; padding: 0 38px; font-size: 18px;
  }
  body[data-view="home"] #collection-button > .icon { width: 22px; height: 22px; left: 8%; }
  body[data-view="home"] #home-restart { left: 4%; right: auto; top: 75%; width: 30%; height: 44px; color: #ffe3af; font-size: 14px; background: #260a14cc; border-radius: 22px; }
  body[data-view="home"] #retry-catalog { left: 48%; top: 62%; width: 46%; height: auto; min-height: 52px; font-size: 16px; }
  #home-view:has(#start-button:disabled) #save-caption { left: 48%; top: 51%; width: 46%; font-size: 13px; }
  body[data-view="home"] .home-bottom { left: 48%; top: 93%; width: 46%; height: auto; font-size: 12px; }
  .home-nav { background: none; }
  .home-nav button, #home-nav-home, #home-nav-collection,
  :root:lang(zh-Hans) #home-nav-home, :root:lang(zh-Hans) #home-nav-collection {
    top: auto; bottom: 0; width: 20%; height: 70px; font-size: 14px;
  }
  #home-nav-home { left: 2%; }
  #home-nav-collection { left: 24%; }
  .home-nav .home-nav-icon { width: 28px; height: 28px; }
  .home-nav button > [data-i18n], :root:not(:lang(zh)) .home-nav button > [data-i18n] { top: 64%; }
}
}
