@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Space+Grotesk:wght@400;500;600;700&display=swap');
:root{--bg:#070d20;--panel:#101c36;--panel2:#0a152e;--cyan:#27ebf0;--pink:#fb4eca;--yellow:#ffdf53;--green:#76f993;--muted:#afbed8;--border:#26365e;--white:#f4f8ff}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--white);font:16px 'Space Grotesk',system-ui,sans-serif;min-height:100vh;background-image:radial-gradient(circle at 80% 10%,#2d1456 0,transparent 28%),linear-gradient(#17235133 1px,transparent 1px),linear-gradient(90deg,#17235133 1px,transparent 1px);background-size:auto,52px 52px,52px 52px}.scanlines{pointer-events:none;position:fixed;inset:0;z-index:40;opacity:.1;background:repeating-linear-gradient(to bottom,transparent 0px,transparent 3px,#000 4px,#000 5px)}button,a,input{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:not-allowed}a{color:inherit;text-decoration:none}.topbar{max-width:1320px;padding:16px 25px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:20px;border-bottom:2px solid #2f3682}.brand,.pixel,h1,h2,h3,.btn,.nav,.tag,.digit{font-family:'Press Start 2P',monospace}.brand{font-size:16px;color:var(--cyan);white-space:nowrap;text-shadow:3px 3px #123147}.brand em{font-style:normal;color:var(--pink)}.alien{color:var(--pink);font-size:22px;margin-right:9px}.topbar nav{display:flex;gap:6px;flex-wrap:wrap}.nav,.icon-btn{border:1px solid transparent;background:none;color:#d7e0f0;padding:12px 13px;font-size:10px}.nav:hover,.nav.active{color:var(--cyan);border-color:var(--cyan);background:#102945}.icon-btn{font-size:21px}main{max-width:1320px;margin:auto;padding:25px}.hero{display:grid;grid-template-columns:1fr 1fr;align-items:center;min-height:350px;border:2px solid #314380;background:radial-gradient(circle at 75% 30%,#32205d 0%,#101c36 35%,#0a142a 78%);box-shadow:8px 8px 0 #040815;padding:40px 50px;position:relative;overflow:hidden}.hero:before{content:'';position:absolute;inset:0;background:repeating-linear-gradient(90deg,transparent 0,transparent 69px,#ffffff06 70px)}.hero>*{position:relative}.eyebrow{color:var(--green);font:10px 'Press Start 2P';line-height:2}.hero h1{font-size:clamp(26px,5vw,65px);line-height:1.3;margin:12px 0 8px;letter-spacing:-3px;color:var(--cyan);text-shadow:5px 5px #174481}.hero h1 span{color:var(--pink);text-shadow:5px 5px #74255e}.hero h2{font:700 22px 'Space Grotesk';margin:0 0 12px}.hero p{max-width:450px;color:var(--muted);line-height:1.6}.hero-graphic{height:280px;position:relative;display:grid;place-items:center}.pixel-sun{position:absolute;width:240px;height:240px;background:linear-gradient(#ffce59,#fd4caa);border-radius:50%;filter:drop-shadow(0 0 35px #f5447377);top:3px;right:15%;clip-path:polygon(0 0,100% 0,100% 60%,0 60%,0 65%,100% 65%,100% 70%,0 70%,0 75%,100% 75%,100% 80%,0 80%,0 86%,100% 86%,100% 94%,0 94%)}.computer{z-index:1;width:245px;background:#8a8ca5;border:12px ridge #aeb5ca;transform:rotate(-3deg);box-shadow:18px 18px 0 #090d20}.screen{height:160px;background:#030c1b;border:9px solid #394963;display:flex;flex-direction:column;align-items:center;justify-content:center;color:var(--green);gap:16px;text-shadow:0 0 10px #4fff80;font:11px 'Press Start 2P'}.screen b{color:var(--cyan);font-size:15px}.keyboard{height:32px;background:repeating-linear-gradient(90deg,#20263a 0,#20263a 13px,#7a8091 14px,#b5bcc9 16px);border:7px solid #949aaf;transform:perspective(70px) rotateX(12deg) translate(8px,1px)}.section-head{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:34px 0 18px}.section-head h2{font-size:19px;color:var(--cyan);margin:0;line-height:1.5}.section-head span{color:var(--muted);font-size:13px}.game-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px}.game-card,.panel{border:2px solid var(--border);background:linear-gradient(160deg,#12213f,#09152a);padding:20px;box-shadow:5px 5px 0 #030711}.game-card:nth-child(1){border-color:#286dcd}.game-card:nth-child(2){border-color:#bd3bb3}.game-card:nth-child(3){border-color:#24a99d}.game-card:nth-child(4){border-color:#b2aa4f}.game-art{height:145px;display:grid;place-items:center;background:#081329;border:1px solid #243c60;margin-bottom:18px;overflow:hidden}.tile-icon{font:25px 'Press Start 2P';color:var(--cyan);text-align:center;line-height:1.9}.art2048{display:grid;grid-template-columns:repeat(2,52px);gap:5px}.art2048 b{font:16px 'Press Start 2P';background:#f8b657;color:#17142c;padding:18px 8px;text-align:center}.art2048 b:last-child{background:#fa6477}.mine-art,.lock-art{font-size:70px;filter:drop-shadow(5px 5px #192b48)}.game-card h3{font:17px 'Press Start 2P';line-height:1.6;margin:0}.game-card p{color:var(--muted);min-height:49px;font-size:14px}.difficulty-small{display:flex;gap:5px;margin:14px 0}.difficulty-small i{width:20px;height:10px;background:#334664}.difficulty-small i.filled{background:var(--green)}.btn{display:inline-flex;align-items:center;justify-content:center;gap:12px;border:2px solid #030c17;outline:2px solid var(--cyan);background:var(--cyan);color:#07182a;font-size:11px;line-height:1.6;padding:12px 16px;text-align:center;min-height:42px}.btn:hover{filter:brightness(1.13);transform:translateY(-2px)}.btn.yellow{background:var(--yellow);outline-color:var(--yellow)}.btn.ghost{background:#12253e;color:var(--cyan);outline-color:#326083}.btn.small{font-size:9px;padding:8px 11px;min-height:36px}.full{width:100%}.lower{display:grid;grid-template-columns:1fr 1fr;gap:20px;margin-top:26px}.panel h3{font-size:13px;line-height:1.7;color:var(--yellow);margin:0 0 17px}.panel p{color:var(--muted)}.stat{display:flex;justify-content:space-between;border-top:1px solid #334467;padding:11px 0}.stat strong{color:var(--cyan)}.footer{max-width:1320px;margin:40px auto 0;border-top:2px solid #253774;padding:20px 25px 30px;display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;color:#90a5ca;font-size:11px}.game-layout{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:24px;align-items:start}.game-panel{padding:22px;min-height:560px}.game-panel h2{font-size:19px;color:var(--cyan);line-height:1.6;margin:0 0 15px}.toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:10px 0 22px}.toolbar label,.label{font-size:13px;color:var(--muted)}select{padding:11px;background:#111e38;border:2px solid #3a5780;color:white;font:14px 'Space Grotesk'}.help{line-height:1.65;font-size:13px;color:var(--muted)}.message{min-height:22px;color:var(--yellow);font-weight:700;margin:12px 0}.game-area{margin:14px auto;display:flex;justify-content:center;align-items:center;min-height:320px}.sudoku{display:grid;grid-template-columns:repeat(9,minmax(0,1fr));width:min(100%,450px);aspect-ratio:1;border:3px solid #67e5f2;background:#202b4f}.sudoku button{font:clamp(11px,2.8vw,23px) 'Space Grotesk';font-weight:700;min-width:0;padding:0;border:1px solid #51617f;background:#111e35;color:white;aspect-ratio:1}.sudoku button.fixed{background:#24385e;color:#a7ddef}.sudoku button.selected{background:#2b687c}.sudoku button.error{color:#ff8b90}.sudoku button.hint{color:var(--green)}.sudoku button:nth-child(3n){border-right:2px solid var(--cyan)}.sudoku button:nth-child(n+19):nth-child(-n+27),.sudoku button:nth-child(n+46):nth-child(-n+54){border-bottom:2px solid var(--cyan)}.numpad{display:flex;gap:6px;justify-content:center;flex-wrap:wrap;margin-top:18px}.numpad button{min-width:39px;background:#182b4a;border:1px solid #496c8e;color:white;padding:11px;font-weight:700}.grid2048{display:grid;grid-template-columns:repeat(4,1fr);gap:9px;background:#1c2b4e;padding:10px;width:min(100%,410px);aspect-ratio:1;touch-action:none}.grid2048>div{display:grid;place-items:center;font-size:clamp(17px,4vw,30px);font-weight:700;color:#0b1530;background:#2d3d5c;border-radius:3px}.grid2048>div.empty{background:#101e3a}.grid2048>div.tile2{background:#e7e9b8}.grid2048>div.tile4{background:#f6cc7e}.grid2048>div.tile8{background:#fbb375}.grid2048>div.tile16{background:#fd9574}.grid2048>div.tile32{background:#fd737f}.grid2048>div.tile64{background:#fb58b7}.grid2048>div.tile128,.grid2048>div.tile256,.grid2048>div.tile512,.grid2048>div.tile1024,.grid2048>div.tile2048,.grid2048>div.tile4096{background:#55e9e1;font-size:22px}.dpad{display:grid;grid-template-columns:repeat(3,44px);gap:6px;justify-content:center;margin:15px}.dpad button{background:#182d4b;color:var(--cyan);border:1px solid #418ca4;min-height:40px}.mine-grid{display:grid;gap:2px;max-width:100%;overflow:auto;justify-content:center}.mine-grid button{width:var(--cell);height:var(--cell);border:1px solid #577394;background:#27466b;color:white;padding:0;font-weight:800;font-size:clamp(11px,2vw,18px)}.mine-grid button.revealed{background:#101c35}.mine-grid button.flagged{color:var(--yellow)}.mine-grid button.exploded{background:#8f294d}.code-row{display:flex;gap:10px;align-items:center;justify-content:center;margin:9px 0}.peg{height:32px;width:32px;border-radius:50%;border:2px solid #93a0b9;background:#283952}.peg.smallpeg{height:12px;width:12px;border:0}.peg.color0{background:#fb6076}.peg.color1{background:#ffce49}.peg.color2{background:#53e4b5}.peg.color3{background:#66a7ff}.peg.color4{background:#b28bff}.peg.color5{background:#ff93e6}.peg.color6{background:#fafafa}.peg.color7{background:#ff9b45}.feedback{display:grid;grid-template-columns:repeat(2,12px);gap:3px;margin-left:12px}.feedback b{height:11px;width:11px;border-radius:50%;background:#283952}.feedback b.exact{background:#60e8b5}.feedback b.partial{background:#ffcd55}.code-picker{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin:20px auto}.code-picker button{width:37px;height:37px;border-radius:50%;border:3px solid #d1d8eb}.code-picker button.picked{outline:3px solid white}.code-guess{display:flex;justify-content:center;align-items:center;gap:8px}.code-guess button{width:40px;height:40px;border:2px solid #8fa0bf;background:#172740;border-radius:50%;color:white}.mini-box{padding:13px;background:#0b1730;border:1px solid #314967;margin:12px 0}.score-item{display:grid;grid-template-columns:1fr auto;gap:10px;border-bottom:1px solid #273756;padding:12px 0}.muted{color:var(--muted)}.daily-box{display:grid;gap:16px;padding:20px;border:1px solid #5972ac;background:#101f3c}.daily-large{font-size:50px;text-align:center}.pill{font-size:11px;color:#071323;background:var(--yellow);padding:5px 9px;display:inline-block}.back{border:0;background:none;color:var(--cyan);padding:0 0 17px;font-weight:700}.overview{max-width:900px;margin:auto}.notice{padding:12px 16px;background:#242449;border-left:4px solid var(--yellow);color:#e3dfbb;font-size:13px;line-height:1.6}@media(max-width:1000px){.game-grid{grid-template-columns:repeat(2,1fr)}.hero{grid-template-columns:1.1fr .9fr;padding:26px}.topbar{flex-wrap:wrap}.game-layout{grid-template-columns:1fr}.hero-graphic{transform:scale(.82)}}@media(max-width:650px){.topbar{padding:13px;gap:12px}.brand{font-size:12px}.topbar nav{width:100%;overflow:auto;flex-wrap:nowrap;order:3}.nav{font-size:8px;padding:10px 8px;white-space:nowrap}.icon-btn{margin-left:auto}main{padding:15px}.hero{grid-template-columns:1fr;padding:24px;min-height:0}.hero h1{font-size:33px}.hero-graphic{height:190px;transform:scale(.68);margin:-30px 0}.game-grid{grid-template-columns:1fr 1fr;gap:9px}.game-card{padding:11px}.game-art{height:95px}.game-card h3{font-size:10px}.game-card p{font-size:12px;min-height:65px}.btn{font-size:8px;padding:9px 5px}.lower{grid-template-columns:1fr}.section-head h2{font-size:14px}.section-head span{font-size:10px}.game-panel{padding:13px}.game-panel h2{font-size:14px}.footer{font-size:9px}.mine-grid button{width:var(--cell);height:var(--cell)}}


/* v1.2 — NIMM-inspired charcoal theme. The retro game controls keep their pixel accents. */
:root {
  --bg:#090c10;
  --panel:#151a20;
  --panel2:#0f141a;
  --border:#29333d;
  --muted:#aab4be;
  --white:#f1f3f4;
}
html { background:#090c10; }
body {
  background-color:#090c10;
  background-image:
    radial-gradient(ellipse 55% 40% at 80% -10%, rgba(88,101,119,.13), transparent 75%),
    radial-gradient(ellipse 45% 35% at 4% 45%, rgba(57,78,89,.09), transparent 80%),
    linear-gradient(180deg,#0b0f13 0%,#0a0e12 52%,#090c10 100%);
  background-size: auto;
  background-attachment: fixed;
}
/* Avoid a prominent arcade grid across the page; restrict playful pixel textures to cards. */
.scanlines { opacity:.035; }
.topbar { border-bottom-color:#303943; }
.hero {
  background: radial-gradient(ellipse at 85% 10%,rgba(81,101,123,.20), transparent 60%),
              linear-gradient(120deg,#151b22,#0e141a 80%);
  border-color:#34404a;
  box-shadow:8px 8px 0 #050709;
}
.hero:before { opacity:.18; }
.game-card,.panel {
  background:linear-gradient(155deg,#1a2028,#10151b 88%);
  box-shadow:5px 5px 0 #050709;
}
.game-art {background:#10151c;border-color:#303d49;}
.footer {border-top-color:#303943;color:#a1acb6;}
.daily-box,.mini-box {background:#141b22;border-color:#344451;}
.notice {background:#24251e;}

/* Solitaire expansion */
.solitaire-page{overflow-x:auto;min-height:640px}
.solitaire-page h2{font-size:18px;color:var(--cyan);line-height:1.7}
.sol-toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin:18px 0}
.sol-top{display:flex;align-items:flex-start;justify-content:space-between;gap:22px;margin:20px 0 28px;min-width:580px}
.sol-group{display:flex;gap:9px}
.sol-single,.sol-column,.sol-slot{width:83px;min-height:113px;border:2px dashed #42545e;border-radius:5px;cursor:pointer}
.sol-single{display:grid;place-items:center}
.sol-tableau{display:flex;gap:8px;align-items:flex-start;min-width:max-content;min-height:430px;padding-bottom:25px}
.sol-column{position:relative;min-height:360px;border-color:#26343e;background:#101719}
.sol-column.sol-selected{box-shadow:0 0 0 2px var(--yellow)}
.sol-card{position:relative;height:35px;cursor:pointer}
.sol-card:last-child{height:113px}
.card-face,.card-back{display:flex;flex-direction:column;justify-content:space-between;width:81px;height:112px;border-radius:4px;padding:8px;background:#f2f1e7;color:#18212b;border:2px solid #aab1b6;font-weight:800}
.card-face.red{color:#b32943}.card-face span{font-size:31px;align-self:center}.card-face b{font-size:18px}
.card-back{color:#7ff0e2;justify-content:center;text-align:center;font:10px monospace;background:repeating-linear-gradient(45deg,#17374c,#17374c 5px,#1e4d55 5px,#1e4d55 10px)}
.empty-pile{font-size:28px;color:#748996;display:grid;place-items:center;min-height:108px}
.sol-icon{font-size:35px;color:#e8d8af;letter-spacing:4px}
@media(max-width:700px){.solitaire-page{margin:0 -10px;padding:12px}.sol-top{transform-origin:left top}.sol-single,.sol-column,.sol-slot{width:56px;min-height:78px}.sol-card{height:24px}.sol-card:last-child{height:78px}.card-face,.card-back{width:54px;height:77px;padding:3px}.card-face span{font-size:23px}.card-face b{font-size:13px}.sol-tableau{gap:4px;min-height:300px}.sol-group{gap:3px}.sol-top{min-width:450px}.sol-icon{font-size:20px}}

/* Logic expansion */
.logic-page{min-height:600px}.logic-page h2{font-size:18px;line-height:1.8;color:var(--cyan)}
.nono-layout{display:grid;grid-template-columns:75px auto;grid-template-rows:100px auto;max-width:620px;margin:20px auto}
.nono-cols{display:grid;grid-template-columns:repeat(var(--n),1fr);align-items:end}
.nono-cols>div{display:flex;flex-direction:column;align-items:center;justify-content:end;gap:1px;height:100%;font-size:12px;color:var(--yellow)}
.nono-rows{display:grid;grid-template-rows:repeat(var(--n),1fr);font-size:12px;color:var(--yellow)}
.nono-rows>div{display:flex;align-items:center;justify-content:end;padding-right:8px;white-space:nowrap}
.nono-grid{display:grid;grid-template-columns:repeat(var(--n),minmax(0,1fr));border:2px solid var(--cyan);width:100%;aspect-ratio:1}
.nono-grid button{border:1px solid #3c5965;background:#151e27;min-width:0;padding:0;color:var(--pink);font-size:18px}
.nono-grid button.filled{background:var(--cyan)}.nono-grid button.cross{background:#29313d}
.soko-grid{display:grid;margin:22px auto;gap:2px;width:100%}.soko-cell{aspect-ratio:1;background:#202f35;display:grid;place-items:center;color:var(--yellow);font-size:clamp(12px,3vw,32px);font-weight:800}.soko-cell.wall{background:#4b5966;border:2px solid #687985}.soko-cell.goal{background:#365c4d;color:#a7ff9c}.soko-pad{display:grid;grid-template-columns:repeat(3,50px);gap:5px;justify-content:center;margin:18px}.soko-pad button{padding:12px 0;background:#22394a;border:1px solid var(--cyan);color:var(--cyan)}
@media(max-width:650px){.nono-layout{grid-template-columns:55px auto;grid-template-rows:86px auto}.nono-cols>div,.nono-rows{font-size:9px}.logic-page{padding:12px}.nono-grid button{font-size:12px}}

/* Game instructions */
.help-card-btn{margin-top:12px;font-size:9px}
.howto-overlay{position:fixed;inset:0;z-index:100;background:#030507df;display:flex;align-items:center;justify-content:center;padding:16px;overflow:auto}
.howto-dialog{background:#151b21;border:2px solid var(--cyan);box-shadow:8px 8px #05080b;color:#f2f6f8;padding:25px;max-width:610px;max-height:90vh;overflow:auto;width:100%;position:relative}
.howto-dialog h2{font:16px/1.6 'Press Start 2P',monospace;color:var(--cyan);margin:12px 0 26px}
.howto-dialog h3{font:10px/1.6 'Press Start 2P',monospace;color:var(--yellow);margin:18px 0 9px}
.howto-dialog p,.howto-dialog li{line-height:1.6;font-size:15px}
.howto-dialog li{margin:9px 0}.howto-steps{padding-left:25px}.howto-kicker{font-size:10px!important;color:var(--green)}
.howto-close{position:absolute;right:13px;top:10px;background:transparent;border:1px solid #536270;color:#fff;padding:8px 12px}
.howto-tip{background:#212c31;border-left:3px solid var(--green);padding:12px 16px;margin:20px 0}
.howto-tip strong{color:var(--green);font-size:12px}.howto-tip p{margin:8px 0 0}
.howto-float:not([hidden]){position:fixed;right:20px;bottom:18px;z-index:41;background:var(--yellow);color:#172027;border:2px solid #090c10;padding:12px 15px;font:9px 'Press Start 2P',monospace;box-shadow:3px 3px #121619;cursor:pointer}
@media(max-width:650px){.howto-dialog{padding:18px}.howto-dialog h2{font-size:12px}.howto-float:not([hidden]){right:10px;bottom:10px;font-size:8px;padding:10px}}
