/* Approved five-size play layout. Physics and canvas coordinates are unchanged. */
body.play-shell{font-family:system-ui,-apple-system,"PingFang TC","Noto Sans TC",sans-serif;--header-h:56px;--hud-h:56px;--tool-h:48px;--play-gap:8px}
body.play-shell.has-play{height:100svh;height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden}
body.play-shell>header{height:calc(var(--header-h) + env(safe-area-inset-top));min-height:calc(var(--header-h) + env(safe-area-inset-top));flex:0 0 auto;padding:env(safe-area-inset-top) max(28px,env(safe-area-inset-right)) 0 max(28px,env(safe-area-inset-left));border:0;box-shadow:inset 0 -1px var(--line);gap:12px;background:#0b242ce8;flex-wrap:nowrap}
body.play-shell.has-play>header{height:calc(var(--header-h) + env(safe-area-inset-top));min-height:calc(var(--header-h) + env(safe-area-inset-top))}
body.play-shell .brand{font-size:20px;letter-spacing:0;gap:7px;white-space:nowrap}
body.play-shell .brand-mark.fruit-icon{width:28px;height:28px}
body.play-shell .brand small{display:none}
body.play-shell .skip-link{position:absolute;left:12px;top:-80px;padding:12px;background:var(--lime);color:#173d34;z-index:100}
body.play-shell .skip-link:focus{top:8px}
body.play-shell .header-actions{display:flex;gap:8px;margin:0}
body.play-shell .header-actions>.quiet{font-size:14px;line-height:1.3;min-width:44px;min-height:44px;padding:8px 12px;border-radius:9px;white-space:nowrap}
body.play-shell #modeMenuBtn{margin-left:auto;font-size:14px;line-height:1.3;min-height:44px;padding:8px 12px;border-radius:9px}
body.play-shell .mode-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
body.play-shell .mode-choices a{min-height:88px;padding:14px;border:1px solid var(--line);border-radius:10px;text-decoration:none;color:var(--ink);line-height:1.6}
body.play-shell .mode-choices a strong{display:block;color:var(--lime);font-size:16px}
body.play-shell .mode-choices a small{display:block;font-size:14px;color:#c0d1c9}
body.play-shell .mode-choices-home{display:none}
body.play-shell.has-play>main{flex:1;min-height:0;min-width:0;width:100%;max-width:none;margin:0;padding:16px 24px max(24px,env(safe-area-inset-bottom));display:grid;grid-template-columns:minmax(0,400px) 280px;justify-content:center;align-items:stretch;gap:40px}
body.play-shell.has-play>main#featureRoot{display:block}
body.play-shell .feature-play{height:100%;min-height:0;display:grid;grid-template-columns:minmax(0,400px) 280px;justify-content:center;align-items:stretch;gap:40px}
body.play-shell.has-play>footer,body.play-shell>.feature-nav,body.play-shell main>.intro,body.play-shell .feature-play>.mode-intro{display:none}
body.play-shell .play-column,body.play-shell .mode-center{width:100%;max-width:none;height:100%;min-height:0;min-width:0;margin:0;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:var(--hud-h) 44px minmax(0,1fr) var(--tool-h);gap:var(--play-gap);order:0}
body.play-shell .game-top{display:flex;align-items:center;justify-content:space-between;flex-wrap:nowrap;gap:12px;min-height:0;padding:0 3px}
body.play-shell .game-top .eyebrow,body.play-shell .hud-label{display:block;font-size:14px;line-height:1.4;letter-spacing:0;color:#c0d1c9}
body.play-shell .game-top strong,body.play-shell .hud-primary strong{font-size:32px;font-weight:720;line-height:1.15;font-variant-numeric:tabular-nums}
body.play-shell .game-top .next{margin:0;gap:8px;font-size:14px}
body.play-shell .next .fruit-icon{width:44px;height:44px}
body.play-shell .mode-title{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
body.play-shell .hud-primary{min-width:0}
body.play-shell .hud-primary .hud-main-line{display:flex;align-items:baseline;gap:10px}
body.play-shell .hud-detail{font-size:14px;color:#c0d1c9;white-space:nowrap}
body.play-shell .hud-primary .hud-secondary{font-size:14px!important;font-weight:500;line-height:1.4;color:#c0d1c9;white-space:nowrap}
body.play-shell [data-mode=puzzle] .hud-primary .hud-secondary{display:none}
body.play-shell .game-top .mode-timer{display:inline;font-size:32px;line-height:1.15}
body.play-shell .hud-puzzle strong{font-size:22px}
body.play-shell .action-status{min-width:0;height:44px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:0 9px;border:1px solid #b1c9b133;border-radius:8px;background:#173b3de8;overflow:hidden}
body.play-shell .action-status p{margin:0;font-size:14px!important;line-height:1.45;color:#d6e2d1;min-width:0;overflow-wrap:normal}
body.play-shell .action-status:has(button:not([hidden])){border-color:#d6ef9a88}
body.play-shell .action-status button{height:44px;min-height:44px;min-width:44px;flex-shrink:0;padding:8px;border:0;border-radius:6px;background:#d6ef9a1a;font-size:14px;color:var(--lime)}
body.play-shell .board-stage{min-width:0;min-height:0;height:100%;display:flex;align-items:center;justify-content:center}
body.play-shell .board-stage #app,body.play-shell .board-stage .mode-board{flex:0 0 auto;max-width:100%;max-height:100%;margin:0;aspect-ratio:2/3;border:0;box-shadow:inset 0 0 0 1px #a5d3bb70,0 14px 32px #0003;border-radius:17px;background:#102f35e8}
body.play-shell .board-stage canvas{width:100%;height:100%}
body.play-shell .board-caption{display:none}
body.play-shell .danger-label{position:absolute;top:calc(24.54% - 22px);left:4.44%;padding:1px 4px;font-size:12px;line-height:1.4;color:#bfd1b9;background:#15383c;pointer-events:none}
body.play-shell .tool-row,body.play-shell .mode-tools{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:0;min-height:var(--tool-h);height:var(--tool-h)}
body.play-shell .tool-row>button,body.play-shell .mode-tools>button{display:flex;align-items:center;justify-content:center;gap:8px;position:relative;min-width:0;min-height:44px;height:100%;border:1px solid #a5c8b947;border-radius:9px;background:#15373ce8;padding:7px 6px;font-size:14px;line-height:1.35}
body.play-shell .tool-row button b,body.play-shell .tool-row button small{display:none}
body.play-shell .tool-row i{position:static;display:inline-grid;place-items:center;width:auto;min-width:20px;height:22px;background:none;border-radius:0;border-left:1px solid #a5c8b947;padding-left:7px;color:var(--lime);font:600 14px system-ui}
body.play-shell .tool-row [data-active=true],body.play-shell .mode-tools [aria-pressed=true]{border-color:var(--lime);background:#36594a}
body.play-shell .tablet-summary,body.play-shell .landscape-details,body.play-shell .play-meta,body.play-shell .mode-shortcuts{display:none}
body.play-shell main>.collection,body.play-shell .feature-play>.mode-aside{display:block;width:100%;max-width:none;min-height:0;max-height:100%;overflow:auto;padding:20px;border:1px solid #a5c8b92b;border-radius:14px;background:#0e2c34de;order:0;grid-column:2;grid-row:1;align-self:start}
body.play-shell .mode-summary{padding-bottom:20px;margin-bottom:20px;border-bottom:1px solid var(--line)}
body.play-shell .mode-summary h2{font-size:18px;margin:0 0 10px}
body.play-shell .mode-summary p{font-size:14px;line-height:1.75;margin:0 0 12px}
body.play-shell .summary-sequence{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;margin:0 0 16px}
body.play-shell .summary-sequence .fruit-icon{width:40px;height:40px}
body.play-shell .mode-summary .quiet{width:100%;min-height:44px;border-radius:9px}
body.play-shell .mode-aside h2{font-size:18px}
body.play-shell .mode-aside .rank-table caption{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
body.play-shell .aside-destinations{display:flex;gap:8px;margin-top:16px}
body.play-shell .aside-destinations a{flex:1;min-height:44px;border-radius:9px;padding:10px 4px;font-size:14px;text-align:center;color:var(--ink)}
body.play-shell dialog .mode-summary,body.play-shell dialog .aside-destinations{display:none}
body.play-shell .danger-label.urgent{color:#ffc0b6}
body.play-shell .collection ol{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px 8px;margin:18px 0}
body.play-shell .collection .fruit-icon{width:52px;height:52px}
body.play-shell .collection .record-symbol,body.play-shell .collection li small,body.play-shell .collection>.eyebrow,body.play-shell .collection .tip{display:none}
body.play-shell .collection>p{display:block}
body.play-shell .collection h2{font-size:18px;line-height:1.5}
body.play-shell .collection .record strong{font-size:28px}
body.play-shell .mode-aside .rank-scroll{max-height:45svh}
body.play-shell .overlay,body.play-shell .mode-cover{padding:18px}
body.play-shell .panel .start-art,body.play-shell .mode-cover .start-art{width:84px;height:84px;margin:0 auto 12px}
body.play-shell .panel h2,body.play-shell .mode-cover .panel h2{font-size:24px;line-height:1.35;margin:0 0 12px}
body.play-shell .panel p,body.play-shell .mode-cover .panel p{font-size:14px;line-height:1.65;margin:0 0 14px}
body.play-shell .panel .primary,body.play-shell .mode-cover .panel .primary{min-width:0;width:100%;max-width:260px;min-height:44px;margin:0;border-radius:9px;padding:11px 14px}
body.play-shell .mode-cover .mode-launch-actions{margin:14px auto 0;max-width:260px;gap:8px}
body.play-shell .panel small{margin-top:12px;font-size:12px}
body.play-shell .extra-menu{display:flex;align-items:stretch;flex-direction:column;gap:10px}
body.play-shell .extra-menu .quiet,body.play-shell .extra-menu .compact-only{display:block;width:100%;min-height:44px;border-radius:9px;font-size:14px;text-align:center;text-decoration:none;color:var(--ink)}
body.play-shell dialog{max-width:none;max-height:calc(100svh - 24px);width:min(560px,calc(100vw - 24px));border-radius:14px;overscroll-behavior:contain}
body.play-shell dialog .close{min-width:44px;min-height:44px}
body.play-shell dialog .panel-header{padding:10px 16px}
body.play-shell dialog .panel-content{padding:20px}
body.play-shell dialog .mode-intro,body.play-shell dialog .mode-aside,body.play-shell dialog .collection{display:block;width:100%;max-height:none;overflow:visible;padding:0;border:0;border-radius:0;background:none}
body.play-shell dialog .mode-shortcuts{display:grid;gap:8px;margin-top:12px}
body.play-shell dialog .mode-shortcuts>button{width:100%;min-height:44px;border-radius:9px}
body.play-shell dialog .mode-shortcuts>.info-shortcut{display:none}
body.play-shell dialog .mode-pause{display:none}
body.play-shell .result-actions{display:grid;grid-template-columns:1fr;gap:8px;margin:18px 0}
body.play-shell .result-actions>button,body.play-shell .result-actions>a{width:100%;min-height:44px;border-radius:9px}
body.play-shell .registration-form,body.play-shell #registrationFields{padding:16px 0;border-top:1px solid var(--line)}
body.play-shell .result-dialog{padding:0 20px 20px}
body.play-shell .result-dialog>.result-close-row{position:sticky;top:0;display:flex;justify-content:flex-end;z-index:3;margin:0 -20px;padding:6px 12px;background:#15343b}
body.play-shell .result-close-row>.close{float:none;position:static;background:#ffffff08;border-radius:50%}
body.play-shell #helpDialog,body.play-shell #leaderboardDialog{padding:0 20px 20px}
body.play-shell .dialog-close-row{position:sticky;top:0;display:flex;justify-content:flex-end;z-index:3;margin:0 -20px;padding:6px 12px;background:#15343b}
body.play-shell .dialog-close-row>.close{float:none;position:static;min-width:44px;min-height:44px;background:#ffffff08;border-radius:50%}
body.play-shell .result-heading{padding:0}
body.play-shell .registration-toggle{font-size:14px}
body.play-shell button:focus-visible,body.play-shell a:focus-visible,body.play-shell canvas:focus-visible{outline-offset:2px}
@media(min-width:721px) and (max-width:1099px) and (min-height:800px){
  body.play-shell{--header-h:64px;--hud-h:64px;--tool-h:56px}
  body.play-shell.has-play>main{display:block;padding:8px max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left))}
  body.play-shell .feature-play{display:block}
  body.play-shell .play-column,body.play-shell .mode-center{max-width:none;width:100%;height:100%}
  body.play-shell main>.collection,body.play-shell .feature-play>.mode-aside{display:none}
  body.play-shell .game-top strong,body.play-shell .game-top .mode-timer{font-size:38px}
  body.play-shell .game-top .next{min-width:170px;justify-content:center;border-left:1px solid var(--line);padding-left:20px}
  body.play-shell .hud-puzzle strong{font-size:26px}
  body.play-shell .tool-row,body.play-shell .mode-tools{gap:8px}
  body.play-shell .tool-row>button,body.play-shell .mode-tools>button{font-size:16px}
}
@media(max-width:720px){
  body.play-shell{--header-h:48px}
  body.play-shell>header{padding-right:max(12px,env(safe-area-inset-right));padding-left:max(12px,env(safe-area-inset-left));gap:7px}
  body.play-shell .brand{font-size:16px;gap:6px}
  body.play-shell .brand-mark.fruit-icon{width:18px;height:18px}
  body.play-shell .header-actions{gap:5px}
  body.play-shell .header-actions>.quiet{font-size:14px;min-width:44px;padding:8px 6px}
  body.play-shell #modeMenuBtn{padding:8px 9px}
  body.play-shell.has-play>main{display:block;padding:8px max(13px,env(safe-area-inset-right)) max(20px,env(safe-area-inset-bottom)) max(13px,env(safe-area-inset-left))}
  body.play-shell .feature-play{display:block}
  body.play-shell .play-column,body.play-shell .mode-center{max-width:430px;margin:auto}
  body.play-shell main>.collection,body.play-shell .feature-play>.mode-aside{display:none}
  body.play-shell .game-top{gap:8px}
  body.play-shell .game-top strong,body.play-shell .game-top .mode-timer{font-size:29px}
  body.play-shell .hud-puzzle strong{font-size:20px}
  body.play-shell .next{min-width:95px}
  body.play-shell .overlay,body.play-shell .mode-cover{padding:16px}
  body.play-shell .panel .start-art,body.play-shell .mode-cover .start-art{width:76px;height:76px}
  body.play-shell .panel h2,body.play-shell .mode-cover .panel h2{font-size:22px}
  body.play-shell .tool-row>button,body.play-shell .mode-tools>button{gap:5px;padding:7px 4px}
  body.play-shell .mode-choices{grid-template-columns:1fr}
  body.play-shell .mode-choices a{min-height:72px;padding:11px 12px}
}
@media(max-width:720px) and (max-height:720px){
  body.play-shell{--header-h:44px;--hud-h:48px;--play-gap:6px}
  body.play-shell .brand-mark{display:none}
  body.play-shell.has-play>main{padding-top:4px;padding-bottom:max(12px,env(safe-area-inset-bottom))}
  body.play-shell .game-top strong,body.play-shell .game-top .mode-timer{font-size:26px}
  body.play-shell .hud-puzzle strong{font-size:19px}
  body.play-shell .next .fruit-icon{width:40px;height:40px}
  body.play-shell .panel .start-art,body.play-shell .mode-cover .start-art{width:60px;height:60px;margin-bottom:10px}
  body.play-shell .panel h2,body.play-shell .mode-cover .panel h2{font-size:21px;margin-bottom:10px}
  body.play-shell .panel .eyebrow,body.play-shell .panel>small{display:none}
  body.play-shell .panel p,body.play-shell .mode-cover .panel p{font-size:14px;line-height:1.5;margin-bottom:10px}
}
@media(min-width:721px) and (max-height:500px){
  body.play-shell{--header-h:44px;--hud-h:64px}
  body.play-shell>header{padding-right:max(18px,env(safe-area-inset-right));padding-left:max(18px,env(safe-area-inset-left))}
  body.play-shell .brand{font-size:17px}
  body.play-shell.has-play>main{display:block;padding:8px max(18px,env(safe-area-inset-right)) max(8px,env(safe-area-inset-bottom)) max(18px,env(safe-area-inset-left))}
  body.play-shell .feature-play{display:block}
  body.play-shell .play-column,body.play-shell .mode-center{width:min(100%,760px);max-width:none;margin:auto;grid-template-columns:220px minmax(0,1fr);grid-template-rows:64px 44px minmax(0,1fr) 48px;column-gap:28px;row-gap:8px}
  body.play-shell .board-stage{grid-column:1;grid-row:1/5}
  body.play-shell .game-top{grid-column:2;grid-row:1}
  body.play-shell .action-status{grid-column:2;grid-row:2}
  body.play-shell .tool-row,body.play-shell .mode-tools{grid-column:2;grid-row:4}
  body.play-shell .landscape-details{display:flex;grid-column:2;grid-row:3;flex-direction:column;justify-content:center;align-items:flex-start;gap:8px;font-size:14px;color:#c0d1c9}
  body.play-shell .landscape-details p{margin:0;font-size:14px;line-height:1.5}
  body.play-shell main>.collection,body.play-shell .feature-play>.mode-aside{display:none}
  body.play-shell .overlay,body.play-shell .mode-cover{padding:10px}
  body.play-shell .panel .start-art,body.play-shell .mode-cover .start-art{width:48px;height:48px;margin-bottom:7px}
  body.play-shell .panel h2,body.play-shell .mode-cover .panel h2{font-size:18px;margin-bottom:9px}
  body.play-shell .panel p,body.play-shell .mode-cover .panel p{font-size:14px;line-height:1.45;margin-bottom:8px}
  body.play-shell .panel .eyebrow,body.play-shell .panel>small{display:none}
}
