:root{color:#1e293b;background:#f6f7fb;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;line-height:1.6}*,:after,:before{box-sizing:border-box}body{margin:0;padding:0}.page{min-height:100vh;display:flex;justify-content:center;padding:24px}.board{width:min(1100px,100%);background:#fff;border:1px solid #e2e8f0;border-radius:14px;box-shadow:0 10px 30px rgba(15,23,42,.08);padding:12px}.drawing{display:flex;flex-direction:column;gap:8px}.toolbar{gap:10px;padding:12px;background:#f9fafb;border:1px solid #e5e7eb;border-radius:10px;box-shadow:0 8px 22px rgba(15,23,42,.05);flex-wrap:nowrap;width:100%}.toolbar,.toolbar-row{display:flex;align-items:center}.toolbar-row{gap:12px}.row-tools{flex-wrap:nowrap;align-items:center}.row-colors{flex-wrap:wrap;overflow:visible;padding:4px 2px;flex:1 1 auto}.row-actions{justify-content:flex-start}.tool-group{gap:12px}.tool,.tool-group{display:inline-flex}.tool{width:46px;height:46px;border-radius:14px;border:1px solid #e6edf5;background:linear-gradient(180deg,#fff,#f6f8fb);color:#374151;font-size:18px;align-items:center;justify-content:center;box-shadow:0 10px 24px rgba(15,23,42,.06);cursor:pointer;transition:transform .12s ease,box-shadow .12s ease,background .12s ease,color .12s ease,border-color .12s ease}.tool.active{transform:translateY(-1px);background:linear-gradient(135deg,#c7d2fe,#a5f3fc);color:#0f172a;border-color:#c4d4f7;box-shadow:0 12px 26px rgba(79,70,229,.22)}.tool .icon{font-size:20px}.slider-group{display:inline-flex;align-items:center;gap:8px;padding:0 8px}.slider-group input[type=range]{accent-color:#4f46e5;width:150px;height:6px}.size-chip{min-width:32px;height:32px;padding:0 8px;border-radius:12px;border:1px solid #e2e8f0;display:grid;place-items:center;background:linear-gradient(135deg,#eef2ff,#e0e7ff);color:#0f172a;font-weight:600;font-size:14px}.colors{display:flex;gap:4px;flex-wrap:wrap;align-items:center}.color{width:24px;height:24px;border-radius:50%;border:2px solid transparent;box-shadow:0 3px 8px rgba(0,0,0,.08);cursor:pointer;aspect-ratio:1/1}.color.selected{border-color:#0f172a;box-shadow:0 0 0 3px rgba(15,23,42,.08)}.color.custom{position:relative;overflow:hidden;padding:0;border-radius:6px;width:26px;height:26px;aspect-ratio:1/1}.color.custom input[type=color]{position:absolute;inset:0;width:100%;height:100%;border:none;padding:0;opacity:0;cursor:pointer}.actions{display:inline-flex;gap:8px;justify-content:flex-end}.ghost{min-width:38px;height:38px;border-radius:10px;border:1px solid #e5e7eb;background:#fff;box-shadow:0 5px 14px rgba(15,23,42,.08);cursor:pointer;font-size:16px;transition:transform .12s ease,box-shadow .12s ease}.ghost:hover{transform:translateY(-1px);box-shadow:0 8px 20px rgba(15,23,42,.1)}.workspace{display:grid;grid-template-columns:minmax(0,1fr);grid-gap:16px;gap:16px;align-items:start;width:100%}.canvas-wrap{border:1px solid #e2e8f0;border-radius:12px;overflow:hidden;background:#fff;box-shadow:inset 0 0 0 1px hsla(0,0%,100%,.6),0 12px 28px rgba(15,23,42,.08);aspect-ratio:3/2}.base-layer,.canvas-wrap{position:relative;width:100%}.base-layer{height:auto;display:block;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}.base-layer.center{display:grid;place-items:center;width:100%;height:100%}.base-layer.center img{max-width:130%;max-height:130%;object-fit:contain;width:100%;height:100%}.canvas-wrap canvas{position:absolute;inset:0;width:100%;height:100%;cursor:crosshair}.reference-overlay{position:absolute;top:12px;right:12px;width:min(22vw,180px);background:#fff;border:1px solid #e2e8f0;border-radius:12px;padding:0;box-shadow:0 10px 26px rgba(15,23,42,.12);pointer-events:none;overflow:hidden}.reference-overlay img{width:100%;height:auto;display:block;pointer-events:none}.tag{align-self:start;justify-self:start;padding:4px 10px;font-size:12px;font-weight:600;color:#4c1d95;background:#ede9fe;border-radius:999px}.muted{margin:0;color:#475569;font-size:14px}.note{margin-top:24px}.note h2{margin:0 0 8px}.note ul{margin:0;padding-left:20px;color:#475569}@media (max-width:720px){.page{padding:16px;min-height:100vh}.board{padding:8px}.drawing{gap:6px}.toolbar{flex-direction:column;align-items:stretch;gap:10px;padding:10px 12px}.tool-group{gap:6px}.tool{width:38px;height:38px;border-radius:12px;font-size:16px}.slider-group{width:100%;padding:0}.slider-group input[type=range]{width:100%}.size-chip{min-width:28px;height:28px;font-size:12px}.colors{width:100%;display:flex;flex-wrap:nowrap;gap:.5px;overflow:hidden;justify-content:flex-start;flex:1 1 auto;min-width:0}.color{width:18px;height:18px;border-radius:50%;border:1px solid transparent;box-shadow:none}.color,.color.custom{padding:0;display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto}.color.custom{width:20px;height:20px;border-radius:4px}.actions{justify-content:flex-start;gap:8px}.ghost{min-width:34px;height:34px;border-radius:9px;font-size:15px}.workspace{grid-template-columns:1fr}.canvas-wrap{aspect-ratio:380/620;margin-top:10px}.base-layer.center img{max-width:200%!important;max-height:200%!important;width:auto!important;height:auto!important}.reference-overlay{position:absolute;top:8px;right:8px;width:120px;margin:0}}@media (min-width:721px) and (max-width:1368px){.page{padding:28px}.board{width:min(960px,98vw);padding:14px}.toolbar{gap:6px;padding:4px 8px}.tool-group{gap:6px}.tool{width:30px;height:30px;border-radius:10px;font-size:14px}.slider-group{padding:0 2px}.row-colors{flex-wrap:nowrap;overflow:hidden;padding:2px 0}.size-chip{min-width:24px;height:24px;font-size:12px}.colors{gap:3px;flex-wrap:nowrap;overflow:hidden;justify-content:flex-start;min-width:0;align-items:center}.color{width:28px;height:28px;border-radius:50%!important}.color,.color.custom{aspect-ratio:1/1;flex:0 0 auto}.color.custom{width:30px;height:30px;border-radius:6px!important}.actions{gap:4px}.ghost{min-width:30px;height:30px;border-radius:9px;font-size:14px}.workspace{gap:12px}.canvas-wrap{max-height:76vh;margin-top:8px}}@media (min-width:1369px) and (max-width:2560px) and (pointer:coarse){.page{padding:28px}.board{width:min(1080px,98vw);padding:14px}.toolbar{gap:6px;padding:4px 8px}.tool-group{gap:6px}.tool{width:30px;height:30px;border-radius:10px;font-size:14px}.slider-group{padding:0 2px}.size-chip{min-width:24px;height:24px;font-size:12px}.colors{gap:3px;flex-wrap:nowrap;overflow:hidden;justify-content:flex-start;min-width:0;align-items:center}.color{width:28px;height:28px;border-radius:50%!important}.color,.color.custom{aspect-ratio:1/1;flex:0 0 auto}.color.custom{width:30px;height:30px;border-radius:6px!important}.actions{gap:4px}.ghost{min-width:30px;height:30px;border-radius:9px;font-size:14px}.workspace{gap:12px}.canvas-wrap{max-height:76vh;margin-top:8px}}