
*{box-sizing:border-box}body{margin:0;color:#203958;background:linear-gradient(#d7efff,#f3fbfc 74%);font:16px 'Trebuchet MS',Arial,sans-serif;min-height:100dvh}button,a,input{font:inherit}button,a{color:inherit;cursor:pointer;font-weight:700;display:inline-flex;align-items:center;justify-content:center;gap:8px;border:0;text-decoration:none;padding:11px 18px;border-radius:30px;background:white;box-shadow:0 3px 0 #29476924;transition:transform .15s,background .15s}button:hover,a:hover{transform:translateY(-2px);background:#fff6dc}button:disabled{opacity:.4;cursor:default;transform:none}button:focus-visible,a:focus-visible{outline:3px solid #ec8210}svg{width:21px;height:21px;flex:none}header{height:72px;display:flex;align-items:center;justify-content:space-between;padding:0 4vw;background:#fffefa;border-bottom:1px solid #c8dfe9;position:relative;z-index:2}strong{font: bold 24px Georgia;letter-spacing:-.7px;display:flex;align-items:center;gap:10px}strong svg{width:40px;height:44px}header button{box-shadow:none;background:none;font-size:15px;padding:10px}#scene{position:fixed;inset:0;width:100%;height:100%;z-index:-1;pointer-events:none}main{text-align:center;padding:clamp(12px,2.7vh,36px) 0 20px}h1{font:bold clamp(32px,5.3vh,60px)/1.08 Georgia;margin:0 0 9px;letter-spacing:-1.5px}p{margin:0;line-height:1.45}#row,nav,#buttons{display:flex;align-items:center;justify-content:center;gap:clamp(12px,3vw,54px)}#row{margin:clamp(16px,3.2vh,40px) auto 0;touch-action:pan-y}#book{width:min(73vw,calc((100dvh - 315px)*1.545),1060px);min-width:min(65vw,435px);display:flex;position:relative;isolation:isolate;background:#fff;border-radius:7px;box-shadow:0 3px #d0cfc7,0 5px white,0 7px #c7c2b8,0 9px #fff,0 0 0 7px #366696,0 9px 0 7px #26466c,0 25px 30px #2444613d;perspective:1500px}#book:after{content:'';position:absolute;inset:0;background:linear-gradient(90deg,#cabb9814,transparent 8%,transparent 43%,#785f3912 48%,#58483236 49.9%,#48382652 50%,#74654417 51%,transparent 57%,transparent 95%,#cabb9814);pointer-events:none;border-radius:7px}.sheet{position:relative;width:50%;padding:0;border-radius:6px;box-shadow:none;display:block;overflow:hidden}.sheet:hover{transform:none}.sheet img{display:block;width:100%;aspect-ratio:17/22;pointer-events:none}.sheet:hover:after{content:'';position:absolute;inset:0;box-shadow:inset 0 0 0 4px #f7b53d;border-radius:6px}.num{position:absolute;bottom:2%;left:5%;font-size:13px;color:#566578}.sheet:nth-child(2) .num{left:auto;right:5%}.turn{position:absolute;top:0;width:50%;height:100%;transform-origin:left;left:50%;animation:flip .5s ease-in-out forwards;z-index:4;backface-visibility:hidden;box-shadow:0 0 20px #25395340}.rev{left:0;transform-origin:right;animation-name:back}@keyframes flip{to{transform:rotateY(-165deg)}}@keyframes back{to{transform:rotateY(165deg)}}.round{width:52px;height:52px;padding:0;border:1px solid #bad4e6;box-shadow:0 4px 0 #90afc345}.round svg{width:28px;height:28px}#buttons{margin:34px auto 18px;width:min(90vw,750px);gap:8vw}.primary{background:#ffbd46;box-shadow:0 4px #d88920;color:#263953}.primary:hover{background:#ffcf6b}nav{gap:20px;font-size:15px}nav span{background:#ffffffed;border-radius:30px;padding:10px 16px;font-weight:bold}nav .round{display:none}dialog{width:min(900px,94vw);border:none;border-radius:22px;color:inherit;padding:22px;background:#f6fbff;max-height:89dvh}dialog::backdrop{background:#112e50aa}h2{font:700 26px Georgia;margin:0}article{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:18px}#grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(125px,1fr));gap:14px}#grid button{flex-direction:column;border-radius:12px;padding:9px;font-size:14px}#grid img{width:100%;aspect-ratio:17/22}#help{max-width:450px}#help p{margin:15px 0}#editor{padding:14px 3vw;max-width:1250px;margin:auto}#editor article{margin-bottom:12px}#work{display:flex;gap:18px;align-items:flex-start;justify-content:center}aside{width:244px;border-radius:20px;background:#fff;padding:18px;box-shadow:0 5px 18px #2947691c;display:grid;gap:14px}#tools,#actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}aside button{box-shadow:none;border-radius:12px;background:#edf4fa;font-size:14px;padding:11px 5px}aside button.on{background:#234d78;color:white}#colors{display:grid;grid-template-columns:repeat(5,1fr);gap:8px;padding:5px}#colors button{width:100%;aspect-ratio:1;border-radius:50%;padding:0;border:1px solid #0001}#colors .on{outline:2px solid #193957;outline-offset:2px}label{display:flex;align-items:center;justify-content:space-between;font-size:14px;font-weight:bold}input[type=range]{width:65%}input[type=color]{width:56px;border:none}#viewport{width:min(68vw,calc((100dvh - 185px)*.773));min-width:min(45vw,410px);aspect-ratio:17/22;overflow:auto;background:white;box-shadow:0 7px 22px #29476929;overscroll-behavior:contain}#paper{width:100%;position:relative;aspect-ratio:17/22;background:white}canvas,#ink{width:100%;height:100%;position:absolute;inset:0}canvas{touch-action:none;cursor:crosshair}#ink{mix-blend-mode:multiply;pointer-events:none}#state{font-size:14px;text-align:center} [hidden]{display:none!important}
@media(max-width:720px){header{height:58px}strong{font-size:18px;gap:4px}strong svg{width:30px}header button{font-size:14px;padding:6px}#row>.round,.sheet:nth-child(2),#buttons button+button,#book:after{display:none}nav .round{display:flex;width:40px;height:40px}nav{gap:8px;font-size:14px}nav button,nav span{padding:9px}#book{min-width:0;width:min(85vw,calc(54dvh*.773 + 4vw));max-width:410px}.sheet,.turn{width:100%;left:0}main p{font-size:14px}#buttons{margin:30px auto 15px}#editor article button,#editor a{font-size:13px;padding:9px}#editor h2{font-size:19px}#work{flex-direction:column-reverse;align-items:center;gap:10px}#viewport{min-width:0;width:min(92vw,calc(48dvh*.773))}aside{width:100%;display:flex;flex-wrap:wrap;gap:8px;justify-content:center;padding:10px}#tools,#actions{display:flex;width:100%}aside button{flex:1;font-size:13px;padding:9px 2px}#colors{width:100%;grid-template-columns:repeat(10,1fr);gap:7px}label{width:45%}#state{font-size:13px}#grid{grid-template-columns:repeat(2,1fr)}}
@media(prefers-reduced-motion:reduce){.turn{display:none}}

header{display:grid;grid-template-columns:1fr auto 1fr;height:76px;padding:0 clamp(12px,3.4vw,68px);color:#091e34;background:#fff;border-bottom:2px solid #102942}
.home,.home:hover{padding:0;border-radius:4px;box-shadow:none;background:transparent;transform:none;justify-self:start}
.home img{display:block;height:71px;width:auto}
header strong{font-size:clamp(21px,2.2vw,28px);letter-spacing:-.6px;white-space:nowrap}
header strong svg{height:34px;width:32px}
#how{justify-self:end;color:#102942;gap:7px}
#how:hover{background:#fff0f6}
#how svg{color:#bd1462}
@media(max-width:720px){
header{height:64px;grid-template-columns:auto 1fr auto;column-gap:10px;padding:0 12px}
.home img{width:min(30vw,131px);height:auto}
header strong{font-size:clamp(16px,4.2vw,21px);padding-left:12px;border-left:1px solid #cbd5dc;letter-spacing:-.45px;line-height:1.4}
header strong svg,#how span{display:none}
#how{padding:6px}
#how svg{width:23px;height:23px}
}
@media(max-width:375px){header{column-gap:6px;padding:0 6px}header strong{padding-left:6px;font-size:15px}#how{padding:3px}}

aside{width:292px;gap:12px;padding:16px;max-height:calc(100dvh - 170px);overflow:auto;scrollbar-width:thin}
#tools,#actions{grid-template-columns:repeat(4,1fr);gap:4px}
#actions{grid-template-columns:repeat(3,1fr)}
#tools button,#actions button{padding:10px 2px;font-size:14px}
#colors{grid-template-columns:repeat(10,1fr);gap:7px;padding:3px}
#colors button{height:23px;width:100%;aspect-ratio:auto;border-radius:7px}
#more{display:grid;grid-template-columns:repeat(3,1fr);gap:5px}
#more button{font-size:14px;padding:10px 1px}
#expand{background:#fbe6ef;color:#8a1047;width:100%;justify-content:space-between;padding:11px}
#advanced{display:grid;gap:10px}
#tip{font-size:14px;line-height:1.35;color:#35536b}
#pins{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
#pins button{height:28px;min-width:26px;flex:none;border:1px solid #adc1ce;border-radius:8px}
#pins button:first-child{padding:0 9px}
#pins button.on{outline:2px solid #122d49}
aside label{width:100%;gap:6px}aside input[type=range]{width:52%;accent-color:#234d78}
aside input[type=checkbox]{width:18px;height:18px;accent-color:#234d78}
#lockRow{justify-content:flex-start}
#state{color:#34536b;font-size:13px}
#toolLabel{overflow-wrap:anywhere}
@media(max-width:720px){aside{width:100%;max-height:none;padding:10px;gap:9px}#advanced,#colors,#pins{width:100%}aside label{width:48%}#advanced label{width:100%}#actions,#tools{display:grid}#tools button,#actions button{padding:8px 1px}#colors button{height:27px}#advanced{grid-template-columns:1fr 1fr}#more,#tip,#pins,#lockRow,#opacityRow{grid-column:1/-1}#viewport{width:min(90vw,calc(44dvh*.773))}}
