*{box-sizing:border-box} :root{--ink:#171e2c;--cream:#fff8df;--board-width:600px;--motion:100ms;--board-art:url('assets/ui/board.png');--tile-art:url('assets/ui/tile.png');--active-art:url('assets/ui/tile-active-clean-v2.png');--panel-art:url('assets/ui/panel.png');--button-art:url('assets/ui/button-clean-v3.png')}[hidden]{display:none!important}html{min-height:100%;background:#bad8ad}body{margin:0;min-height:100dvh;color:var(--ink);font-family:'Comic Sans MS','Arial Rounded MT Bold','Trebuchet MS',system-ui,sans-serif;line-height:1.4}#backdrop{position:fixed;inset:0;z-index:-1;background:url('assets/backgrounds/sunny-courtyard-v1.png') center/cover no-repeat}button,select,input,a{touch-action:manipulation}button,select{font:inherit;color:inherit}button{cursor:pointer;min-height:46px;font-weight:800;border:0;background:none;padding:10px 20px;transition:transform .12s}button:hover{filter:brightness(1.04)}button:active{transform:translateY(2px)}button:focus-visible,select:focus-visible,a:focus-visible,input:focus-visible{outline:4px solid #4a92db;outline-offset:3px}button:disabled{opacity:.6;cursor:default}header{padding:14px 26px;display:flex;align-items:center;justify-content:space-between;max-width:1460px;margin:auto;gap:15px}.brand{font-size:clamp(24px,3.4vw,48px);font-weight:1000;letter-spacing:-1.5px;text-shadow:0 2px #fff8,1px 0 #172131;line-height:1.1;text-align:left;padding:6px 0}.icon{width:52px;height:52px;min-width:52px;padding:4px;font-size:29px;line-height:1}.cream,.pill{background:#fff5d9;border:3px solid var(--ink);border-radius:19px 22px 18px 23px;box-shadow:inset 0 -5px 0 #ead7ab,inset 0 3px 0 #fffdf1}.green{background-image:var(--button-art);background-size:100% 145%;background-position:center;background-repeat:no-repeat;min-height:59px;color:#fffdf0;font-size:20px;text-shadow:0 2px #24522b}.panel{position:relative;background:var(--panel-art) center/100% 100% no-repeat;padding:38px 34px;isolation:isolate}.panel:before{content:'';position:absolute;inset:6%;background:#fffae8;border-radius:24px;z-index:-1}main{max-width:1380px;margin:auto;padding:8px 24px 32px}.home-panel{max-width:480px;text-align:center;margin:5vh auto;display:flex;flex-direction:column;gap:13px;padding:48px 44px}.home-panel h1{font-size:42px;line-height:1.1;margin:0}.home-panel p{margin:4px 0 12px;font-size:18px}.home-panel #home-progress{font-size:14px}.home-panel>.cream{font-size:16px}.collection-top{display:flex;align-items:center;flex-wrap:wrap;gap:16px;padding:26px 38px;margin:0 auto 20px;max-width:1100px}.collection-top h1{margin:0;font-size:30px}.collection-top #total{margin-left:auto;font-weight:800}.tabs{display:flex;gap:8px;flex:1 1 100%}.tabs button{flex:1}.tabs button[aria-pressed=true]{background:#edc45e}.cards{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:18px}.card{padding:8px 8px 14px;background:#fff8e5;border:3px solid #25212b;border-radius:21px;box-shadow:0 4px #77533080;text-align:left;overflow:hidden}.card .thumb{aspect-ratio:1;position:relative;overflow:hidden;border-radius:13px;background:#c4d7ad}.card img{width:100%;height:100%;object-fit:cover;display:block}.card .locked img{filter:blur(12px);transform:scale(1.08)}.card strong{display:block;margin:10px 3px 4px;font-size:14px}.card small{display:block;margin:4px 3px 0;font-size:11px;line-height:1.35}.card .check{position:absolute;right:7px;bottom:6px;background:#3f963f;color:white;border:2px solid var(--ink);border-radius:50%;width:28px;height:28px;text-align:center}.card .record{font-weight:800}.game-layout{display:grid;grid-template-columns:minmax(0,1fr) 330px;gap:32px;align-items:start;max-width:1100px;margin:0 auto}.play-area{width:100%;max-width:var(--board-width);margin:auto}.board-top{display:flex;justify-content:center;gap:12px;align-items:center}.pill{display:inline-block;padding:7px 18px;font-size:18px;font-weight:800;text-align:center;line-height:1.3}.board-top .pill{min-width:100px}.puzzle-title{text-align:center;font-size:17px;line-height:1.2;margin:10px auto 6px;color:var(--ink);background:#fff8e5ee;border-radius:20px;width:fit-content;padding:5px 18px;max-width:100%}#board{position:relative;width:100%;aspect-ratio:1;background:var(--board-art) center/110% 110% no-repeat;isolation:isolate;border-radius:9%;container-type:inline-size;overflow:hidden}.tile{position:absolute;background:var(--tile-art) center/107% 107% no-repeat;font-size:12cqw;line-height:1;font-weight:1000;padding:0;display:grid;place-items:center;transition:left var(--motion) ease,top var(--motion) ease;min-height:0;border-radius:16%;font-variant-numeric:tabular-nums;letter-spacing:-1px;text-shadow:1px 1px #171e2c}.tile.movable{background-image:var(--active-art)}.tile[aria-disabled=true]{cursor:default}.tile:hover{filter:none}.tile:active{transform:none}.tile:focus-visible{outline-offset:-6px}.below-board{display:flex;align-items:center;justify-content:center;gap:10px;margin:8px 0}.below-board .pill{font-size:15px;flex:1}.feedback{display:block;font-size:12px;padding:6px 12px;margin:10px auto 0;width:fit-content;border-width:2px;max-width:100%}.menu-panel{display:flex;flex-direction:column;gap:11px;padding:32px}.menu-heading{display:flex;justify-content:space-between;align-items:center;gap:10px}.menu-heading h2{margin:0;font-size:34px}.menu-close{width:38px;height:38px;min-width:38px;min-height:38px;font-size:28px}.setting{display:flex;gap:12px;align-items:center;justify-content:space-between;font-weight:800;font-size:16px;margin-top:4px}.setting select{width:62%}select{width:100%;padding:8px 9px;border:2px solid #3b3029;border-radius:11px;background:#fff9e9;min-height:44px;font-size:14px}.menu-panel>button{font-size:16px}.menu-panel .green{font-size:20px}.toggle-row input{appearance:none;width:54px;height:30px;border:2px solid var(--ink);border-radius:30px;background:#aba593;position:relative;cursor:pointer;margin:0;flex-shrink:0}.toggle-row input:after{content:'';position:absolute;top:2px;left:3px;width:22px;height:22px;background:#fff9e8;border-radius:50%}.toggle-row input:checked{background:#4eba50}.toggle-row input:checked:after{left:25px}#desktop-menu .menu-close,#desktop-menu .menu-continue{display:none}dialog{padding:0;border:0;background:transparent;color:var(--ink);max-width:min(94vw,600px);max-height:94dvh;width:560px;overflow:auto}dialog::backdrop{background:#17213166;backdrop-filter:blur(2px)}.dialog-inner{padding:32px}.dialog-inner:has(.menu-panel){padding:0;background:none}.dialog-inner:has(.menu-panel):before{display:none}#dialog-content h2{font-size:29px;line-height:1.2;margin:5px 0 18px}#dialog-content p{font-size:16px}#dialog-content .actions{display:flex;flex-wrap:wrap;gap:9px;margin-top:20px}#dialog-content .actions button{flex:1 1 180px}.reward-image{width:100%;aspect-ratio:1;object-fit:contain;display:block;border-radius:15px}.record-message{font-weight:900;color:#316f32}.notice{position:relative;z-index:5;margin:5px auto;max-width:760px;padding:12px 18px;background:#fff1c9;border:2px solid #8d6f36;border-radius:12px;font:14px/1.4 system-ui}.target-grid{display:grid;gap:4px;max-width:320px;margin:15px auto}.target-grid span{text-align:center;background:#ecdfb9;border-radius:5px;padding:5px;font-weight:800}.about-links a{display:block;color:#245781;margin:8px 0}.share-preview{width:100%;max-height:45dvh;object-fit:contain}.confetti{position:fixed;inset:0;pointer-events:none;z-index:20;overflow:hidden}.confetti i{position:absolute;top:-20px;left:var(--x);width:12px;height:17px;background:var(--c);border-radius:3px;animation:fall 1.8s ease-in var(--delay) both}@keyframes fall{to{transform:translateY(100vh) rotate(650deg);opacity:0}}.visually-hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
@media(min-width:1000px) and (max-height:850px){:root{--board-width:520px}.game-layout{max-width:980px;gap:24px}header{padding:10px 24px}.brand{font-size:36px}.menu-panel{gap:7px;padding:28px}.menu-heading h2{font-size:30px}.puzzle-title{margin:5px auto}.board-top .icon{width:44px;height:44px;min-width:44px;min-height:44px}.feedback{margin:4px auto}}
@media(max-width:1000px){.cards{grid-template-columns:repeat(3,minmax(0,1fr))}.game-layout{grid-template-columns:minmax(0,1fr);max-width:600px}#desktop-menu{display:none}.brand{font-size:34px}.home-panel{margin-top:4vh}}
@media(max-width:600px){header{padding:12px;gap:10px}.brand{font-size:26px;letter-spacing:-.8px}.icon{width:45px;height:45px;min-width:45px;min-height:45px;font-size:25px}main{padding:5px 10px 24px}.home-panel{margin-top:9vh;padding:40px 32px}.home-panel h1{font-size:35px}.home-panel p{font-size:16px}.cards{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.card{border-width:2px;padding:6px 6px 12px}.card strong{font-size:13px}.card small{font-size:10px}.collection-top{padding:24px;gap:9px}.collection-top h1{font-size:24px}.collection-top #total{font-size:12px}.tabs{gap:5px}.tabs button{padding:8px;font-size:15px}.board-top{gap:7px}.board-top .pill{font-size:16px;padding:7px 10px;min-width:84px}.puzzle-title{font-size:14px;margin-top:9px}.below-board .pill{font-size:12px}.feedback{font-size:11px}.dialog-inner{padding:27px}.menu-panel{padding:30px;gap:12px}#dialog-content h2{font-size:26px}.home-panel .green{font-size:19px}.pill{border-width:2px}.setting{font-size:15px}.tile{text-shadow:.5px .5px #171e2c}.brand{max-width:calc(100% - 60px)}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important}}
.panel:before{display:none}.tile{isolation:isolate}.tile:before{content:'';position:absolute;inset:5%;border-radius:14%;background:#fff4d3;z-index:-2}.tile:after{content:'';position:absolute;inset:0;background:var(--tile-art) center/107% 107% no-repeat;z-index:-1}.tile.movable:before{background:#ffdb48}.tile.movable:after{background-image:var(--active-art)}.tile,.tile.movable{background:none}.green{position:relative;isolation:isolate}.green:before{content:'';position:absolute;inset:12% 3%;background:#389743;border-radius:25px;z-index:-2}.green:after{content:'';position:absolute;inset:0;background:var(--button-art) center/100% 145% no-repeat;z-index:-1}.green{background:none}
.panel{background-size:116% 110%}

/* Visual revision: embedded rounded lettering and compact collection toolbar. */
@font-face{font-family:DynaPuff;src:url('assets/fonts/DynaPuff.ttf') format('truetype');font-weight:400 700;font-display:swap}
body{font-family:DynaPuff,'Arial Rounded MT Bold',system-ui,sans-serif;font-weight:400}
button,.pill,.setting,strong{font-weight:600}h1,h2,.brand,.tile{font-weight:700}
.brand{letter-spacing:-1px;color:#172131;-webkit-text-stroke:5px #fff4d8;paint-order:stroke fill;text-shadow:0 3px 0 #172131;font-size:clamp(24px,3.6vw,50px)}
.home-panel h1{font-size:39px}.home-panel p{font-size:16px}.tile{text-shadow:none;letter-spacing:-1px}
.menu-heading h2{font-size:36px}.green{text-shadow:0 2px #286531;font-weight:600}
.collection-top{max-width:none;padding:14px 18px;gap:12px;background:#fff8e8;border:3px solid #202634;border-radius:23px 19px 24px 20px;box-shadow:0 4px 0 #2a251c26;display:grid;grid-template-columns:auto 1fr auto;align-items:center;margin-bottom:20px}
.collection-top h1{font-size:25px}.collection-top #total{font-size:13px;grid-column:3;grid-row:1;margin:0}.tabs{grid-column:2;grid-row:1;justify-self:center;gap:5px;background:#eadfc2;border-radius:15px;padding:4px}.tabs button{flex:none;min-width:80px;min-height:42px;padding:7px 13px;border:2px solid transparent;border-radius:12px;background:none;box-shadow:none;font-size:17px}.tabs button[aria-pressed=true]{background:#ffdf77;border-color:#242a31;box-shadow:0 2px #c79d3d}.collection-top #resume-collection{grid-column:1/-1;justify-self:end;font-size:15px;min-height:44px;padding:8px 18px}
@media(max-width:700px){.collection-top{grid-template-columns:1fr auto;padding:12px;gap:10px}.collection-top h1{font-size:22px}.collection-top #total{grid-column:2;font-size:11px}.tabs{grid-column:1/-1;grid-row:2;justify-self:stretch;justify-content:center}.tabs button{flex:1;min-width:0}.collection-top #resume-collection{grid-row:3}.brand{font-size:25px;-webkit-text-stroke:4px #fff4d8;letter-spacing:-.7px}.home-panel h1{font-size:32px}.menu-panel{padding:28px;gap:10px}.setting{font-size:14px}.menu-panel>button{font-size:14px}.menu-panel .green{font-size:18px}}
.tile.movable:after{border-radius:16%;background-size:104% 104%}
@font-face{font-family:Nunito;src:url('assets/fonts/Nunito.ttf') format('truetype');font-weight:200 1000;font-display:swap}
body{font-family:Nunito,system-ui,sans-serif;font-weight:700}button,.pill,.setting,strong{font-weight:900}.brand,h1,h2{font-family:Nunito,system-ui,sans-serif;font-weight:1000}.brand{letter-spacing:-1.3px}.tile{font-family:DynaPuff,system-ui,sans-serif;font-weight:700}.green{font-weight:1000}.card strong{font-size:16px}.card small{font-size:12px}.menu-panel>button{font-size:17px}.menu-panel .green{font-size:21px}select{font-size:16px;font-weight:800}
@media(max-width:600px){.card strong{font-size:14px}.card small{font-size:11px}.menu-panel>button{font-size:16px}.menu-panel .green{font-size:20px}}
.green:after{inset:5% 0;border-radius:24px;background-size:104% 120%}.green:before{display:none}
/* Keep the illustrated corners at a fixed size instead of stretching the panel. */
.panel{background:none}
.panel:before{display:block;content:'';position:absolute;inset:-8px;background:none;border-radius:0;border-image:var(--panel-art) 180 200 fill / 44px / 0 stretch;z-index:-1;pointer-events:none}
.dialog-inner:has(.menu-panel):before{display:none}
dialog[data-kind='about'],dialog[data-kind='pause'],dialog[data-kind='confirm']{width:400px}
dialog[data-kind='menu']{width:400px}
dialog[data-kind='about'] .dialog-inner{padding:32px}
dialog[data-kind='about'] #dialog-content{min-height:260px;display:flex;flex-direction:column}
dialog[data-kind='about'] h2{text-align:center}
dialog[data-kind='about'] p{line-height:1.65;margin:4px 0 18px}
dialog[data-kind='about'] .actions{margin-top:auto;padding-top:14px}
#dialog-content .actions{justify-content:center;gap:12px}
#dialog-content .actions button{flex:0 1 210px;width:210px;max-width:100%;min-height:56px;padding:11px 16px;border-radius:17px 19px 16px 18px;line-height:1.25}
.home-panel>button{align-self:center;width:250px;max-width:100%;min-height:58px}
.menu-panel>button{align-self:center;width:240px;max-width:100%;min-height:56px;line-height:1.25;padding:10px 16px}
.menu-panel>.green{min-height:62px}
.green{min-height:60px;padding:12px 20px;line-height:1.25}
.green:after{inset:0;border-radius:19px;background-size:104% 114%}
.collection-top #resume-collection{min-height:52px;min-width:170px}
@media(max-width:600px){.menu-panel{padding:28px 26px}.home-panel>button{width:230px}.menu-panel>button{width:230px}#dialog-content .actions button{flex-basis:200px;width:200px}dialog[data-kind='about'] .dialog-inner{padding:28px}.panel:before{border-image-width:38px}.home-panel{padding:36px 28px}}
/* Keep decorative paint inside its layout box; never enlarge/crop button artwork. */
.panel:before{inset:0}
.green:after{inset:0;border-radius:0;background-size:100% 100%}
dialog{max-width:calc(100vw - 20px);max-height:calc(100dvh - 20px);overflow:visible}
body:has(dialog[open]){overflow:hidden}
dialog[data-kind='reward'] .reward-image{width:auto;max-width:100%;height:auto;max-height:calc(100dvh - 320px);aspect-ratio:auto;margin-inline:auto}
dialog[data-kind='share'] .share-preview{max-height:calc(100dvh - 350px)}
@media(max-width:600px){dialog[data-kind='reward'] .reward-image{max-height:calc(100dvh - 420px)}}
@media(max-height:740px){dialog .menu-panel{gap:6px;padding:22px 26px}dialog .menu-panel>button{min-height:44px}dialog .menu-panel>.green{min-height:50px}dialog .setting{margin-top:0}dialog .menu-heading h2{font-size:26px}dialog select{min-height:38px;padding:5px 8px}dialog .dialog-inner{padding:24px}#dialog-content .actions{gap:8px;margin-top:12px}#dialog-content .actions button{min-height:46px}dialog[data-kind='reward'] .reward-image{max-height:calc(100dvh - 300px)}#dialog-content h2{margin-bottom:10px}}
dialog[data-kind='reward'] .reward-image{max-height:calc(100dvh - 365px)}
@media(max-width:600px){dialog[data-kind='reward'] .reward-image{max-height:calc(100dvh - 430px)}}
dialog[data-kind='share'] .share-preview{max-height:calc(100dvh - 480px);width:auto;max-width:100%;display:block;margin-inline:auto}
