:root{--S:#315c80;--T:#96c23d;--E:#f6c331;--M:#ef3434;--ink:#173044;--paper:#fffaf0}*{box-sizing:border-box}body{margin:0;font-family:system-ui,Segoe UI,sans-serif;background:radial-gradient(circle at top,#fff8df,#ead8b0);color:var(--ink);min-height:100vh}main{max-width:1300px;margin:auto;padding:24px}.card{background:#fffdf8;border-radius:24px;padding:32px;text-align:center;box-shadow:0 15px 50px #5b3a1830}h1{font-family:Georgia,serif;letter-spacing:.04em;font-size:clamp(2rem,5vw,4rem);margin:.2em}.lead{font-size:1.4rem}.teams{display:flex;justify-content:center;gap:18px;flex-wrap:wrap;margin:30px}.teams button,.badge,.stemlogo b{border:0;color:white;font-weight:800;border-radius:18px}.teams button{width:140px;height:140px;font-size:76px;cursor:pointer;box-shadow:0 8px 18px #0002}.S{background:var(--S)!important}.T{background:var(--T)!important}.E{background:var(--E)!important}.M{background:var(--M)!important}.teacher{color:#555}.hidden{display:none!important}header{display:flex;align-items:center;gap:18px;background:#fffdf8;padding:15px 22px;border-radius:20px;margin-bottom:18px}.badge{width:75px;height:75px;display:grid;place-items:center;font-size:45px}header h2{margin:0}#timer{margin-left:auto;font-size:2.3rem;font-variant-numeric:tabular-nums;font-weight:800}.gamegrid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.tray,.board{min-height:520px;background:#ffffffb8;border-radius:18px;padding:12px}.tray{display:grid;grid-template-columns:repeat(6,1fr);grid-auto-rows:110px;gap:6px}.piece{background-size:600% 400%;border-radius:5px;cursor:grab;box-shadow:0 2px 7px #0003}.board{display:grid;grid-template-columns:repeat(6,1fr);grid-template-rows:repeat(4,1fr);gap:2px;padding:0;overflow:hidden;aspect-ratio:3/2;min-height:0}.slot{border:1px dashed #315c8055;background:#fff8}.slot .piece{width:100%;height:100%;border-radius:0;box-shadow:none}.modal{position:fixed;inset:0;background:#0009;display:grid;place-items:center;padding:20px}.modalbox{background:white;padding:30px;border-radius:22px;max-width:520px;width:100%;text-align:center}.modal input{width:100%;padding:14px;font-size:18px;margin:12px 0}.modal button{padding:12px 25px}.mosaic{position:relative;display:grid;grid-template-columns:1fr 1fr;max-width:900px;margin:25px auto;overflow:hidden;border-radius:22px;box-shadow:0 12px 35px #0003}.mosaic img{width:100%;display:block}.stemlogo{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);display:grid;grid-template-columns:1fr 1fr;gap:4px;background:white;padding:7px;border-radius:14px;box-shadow:0 5px 25px #0007}.stemlogo b{width:70px;height:70px;display:grid;place-items:center;font-size:45px;border-radius:9px}#ranking{max-width:600px;margin:20px auto;text-align:left;font-size:1.25rem}.rank{background:white;margin:8px;padding:12px 18px;border-radius:12px}@media(max-width:800px){.gamegrid{grid-template-columns:1fr}.tray{grid-auto-rows:75px}header{align-items:flex-start;flex-wrap:wrap}#timer{font-size:1.7rem}}
