@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;450;500;550;600;650;700&family=Manrope:wght@400;450;500;550;600;650;700&display=swap');
:root{color-scheme:dark;--bg:#19171e;--surface:#211e28;--surface2:#292430;--line:#3c3446;--accent:#d7c0eb;--accent-soft:#d7c0eb16;--text:#f0ebf5;--muted:#a79bb2;--faint:#776b85;--coral:#e9a6b2;font-family:'DM Sans',sans-serif;font-synthesis:none;background:var(--bg);color:var(--text);font-weight:400}
*{box-sizing:border-box}html,body{height:100%;margin:0;overflow:hidden}body{background:radial-gradient(ellipse at 56% 35%,#4d385a1a,transparent 65%),var(--bg);min-width:280px}button,input,select{font:inherit}button,a,input,select{-webkit-tap-highlight-color:transparent}button{cursor:pointer;color:inherit;border:0;touch-action:manipulation;transition:background .2s,border-color .2s,color .2s,transform .2s}button:disabled{cursor:default;opacity:.38}button:active:not(:disabled){transform:scale(.97)}a{color:inherit;text-decoration:none}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid var(--accent);outline-offset:4px}h1,h2,h3,p{margin:0}svg{height:20px;width:20px;flex-shrink:0;vertical-align:middle}::selection{background:#d7c0eb36}[hidden]{display:none!important}.app-shell{height:100dvh;max-width:1600px;margin:auto;padding:0 clamp(20px,4.5vw,76px);display:grid;grid-template-rows:76px minmax(0,1fr) 40px;gap:0}.site-header{display:flex;align-items:center;justify-content:space-between;gap:20px;border-bottom:1px solid #d7c0eb14}.brand{display:flex;align-items:center;gap:14px;font-size:21px;letter-spacing:-.7px;white-space:nowrap}.brand-mark{width:36px;height:36px;border:1px solid #d7c0eb35;display:grid;place-content:center;grid-auto-flow:column;border-radius:12px;color:var(--accent);font:25px Georgia,serif;background:#d7c0eb06}.brand-mark>span{font-family:Arial,sans-serif;color:#8f719f}.brand strong{font-weight:400;color:var(--accent)}.brand-divider{color:#6b5d77;padding:0 2px}.brand-game{border-left:1px solid var(--line);margin-left:7px;padding-left:20px;font-size:8px;letter-spacing:2px;color:var(--faint)}.site-header nav{display:flex;align-items:center;gap:24px}.header-help{background:none;font-size:12px;color:var(--muted)}.header-help:hover{color:var(--accent)}.login-button{display:flex;align-items:center;gap:9px;background:#d7c0eb0b;border:1px solid #d7c0eb30;padding:10px 17px;border-radius:8px;font-size:12px;color:var(--accent)}.login-button svg{width:15px;height:15px}.login-button:hover{background:#d7c0eb1a;border-color:#d7c0eb70}.site-footer{display:flex;justify-content:space-between;align-items:center;gap:16px;border-top:1px solid #d7c0eb14;font-size:9px;color:#8f819b}.site-footer>span{display:flex;align-items:center;gap:7px}.site-footer>span:nth-child(2){color:#7e718c;font-size:8px}.site-footer i{width:4px;height:4px;background:#a999b8;border-radius:50%}.site-footer>span:last-child{letter-spacing:1.6px;font-size:7px}.site-footer b{font-size:8px;color:#baa5ca;border-left:1px solid var(--line);padding-left:12px;margin-left:4px;font-weight:400}main{min-height:0;min-width:0;position:relative}main:focus{outline:none}.skip-link{position:fixed;top:10px;left:10px;z-index:1000;padding:12px 18px;background:var(--accent);color:var(--bg);border-radius:6px;transform:translateY(-200%)}.skip-link:focus{transform:none}.eyebrow{display:flex;align-items:center;gap:9px;font-size:9px;font-weight:500;letter-spacing:2.5px;color:#bda8cd}.eyebrow i{width:5px;height:5px;border-radius:50%;background:var(--accent);box-shadow:0 0 12px #d7c0eb44}em{font-family:Georgia,'Times New Roman',serif;font-weight:400;color:var(--accent)}.primary-button{display:inline-flex;justify-content:center;align-items:center;gap:20px;background:var(--accent);color:#302039;border:1px solid #e3cdf5;border-radius:9px;padding:15px 22px;min-height:48px;font-size:13px;font-weight:500;box-shadow:inset 0 1px #ffffff22,0 5px 18px #0001}.primary-button svg{width:17px;height:17px}.primary-button:hover{background:#e5cef7;box-shadow:0 5px 25px #d7c0eb13}.text-button{display:inline-flex;justify-content:center;align-items:center;gap:8px;padding:6px 0;background:transparent;font-size:11px;color:#bba6ce}.text-button svg{height:14px;width:14px}.text-button:hover{color:var(--text)}.icon-button{display:inline-grid;place-items:center;min-width:34px;min-height:34px;border-radius:8px;background:transparent;color:#bda9ce}.icon-button svg{width:18px;height:18px}.icon-button:hover{background:#d7c0eb0e;color:#ead7f8}.full{width:100%}.centered{display:flex;width:100%;margin-top:15px}.screen-enter{animation:screen-in .45s ease both}.screen-top{display:flex;justify-content:space-between;align-items:center;gap:16px;min-height:36px}.screen-top>.eyebrow{font-size:8px;color:#857190;letter-spacing:2px}

/* A single, open invitation. */
.home-screen{display:grid;grid-template-columns:1.08fr 1fr;grid-template-rows:minmax(0,1fr) 55px;align-items:center;column-gap:30px;padding:30px 0 12px}.home-intro{padding-left:4vw;position:relative;z-index:2}.home-intro h1{font-family:'Manrope',sans-serif;font-weight:400;font-size:clamp(48px,5.2vw,80px);letter-spacing:-3.6px;line-height:1.1;margin:28px 0}.home-intro h1 em{letter-spacing:-3.2px}.home-intro>p{color:var(--muted);font-size:14px;line-height:1.95}.home-actions{display:flex;align-items:center;gap:24px;margin-top:36px}.home-note{font-size:7px;letter-spacing:1.8px;line-height:2;color:#8b769b}.home-actions .primary-button{min-width:190px;justify-content:space-between}.resume-button{display:flex;align-items:center;gap:8px;background:none;color:#bba6cb;font-size:11px;flex-wrap:wrap;max-width:180px;text-align:left}.resume-button svg{width:14px;height:14px}.resume-button span{font-size:9px;color:#7f6a90;padding-left:22px;flex-basis:100%;font-variant-numeric:tabular-nums}.home-account{display:flex;align-items:center;gap:12px;margin-top:48px}.account-symbol{display:grid;place-items:center;width:32px;height:32px;border:1px solid #d7c0eb22;border-radius:50%;color:#a994ba}.account-symbol svg{width:14px;height:14px}.home-account strong{font-size:11px;font-weight:400;color:#c0b0cb}.home-account p{color:#82728f;font-size:9px;margin-top:5px;line-height:1.7}.home-account button{font-size:9px;padding:0;background:transparent;color:#bda2d2}.home-account button:hover{text-decoration:underline}.home-art{height:min(470px,65vh);position:relative;display:grid;place-items:center;isolation:isolate}.art-halo{position:absolute;width:100%;height:100%;background:radial-gradient(ellipse,#9671b326,transparent 62%);filter:blur(16px)}.art-ring{position:absolute;width:86%;height:75%;border:1px solid #bfa3d31c;border-radius:50%;transform:rotate(-28deg);animation:orbital-drift 60s linear infinite}.art-ring:after{content:'';position:absolute;left:14%;top:14%;width:5px;height:5px;border-radius:50%;background:#bc9cd3;box-shadow:0 0 15px #cba8e677}.art-ring.second{width:65%;height:98%;border-color:#bfa3d310;animation-direction:reverse;animation-duration:80s}.sculpture-grid{width:clamp(230px,24vw,350px);aspect-ratio:1;display:grid;grid-template-columns:repeat(3,1fr);gap:9px;transform:perspective(800px) rotateY(-12deg) rotateX(9deg) rotate(-9deg);animation:sculpture-float 9s ease-in-out infinite;z-index:1}.tile{display:grid;place-items:center;background:linear-gradient(140deg,#58446260,#302837);border:1px solid #d7c0eb28;border-radius:15px;font-family:'Manrope',sans-serif;font-size:clamp(26px,3vw,44px);font-weight:400;color:#c6b2d5;box-shadow:inset 0 1px #d7c0eb14,5px 8px 20px #0002}.tile-4{background:linear-gradient(140deg,#e1caee,#b99aca);color:#493155;border-color:#e1caee88;box-shadow:0 0 40px #d7c0eb12;transform:translateZ(25px)}.tile i{height:4px;width:4px;border-radius:50%;background:#7a6389}.art-coordinate{position:absolute;font-size:7px;letter-spacing:2px;color:#987eaa}.coordinate-top{top:5%;right:10%}.coordinate-bottom{bottom:0;left:50%;transform:translateX(-50%);white-space:nowrap;font-size:6px}.art-star{position:absolute;font-style:normal;left:5%;bottom:20%;color:#9d80b0;font-size:20px;font-weight:300}.home-bottom{grid-column:1/-1;display:flex;justify-content:space-between;align-items:center;align-self:end;padding:0 4vw;font-size:7px;letter-spacing:1.5px;color:#7f6f8a}.home-bottom button{display:flex;align-items:center;gap:8px;background:none;color:#9e8aac;font-size:10px;letter-spacing:0}.home-bottom button svg{width:13px;height:13px}

/* A library with breathing space; every level stays in view. */
.levels-screen{display:grid;grid-template-rows:36px auto minmax(0,1fr);padding:24px 3vw 30px;gap:26px}.levels-heading{display:flex;justify-content:space-between;align-items:center;gap:24px}.levels-heading h1{font-family:'Manrope',sans-serif;font-size:clamp(32px,3.5vw,48px);font-weight:400;letter-spacing:-1.8px;margin-bottom:12px}.levels-heading p{font-size:12px;color:var(--muted);line-height:1.7}.difficulty-tabs{display:flex;padding:5px;border:1px solid #d7c0eb21;background:#d7c0eb03;border-radius:11px;gap:4px}.difficulty-tabs button{display:flex;align-items:center;gap:10px;padding:12px 18px;border:1px solid transparent;background:transparent;border-radius:7px;color:#9d89ac;font-size:12px;white-space:nowrap}.difficulty-tabs button[aria-selected=true]{background:#d7c0eb19;color:#e2cdef;border-color:#d7c0eb2e;box-shadow:0 2px 8px #0002}.difficulty-tabs button:hover{color:var(--accent);background:#d7c0eb0d}.difficulty-bars{display:flex;gap:3px;height:13px;align-items:flex-end}.difficulty-bars i{width:3px;height:5px;background:#51425c;border-radius:2px}.difficulty-bars i:nth-child(2){height:9px}.difficulty-bars i:nth-child(3){height:13px}.difficulty-bars i.filled{background:currentColor}.levels-collection{display:flex;flex-direction:column;min-height:0;justify-content:center}.collection-heading{display:flex;justify-content:space-between;gap:16px;padding-bottom:18px;font-size:8px;letter-spacing:1.2px;color:#b39cc4}.collection-heading>span:first-child{display:flex;align-items:center;gap:10px}.collection-heading i{width:3px;height:3px;border-radius:50%;background:#7c658d}.collection-heading>span:last-child{font-size:7px;color:#84708f}.level-grid{display:grid;grid-template-columns:repeat(10,1fr);grid-template-rows:repeat(2,minmax(0,1fr));gap:12px;min-height:0;max-height:340px;flex:1}.level{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:10px;padding:16px 6px;border:1px solid #d7c0eb1a;border-radius:12px;background:linear-gradient(140deg,#d7c0eb06,#d7c0eb01);overflow:hidden;min-width:0;min-height:0}.level.locked{opacity:1;color:#6e5e7c}.level-small{font-size:6px;letter-spacing:1.5px;color:#756480}.level strong{font:400 clamp(24px,2.3vw,36px) 'Manrope',sans-serif;letter-spacing:-1px}.level-state{display:flex;align-items:center;gap:5px;font-size:8px;color:#71617c}.level-state svg{height:10px;width:10px}.level.available{border-color:#d7c0eb77;background:linear-gradient(140deg,#d7c0eb20,#d7c0eb07);color:#e1c9f1}.level.available .level-small{color:#baa0cd}.level.available .level-state{color:#c7acd9}.level.available:hover{transform:translateY(-3px);background:#d7c0eb25;box-shadow:0 10px 28px #0002}.level-glow{position:absolute;bottom:0;left:18%;right:18%;height:1px;background:linear-gradient(90deg,transparent,#d7c0eb,transparent)}.collection-footer{display:flex;justify-content:space-between;align-items:center;gap:16px;padding-top:20px;font-size:9px;color:#8f7b9e}.collection-footer>span{display:flex;align-items:center;gap:7px}.collection-footer svg{width:12px;height:12px}.preview-caption{font-size:8px;color:#6d5d79}

/* A board sized from the viewport, with tools alongside it. */
.game-screen{--board-size:min(42vw,calc(100dvh - 252px),580px);display:grid;grid-template-rows:38px minmax(0,1fr);gap:18px;padding:18px 0 22px}.game-top{display:flex;align-items:center;gap:20px}.game-top>.text-button{font-size:11px}.game-title{display:flex;align-items:center;gap:9px;color:#a590b6;font-size:10px;margin-left:auto}.game-title i{width:3px;height:3px;border-radius:50%;background:#80628e}.game-top>.icon-button{margin-left:3px;min-width:30px;min-height:30px}.game-workspace{display:grid;grid-template-columns:minmax(140px,1fr) auto minmax(220px,260px);gap:clamp(24px,3vw,52px);align-items:center;justify-content:center;min-height:0}.game-story{align-self:center;min-width:0;padding:0 0 0 1vw}.game-story>.eyebrow{font-size:7px;letter-spacing:1.6px}.game-story h1{font-family:'Manrope',sans-serif;font-size:clamp(29px,2.8vw,42px);letter-spacing:-1.6px;font-weight:400;line-height:1.18;margin:22px 0}.game-story>p{font-size:11px;line-height:1.9;color:#95849f}.story-progress{max-width:180px;margin-top:40px}.story-progress>div{display:flex;justify-content:space-between;align-items:center;font-size:9px;color:#a995b8}.story-progress strong{font-weight:400;color:var(--accent);font-size:10px}.progress-line{display:block;background:#d7c0eb12;height:2px;margin:12px 0}.progress-line i{display:block;height:100%;background:#c4a5dc;transition:width .3s}.story-progress small{font-size:8px;color:#715c80}.story-tip{display:flex;gap:10px;align-items:flex-start;margin-top:44px;color:#967ea5}.story-tip svg{height:14px;width:14px;margin-top:2px}.story-tip p{font-size:9px;line-height:1.8;color:#826e90}.board-column{width:var(--board-size);min-width:0;display:flex;flex-direction:column;align-items:stretch}.board-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px;height:32px;flex-shrink:0}.timer-group{display:flex;align-items:center;gap:10px}.timer-group>span{font-size:13px;letter-spacing:1px;font-variant-numeric:tabular-nums;color:#cdb9dc}.timer-group .icon-button{width:27px;height:27px;min-height:27px;min-width:27px;border:1px solid #d7c0eb26;border-radius:6px}.timer-group svg{width:12px;height:12px}.mistake-indicator{display:flex;gap:9px;align-items:center;font-size:9px;color:#93819f}.mistake-indicator strong{font-weight:400;font-size:11px;color:#c2a7d4}.mistake-indicator>span:last-child{display:flex;gap:3px}.mistake-indicator i{width:4px;height:4px;border-radius:50%;background:#c2a3d8}.mistake-indicator i.used{background:#614655}.board-wrap{min-height:0;display:grid;place-items:center;width:100%;flex:1}.board-frame{width:var(--board-size);height:var(--board-size);border:1px solid #9781a8;border-radius:11px;overflow:hidden;box-shadow:0 18px 60px #0002,0 0 0 7px #d7c0eb03;background:#211c29}.sudoku-board{display:grid;grid-template-columns:repeat(9,1fr);grid-template-rows:repeat(9,1fr);width:100%;height:100%;position:relative}.cell{min-width:0;min-height:0;position:relative;display:grid;place-items:center;padding:0;background:#231f2c;border-right:1px solid #3a3045;border-bottom:1px solid #3a3045;border-radius:0;font-family:'Manrope',sans-serif;font-size:clamp(22px,2.1vw,30px);font-weight:400;line-height:1;color:#e1d6ea;transition:background .16s,color .16s}.cell:nth-child(9n){border-right:0}.cell:nth-child(n+73){border-bottom:0}.cell.box-right{border-right:2px solid #80688f}.cell.box-bottom{border-bottom:2px solid #80688f}.cell.related{background:#2d2537}.cell.entered{color:#c4a0e1;font-weight:600}.cell.matching{background:#554161;color:#f0d9ff}.cell.selected{background:#d0b2e7!important;color:#382242!important;box-shadow:inset 0 0 0 2px #ead3fa;z-index:1}.cell:hover:not(.selected){background:#41304f}.cell.conflict{color:#f0b0bf;background:#66384d55}.cell.selected.conflict{background:#e5a8bd!important;color:#5d253a!important;box-shadow:inset 0 0 0 2px #ffd2e1}.cell:focus-visible{outline:2px solid #f0dcff;outline-offset:-3px;z-index:2}.cell-notes{display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,1fr);width:100%;height:100%;padding:3px;font:400 clamp(8px,.8vw,11px) 'DM Sans',sans-serif;line-height:1;color:#b29ac2}.cell-notes>span{display:grid;place-items:center}.selected .cell-notes{color:#513a61}.concealed .sudoku-board{visibility:hidden}.concealed{background:radial-gradient(ellipse,#392b43,#211c29)}.wrong-move{animation:wrong-shake .3s ease}.board-foot{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-top:17px;flex-shrink:0}.board-foot>span:first-child{display:flex;gap:6px;align-items:center;font-size:8px;color:#9882a8}.board-foot svg{width:11px;height:11px}.notes-indicator{font-size:6px;letter-spacing:1.2px;color:#8b719e}.play-controls{align-self:center;min-width:0;display:flex;flex-direction:column;gap:22px}.control-heading>.eyebrow{font-size:7px;letter-spacing:1.6px;color:#8d739f}.control-heading h2{font-family:'Manrope',sans-serif;font-size:23px;font-weight:400;letter-spacing:-.8px;margin-top:10px}.number-pad{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.number-pad button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-height:62px;border:1px solid #d7c0eb27;border-radius:9px;background:linear-gradient(145deg,#d7c0eb0c,#d7c0eb03);color:#cbb2dd}.number-pad strong{font:400 26px 'Manrope',sans-serif;line-height:1.2}.number-pad small{font-size:7px;color:#725b83;line-height:1}.number-pad button:hover{border-color:#d7c0eb70;background:#d7c0eb15}.number-pad button.active{background:#d7c0eb18;border-color:#d7c0eb59;color:#e5c9f9}.tool-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px 8px}.tool-grid button{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;background:transparent;color:#b59ac8;min-height:48px;border:1px solid transparent;border-radius:8px;font-size:9px}.tool-grid svg{width:18px;height:18px}.tool-grid button:hover:not(:disabled){background:#d7c0eb0b;border-color:#d7c0eb1c}.tool-grid button[aria-pressed=true]{color:#e8cafa;background:#d7c0eb15;border-color:#d7c0eb40}.tool-grid button[aria-pressed=true] i{position:absolute;top:6px;right:8px;width:4px;height:4px;border-radius:50%;background:var(--accent)}.tool-grid small{font-size:7px;color:#8d6ba5;margin-left:2px}.music-player{display:flex;align-items:center;gap:11px;padding:12px;border:1px solid #d7c0eb27;background:linear-gradient(110deg,#d7c0eb0c,#d7c0eb02);border-radius:11px;min-width:0}.album-art{position:relative;flex-shrink:0;display:grid;place-items:center;width:40px;height:40px;border-radius:7px;background:radial-gradient(ellipse at 40% 65%,#d4adcb77,transparent 65%),linear-gradient(145deg,#5b3c72,#2f2840);overflow:hidden}.album-art>span{position:absolute;width:32px;height:32px;border:1px solid #eacdf944;border-radius:50%;transform:rotate(-25deg) scaleX(.7)}.album-art>i{position:absolute;width:20px;height:20px;border-radius:50%;border:1px solid #eacdf966;transform:rotate(25deg) scaleX(.5)}.track-copy{flex:1;min-width:0}.track-eyebrow{font-size:5px;letter-spacing:.8px;color:#957ba5;display:block;margin-bottom:5px;white-space:nowrap}.track-copy strong{display:block;font-size:11px;font-weight:500;color:#d2bbdf}.track-copy small{display:block;color:#826c94;font-size:7px;margin-top:4px;white-space:nowrap}.track-copy small>span{padding:0 2px}.music-toggle{min-height:28px;min-width:28px;width:28px;height:28px;border-radius:50%;border:1px solid #d7c0eb42;color:#d9bdeb}.music-toggle svg{width:12px;height:12px}.equalizer{display:flex;align-items:center;gap:2px;height:15px}.equalizer i{display:block;width:2px;height:3px;border-radius:2px;background:#b796cd}.playing .equalizer i{animation:equalize 1.4s ease-in-out infinite}.playing .equalizer i:nth-child(2){animation-delay:-.3s}.playing .equalizer i:nth-child(3){animation-delay:-.7s}.playing .equalizer i:nth-child(4){animation-delay:-1s}.control-note{text-align:center;font:italic 12px Georgia,serif;color:#725d81;margin-top:-10px}

/* A Hicarl orbit between spaces. */
.page-transition{position:fixed;inset:0;z-index:1000;display:flex;align-items:center;justify-content:center;flex-direction:column;background:radial-gradient(ellipse at 50% 42%,#312638,#19171e 65%);animation:fade-in .2s ease both;pointer-events:auto}.page-transition.leaving{animation:fade-out .26s ease both}.loading-orbit{width:106px;height:106px;position:relative;display:grid;place-items:center;margin-bottom:36px;border:1px solid #cbb3e324;border-radius:50%;box-shadow:0 0 50px #cbb3e307}.loading-orbit:before{content:'';position:absolute;inset:16px;border:1px dashed #cbb3e31c;border-radius:50%}.loading-orbit>span{font-size:35px;letter-spacing:-2px;color:#cbb3e3;font-weight:400}.loading-orbit>i,.loading-orbit>b{position:absolute;inset:-1px;border-radius:50%;border-top:1px solid #cbb3e380;animation:orbit 4s linear infinite}.loading-orbit>i:after,.loading-orbit>b:after{content:'';position:absolute;top:2px;left:34px;width:6px;height:6px;background:#d7c0eb;border-radius:50%;box-shadow:0 0 10px #d7c0eb55}.loading-orbit>b{inset:16px;border:0;animation-duration:7s;animation-direction:reverse}.loading-orbit>b:after{width:3px;height:3px;left:15px;opacity:.5}.page-transition>.eyebrow{font-size:8px;letter-spacing:2.6px;color:#a58bb7}.page-transition h2{font-family:'Manrope',sans-serif;font-size:30px;font-weight:400;letter-spacing:-1.2px;margin:16px 0 12px}.page-transition p{font-size:11px;color:#a18cab}.loading-track{width:180px;height:2px;background:#d7c0eb14;overflow:hidden;margin:28px 0 14px}.loading-track i{display:block;width:40%;height:100%;background:linear-gradient(90deg,transparent,#d7c0eb);animation:loading-travel 1.6s ease-in-out infinite}.page-transition small{font-size:8px;color:#776183}

/* Dialogs remain inside the viewport; settings have their own small panels. */
dialog{width:min(460px,calc(100% - 32px));max-height:calc(100dvh - 32px);overflow:auto;border:1px solid #d7c0eb38;border-radius:22px;padding:36px;background:radial-gradient(ellipse at 50% 0,#76568c20,transparent 60%),#211c29;color:var(--text);box-shadow:0 30px 100px #0007;scrollbar-width:thin;scrollbar-color:#715c81 transparent}dialog::backdrop{background:#141018da;backdrop-filter:blur(12px)}dialog[open]{animation:dialog-in .3s ease both}.modal-close{position:absolute;right:16px;top:15px}.dialog-symbol{display:grid;place-items:center;width:47px;height:47px;border-radius:14px;border:1px solid #d7c0eb30;background:#d7c0eb08;color:#d7c0eb;margin-bottom:25px}.dialog-symbol svg{width:22px;height:22px}dialog>.eyebrow{font-size:7px;letter-spacing:1.8px;color:#b89cc9}dialog h2{font-family:'Manrope',sans-serif;font-size:33px;font-weight:400;letter-spacing:-1.3px;line-height:1.18;margin:16px 0 18px}dialog>p{font-size:12px;line-height:1.9;color:#a693b3;margin-bottom:24px}.dialog-note{padding:14px 16px;border:1px solid #d7c0eb15;border-radius:9px;background:#d7c0eb04;color:#9e86ad;font-size:10px;line-height:1.9;margin:20px 0}.benefits{list-style:none;padding:0;margin:24px 0;display:flex;flex-direction:column;gap:14px}.benefits li{display:flex;align-items:center;gap:10px;color:#c1a9d1;font-size:11px}.benefits svg{width:14px;height:14px;color:#dac1ec}.how-list{padding-left:18px;color:#ad97bb;font-size:12px;line-height:1.8}.how-list li{padding-left:4px;margin-bottom:13px}.how-list strong{font-weight:500;color:#d7c0eb}.difficulty-guide>div{padding:14px 0;border-bottom:1px solid #d7c0eb14}.difficulty-guide h3{font-size:14px;font-weight:400;color:#d4b9e8;margin-bottom:6px}.difficulty-guide p{color:#9b81ac;font-size:11px;line-height:1.8}dialog[data-kind=ready],dialog[data-kind=pause],dialog[data-kind=won],dialog[data-kind=lost]{text-align:center;padding:34px 36px}.dialog-orbit{position:relative;width:65px;height:65px;display:grid;place-items:center;border:1px solid #d7c0eb38;border-radius:50%;margin:10px auto 29px;color:#d2b8e7;box-shadow:0 0 0 10px #d7c0eb03,0 0 0 11px #d7c0eb10}.dialog-orbit>span{font-size:26px;letter-spacing:-2px}.dialog-orbit>i{position:absolute;inset:-11px;border-radius:50%;border-top:1px solid #d7c0eb4a;animation:orbit 8s linear infinite}.dialog-orbit>i:after{content:'';position:absolute;top:4px;left:15px;width:4px;height:4px;background:#d7c0eb;border-radius:50%}dialog[data-kind=ready]>.eyebrow,dialog[data-kind=pause]>.eyebrow,dialog[data-kind=won]>.eyebrow,dialog[data-kind=lost]>.eyebrow{justify-content:center}dialog[data-kind=won] .dialog-symbol,dialog[data-kind=lost] .dialog-symbol{margin:0 auto 24px}.ready-details{display:flex;justify-content:center;gap:28px;margin:26px 0}.ready-details>span{min-width:60px;font-family:'Manrope',sans-serif;font-size:23px;color:#d2b7e5;letter-spacing:-.5px}.ready-details small{display:block;margin-top:8px;font-size:6px;letter-spacing:1.5px;font-family:'DM Sans',sans-serif;color:#8c719e}.ready-music{display:flex;justify-content:center;align-items:center;gap:6px;font-size:9px;color:#947aa6;margin:20px 0}.ready-music svg{height:12px;width:12px}.ready-music button{background:none;color:#c8a9df;padding:2px 0 2px 3px;text-decoration:underline;text-underline-offset:3px;font-size:9px}.paused-time{font-family:'Manrope',sans-serif;font-size:34px;letter-spacing:2px;font-variant-numeric:tabular-nums;color:#c9afd9;margin:28px 0}.settings-tabs{display:flex;gap:5px;padding:4px;background:#17131d;border:1px solid #d7c0eb1c;border-radius:9px;margin:22px 0 8px}.settings-tabs button{flex:1;min-width:0;padding:10px;background:none;font-size:11px;color:#967ea8;border-radius:6px;white-space:nowrap}.settings-tabs [aria-selected=true]{background:#d7c0eb19;color:#e1c8f3;box-shadow:inset 0 0 0 1px #d7c0eb25}.panel-enter{animation:panel-in .25s ease both}#settings-panel{min-height:270px}.setting-row{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:14px 0;border-bottom:1px solid #d7c0eb10;min-height:59px}.setting-row label{font-size:11px;color:#d1bbdf;line-height:1.4}.setting-row label small{display:block;font-size:8px;color:#816b92;margin-top:5px;max-width:220px;line-height:1.6}.setting-row select{font-size:10px;max-width:125px;min-width:104px;padding:9px 10px;border-radius:7px;background:#302638;border:1px solid #d7c0eb24;color:#d1b5e5}.switch{appearance:none;-webkit-appearance:none;flex-shrink:0;position:relative;width:32px;height:19px;border-radius:20px;background:#3b2e46;border:1px solid #5b4669;margin:0;cursor:pointer;transition:background .2s}.switch:before{content:'';position:absolute;top:3px;left:3px;width:11px;height:11px;border-radius:50%;background:#826994;transition:transform .2s}.switch:checked{background:#745886;border-color:#9b78b4}.switch:checked:before{background:#e4cdf5;transform:translateX(13px)}.switch:disabled{opacity:.35;cursor:default}.settings-bottom{display:flex;justify-content:space-between;align-items:center;gap:18px;padding-top:20px}.settings-bottom>span{font-size:8px;color:#8c739e}.settings-bottom>.primary-button{min-height:37px;padding:10px 18px;font-size:11px;gap:12px}.settings-bottom svg{height:14px;width:14px}.volume-row{flex-wrap:wrap;gap:12px}.volume-row label{flex:1}.volume-row input{max-width:120px;accent-color:var(--accent)}.volume-row output{font-size:9px;color:#b69ac9}.sound-preview{display:flex;align-items:center;gap:14px;margin-top:24px;padding:18px;background:#d7c0eb06;border:1px solid #d7c0eb14;border-radius:11px}.sound-preview strong{font-size:12px;font-weight:500;color:#d2bbdf}.sound-preview p{font-size:9px;line-height:1.8;color:#947ba7;margin-top:6px}.toast{position:fixed;z-index:2000;left:50%;bottom:50px;transform:translate(-50%,12px);opacity:0;pointer-events:none;border:1px solid #d7c0eb38;border-radius:10px;background:#33283e;color:#dbc2eb;box-shadow:0 10px 30px #0004;padding:12px 19px;max-width:calc(100% - 32px);width:max-content;font-size:11px;line-height:1.6;text-align:center;transition:opacity .2s,transform .2s}.toast.visible{opacity:1;transform:translate(-50%,0)}

@keyframes screen-in{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}@keyframes panel-in{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}@keyframes dialog-in{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}@keyframes fade-in{from{opacity:0}to{opacity:1}}@keyframes fade-out{to{opacity:0}}@keyframes orbit{to{transform:rotate(360deg)}}@keyframes orbital-drift{to{transform:rotate(332deg)}}@keyframes sculpture-float{50%{transform:perspective(800px) rotateY(-8deg) rotateX(12deg) rotate(-7deg) translateY(-8px)}}@keyframes loading-travel{from{transform:translateX(-100%)}to{transform:translateX(350%)}}@keyframes equalize{50%{height:14px}}@keyframes wrong-shake{25%{transform:translateX(-3px)}75%{transform:translateX(3px)}}

@media(min-width:1500px){.home-intro h1{font-size:84px}.game-screen{--board-size:min(40vw,calc(100dvh - 250px),620px)}.game-workspace{grid-template-columns:minmax(180px,1fr) auto 280px;gap:48px}.number-pad button{min-height:70px}.play-controls{gap:26px}.level-grid{max-height:390px}}
@media(max-height:800px) and (min-width:621px){.app-shell{grid-template-rows:64px minmax(0,1fr) 34px}.home-screen{padding:16px 0 8px;grid-template-rows:minmax(0,1fr) 38px}.home-intro h1{font-size:clamp(40px,4.5vw,64px);margin:22px 0}.home-account{margin-top:32px}.home-actions{margin-top:24px}.home-art{height:min(400px,60vh)}.levels-screen{padding:18px 2vw 22px;gap:20px}.levels-heading h1{font-size:37px;margin-bottom:8px}.game-screen{--board-size:min(42vw,calc(100dvh - 252px),540px);padding:12px 0 14px;gap:12px}.play-controls{gap:16px}.control-heading h2{font-size:21px}.number-pad button{min-height:54px}.tool-grid{gap:6px}.tool-grid button{min-height:42px;gap:6px}.music-player{padding:10px}.control-note{font-size:10px;margin-top:-6px}.game-story h1{font-size:32px;margin:18px 0}.story-progress{margin-top:28px}.story-tip{margin-top:30px}}
@media(max-width:1150px){.app-shell{padding:0 30px}.brand-game{display:none}.home-intro{padding-left:1vw}.home-intro h1{font-size:56px;letter-spacing:-2.8px}.home-intro h1 em{letter-spacing:-2.7px}.home-bottom{padding:0 1vw}.game-screen{--board-size:min(52vw,calc(100dvh - 252px),560px)}.game-story{display:none}.game-workspace{grid-template-columns:auto 255px;gap:36px}.game-top{max-width:850px;width:100%;margin:auto}.levels-screen{padding-left:0;padding-right:0}.difficulty-tabs button{padding:11px 14px}.level-grid{gap:9px}.level strong{font-size:27px}.level{gap:8px}.levels-heading p{font-size:11px}.collection-footer{font-size:8px}}
@media(max-width:850px){.app-shell{padding:0 24px}.site-header nav{gap:14px}.site-footer>span:nth-child(2){display:none}.home-intro h1{font-size:45px;letter-spacing:-2px}.home-intro h1 em{letter-spacing:-2px}.home-intro>p{font-size:12px}.home-intro>.eyebrow{font-size:7px;letter-spacing:1.7px}.home-actions{gap:16px;flex-wrap:wrap}.home-actions>.primary-button{min-width:170px;font-size:12px}.home-note{font-size:6px}.home-account p{max-width:230px}.sculpture-grid{width:220px;gap:6px}.tile{font-size:28px;border-radius:12px}.home-art{height:330px}.coordinate-bottom{font-size:5px;letter-spacing:1px}.home-bottom>span{font-size:6px;letter-spacing:1px}.level-grid{grid-template-columns:repeat(5,1fr);grid-template-rows:repeat(4,minmax(0,1fr));max-height:none;gap:10px}.level{gap:6px;padding:8px}.level-small{font-size:5px}.level strong{font-size:24px}.level-state{font-size:7px}.levels-screen{gap:18px;padding-bottom:24px}.levels-heading{align-items:flex-start;flex-direction:column;gap:18px}.levels-heading h1{font-size:38px}.difficulty-tabs{width:100%;max-width:440px}.difficulty-tabs button{flex:1;justify-content:center}.collection-heading{padding-bottom:12px}.collection-footer{padding-top:14px}.game-workspace{grid-template-columns:auto 220px;gap:24px}.game-screen{--board-size:min(calc(100vw - 292px),calc(100dvh - 252px),480px)}.play-controls{gap:16px}.control-heading h2{font-size:20px}.number-pad button{min-height:54px}.number-pad strong{font-size:24px}.tool-grid{gap:5px}.tool-grid button{min-height:42px}.music-player{gap:8px;padding:9px}.album-art{width:33px;height:33px}.track-copy strong{font-size:10px}.track-copy small{font-size:6px}.track-eyebrow{font-size:4px;letter-spacing:.5px}.equalizer{display:none}.control-note{font-size:10px}.cell{font-size:23px}.cell-notes{font-size:8px}.mistake-indicator>span:last-child{display:none}}
@media(max-width:620px){.app-shell{padding:0 18px;grid-template-rows:58px minmax(0,1fr) 28px}.brand{font-size:18px;gap:9px}.brand-mark{width:29px;height:29px;border-radius:9px;font-size:21px}.site-header nav{gap:8px}.header-help{display:none}.site-header>.brand{letter-spacing:-.6px}.site-header .icon-button{min-height:30px;min-width:30px}.site-header .icon-button svg{width:16px;height:16px}.login-button{font-size:10px;padding:8px 10px;gap:6px}.login-button svg{width:12px;height:12px}.site-footer{font-size:7px}.site-footer>span:last-child{font-size:6px;letter-spacing:1.2px}.site-footer b{font-size:7px;margin-left:0;padding-left:8px}.home-screen{display:flex;flex-direction:column;justify-content:center;align-items:stretch;gap:0;padding:14px 4px 10px}.home-intro{padding:0;text-align:left}.home-intro>.eyebrow{font-size:7px;letter-spacing:1.6px}.home-intro h1{font-size:clamp(40px,10.6vw,58px);letter-spacing:-2.3px;line-height:1.08;margin:22px 0 18px}.home-intro h1 em{letter-spacing:-2.3px}.home-intro>p{font-size:12px;line-height:1.9}.home-actions{margin-top:26px;gap:18px}.home-actions>.primary-button{min-height:46px;min-width:175px;padding:13px 18px}.home-note{font-size:6px;letter-spacing:1.6px}.home-account{margin-top:30px;gap:10px}.home-account strong{font-size:10px}.home-account p{font-size:8px;max-width:none}.home-account button{font-size:8px}.account-symbol{width:28px;height:28px}.home-art{position:absolute;right:-12px;top:5%;height:140px;width:150px;opacity:.18;z-index:-1;pointer-events:none}.sculpture-grid{width:100px;gap:3px}.tile{font-size:17px;border-radius:5px}.tile i{height:2px;width:2px}.art-coordinate,.art-star{display:none}.home-bottom{margin-top:auto;padding:22px 0 4px;flex-shrink:0}.home-bottom>span{display:none}.home-bottom button{font-size:9px}.home-intro{margin:auto 0}.home-screen>.home-bottom{margin-top:0}.resume-button{font-size:9px;max-width:130px}.resume-button>span{font-size:8px}.levels-screen{grid-template-rows:26px auto minmax(0,1fr);padding:12px 0 15px;gap:16px}.screen-top{min-height:26px;gap:10px}.screen-top>.eyebrow{display:none}.screen-top .text-button{font-size:9px}.levels-heading{gap:15px}.levels-heading h1{font-size:32px;letter-spacing:-1.2px;margin-bottom:7px}.levels-heading p{font-size:10px;line-height:1.7;max-width:300px}.difficulty-tabs{padding:4px;gap:3px;max-width:none;border-radius:9px}.difficulty-tabs button{padding:10px 8px;font-size:10px;gap:7px;border-radius:6px}.difficulty-bars{height:11px;gap:2px}.difficulty-bars i{width:2px}.difficulty-bars i:nth-child(3){height:11px}.difficulty-bars i:nth-child(2){height:8px}.collection-heading{font-size:7px;padding-bottom:12px;gap:6px;letter-spacing:.7px}.collection-heading>span:first-child{gap:7px}.collection-heading>span:last-child{font-size:6px;white-space:nowrap}.level-grid{gap:8px}.level{border-radius:9px;gap:6px;padding:6px 3px}.level strong{font-size:22px}.level-small{font-size:5px;letter-spacing:1px}.level-state{font-size:6px;gap:4px}.level-state svg{width:8px;height:8px}.collection-footer{padding-top:12px;font-size:7px;line-height:1.6}.collection-footer svg{width:10px;height:10px}.collection-footer .preview-caption{display:none}.game-screen{--board-size:min(calc(100vw - 36px),calc(100dvh - 300px),460px);grid-template-rows:26px minmax(0,1fr);padding:10px 0 12px;gap:9px}.game-top{height:26px;gap:9px}.game-top>.text-button{font-size:9px}.game-title{font-size:8px;gap:6px}.game-top>.icon-button{min-height:25px;min-width:25px}.game-top>.icon-button svg{width:14px;height:14px}.game-workspace{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto;gap:12px;justify-items:center;align-items:stretch;min-height:0}.board-column{width:100%;max-width:460px;min-height:0;align-self:center;align-items:center}.board-toolbar{width:var(--board-size);height:26px;margin-bottom:10px;gap:8px}.timer-group{gap:8px}.timer-group>span{font-size:11px}.timer-group .icon-button{height:24px;width:24px;min-width:24px;min-height:24px}.mistake-indicator{font-size:8px;gap:6px}.mistake-indicator strong{font-size:10px}.board-frame{border-radius:8px;box-shadow:0 0 0 4px #d7c0eb03}.cell{font-size:clamp(19px,5.6vw,27px)}.cell-notes{font-size:clamp(7px,1.8vw,10px);padding:2px}.board-foot{width:var(--board-size);margin-top:9px}.board-foot>span:first-child{font-size:7px;gap:5px}.board-foot svg{width:10px;height:10px}.notes-indicator{font-size:5px;letter-spacing:.8px}.play-controls{width:100%;max-width:460px;display:grid;grid-template-columns:1fr;gap:9px;align-self:end}.control-heading,.control-note{display:none}.number-pad{grid-template-columns:repeat(9,1fr);gap:5px}.number-pad button{min-height:41px;gap:2px;border-radius:6px}.number-pad strong{font-size:21px;line-height:1.2}.number-pad small{font-size:5px}.tool-grid{grid-template-columns:repeat(6,1fr);gap:3px}.tool-grid button{min-height:38px;padding:4px 2px;gap:5px;font-size:7px;border-radius:6px}.tool-grid svg{height:16px;width:16px}.tool-grid small{font-size:6px}.tool-grid button[aria-pressed=true] i{top:4px;right:5px;width:3px;height:3px}.music-player{padding:7px 10px;gap:10px;border-radius:8px;height:46px}.album-art{width:30px;height:30px;border-radius:5px}.album-art>span{width:24px;height:24px}.album-art>i{width:16px;height:16px}.track-eyebrow{display:none}.track-copy strong{font-size:10px}.track-copy small{font-size:6px;margin-top:3px}.equalizer{display:flex;margin-right:5px}.music-toggle{width:26px;height:26px;min-height:26px;min-width:26px}.page-transition h2{font-size:25px;letter-spacing:-.8px;text-align:center}.page-transition p{font-size:10px}.loading-orbit{width:90px;height:90px;margin-bottom:30px}.page-transition .eyebrow{font-size:7px}.page-transition small{font-size:7px}dialog{padding:28px 24px;border-radius:18px;width:calc(100% - 28px)}dialog h2{font-size:29px;letter-spacing:-1px}dialog>p{font-size:11px}dialog[data-kind=ready],dialog[data-kind=pause],dialog[data-kind=won],dialog[data-kind=lost]{padding:28px 26px}.dialog-orbit{width:58px;height:58px;margin:8px auto 25px}.ready-details{gap:20px;margin:22px 0}.ready-details>span{font-size:21px}.ready-details small{font-size:6px;letter-spacing:1px}.ready-music{font-size:8px;gap:5px}.ready-music button{font-size:8px}.primary-button{min-height:43px;font-size:11px;padding:13px 16px;gap:14px}.primary-button svg{width:15px;height:15px}.text-button.centered{font-size:10px}.settings-tabs{margin:18px 0 5px}.settings-tabs button{padding:9px 6px;font-size:10px}#settings-panel{min-height:240px}.setting-row{padding:11px 0;min-height:53px;gap:12px}.setting-row label{font-size:10px}.setting-row label small{font-size:7px;max-width:160px;margin-top:4px}.setting-row select{font-size:9px;padding:8px;min-width:96px;max-width:105px}.settings-bottom{padding-top:17px;gap:10px}.settings-bottom>span{font-size:7px}.settings-bottom>.primary-button{min-height:34px;padding:9px 13px;font-size:10px}.settings-bottom svg{height:13px;width:13px}.sound-preview{padding:15px;gap:12px}.toast{font-size:9px;bottom:35px;padding:10px 14px}.volume-row input{max-width:100px}.volume-row output{font-size:8px}}
@media(max-width:620px) and (max-height:700px){.app-shell{grid-template-rows:52px minmax(0,1fr) 24px}.home-intro h1{font-size:42px;margin:18px 0 15px}.home-intro>p{font-size:11px}.home-account{margin-top:24px}.home-actions{margin-top:22px}.home-bottom{padding-top:16px}.levels-screen{gap:12px;padding-top:10px;padding-bottom:12px}.levels-heading{gap:11px}.levels-heading h1{font-size:29px}.levels-heading p{font-size:9px;line-height:1.6}.difficulty-tabs button{padding:9px 6px}.collection-heading{padding-bottom:10px}.level-grid{gap:6px}.level strong{font-size:20px}.level{gap:4px}.level-small{font-size:4px}.collection-footer{padding-top:9px;font-size:6px}.game-screen{--board-size:min(calc(100vw - 36px),calc(100dvh - 308px));padding-top:7px;padding-bottom:9px;gap:6px}.game-workspace{gap:8px}.board-toolbar{margin-bottom:8px;height:24px}.board-foot{margin-top:7px}.play-controls{gap:6px}.number-pad button{min-height:37px}.tool-grid button{min-height:35px;gap:4px}.music-player{height:41px;padding:5px 9px}.album-art{width:28px;height:28px}.track-copy strong{font-size:9px}.track-copy small{font-size:6px}.cell{font-size:22px}.cell-notes{font-size:8px}.board-foot>span:first-child{font-size:6px}.notes-indicator{font-size:5px}dialog[data-kind=settings]{padding:22px}dialog[data-kind=settings] h2{font-size:26px;margin:12px 0}.setting-row{min-height:48px;padding:9px 0}.setting-row label small{font-size:6.5px}.settings-tabs{margin:14px 0 4px}.settings-bottom{padding-top:14px}#settings-panel{min-height:220px}}
@media(max-width:360px){.app-shell{padding:0 14px}.brand{font-size:16px;gap:7px}.brand-mark{width:27px;height:27px}.site-header nav{gap:5px}.login-button{padding:7px 9px;font-size:9px}.login-button>svg{display:none}.home-intro h1{font-size:37px;letter-spacing:-1.8px}.home-intro h1 em{letter-spacing:-1.8px}.home-intro>.eyebrow{font-size:6px}.home-actions>.primary-button{min-width:156px;font-size:11px}.home-note{font-size:5px}.resume-button{max-width:110px;font-size:8px}.home-account p{font-size:7px}.home-account button{font-size:7px}.home-bottom button{font-size:8px}.game-screen{--board-size:min(calc(100vw - 28px),calc(100dvh - 308px))}.number-pad{gap:4px}.number-pad strong{font-size:19px}.tool-grid button{font-size:6px}.tool-grid svg{width:14px;height:14px}.game-title{font-size:7px}.game-top>.text-button{font-size:8px}.level-state{font-size:5px}.level-state svg{width:7px;height:7px}.collection-heading{font-size:6px}.settings-bottom>span{max-width:130px;line-height:1.7}.ready-music{font-size:7px}.ready-music button{font-size:7px}}
@media(max-height:560px) and (min-width:621px){.app-shell{grid-template-rows:48px minmax(0,1fr) 25px;padding:0 24px}.brand{font-size:18px}.brand-mark{width:28px;height:28px;font-size:21px}.header-help{font-size:10px}.login-button{padding:7px 12px;font-size:10px}.site-footer{font-size:7px}.home-screen{padding:10px 0 4px;grid-template-rows:minmax(0,1fr) 26px}.home-intro h1{font-size:clamp(31px,4.5vw,48px);margin:14px 0}.home-intro>p{font-size:10px;line-height:1.7}.home-account{display:none}.home-actions{margin-top:18px}.home-actions>.primary-button{min-height:38px;padding:10px 16px;font-size:11px}.home-art{height:220px}.sculpture-grid{width:170px;gap:5px}.tile{font-size:25px;border-radius:10px}.coordinate-top{font-size:5px}.coordinate-bottom{font-size:5px}.home-bottom button{font-size:8px}.home-bottom>span{font-size:5px}.levels-screen{padding:8px 0 12px;grid-template-rows:24px auto minmax(0,1fr);gap:9px}.screen-top{min-height:24px}.screen-top .text-button{font-size:8px}.screen-top>.eyebrow{font-size:6px}.levels-heading{flex-direction:row;align-items:center;gap:16px}.levels-heading h1{font-size:26px;margin-bottom:5px}.levels-heading p{font-size:8px}.difficulty-tabs{max-width:320px;width:auto}.difficulty-tabs button{font-size:9px;padding:8px 10px}.level-grid{grid-template-columns:repeat(10,1fr);grid-template-rows:repeat(2,minmax(0,1fr));gap:6px}.level{gap:3px;padding:4px}.level strong{font-size:20px}.level-small{font-size:4px}.level-state{font-size:6px}.level-state svg{width:7px;height:7px}.collection-heading{padding-bottom:8px;font-size:6px}.collection-footer{padding-top:8px;font-size:6px}.game-screen{--board-size:min(40vw,calc(100dvh - 170px));padding:7px 0 9px;grid-template-rows:24px minmax(0,1fr);gap:6px}.game-top{min-height:24px;height:24px;max-width:700px}.game-top>.text-button{font-size:8px}.game-title{font-size:8px}.game-workspace{grid-template-columns:auto minmax(260px,340px);gap:28px}.game-story{display:none}.board-toolbar{height:23px;margin-bottom:6px}.board-foot{margin-top:7px}.timer-group>span{font-size:10px}.timer-group>.icon-button{height:23px;min-height:23px;min-width:23px;width:23px}.mistake-indicator{font-size:7px}.mistake-indicator strong{font-size:9px}.board-foot>span:first-child{font-size:6px}.notes-indicator{font-size:5px}.cell{font-size:19px}.cell-notes{font-size:6px;padding:1px}.play-controls{gap:12px}.control-heading,.control-note{display:none}.number-pad{grid-template-columns:repeat(9,1fr);gap:4px}.number-pad button{min-height:37px;gap:3px;border-radius:5px}.number-pad strong{font-size:19px}.number-pad small{font-size:5px}.tool-grid{grid-template-columns:repeat(6,1fr);gap:4px}.tool-grid button{min-height:36px;font-size:6px;gap:6px}.tool-grid svg{width:14px;height:14px}.tool-grid small{font-size:5px}.music-player{padding:8px 10px;height:46px}.album-art{width:30px;height:30px}.track-eyebrow{display:none}.track-copy strong{font-size:10px}.track-copy small{font-size:6px}.equalizer{display:flex}dialog{max-height:calc(100dvh - 20px);padding:24px}dialog[data-kind=ready],dialog[data-kind=pause]{padding:22px 28px}.dialog-orbit{display:none}dialog h2{font-size:27px;margin:10px 0}dialog>p{font-size:10px;margin-bottom:14px}.ready-details{margin:16px 0}.ready-details>span{font-size:20px}.ready-music{margin:14px 0}.primary-button{min-height:38px;padding:10px 18px;font-size:11px}.paused-time{font-size:27px;margin:18px 0}.page-transition h2{font-size:25px}.loading-orbit{width:75px;height:75px;margin-bottom:22px}.loading-orbit>span{font-size:28px}.loading-track{margin:18px 0 10px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
/* Clear actions, readable counts, and a quieter game toolbar. */
.level-actions{display:flex;align-items:center;gap:16px}.preferences-button{display:flex;align-items:center;gap:8px;padding:9px 13px;border:1px solid #d7c0eb38;border-radius:10px;background:#d7c0eb0a;color:var(--accent);font-size:11px}.preferences-button svg{width:15px;height:15px}.preferences-button:hover{background:#d7c0eb20}.game-session-label{font-size:8px;letter-spacing:1.5px;color:var(--faint)}
.dialog-action{position:relative;isolation:isolate;overflow:hidden;display:flex;align-items:center;gap:14px;width:100%;padding:13px;border:1px solid #d7c0eb65;border-radius:14px;background:linear-gradient(120deg,#554261,#32283d);text-align:left;box-shadow:inset 0 1px #ffffff12,0 8px 24px #0002}.dialog-action:before{content:'';position:absolute;inset:0;background:linear-gradient(100deg,transparent,#ffffff12,transparent);transform:translateX(-110%);transition:transform .6s;z-index:-1}.dialog-action:hover:before{transform:translateX(110%)}.dialog-action:hover{border-color:var(--accent);transform:translateY(-2px)}.action-symbol{display:grid;place-items:center;flex-shrink:0;width:38px;height:38px;background:#e5d1f21a;border:1px solid #e5d1f22a;border-radius:11px;color:#e5d1f2}.action-symbol svg{width:18px;height:18px}.action-copy{display:grid;gap:5px;flex:1}.action-copy strong{font-size:13px;font-weight:550;color:#f2e9fa}.action-copy small{font-size:10px;color:#bfaacb}.action-forward{display:grid;place-items:center;width:27px;height:27px;border-radius:50%;background:#e5d1f213}.action-forward svg{width:14px;height:14px}.secondary-action{display:block;width:100%;margin-top:10px;padding:12px 14px;border:1px solid #d7c0eb24;border-radius:11px;background:#d7c0eb04;font-size:11px;color:#c7b5d3}.secondary-action:hover{background:#d7c0eb10;border-color:#d7c0eb55}.progress-invite{display:grid;grid-template-columns:28px 1fr;gap:10px;text-align:left;padding:17px;border:1px solid #d7c0eb26;border-radius:14px;margin:18px 0;background:#d7c0eb06}.progress-invite>span{color:var(--accent)}.progress-invite strong{font-size:12px;font-weight:500}.progress-invite p{font-size:10px;color:var(--muted);line-height:1.6;margin-top:5px}.progress-invite button{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;padding:11px 13px;border-radius:8px;background:#d7c0eb18;border:1px solid #d7c0eb35;color:var(--accent);font-size:11px}.progress-invite button:hover{background:#d7c0eb2a}.progress-invite button svg{width:14px;height:14px}.progress-invite>small{grid-column:1/-1;font-size:9px;color:var(--muted);line-height:1.6}
.number-pad button{position:relative;overflow:hidden;min-height:74px;border-radius:12px;background:linear-gradient(145deg,#302936,#211d27);border:1px solid #d7c0eb2c;gap:7px;box-shadow:inset 0 1px #ffffff06}.number-pad button:after{content:'';position:absolute;bottom:0;left:0;width:100%;height:2px;background:#c4a4dc70;transform:scaleX(var(--remaining,1));transform-origin:left;transition:transform .3s}.number-pad button:hover{background:#42334f;border-color:#d7c0eb88;transform:translateY(-2px)}.number-pad strong{font-size:29px;color:#e0cbed}.number-count{display:flex;align-items:center;justify-content:center;gap:4px;padding:2px 7px;border-radius:6px;background:#d7c0eb0c;color:#ae9fbb;line-height:1.2}.number-count b{font-size:12px;font-weight:550;color:#d9c9e5}.number-count>span{font-size:10px}.number-pad button.active{background:linear-gradient(140deg,#725780,#44324f);border-color:#e0c6f0}.number-pad button.complete{border-color:#9cbeb444}.count-changed{animation:count-pop .25s ease}.tool-grid button{border:1px solid #d7c0eb18;border-radius:10px;background:#d7c0eb04;min-height:57px;gap:7px;font-size:10px}.tool-grid button:hover:not(:disabled){background:#d7c0eb12;border-color:#d7c0eb44}.tool-grid svg{width:20px;height:20px;transition:transform .2s}.tool-grid button:hover:not(:disabled) svg{transform:translateY(-2px) rotate(-5deg)}.tool-grid small{font-size:10px;display:inline-block;background:#d7c0eb18;border-radius:4px;padding:1px 4px}.tool-grid button[aria-pressed=true]{background:#d7c0eb18;border-color:#d7c0eb70}@keyframes count-pop{50%{transform:translateY(-3px);background:#d7c0eb28}}
@media(min-width:621px) and (max-height:800px){.number-pad button{min-height:60px;gap:4px}.number-pad strong{font-size:25px}.tool-grid button{min-height:45px;font-size:9px}.play-controls{gap:12px}.control-note{display:none}}
@media(max-width:620px),(max-height:560px){.number-pad button{min-height:52px;gap:4px;border-radius:8px}.number-pad strong{font-size:21px}.number-count{padding:2px 4px}.number-count b{font-size:11px}.number-count>span{display:none}.tool-grid button{min-height:44px;font-size:8px;gap:5px}.tool-grid svg{width:17px;height:17px}.tool-grid small{font-size:9px;padding:0 2px}.game-session-label{display:none}.preferences-button{font-size:10px;padding:7px 10px}.level-actions{gap:10px}.dialog-action{gap:10px;padding:10px;border-radius:12px}.action-copy strong{font-size:12px}.action-copy small{font-size:9px}.action-symbol{width:32px;height:32px}.action-forward{width:23px;height:23px}.secondary-action{padding:11px;font-size:10px}.progress-invite{padding:12px;margin:12px 0}}
@media(max-width:620px){.game-screen{--board-size:min(calc(100vw - 36px),calc(100dvh - 332px),460px)}}
@media(max-width:620px) and (max-height:700px){.game-screen{--board-size:min(calc(100vw - 36px),calc(100dvh - 340px))}}
@media(max-width:360px){.game-screen{--board-size:min(calc(100vw - 28px),calc(100dvh - 340px))}.number-pad strong{font-size:19px}.number-count{padding:2px 3px}.tool-grid button{font-size:7px}}
@media(prefers-reduced-motion:reduce){.count-changed,.dialog-action:before{animation:none;transition:none}}
/* Shared Hicarl shell: 1340px content, 72px desktop / 60px mobile header. */
.app-shell{max-width:none;padding:0 max(24px,calc((100vw - 1340px)/2));grid-template-rows:72px minmax(0,1fr) 40px}.brand{font-size:23px}.site-header{height:72px}.game-top{display:flex;justify-content:space-between}.game-title{margin-left:auto}.game-session-label{margin-left:16px}
/* Chapters keep a large library calm and navigable. */
.levels-screen{padding:24px 0 22px;gap:22px;grid-template-rows:32px auto minmax(0,1fr)}.levels-heading h1{font-size:40px}.difficulty-tabs button{padding:11px 16px}.difficulty-bars i:nth-child(4){height:14px}.levels-collection{display:grid;grid-template-rows:auto auto minmax(0,1fr) auto;min-height:0;gap:18px}.chapter-heading{display:flex;align-items:center;justify-content:space-between;gap:20px}.chapter-heading .eyebrow{font-size:8px;letter-spacing:1.6px}.chapter-heading h2{font-size:25px;font-weight:450;letter-spacing:-.7px;margin-top:8px}.library-progress{display:flex;flex-direction:column;gap:6px;text-align:right;min-width:150px}.library-progress strong{font-size:23px;font-weight:500;color:var(--accent)}.library-progress small{font-size:13px;color:var(--muted);font-weight:400}.library-progress>span{font-size:7px;letter-spacing:1.5px;color:var(--muted)}.library-progress>i{height:3px;width:100%;background:linear-gradient(to right,#a7e9c4 var(--progress),#d7c0eb15 var(--progress));border-radius:3px;margin-top:3px}.chapter-nav{display:flex;align-items:center;gap:12px;padding:8px 12px;background:#d7c0eb07;border:1px solid #d7c0eb20;border-radius:12px}.chapter-nav label{font-size:10px;color:var(--muted)}.chapter-nav select{background:transparent;border:0;color:var(--accent);font-size:12px;padding:5px;max-width:240px}.chapter-nav option{background:#292430}.chapter-position{font-size:8px;letter-spacing:1px;color:var(--muted);margin-left:auto}.chapter-nav .icon-button{border:1px solid #d7c0eb22;min-height:28px;min-width:28px}.chapter-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));gap:14px;min-height:0;max-height:390px}.level-card{--status:#bda8cd;position:relative;min-height:0;perspective:900px;border-radius:15px}.level-card.won{--status:#9ce3bd}.level-card.progress{--status:#efd08b}.level-card.lost{--status:#ed9ba9}.level-flipper{position:relative;height:100%;width:100%;transform-style:preserve-3d;transition:transform .55s cubic-bezier(.2,.7,.2,1)}.level-card.flipped .level-flipper{transform:rotateY(180deg)}.level-front,.level-back{position:absolute;inset:0;backface-visibility:hidden;border-radius:15px;border:1px solid color-mix(in srgb,var(--status) 28%,transparent);background:linear-gradient(135deg,color-mix(in srgb,var(--status) 9%,#211e28),#211e28);overflow:hidden}.level-front:after{content:'';position:absolute;pointer-events:none;bottom:0;left:18px;right:18px;height:2px;background:var(--status);opacity:.45}.level-card.locked{opacity:.45}.level-card.locked .level-front:after{display:none}.level-launch{display:flex;flex-direction:column;align-items:flex-start;justify-content:space-between;height:100%;width:100%;padding:18px 20px;background:none;text-align:left;color:var(--status)}.level-launch:disabled{opacity:1}.level-launch:hover:not(:disabled){background:#d7c0eb09}.level-topline{display:flex;align-items:center;justify-content:space-between;width:100%;font-size:7px;letter-spacing:1.5px}.level-topline svg{width:14px;height:14px}.level-launch>strong{font-size:clamp(26px,3vw,42px);font-family:Manrope,sans-serif;font-weight:450;letter-spacing:-1px;line-height:1}.level-launch .level-state{font-size:10px;gap:6px}.level-state i{display:inline-block;width:5px;height:5px;background:var(--status);border-radius:50%}.level-stats{position:absolute;right:12px;bottom:12px;display:grid;place-items:center;background:color-mix(in srgb,var(--status) 10%,transparent);border:1px solid color-mix(in srgb,var(--status) 30%,transparent);color:var(--status);width:28px;height:28px;border-radius:8px}.level-stats svg{width:14px;height:14px}.level-stats:hover{background:color-mix(in srgb,var(--status) 25%,transparent)}.level-back{transform:rotateY(180deg);padding:12px 16px;display:flex;flex-direction:column;justify-content:center;gap:8px}.stats-top{display:flex;justify-content:space-between;align-items:center;font-size:8px;letter-spacing:1px;color:var(--status)}.stats-top button{background:none;padding:3px;color:var(--status)}.stats-top svg{width:13px;height:13px}.level-back dl{display:grid;gap:5px;margin:0}.level-back dl>div{display:flex;justify-content:space-between;gap:6px;font-size:10px}.level-back dt{color:var(--muted)}.level-back dd{margin:0;color:var(--status);font-variant-numeric:tabular-nums}.collection-footer{padding:0;font-size:10px;gap:12px}.status-legend{display:flex;gap:15px;font-size:9px}.status-legend>span:before{content:'';display:inline-block;width:5px;height:5px;background:currentColor;border-radius:50%;margin-right:5px}.status-legend .won{color:#9ce3bd}.status-legend .progress{color:#efd08b}.status-legend .lost{color:#ed9ba9}
/* An explicit pencil workspace, not just a tiny active dot. */
.mode-switch{display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:4px;background:#100e1466;border:1px solid #d7c0eb28;border-radius:12px}.mode-switch button{display:flex;align-items:center;justify-content:center;gap:7px;background:transparent;color:var(--muted);padding:10px 5px;font-size:11px;border-radius:8px;border:1px solid transparent}.mode-switch svg{height:16px;width:16px}.mode-switch button[aria-pressed=true]{background:#d7c0eb1a;border-color:#d7c0eb50;color:#e7d4f5;box-shadow:0 2px 8px #0002}.mode-switch b{font-size:7px;letter-spacing:.5px;background:#ffffff0b;padding:3px 4px;border-radius:4px;font-weight:500}.notes-mode{--accent:#8fdad1}.notes-mode .mode-switch button[aria-pressed=true]{color:#a9f1e7;background:#8fdad125;border-color:#8fdad180}.notes-mode .board-frame{border-color:#8fdad1;box-shadow:0 0 0 4px #8fdad112,0 0 35px #8fdad10b}.notes-mode .cell.selected{background:#31534f;box-shadow:inset 0 0 0 2px #a4e6dc;outline:0}.notes-mode .cell.related{background:#8fdad10c}.notes-mode .cell.selected:after{content:'';position:absolute;inset:4px;border:1px dashed #a4e6dc70;pointer-events:none}.cell{position:relative}.cell-notes{color:#a9f1e7;font-family:Manrope,sans-serif}.notes-indicator{display:flex;align-items:center;gap:5px;color:var(--accent);padding:4px 7px;border-radius:5px;background:#d7c0eb0c;font-size:7px}.notes-indicator svg{width:10px;height:10px}.notes-mode .notes-indicator{background:#8fdad11c;color:#a9f1e7}.notes-mode .number-pad button{border-style:dashed;border-color:#8fdad155}.notes-mode .number-pad strong{color:#ade8df;font-family:Georgia,serif;font-style:italic}.notes-mode .number-pad button.active{background:#8fdad126}.notes-mode .number-pad button:after{background:#8fdad180}.notes-mode .control-heading h2{color:#ade8df}.hinted{color:#f0d28e!important;background:#f0d28e0d}.hint-marker{position:absolute;top:3px;right:4px;font-size:9px;line-height:1;color:#f0d28e;pointer-events:none}.tool-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:6px}.tool-grid button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;border:0;background:transparent;min-height:62px;padding:4px 0;font-size:9px;border-radius:9px}.tool-grid .tool-icon{display:grid;place-items:center;border:1px solid #d7c0eb2c;background:linear-gradient(140deg,#d7c0eb12,#d7c0eb04);border-radius:11px;width:36px;height:36px;transition:background .2s,transform .2s}.tool-grid button:hover:not(:disabled){background:transparent}.tool-grid button:hover:not(:disabled) .tool-icon{background:#d7c0eb22;transform:translateY(-3px)}.tool-grid svg{width:18px;height:18px}.tool-grid button:disabled{opacity:.35}.tool-grid small{font-size:9px;padding:1px 3px;margin-left:2px}.control-tooltip{position:fixed;z-index:10000;max-width:220px;padding:10px 13px;border-radius:10px;border:1px solid #d7c0eb50;background:#352a3f;box-shadow:0 8px 25px #0005;color:#eadcf3;font-size:11px;line-height:1.5;pointer-events:none;animation:tooltip-in .15s ease}.control-tooltip:after{content:'';position:absolute;bottom:-5px;left:50%;width:8px;height:8px;background:#352a3f;border-right:1px solid #d7c0eb50;border-bottom:1px solid #d7c0eb50;transform:rotate(45deg)}.expert-rules{text-align:left;padding:25px 0}.expert-rules>span{display:flex;align-items:center;gap:8px;font-size:8px;letter-spacing:1px;color:#edcf91}.expert-rules h3{font-size:20px;font-weight:450;margin:20px 0 12px}.expert-rules p{font-size:12px;line-height:1.9;color:var(--muted)}.expert-rules small{display:block;font-size:10px;line-height:1.7;color:#edcf91;margin-top:20px}.expert-game .number-pad button:after{display:none}.number-exhausted{visibility:hidden}.expert-game .story-tip{visibility:hidden}
/* Short, non-flashing result effects. */
.celebration{position:absolute;inset:0;overflow:hidden;border-radius:inherit;pointer-events:none;z-index:2}.celebration i{position:absolute;top:-12px;left:var(--x);width:6px;height:12px;border-radius:2px;background:var(--color);opacity:0;animation:confetti-fall 2.6s var(--delay) ease-out both}.outcome-won{border-color:#8bdcb470;box-shadow:0 0 100px #8bdcb415}.outcome-won>.dialog-symbol{color:#a7e9c4;border-color:#a7e9c460;background:#a7e9c410;animation:success-bloom .7s ease both}.outcome-lost{border-color:#ed9ba970;animation:failure-settle .55s ease both}.outcome-lost>.dialog-symbol{color:#ed9ba9;border-color:#ed9ba955;background:#ed9ba910}.outcome-lost h2 em{color:#edb0bb}@keyframes confetti-fall{0%{opacity:0;transform:translateY(-10px) rotate(0)}10%{opacity:1}100%{opacity:0;transform:translateY(580px) rotate(var(--turn))}}@keyframes success-bloom{0%{transform:scale(.7);box-shadow:0 0 0 0 #a7e9c460}65%{transform:scale(1.08);box-shadow:0 0 0 22px #a7e9c400}100%{transform:scale(1)}}@keyframes failure-settle{0%{opacity:0;transform:translateY(-8px)}40%{transform:translateX(-5px)}65%{transform:translateX(4px)}100%{opacity:1;transform:none}}@keyframes tooltip-in{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}
@media(min-width:621px) and (max-height:800px){.play-controls{gap:9px}.control-heading{display:none}.number-pad button{min-height:58px}.mode-switch button{padding:8px 4px}.tool-grid button{min-height:53px}.tool-grid .tool-icon{width:30px;height:30px}.levels-screen{gap:14px;padding:16px 0}.levels-heading h1{font-size:33px}.levels-collection{gap:12px}.chapter-heading h2{font-size:21px}.level-launch{padding:12px 16px}.level-back{padding:8px 12px;gap:3px}.level-back dl{gap:3px}.level-back dl>div{font-size:9px}}
@media(max-width:850px){.levels-heading{flex-direction:row;align-items:center}.difficulty-tabs{width:auto;max-width:none}.difficulty-tabs button{padding:9px 10px;font-size:10px}.difficulty-bars{display:none}.chapter-grid{gap:10px}.level-launch{padding:12px}.level-stats{right:7px;bottom:8px;width:24px;height:24px}.level-launch .level-state{font-size:8px}.level-back{padding:9px}.level-back dl>div{font-size:8px}.level-back dl{gap:4px}.stats-top{font-size:7px}.game-screen{--board-size:min(calc(100vw - 292px),calc(100dvh - 265px),480px)}}
@media(max-width:620px){.app-shell{padding:0 20px;grid-template-rows:60px minmax(0,1fr) 28px}.site-header{height:60px}.brand{font-size:20px}.brand-mark{display:none}.levels-screen{padding:10px 0 12px;gap:12px;grid-template-rows:28px auto minmax(0,1fr)}.levels-heading{display:flex;flex-direction:column;align-items:stretch;gap:10px}.levels-heading h1{font-size:29px;margin-bottom:5px}.levels-heading p{font-size:10px;max-width:none}.difficulty-tabs{width:100%}.difficulty-tabs button{font-size:10px;padding:8px 4px}.levels-collection{gap:10px;grid-template-rows:auto auto minmax(0,1fr) auto}.chapter-heading h2{font-size:18px;margin-top:5px}.chapter-heading .eyebrow{font-size:6px;letter-spacing:1px}.library-progress{min-width:90px;gap:4px}.library-progress strong{font-size:19px}.library-progress small{font-size:11px}.library-progress>span{font-size:5px;letter-spacing:.8px}.chapter-nav{gap:6px;padding:5px 7px;border-radius:9px}.chapter-nav label{display:none}.chapter-nav select{font-size:10px;width:auto;min-width:0;flex:1;padding:4px 0}.chapter-position{font-size:6px;white-space:nowrap}.chapter-nav .icon-button{min-width:25px;min-height:25px}.chapter-nav svg{width:13px;height:13px}.chapter-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(5,minmax(0,1fr));gap:6px;max-height:none}.level-front,.level-back{border-radius:10px}.level-launch{padding:7px 10px;display:grid;grid-template-columns:1fr auto;grid-template-rows:1fr 1fr;gap:2px 6px;align-items:center}.level-topline{font-size:5px;letter-spacing:1px;grid-row:1;grid-column:1}.level-topline svg{display:none}.level-launch>strong{grid-column:2;grid-row:1/-1;font-size:23px;margin-right:2px}.level-launch .level-state{font-size:8px;grid-row:2;grid-column:1}.level-state i{width:4px;height:4px}.level-front:after{left:10px;right:10px;height:1px}.level-stats{right:38px;bottom:9px;width:22px;height:22px;border-radius:6px}.level-stats svg{width:11px;height:11px}.level-back{padding:4px 8px;gap:2px}.stats-top{font-size:6px;line-height:1}.stats-top button{padding:0}.stats-top svg{width:10px;height:10px}.level-back dl{grid-template-columns:1fr 1fr;gap:2px 7px}.level-back dl>div{font-size:6px;gap:3px}.level-back dt{white-space:nowrap}.collection-footer{font-size:7px;padding-top:1px;display:block;line-height:1.5}.collection-footer>span{display:flex;gap:5px}.status-legend{font-size:7px;gap:12px;margin-top:6px}.status-legend>span:before{width:4px;height:4px}.game-screen{--board-size:min(calc(100vw - 40px),calc(100dvh - 385px),460px)}.play-controls{gap:6px;grid-template-columns:1fr}.mode-switch{padding:3px;border-radius:9px;gap:4px}.mode-switch button{font-size:10px;padding:6px;gap:6px}.mode-switch svg{width:13px;height:13px}.mode-switch b{font-size:6px;padding:2px 4px}.number-pad button{min-height:47px}.number-pad strong{font-size:20px}.tool-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:5px}.tool-grid button{min-height:45px;font-size:8px;gap:3px;padding:0}.tool-grid .tool-icon{width:27px;height:27px;border-radius:8px}.tool-grid svg{width:15px;height:15px}.tool-grid small{font-size:8px}.notes-indicator{font-size:6px;padding:2px 4px}.notes-indicator svg{width:9px;height:9px}.hint-marker{top:1px;right:2px;font-size:7px}.cell{font-size:clamp(16px,5vw,25px)}.cell-notes{font-size:7px}.game-title{margin-left:0}.control-tooltip{font-size:10px;max-width:190px}}
@media(max-width:620px) and (max-height:700px){.game-screen{--board-size:min(calc(100vw - 40px),calc(100dvh - 364px))}.levels-screen{gap:8px;padding:8px 0}.levels-heading h1{font-size:26px}.levels-heading p{display:none}.levels-heading{gap:8px}.levels-collection{gap:8px}.chapter-heading h2{font-size:16px}.library-progress>span{display:none}.chapter-grid{gap:5px}.level-launch>strong{font-size:21px}.level-launch{padding:5px 9px}.level-launch .level-state{font-size:7px}.level-stats{bottom:7px}.status-legend{margin-top:4px}.cell{font-size:18px}.cell-notes{font-size:6px}.board-toolbar{margin-bottom:6px}.notes-indicator svg{display:none}}
@media(min-width:621px) and (max-height:560px){.game-screen{--board-size:min(38vw,calc(100dvh - 195px))}.game-workspace{gap:22px}.play-controls{gap:7px}.number-pad button{min-height:42px}.mode-switch button{padding:5px}.tool-grid button{min-height:43px}.tool-grid .tool-icon{width:25px;height:25px}.tool-grid svg{width:14px;height:14px}.levels-screen{gap:7px;padding:7px 0;grid-template-rows:24px auto minmax(0,1fr)}.levels-heading h1{font-size:25px}.levels-heading p{display:none}.levels-collection{gap:6px;grid-template-rows:auto auto minmax(0,1fr) auto}.chapter-heading h2{display:none}.library-progress{flex-direction:row;align-items:center;gap:8px}.library-progress strong{font-size:15px}.library-progress>span{font-size:6px}.library-progress>i{display:none}.chapter-nav{padding:3px 8px}.chapter-nav .icon-button{min-height:22px;min-width:24px}.chapter-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:5px}.level-launch{padding:5px 10px;display:grid;grid-template-columns:1fr auto;grid-template-rows:1fr 1fr;gap:1px}.level-topline{font-size:5px;grid-column:1;grid-row:1}.level-topline svg{display:none}.level-launch>strong{font-size:21px;grid-column:2;grid-row:1/-1}.level-launch .level-state{font-size:7px}.level-stats{right:35px;bottom:7px;width:20px;height:20px}.level-back{padding:4px 8px;gap:1px}.stats-top{font-size:6px}.stats-top button{padding:0}.stats-top svg{width:9px;height:9px}.level-back dl{grid-template-columns:1fr 1fr;gap:2px 6px}.level-back dl>div{font-size:6px}.collection-footer{font-size:7px}.status-legend{font-size:7px}}
@media(prefers-reduced-motion:reduce){.celebration{display:none}.level-flipper,.control-tooltip,.outcome-won,.outcome-lost,.outcome-won>.dialog-symbol{animation:none;transition:none}}
.levels-collection{width:100%;max-width:1140px;margin:0 auto}.chapter-grid{width:100%}
@media(min-width:601px){.app-shell{padding:0 max(24px,calc((100vw - 1340px)/2));grid-template-rows:72px minmax(0,1fr) 40px}.site-header{height:72px}.brand{font-size:23px}}
@media(max-width:620px){.level-back dl>div{font-size:7px}.stats-top{font-size:7px}.level-back{padding:4px 7px}.level-back dl{column-gap:6px}}
.levels-collection{grid-template-columns:minmax(0,1fr);justify-content:stretch}.notes-mode .cell.selected.related,.notes-mode .cell.selected.matching{background:#31534f}
@media(max-width:620px){.level-card.flipped{z-index:5}.level-card.flipped .level-flipper{position:absolute;bottom:0;left:0;width:calc(200% + 6px);height:126px}.level-card.flipped:nth-child(even) .level-flipper{left:auto;right:0}.level-card.flipped .level-back{padding:13px 16px;gap:10px;background:#292630;box-shadow:0 12px 35px #0008}.level-card.flipped .stats-top{font-size:10px}.level-card.flipped .stats-top svg{width:16px;height:16px}.level-card.flipped .level-back dl{gap:12px 18px}.level-card.flipped .level-back dl>div{font-size:10px;display:grid;gap:4px}.level-card.flipped .level-back dd{font-size:13px}}
@media(max-width:620px){.level-card.flipped .level-flipper{height:142px}}
.chapter-label{font-size:10px;color:var(--muted)}.chapter-picker{position:relative;min-width:0}.chapter-trigger{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:9px 12px;background:#d7c0eb0b;border:1px solid #d7c0eb30;border-radius:9px;color:var(--accent);font-size:12px;min-width:215px;text-align:left}.chapter-trigger b{font-weight:600;color:#f0e1fb}.chapter-trigger>svg{width:14px;height:14px;transition:transform .2s}.chapter-trigger[aria-expanded=true]{background:#d7c0eb18;border-color:#d7c0eb75}.chapter-trigger[aria-expanded=true]>svg{transform:rotate(180deg)}.chapter-options{position:absolute;z-index:30;top:calc(100% + 8px);left:0;width:max(100%,260px);max-height:min(300px,42dvh);overflow:auto;padding:6px;border:1px solid #d7c0eb45;border-radius:13px;background:#28222f;box-shadow:0 14px 40px #0008;scrollbar-width:thin;scrollbar-color:#776486 #28222f;animation:panel-in .18s ease}.chapter-options button{display:flex;align-items:center;gap:12px;width:100%;padding:10px;border-radius:8px;background:transparent;text-align:left;border:1px solid transparent;color:var(--muted)}.chapter-options button:hover,.chapter-options button:focus-visible{background:#d7c0eb10;border-color:#d7c0eb30;outline:none}.chapter-options button[aria-selected=true]{background:#d7c0eb18;color:#edddf8;border-color:#d7c0eb35}.chapter-option-number{display:grid;place-items:center;width:30px;height:32px;border-radius:7px;background:#d7c0eb0d;color:var(--accent);font-size:11px}.chapter-options strong{font-size:11px;font-weight:500;display:block}.chapter-options small{font-size:10px;display:block;margin-top:4px;color:var(--muted)}.chapter-options svg{width:15px;height:15px;margin-left:auto}.level-play{display:flex;align-items:center;justify-content:center;gap:7px;border:1px solid color-mix(in srgb,var(--status) 40%,transparent);background:color-mix(in srgb,var(--status) 13%,transparent);color:var(--status);border-radius:8px;padding:8px 10px;font-size:10px;min-height:30px}.level-play svg{height:13px;width:13px}.level-play:hover{background:color-mix(in srgb,var(--status) 24%,transparent)}.level-card.flipped{z-index:5}.level-card.flipped .level-flipper{position:absolute;bottom:0;min-height:180px}.level-card.flipped .level-back{box-shadow:0 8px 24px #0005;background:#292630}.expert-briefing{text-align:left;border:1px solid #edcf9140;border-radius:12px;padding:15px 17px;margin:16px 0;background:linear-gradient(130deg,#edcf910c,#edcf9103)}.expert-briefing>div{display:flex;align-items:center;gap:7px;color:#edcf91;font-size:8px;letter-spacing:1px}.expert-briefing svg{height:14px;width:14px}.expert-briefing h3{font-size:14px;font-weight:500;color:#f2dcae;margin:10px 0}.expert-briefing ul{margin:0;padding-left:14px;color:#c1b3c7;font-size:10px;line-height:1.75}.expert-briefing li+li{margin-top:3px}.expert-briefing p{color:#d7bf91;font-size:9px;line-height:1.6;margin-top:10px}.ready-expert .dialog-orbit{display:none}.ready-expert .ready-details{margin:18px 0}.ready-expert>p{margin-bottom:12px}.ready-expert .ready-music{margin:12px 0}
@media(max-width:620px){.chapter-label{display:none}.chapter-picker{flex:1}.chapter-trigger{min-width:0;width:100%;font-size:10px;padding:6px 8px;gap:6px}.chapter-options{width:max(100%,215px);max-height:38dvh;left:-20px}.chapter-options button{padding:8px;gap:9px}.chapter-options strong{font-size:10px}.chapter-options small{font-size:9px}.level-card.flipped .level-flipper{height:190px;min-height:190px}.level-card.flipped .level-back{gap:9px}.level-play{font-size:11px;min-height:32px}.expert-briefing{padding:12px 14px;margin:12px 0}.expert-briefing h3{font-size:12px}.expert-briefing ul{font-size:9px}.expert-briefing p{font-size:8px}}
@media(min-width:621px) and (max-height:560px){.chapter-trigger{font-size:10px;padding:4px 8px;min-width:190px}.chapter-options{max-height:40dvh}.level-card.flipped .level-flipper{min-height:140px}.level-card.flipped .level-back{padding:10px;gap:8px}.level-card.flipped .level-back dl{grid-template-columns:1fr}.level-card.flipped .level-back dl>div{font-size:9px}.level-play{font-size:9px;padding:6px}}
@media(prefers-reduced-motion:reduce){.chapter-options{animation:none}.chapter-trigger>svg{transition:none}}
/* Account dialog and save status stay inside the existing game shell. */
.auth-message{font-size:11px!important;line-height:1.6;overflow-wrap:anywhere}.login-button{max-width:min(290px,35vw)}.login-button>span:last-child{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.site-footer>span:nth-child(2){overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.auth-callback{max-width:520px;margin:15vh auto;padding:24px;text-align:center}.auth-callback h1{font-size:36px}.auth-callback p{margin:24px 0}.auth-callback a{color:#d7c0eb;text-decoration:underline}.level-card.lock-error{animation:locked-shake .48s ease}.level-card.lock-error .level-front{border-color:#eaa0b5;background:#492b3a}.level-card.lock-error .level-topline svg{animation:lock-rattle .48s ease}.level-launch[aria-disabled=true]{cursor:not-allowed}.level-launch[aria-disabled=true]:hover{background:transparent}
@keyframes locked-shake{0%,100%{transform:translateX(0)}20%,60%{transform:translateX(-5px)}40%,80%{transform:translateX(5px)}}@keyframes lock-rattle{25%,75%{transform:rotate(-13deg)}50%{transform:rotate(13deg)}}
@media(max-width:600px){.login-button{max-width:44vw}}
@media(prefers-reduced-motion:reduce){.level-card.lock-error,.level-card.lock-error .level-topline svg{animation:none}.level-flipper{transition:none}}
/* Google-only sign-in and a compact player profile. */
#modal.signin-dialog,#modal.account-dialog{padding:32px;background:radial-gradient(ellipse at 50% 0,#aeb4cb13,transparent 60%),#211e27;border-color:#ffffff26;text-align:left}#modal.signin-dialog h2{margin:12px 0 14px;font-size:36px;line-height:1.12}#modal.signin-dialog>p{font-size:12px;line-height:1.8;color:#bcb3c5}.signin-art{display:flex;align-items:center;justify-content:center;position:relative;height:104px;margin:0 0 22px}.signin-art>div{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;transform:rotate(-9deg);padding:8px;border:1px solid #ffffff25;border-radius:14px;background:#ffffff05;box-shadow:0 12px 35px #0003}.signin-art>div span{display:grid;place-items:center;width:25px;height:25px;border-radius:5px;background:#ffffff07;color:#dfd9e7;font-size:12px}.signin-art>span{margin-left:-10px;align-self:flex-end;z-index:1;width:38px;height:38px;display:grid;place-items:center;border-radius:12px;background:#e9e8ee;color:#35303c;border:4px solid #211e27}.signin-benefits{display:grid;gap:12px;margin:22px 0;color:#d4cbdc;font-size:11px}.signin-benefits>span{display:flex;align-items:center;gap:10px}.signin-benefits svg{width:15px;height:15px;color:#b7cdbd}.google-button{width:100%;height:44px;display:flex;justify-content:center;align-items:center;gap:12px;background:#fff!important;color:#1f1f1f!important;border:1px solid #747775;border-radius:8px;padding:0 12px;font:500 14px/20px Arial,sans-serif;transition:box-shadow .2s,background .2s}.google-button:hover{background:#f7f8f8!important;box-shadow:0 2px 8px #0003}.google-button img{flex-shrink:0;object-fit:contain}.auth-caption{font-size:9px!important;text-align:center;margin:12px 0!important}.guest-button,.account-signout{width:100%;background:none;border:0;border-top:1px solid #ffffff14;border-radius:0;padding:16px 0 0;color:#b8adbf;font-size:11px}.signin-dialog .auth-message:empty,.account-dialog #auth-message:empty{display:none}.signin-dialog .auth-message{font-size:11px!important;color:#e1c9c9!important;margin:12px 0}.account-heading{display:flex;align-items:center;justify-content:space-between;padding-right:28px;gap:12px}.account-connected{font-size:9px;color:#afd4be;display:flex;align-items:center;gap:5px}.account-connected svg{width:12px;height:12px}.profile-identity{display:flex;align-items:center;gap:16px;margin:30px 0}.profile-avatar{width:58px;height:58px;flex-shrink:0;border-radius:18px;background:linear-gradient(135deg,#e7e5eb,#acb4c2);color:#33313a;font-size:20px;display:grid;place-items:center;box-shadow:inset 0 1px #fff7}.profile-identity>div:last-child{min-width:0}.profile-identity h2{font-size:23px!important;letter-spacing:-.6px;margin:0 0 7px!important;overflow-wrap:anywhere}.profile-identity p{font-size:11px;color:#aaa0b6;overflow-wrap:anywhere;margin:0}.account-metrics{display:grid;grid-template-columns:1fr 1fr;border:1px solid #ffffff18;border-radius:12px;background:#ffffff03}.account-metrics>div{display:flex;flex-direction:column;gap:7px;padding:18px}.account-metrics>div+div{border-left:1px solid #ffffff18}.account-metrics strong{font-size:28px;font-weight:450;color:#e7dfed}.account-metrics span{font-size:10px;color:#aaa0b6}.sync-card{display:flex;align-items:center;gap:12px;margin:20px 0 24px}.sync-card>svg{width:19px;color:#a9c5b4;flex-shrink:0}.sync-card strong{font-size:11px;font-weight:500;color:#d3c9dd}.sync-card p{font-size:10px;line-height:1.6;color:#a9a0b5;margin:5px 0 0}.account-primary{display:flex;align-items:center;justify-content:center;gap:12px;width:100%;padding:13px;border:1px solid #fff4;border-radius:10px;background:#eceaf0;color:#29262f;font-size:12px}.account-primary svg{width:14px}.account-signout{margin-top:20px}.setting-select{display:flex;align-items:center;justify-content:space-between;gap:20px;min-width:130px;max-width:48%;padding:10px 12px;border:1px solid #d7c0eb35;border-radius:9px;background:#ffffff06;color:#e7d8f0;font-size:11px;text-align:left}.setting-select:after{content:'';width:6px;height:6px;border-bottom:1px solid #cbb3e3;border-right:1px solid #cbb3e3;transform:rotate(45deg);margin-top:-3px;flex-shrink:0}.setting-select[aria-expanded=true]{background:#d7c0eb15;border-color:#cbb3e380}.setting-select[aria-expanded=true]:after{transform:rotate(225deg);margin-top:3px}.setting-options{position:fixed;inset:auto;margin:0;padding:6px;border:1px solid #bda8cf55;border-radius:12px;background:#2c2633;color:#e7d9f1;box-shadow:0 18px 50px #0007;overflow:auto;scrollbar-width:thin}.setting-options:popover-open{animation:panel-in .16s ease}.setting-options button{position:relative;display:block;width:100%;padding:10px 30px 10px 10px;border:0;border-radius:7px;background:none;color:#c5b8cf;font-size:11px;text-align:left}.setting-options button:hover,.setting-options button[data-active=true]{background:#d7c0eb14}.setting-options button[aria-selected=true]{background:#d7c0eb20;color:#f0e1fa}.setting-options button[aria-selected=true]:after{content:'\2713';position:absolute;right:10px;color:#d7c0eb}.setting-options button:focus-visible{outline:1px solid #d7c0eb}.setting-row select[hidden]{display:none}.shortcut-row{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:7px 0;font-size:10px}.shortcut-row>span:first-child{display:flex;align-items:center;gap:4px}.shortcut-row kbd{display:inline-grid;place-items:center;min-width:22px;padding:4px 6px;border:1px solid #d7c0eb3a;border-bottom-width:3px;border-radius:5px;background:linear-gradient(#ffffff09,#ffffff02);color:#e4d7ed;font:10px/1.1 Arial,sans-serif;box-shadow:0 2px 3px #0002}.key-or{font-size:9px;color:#94869f}.chapter-options{background:#2c2633;border-color:#bda8cf55;box-shadow:0 18px 50px #0007}
@media(max-width:600px){#modal.signin-dialog,#modal.account-dialog{padding:26px 24px}.signin-art{height:88px;margin-bottom:18px}.profile-identity{gap:12px}.profile-identity h2{font-size:20px!important}.profile-avatar{width:48px;height:48px;border-radius:14px}.account-heading{gap:7px}.account-heading .eyebrow{font-size:6px}.setting-select{min-width:110px;padding:9px 10px;font-size:10px}.shortcut-row{gap:8px;font-size:9px}.shortcut-row kbd{font-size:9px;min-width:18px;padding:4px}}
@media(prefers-reduced-motion:reduce){.setting-options:popover-open{animation:none}.google-button{transition:none}}
