:root{font-family:"Yu Gothic UI","Meiryo",sans-serif;color:#202039;background:#f2f4fa;font-size:16px}*{box-sizing:border-box}body{margin:0}header{max-width:1320px;margin:auto;padding:25px 32px;display:flex;justify-content:space-between;align-items:center}.brand{display:flex;gap:13px;align-items:center}.logo{width:46px;height:46px;border-radius:14px;background:#5546df;color:white;display:grid;place-items:center;font-size:30px;font-weight:900}h1{font-size:24px;margin:0;letter-spacing:-.5px}h2{font-size:17px;margin:0 0 18px}p{margin:5px 0;color:#74758b;font-size:14px;line-height:1.7}#saveStatus{font-size:14px;color:#687386}main{max-width:1320px;margin:0 auto;padding:0 32px 32px;display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:24px}.workspace{min-width:0}.toolbar{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px;gap:10px}.tabs{background:#e7e9f2;border-radius:12px;padding:4px;display:flex}.tabs button{background:transparent;border:0}.tabs .active{background:white;color:#5546df;box-shadow:0 2px 5px #25254b10}button{font:inherit;font-size:14px;font-weight:700;border:1px solid #e1e3ee;background:white;color:#49495f;border-radius:9px;padding:11px 15px;cursor:pointer}button:hover{background:#f0efff}button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #9489ff;outline-offset:2px}.primary{background:#5546df;color:white;border-color:#5546df}.primary:hover{background:#4336c1}.board-shell{position:relative;border-radius:20px;overflow:hidden;box-shadow:0 12px 38px #33385812}canvas{display:block;width:100%;height:auto}.cell-buttons{position:absolute;inset:0;display:grid;grid-template-columns:repeat(5,1fr);grid-template-rows:repeat(5,1fr);padding:2%;gap:.65%}.cell-buttons button{padding:0;background:transparent;border:3px solid transparent;border-radius:10px}.cell-buttons button.selected{border-color:#8273ff}.cell-buttons button.exchange{border-color:#f49d45}.cell-buttons button:hover{background:#5546df0c}.board-footer{display:flex;justify-content:space-between;gap:10px;font-size:12px;color:#77798b;padding:14px 3px}aside{display:flex;flex-direction:column;gap:16px}.card{background:white;border:1px solid #e7e9f2;border-radius:16px;padding:22px}.eyebrow{font-size:12px;font-weight:800;letter-spacing:2px;color:#8a82c4;margin-bottom:8px}.total{background:#f3f1ff;border-radius:12px;padding:18px 15px;display:flex;align-items:baseline;gap:9px;color:#5546df;margin-bottom:16px}.total strong{font-size:32px;letter-spacing:-1px;overflow-wrap:anywhere}.total span{font-size:13px}.stat-row{display:flex;justify-content:space-between;margin-top:12px;font-size:14px}.stat-row span{color:#77798b}.editor-top{display:flex;justify-content:space-between;align-items:start}.badge{font-size:12px;color:#5546df}label{display:block;font-size:14px;font-weight:600;margin-bottom:14px}input,textarea,select{display:block;width:100%;font:inherit;font-size:14px;border:1px solid #dedfea;border-radius:8px;padding:10px;margin-top:7px;color:#34344e;background:#fbfcff}textarea{resize:vertical;min-height:100px}.two{display:grid;grid-template-columns:1fr 1fr;gap:10px}.image-picker{display:flex;gap:12px;align-items:center;margin:12px 0 18px}.image-picker img{width:60px;height:60px;object-fit:contain;border:1px solid #eee;border-radius:10px}.image-picker label{margin:0;flex:1}.image-picker input{font-size:12px;padding:5px}.actions{display:flex;gap:8px;margin:10px 0 18px}.actions button{flex:1}.hint{font-size:13px;color:#78798e;line-height:1.7;margin:12px 0}.danger{color:#b75062;width:100%;margin-top:12px}.storage p{font-size:12px;margin-top:12px}dialog{border:0;border-radius:18px;padding:28px;width:min(420px,90vw);box-shadow:0 20px 70px #2225}dialog::backdrop{background:#17152e66}.dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:25px}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);padding:13px 22px;border-radius:10px;background:#29263d;color:white;font-size:14px;opacity:0;pointer-events:none;transition:opacity .2s;z-index:10}#toast.show{opacity:1}@media(min-width:1100px){.board-shell{max-width:790px}}@media(max-width:900px){main{grid-template-columns:1fr;padding:0 16px 24px}header{padding:20px 16px}aside{display:grid;grid-template-columns:1fr 1fr}.storage{grid-column:1/-1}.board-footer{flex-wrap:wrap}}@media(max-width:560px){aside{display:flex}h1{font-size:20px}.brand p{font-size:12px}#saveStatus{font-size:12px}.toolbar button{padding:10px;font-size:13px}.card{padding:18px}}
[hidden]{display:none!important}
.guide{max-width:1320px;margin:0 auto;padding:0 32px 40px}.guide .card{padding:30px}.guide h2{font-size:22px}.guide h3{font-size:17px;margin:26px 0 12px}.guide p{font-size:15px;color:#55566c;line-height:1.85}.guide ol{padding-left:24px;margin:0}.guide li{padding:10px 0 10px 8px}.guide li strong{font-size:16px}.guide-notes{border-top:1px solid #e7e9f2;margin-top:18px}.guide-notes p{margin:12px 0}@media(max-width:900px){.guide{padding:0 16px 24px}.guide .card{padding:22px}}@media(max-width:560px){h1{font-size:18px}}
.author{max-width:1320px;margin:0 auto;padding:0 32px 32px;text-align:center;font-size:14px;color:#55566c}.author span{margin-left:8px;color:#74758b}
.author .version{display:inline-block;margin-left:16px;padding-left:16px;border-left:1px solid #dedfea;white-space:nowrap}

:root{--accent:#5546df}.logo,.primary{background:var(--accent)}.primary{border-color:var(--accent)}.tabs .active,.badge{color:var(--accent)}.appearance label{margin-bottom:0}.appearance p{font-size:13px;margin-top:12px}

.export-actions{display:flex;gap:8px}#imageDialog{width:min(680px,94vw);max-height:92vh;overflow:auto}#exportPreview{display:block;width:100%;height:auto;margin-top:16px;-webkit-touch-callout:default}.export-actions button:disabled{opacity:.6;cursor:wait}@media(max-width:650px){.toolbar{flex-wrap:wrap}.export-actions{width:100%;justify-content:flex-end}#imageDialog{padding:18px}}

.cell-buttons{display:block;padding:0;gap:0}.row-counts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.row-counts label{margin:0 0 10px}.row-counts input{width:100%}@media(max-width:900px){#layoutSettings{grid-column:1/-1}}

#backgroundPreview{display:block;width:100%;max-height:180px;object-fit:contain;border-radius:8px;margin:12px 0}.reveal-settings p{font-size:13px}.reveal-settings label{margin-top:12px}

.board-shell.reveal-board{border-radius:0}.reveal-board .cell-buttons button{border-radius:0}

#cropDialog{width:min(720px,95vw);max-height:94vh;overflow:auto}.crop-stage{background:#e7e9f2;display:flex;justify-content:center;align-items:center;padding:12px;margin:14px 0}#cropCanvas{width:auto;max-width:100%;height:auto;max-height:42vh;touch-action:none;cursor:grab}#cropCanvas:active{cursor:grabbing}#cropDialog input[type=range]{padding:0}#cropDialog .dialog-actions{flex-wrap:wrap}

.sharing button{margin:5px 0}.sharing p{font-size:13px}.sharing details{margin-top:15px}.sharing li{font-size:12px;margin-bottom:12px}.sharing li button{padding:5px;margin-left:5px}.sharing #sharingPeople div{display:flex;align-items:center;justify-content:space-between;gap:8px}#sharedPreview{max-height:250px;max-width:100%;object-fit:contain;display:block;margin:15px auto}#sharedConfirm,#sharedLinkDialog{max-height:90vh;overflow:auto;width:min(600px,94vw)}

#sharingCard.sharing-owner{grid-column:1/-1}

body.sharing-ended > :not(#sharingEnded){display:none!important}body.sharing-ended{display:grid;min-height:100dvh;margin:0;place-items:center}#sharingEnded{margin:0;padding:24px;font-size:clamp(20px,4vw,28px);font-weight:700;text-align:center}

body.supporter-view{background:#eef8f6}
.supporter-view header{border-bottom:3px solid #168575;margin-bottom:22px}
.supporter-view .logo{background:#13796b}
#supporterBanner{color:#17695e;margin-top:8px;line-height:1.6}
#supporterBanner strong{display:inline-block;background:#d0eee6;color:#115e52;border-radius:6px;padding:3px 10px;margin-right:8px;font-size:14px}
#supporterBanner span{display:block;margin-top:6px;font-size:13px}
.supporter-view #saveStatus,.supporter-view .toolbar,.supporter-view .guide,.supporter-view #imageSize{display:none}
.supporter-view .card{border-color:#cce5df}
.supporter-view .editor{border-top:4px solid #168575}
.supporter-view .primary{background:#13796b;border-color:#13796b}
.supporter-view .primary:hover{background:#0c6054}
.supporter-view .total{color:#115e52;background:#e0f3ec}
.supporter-view .eyebrow,.supporter-view .badge{color:#17695e}
.supporter-view .cell-buttons button.selected{border-color:#168575}
.supporter-view button:focus-visible,.supporter-view input:focus-visible{outline-color:#168575}

#ownerSharingBanner{max-width:1256px;margin:0 auto 20px;padding:16px 20px;border:1px solid #c7bdf4;border-left:5px solid #5546df;border-radius:12px;background:#eeeaff;color:#3b2b87}#ownerSharingBanner strong{display:block;font-size:16px}#ownerSharingBanner strong span{color:#16834c;margin-right:5px}#ownerSharingBanner>span{display:block;font-size:13px;line-height:1.7;margin-top:5px}.settings-locked{color:#747087;background:#edeaf3!important}.settings-locked::after{content:" 🔒"}@media(max-width:1320px){#ownerSharingBanner{margin-left:32px;margin-right:32px}}@media(max-width:900px){#ownerSharingBanner{margin-left:16px;margin-right:16px}}
#editor .actions{display:flex;flex-wrap:nowrap;gap:6px}#editor .actions button{flex:1 1 0;min-width:0;padding:10px 4px}.number-with-zero{min-width:0;margin-bottom:14px}.number-with-zero label{margin:0}.number-controls{display:flex;align-items:center;gap:6px;margin-top:7px}.number-controls input{flex:1;min-width:0;margin-top:0;appearance:textfield}.number-controls input::-webkit-inner-spin-button,.number-controls input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.number-controls>button{flex:0 0 28px;width:28px;height:28px;padding:0;border-radius:6px;font-size:12px;color:#858599;background:#f6f7fa;border-color:#e7e8ee}.image-picker{flex-wrap:wrap}.image-actions{display:flex;gap:12px;margin:12px 0}
