@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;600;700&family=Noto+Sans+JP:wght@400;500;700;900&display=swap');
:root{--ink:#263c37;--green:#32775f;--cream:#f8f7ef;--line:#dfe6dc;--orange:#e88362}*{box-sizing:border-box}body{margin:0;background:var(--cream);color:var(--ink);font-family:'DM Sans','Noto Sans JP',sans-serif}button,input,select{font:inherit}button{cursor:pointer}header{height:88px;background:#fff;display:flex;align-items:center;padding:0 max(5vw,24px);gap:45px;border-bottom:1px solid #edf0e8}.brand{display:flex;align-items:center;gap:9px;color:var(--ink);text-decoration:none;font-size:18px;font-weight:900;line-height:1.15;white-space:nowrap}.brand-icon{font-size:36px;color:#eea07f}.brand-accent{color:var(--green)}.brand small{display:block;font:700 8px 'DM Sans';letter-spacing:.2em;margin-top:5px;color:#9aa99f}nav{display:flex;align-self:stretch;gap:24px;margin:auto}.nav{border:0;background:none;color:#8a9990;font-size:13px;font-weight:700;padding:0 8px;border-bottom:3px solid transparent}.nav.active{color:var(--green);border-color:var(--green)}.prototype,.pill{background:#f3f7ef;border:1px solid #dfeadb;border-radius:40px;padding:8px 14px;font-size:11px;font-weight:700;color:var(--green)}main{max-width:1200px;margin:auto;padding:0 28px}.view{display:none}.view.active{display:block}.hero{position:relative;display:grid;grid-template-columns:1fr 480px;align-items:center;gap:70px;min-height:515px;padding:52px 0 42px}.eyebrow{font-size:10px;letter-spacing:.2em;color:var(--green);font-weight:900;margin:0 0 18px}.hero h1{font-size:clamp(38px,4.3vw,61px);line-height:1.38;letter-spacing:.03em;margin:0;font-weight:900}.hero h1 em{font-style:normal;color:var(--green);position:relative}.lead{font-size:15px;line-height:2.1;color:#71827a;margin:22px 0}.actions{display:flex;gap:12px;flex-wrap:wrap}.primary,.secondary{border-radius:9px;padding:15px 22px;font-size:13px;font-weight:700;border:1px solid var(--green)}.primary{background:var(--green);color:white;box-shadow:0 5px 0 #245d4a}.primary:hover{background:#28674f}.primary span{margin-left:18px}.secondary{background:#fff;color:var(--green)}.note,.tiny{font-size:11px;color:#98a79e;line-height:1.7}.hero-art{background:#fff;border-radius:18px;padding:20px 22px;box-shadow:0 18px 50px #bbc8b850;transform:rotate(3deg);width:390px;justify-self:center}.art-label,.art-bottom,.canvas-top,.canvas-bottom{display:flex;justify-content:space-between;font-size:9px;font-weight:700;letter-spacing:.13em;color:#9aa99e}.art-label span{color:var(--orange);font-size:19px}.art-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;margin:15px 0}.art-grid div{aspect-ratio:1;background:#e9f2e8;border-radius:7px;display:grid;place-items:center;font-size:43px}.art-grid div:nth-child(2n){background:#f9e9db}.art-grid div:nth-child(3n){background:#fbf1cb}.art-grid .empty{background:#f5f6f0;color:#d6dfd5;font-size:25px}.art-bottom strong{color:var(--green)}.spark{position:absolute;color:#e6a083;font-size:28px}.s1{right:20px;top:80px}.s2{right:470px;bottom:60px}.section-heading{border-top:1px solid #dfe5da;padding-top:32px;display:flex;justify-content:space-between;align-items:end}.section-heading h2,.pagehead h1{margin:0;font-size:27px}.section-heading>p,.pagehead p:not(.eyebrow){font-size:12px;line-height:1.8;color:#86968d}.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin:26px 0 80px}.steps article{background:#fff;border:1px solid #edf0e8;border-radius:12px;padding:22px 24px;position:relative}.steps article>span{position:absolute;right:20px;top:20px;color:#d7e2d9;font-weight:700}.step-icon{width:44px;height:44px;border-radius:12px;display:grid;place-items:center;font-size:23px}.peach{background:#fae9df;color:#db8d72}.yellow{background:#fbf2d6;color:#c8a44b}.mint{background:#e4f1e8;color:#6aa486}.steps h3{font-size:15px;margin:18px 0 8px}.steps p{font-size:12px;color:#8b9b92;line-height:1.8;margin:0}.pagehead{padding:54px 0 30px;display:flex;align-items:center;justify-content:space-between}.workspace,.play-layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:28px;margin-bottom:70px}.canvas-wrap,.tools{background:#fff;border:1px solid #e7ece4;border-radius:14px;padding:22px;box-shadow:0 7px 25px #cdd6c629}.canvas-top,.canvas-bottom{padding:0 3px 13px}.canvas-bottom{padding:15px 3px 0;letter-spacing:0;font-size:11px;color:#7d9a89}.canvas-bottom span{color:#b4c0b5}canvas{display:block;width:100%;aspect-ratio:1;max-height:650px;border:1px solid #edf0e8;border-radius:7px;touch-action:none;background:#fff;cursor:crosshair}.tools{padding:26px}.tool-title{display:flex;justify-content:space-between;align-items:start}.tool-title>span{font-size:30px;color:#e6a081}.tools h2{margin:0 0 24px;font-size:19px}.tools label{display:block;font-size:12px;font-weight:700;margin:22px 0 10px}.segmented{display:flex;gap:6px}.segmented button,.edit-actions button{flex:1;border:1px solid #e1e9e0;background:white;border-radius:7px;padding:10px 4px;font-size:11px;color:#71857a}.segmented .selected{background:#e9f3eb;border-color:#82ad91;color:#287054;font-weight:700}.colors{display:flex;gap:9px;flex-wrap:wrap}.color{width:29px;height:29px;border:3px solid white;border-radius:50%;box-shadow:0 0 0 1px #d8e0d8}.color.selected{box-shadow:0 0 0 2px var(--green)}.edit-actions{display:flex;gap:6px;margin-top:22px}.tools hr{border:0;border-top:1px solid #edf0e8;margin:24px 0}.tools select,.tools input{width:100%;border:1px solid #dfe7dd;background:#fbfcf9;border-radius:7px;padding:12px;color:var(--ink);font-size:13px}.wide{width:100%;margin-top:20px}.text-button{display:block;margin:17px auto 0;border:0;background:none;color:var(--green);font-size:12px;font-weight:700}.tools .tiny{text-align:center}.stats{display:flex;gap:35px;align-items:center;font-size:10px;color:#9aa99e;letter-spacing:.1em;margin-bottom:15px}.stats strong{font-size:20px;color:var(--ink);margin-left:8px}.board{display:grid;gap:4px;background:#e4ece2;border-radius:12px;padding:8px;aspect-ratio:1;max-width:650px}.tile{border:0;border-radius:5px;background-repeat:no-repeat;transition:transform .12s}.tile:hover{filter:brightness(.93)}.tile.empty{background:#f5f8f2;cursor:default}.hint-frame{aspect-ratio:1;position:relative;background:#eef5ed;border-radius:8px;overflow:hidden}.hint-frame img{width:100%;height:100%;object-fit:contain}.hint-frame span{position:absolute;inset:0;display:grid;place-items:center;background:#edf5ec;color:#9bbda5;font-size:60px}.play-tools>p:not(.eyebrow){font-size:12px;line-height:1.8;color:#8a9b91}#success{background:#f4f8ed;border-radius:10px;padding:16px;margin-top:20px}#success h3{color:var(--green);margin:0}#success p{font-size:12px}.gallery{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin-bottom:80px}.card{background:white;border-radius:12px;padding:14px;border:1px solid #e7ece4}.card img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:7px}.card h3{font-size:15px}.card button{margin-right:8px}.empty-gallery{grid-column:1/-1;text-align:center;padding:80px;color:#8a9b91;background:white;border-radius:12px}footer{border-top:1px solid #e2e9df;display:flex;justify-content:space-between;padding:25px max(5vw,24px);color:#94a59b;font-size:10px}footer span:first-child{font-weight:700;color:var(--green)}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:#29483c;color:#fff;border-radius:8px;padding:12px 20px;font-size:12px;display:none}@media(max-width:760px){header{height:auto;padding:14px 20px;flex-wrap:wrap;gap:10px}.brand{font-size:15px}nav{order:3;width:100%;justify-content:space-around;height:42px;gap:4px}.prototype{margin-left:auto}.hero{grid-template-columns:1fr;gap:20px;padding:50px 0}.hero-art{width:min(86%,360px)}.spark{display:none}.section-heading{display:block}.steps{grid-template-columns:1fr}.workspace,.play-layout{grid-template-columns:1fr}.pagehead{padding-top:35px;gap:15px}.pagehead h1{font-size:24px}.canvas-bottom span{display:none}.gallery{grid-template-columns:repeat(2,1fr)}footer span:last-child{display:none}}
[hidden]{display:none!important}

.puzzle-areas{display:grid;grid-template-columns:1fr 1fr;gap:16px;align-items:start}.puzzle-areas h3{font-size:12px;color:#71857a;margin:0 0 10px}.puzzle-areas .board,.piece-tray{width:100%;aspect-ratio:1;padding:6px;border-radius:10px;background:#e4ece2}.piece-tray{background:#eee8d8}.puzzle-areas canvas{width:100%;height:100%;max-height:none;border:0;touch-action:none;cursor:grab}.puzzle-areas canvas:active{cursor:grabbing}@media(max-width:760px){.puzzle-areas{gap:8px}.puzzle-areas h3{font-size:11px}}
/* にくねこと、紙のステッカーのような広場 */
:root{--ink:#3e3331;--green:#d66550;--cream:#fff9ee;--line:#eee0cf;--orange:#ed9d62}
body{background:#fff9ee;color:var(--ink);background-image:radial-gradient(#efdfca 0.8px,transparent 0.8px);background-size:19px 19px}
header{background:#fffdf8;border-bottom:2px solid #f1dfcf}
.brand{font-size:18px;color:#453332}.brand-accent{color:#d66550}.brand small{color:#c6a99e;letter-spacing:.14em}.brand-mark{display:flex;align-items:center;justify-content:center;width:52px;height:52px;border-radius:18px;background:#ffe8d9;overflow:hidden}.brand-mark img{width:57px;height:57px;object-fit:contain}
.nav{color:#aa958a}.nav.active{color:#d66550;border-color:#e0816d}.prototype,.pill{background:#fff0df;border-color:#f7dcc4;color:#bc6b55}
.hero{min-height:555px;grid-template-columns:1fr 470px;gap:45px}.eyebrow{color:#d56e59;letter-spacing:.15em}.hero h1{font-size:clamp(40px,4.6vw,65px);line-height:1.4}.hero h1 em{color:#dd715a}.lead{color:#937f75;font-weight:500}.primary{background:#dc755d;border-color:#dc755d;box-shadow:0 5px 0 #b65946}.primary:hover{background:#c96851}.secondary{border-color:#e4ab96;color:#b75c49;background:#fffefa}.note{color:#ad9b8f}
.hero-art{position:relative;transform:rotate(2deg);width:410px;max-width:100%;background:#fffdf8;border:2px solid #edddce;border-radius:20px;padding:20px;box-shadow:0 15px 0 #f1e0d1,0 24px 45px #bca3953b}.hero-art-header{display:flex;justify-content:space-between;align-items:center;color:#bd8e7a;font-size:10px;letter-spacing:.14em;font-weight:700}.hero-art-header strong{color:#b66050;font-size:12px;letter-spacing:.05em}.hero-art-header span:last-child{font-size:21px;color:#e59d70}.sticker-scene{position:relative;height:315px;margin:12px 0;background:#fbe4ce;border-radius:14px;overflow:hidden;background-image:radial-gradient(#eec8a9 1px,transparent 1px);background-size:17px 17px}.sticker{position:absolute;display:flex;justify-content:center;align-items:center}.sticker img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(2px 5px 0 #d8b7a866)}.sticker-main{width:250px;height:250px;left:4px;bottom:0;transform:rotate(-9deg)}.sticker-friend{width:155px;height:155px;right:0;bottom:5px;transform:rotate(12deg)}.sticker-note{position:absolute;top:42px;right:26px;background:#fffdf8;border:2px solid #d9826c;border-radius:50%;width:90px;height:80px;display:grid;place-items:center;text-align:center;color:#c76a55;font-size:13px;font-weight:900;line-height:1.4;transform:rotate(9deg)}.sticker-spark{position:absolute;color:#d57e62;font-size:28px}.spark-a{top:36px;left:40px}.spark-b{bottom:45px;right:144px}.art-bottom{color:#b9a094;letter-spacing:.04em}.art-bottom strong{color:#dd8068}.spark{color:#e49c7f}
.section-heading{border-color:#efdfd0}.section-heading>p,.pagehead p:not(.eyebrow){color:#a49185}.steps article{border:1px solid #f1e1d1;border-radius:16px;background:#fffdf9;box-shadow:0 4px 0 #f1e3d7}.steps article>span{color:#e8c4b3}.step-icon{width:88px;height:77px;border-radius:20px;overflow:hidden}.step-icon img{width:100%;height:100%;object-fit:contain}.peach{background:#fbe4d9}.yellow{background:#fbefce}.mint{background:#e9f1e1}.steps p{color:#a28f84}
.canvas-wrap,.tools,.card{background:#fffefa;border-color:#f0e1d3}.segmented .selected{background:#fdf0e8;border-color:#df9e88;color:#b35f4e}.tools select,.tools input{border-color:#eadacf;background:#fffdfa}.text-button{color:#bd6653}.board{background:#efdfd3}.piece-tray{background:#f0e4cf}footer{border-color:#efdfd0;color:#b8a497}footer span:first-child{color:#c66b56}
@media(max-width:760px){.hero{grid-template-columns:1fr;gap:25px}.hero-art{width:min(88%,380px)}.sticker-scene{height:280px}.sticker-main{width:225px;height:225px}.sticker-friend{width:135px;height:135px}.brand{font-size:14px}.brand-mark{width:42px;height:42px}.brand-mark img{width:48px;height:48px}.steps{gap:12px}.steps article{min-height:140px;padding-left:125px}.steps .step-icon{position:absolute;left:20px;top:24px}.steps h3{margin-top:8px}}
.sound-toggle{border:1px solid #e8cfc0;border-radius:30px;background:#fffaf4;color:#b66050;padding:9px 12px;font-size:11px;font-weight:700;white-space:nowrap}.sound-toggle:hover{background:#fff0df}@media(max-width:760px){.sound-toggle{margin-left:auto}.prototype{margin-left:0}}
.sample-size-label{font-size:11px;color:#a2887b;font-weight:700;align-self:center}.actions #sample-size{border:1px solid #e4c9b8;border-radius:8px;background:#fffefa;color:#73584d;padding:10px;font-size:12px;max-width:180px}.actions #sample{align-self:center}
/* ピースがはまった瞬間の小さなお祝い */
.puzzle-areas .board{position:relative;overflow:hidden}.snap-effect{position:absolute;width:0;height:0;pointer-events:none;z-index:5}.snap-ring{position:absolute;left:-13px;top:-13px;width:26px;height:26px;border:2px solid #e99475;border-radius:50%;animation:snap-ring .6s ease-out forwards}.snap-spark{position:absolute;left:-7px;top:-10px;color:#efab70;font-size:16px;font-weight:bold;line-height:1;opacity:0;animation:snap-spark .6s ease-out var(--delay) forwards;text-shadow:0 1px #fff,1px 0 #fff}.snap-spark:nth-of-type(3n){color:#d9806a}.snap-spark:nth-of-type(3n+1){color:#e5b85f}@keyframes snap-spark{0%{opacity:0;transform:translate(0,0) scale(.4)}20%{opacity:1}100%{opacity:0;transform:translate(var(--dx),var(--dy)) scale(1.2)}}@keyframes snap-ring{0%{opacity:.8;transform:scale(.2)}100%{opacity:0;transform:scale(2)}}@media(prefers-reduced-motion:reduce){.snap-effect{display:none}}
.rotation-controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0 0 14px;color:#73584d}.rotation-controls span{font-size:12px;font-weight:700;margin-right:4px}.rotation-controls button{padding:9px 13px}.rotation-controls small{color:#a28f84;font-size:10px}@media(max-width:760px){.rotation-controls small{width:100%}}
/* スマホではお絵描きキャンバスをできるだけ広く使う */
@media(max-width:760px){#draw{margin-inline:-20px}#draw .workspace{gap:16px}#draw .canvas-wrap{padding:6px}#draw .canvas-top{padding:3px 3px 8px}#draw #canvas{width:100%;max-height:none;aspect-ratio:1;touch-action:none}#draw .tools{padding:20px}}
