/* Touch-sized tools; independent scroll areas for layers and properties. */
:root{--studio-header:64px;--studio-options:54px}header{height:var(--studio-header);padding:0 max(18px,env(safe-area-inset-right)) 0 max(18px,env(safe-area-inset-left));gap:16px}.brand>span{font-size:22px}.brand small{font-size:7px;margin-top:4px}.brand svg{width:26px}.document{flex:1;min-width:80px}.document input{width:100%;font-size:13px}.header-actions{gap:5px;flex-shrink:0}.header-actions button{font-size:12px}.header-history{display:flex;gap:2px;margin-right:8px}.header-history button{width:44px;font-size:24px;padding:0}.workspace-switch{margin:0;flex-shrink:0}.workspace-switch button{min-height:44px;min-width:76px;padding:3px 11px}.workspace{height:calc(100dvh - var(--studio-header));grid-template-columns:68px minmax(0,1fr) 320px}main{min-height:0}.tools{padding:8px 7px;gap:2px}.tools button{min-height:53px}.tools small{font-size:9px}.tools .tool-divider{margin:3px}.color-tool{padding:8px 4px}.color-tool input{width:34px;height:34px}.editor-options{height:var(--studio-options);display:flex;align-items:center;gap:8px;padding:0 12px;border-bottom:1px solid var(--line);background:var(--panel);flex-shrink:0;min-width:0}.context-bar{display:flex;align-items:center;gap:10px;flex:1;min-width:0;overflow-x:auto;white-space:nowrap;scrollbar-width:none;height:100%}.context-bar::-webkit-scrollbar{display:none}.tool-identity{display:flex;gap:7px;align-items:center;flex-shrink:0;font-size:11px;padding-right:10px;border-right:1px solid var(--line)}kbd{font:10px -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--muted);border:1px solid #dddfd6;border-radius:4px;padding:2px 4px;background:#f7f7f1}.tool-identity b{font-weight:600}.context-group{display:flex;align-items:center;gap:7px;flex-shrink:0}.context-bar label{display:flex;gap:7px;align-items:center;font-size:11px}.context-bar button{font-size:11px;min-height:44px;padding:0 9px}.context-bar input[type=number]{width:64px;height:36px;min-height:36px;border:1px solid var(--line);border-radius:6px;font-size:16px;padding:0 7px;background:white;color:var(--ink)}.context-bar input[type=range]{width:86px;accent-color:var(--pink);height:36px}.context-bar output{font-size:10px;width:37px}.context-color{display:flex;align-items:center;flex-shrink:0}.context-color span{display:none}.context-color input{width:32px;height:32px;border:0;padding:0;background:none}.context-selection{padding-left:2px}.context-selection>span{max-width:110px;text-overflow:ellipsis;overflow:hidden;font-size:10px;color:var(--muted)}.canvas-toolbar{height:44px;padding:0;gap:3px;flex-shrink:0}.canvas-toolbar .zoom-controls{height:36px;margin:0;background:#f8f8f2}.canvas-toolbar .zoom-controls button{height:36px;min-height:36px;min-width:36px;padding:0 8px;font-size:11px}.canvas-toolbar #fit{min-width:58px}.canvas-toolbar #toggleLayers,.canvas-toolbar #focusMode{display:block;min-width:44px;min-height:44px;padding:0 8px;font-size:22px}.stage{margin:12px 12px 0;border-radius:4px}.artboard{-webkit-user-select:none;-webkit-touch-callout:none}#canvas:focus{outline:none}#canvas:focus-visible{outline:2px solid var(--pink);outline-offset:3px}.bottom-bar{height:32px;padding:0 14px;font-size:10px}.bottom-bar button{font-size:11px;min-height:30px}.inspector{position:relative;top:auto;bottom:auto;right:auto;width:auto;display:flex;overflow:hidden;min-height:0;height:100%;box-shadow:none}.inspector-head{position:static;height:54px;padding:0 16px;gap:8px;flex-shrink:0}.inspector-head h2{flex:1;font-size:13px}.inspector-head>span{font-family:inherit;font-size:10px}.inspector-head #closeLayers{display:none;font-size:24px;width:44px;padding:0}.dock-tabs{display:flex;flex-shrink:0;border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:0 12px;gap:12px}.dock-tabs [role=tab]{position:relative;min-height:44px;font-size:12px;border-radius:0;padding:0 12px}.dock-tabs [aria-selected=true]{color:var(--pink);font-weight:600}.dock-tabs [aria-selected=true]::after{content:"";height:2px;position:absolute;bottom:0;left:12px;right:12px;background:var(--pink)}.dock-body{flex:1;min-height:0;overflow:hidden;display:flex}.inspector #layersPanel{padding:0;border:0;display:flex;flex-direction:column;flex:1;min-height:0;min-width:0}.inspector #propertiesPanel{padding:16px;border:0;flex:1;min-width:0;min-height:0;overflow-y:auto;overscroll-behavior:contain}.layer-title{height:50px;padding:0 14px;margin:0;flex-shrink:0}.layer-title h2{font-size:11px;color:var(--muted)}.layer-title button{font-size:23px;width:44px;padding:0}#layers{overflow-y:auto;flex:1;min-height:0;padding:0 8px 8px;gap:3px;overscroll-behavior:contain}.layer{padding:2px;gap:0;min-height:54px;flex-shrink:0;border-radius:7px}.layer .pick{padding:0 4px;gap:9px;min-height:48px;flex:1;min-width:0}.layer-symbol{width:34px;min-width:34px;height:36px;font-size:20px;background:#faf9f5}.layer-label{display:flex;flex-direction:column;gap:4px;min-width:0}.layer-label b{font-size:12px;font-weight:500;text-overflow:ellipsis;overflow:hidden;max-width:145px;white-space:nowrap}.layer-label small{font-size:9px;color:#73776d}.layer .eye,.layer .lock{width:40px;min-width:40px;min-height:44px;display:grid;place-items:center;padding:0;color:#676e61}.layer .lock{color:#a8ada1}.layer .lock[aria-pressed=true]{color:#555f4d}.layer.locked .pick{opacity:.75}.layer-actions{padding:10px 12px 12px;border-top:1px solid var(--line);flex-shrink:0}.layer-current{display:flex;align-items:center;gap:10px;margin-bottom:5px}.layer-current b{font-size:11px;font-weight:500;min-width:0;flex:1;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layer-current button{font-size:10px;min-height:36px;padding:0 5px}.layer-action-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:4px}.layer-action-grid button{border:1px solid var(--line);min-height:40px;font-size:11px;padding:0 4px}.empty-layers{font-size:12px;color:var(--muted);text-align:center;line-height:1.9;padding:30px 12px}.local-note{padding:10px 14px;font-size:9px;flex-shrink:0;line-height:1.5}.local-note p{margin:0 0 4px;font-size:9px}.property-heading{display:flex;flex-direction:column;gap:6px;padding-bottom:16px;margin-bottom:12px;border-bottom:1px solid var(--line)}.property-heading>b{font-size:13px;font-weight:600;overflow-wrap:anywhere}.property-heading>span{font-size:9px;letter-spacing:1px;color:var(--muted)}#properties label{font-size:12px;margin:12px 0}#properties input[type=text],.dimension-input,.rename-input{min-height:44px;font-size:16px}#properties input[type=range]{min-height:38px}#properties .property-group-body>input[type=range]{width:100%;margin:0}.property-group{border-top:1px solid var(--line);padding:0;margin-top:18px}.property-group>summary{min-height:48px;align-content:center;cursor:pointer;font-size:12px;font-weight:600}.property-group-body{padding:0 0 10px}.property-group .section-label{margin:0}.property-group .transform-buttons{margin:12px 0 0}.property-group .transform-buttons button{min-height:44px;font-size:11px}.property-group .node-actions button{font-size:11px;min-height:44px}.locked-message{font-size:13px;color:var(--muted);line-height:1.8}.rename-label{display:block;font-size:12px;margin-top:18px}.rename-input{width:100%;border:1px solid var(--line);border-radius:8px;padding:10px;margin-top:8px;background:white;color:var(--ink)}.alignment-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:20px 0}.alignment-grid button{min-height:48px;border:1px solid var(--line);font-size:12px}.alignment-grid .primary{grid-column:1/-1}.shortcut-help{padding:16px 0;border-top:1px solid var(--line);margin-top:18px}.shortcut-help h3{font-size:15px}.exit-focus{position:fixed;right:max(12px,env(safe-area-inset-right));top:max(12px,env(safe-area-inset-top));min-height:44px;padding:0 14px;display:flex;gap:12px;align-items:center;font-size:12px;background:var(--panel);border:1px solid var(--line);box-shadow:0 4px 18px #0001;z-index:30}.focus-mode header,.focus-mode .tools,.focus-mode .inspector,.focus-mode .editor-options,.focus-mode .bottom-bar{display:none!important}.focus-mode .workspace{grid-template-columns:minmax(0,1fr);height:100dvh}.focus-mode .stage{margin:0;border:0;border-radius:0}.focus-mode .canvas-badge{display:none}
@media(max-width:1200px){.workspace{grid-template-columns:64px minmax(0,1fr) 288px}.brand>span{font-size:21px}.brand small{display:none}.header-actions #projects{padding:0 8px}.context-selection>span{display:none}.header-history{margin-right:3px}.header-actions button{padding:0 10px}.document input{max-width:180px}.layer-label b{max-width:116px}}
@media(max-width:1000px),(max-height:600px){.workspace{grid-template-columns:62px minmax(0,1fr)}.inspector{display:none;position:fixed;top:var(--studio-header);bottom:0;right:env(safe-area-inset-right,0px);width:304px;max-width:calc(100vw - 64px);height:calc(100dvh - var(--studio-header));z-index:6;box-shadow:-10px 0 30px #20251e15}.inspector.open{display:flex}.inspector-head #closeLayers{display:block}.tools{padding:5px 6px max(5px,env(safe-area-inset-bottom));gap:0}.tools button{min-height:44px}.tools small{display:none}.tools .tool-divider{display:none}.color-tool{padding:3px 0}.color-tool small{display:none}.editor-options{padding:0 8px;gap:4px}.canvas-toolbar{gap:1px}.stage{margin:8px 8px 0}.bottom-bar{height:44px;font-size:9px;padding:0 10px}.bottom-bar .compact-history{display:flex}.compact-history button{min-height:44px;font-size:22px}.bottom-bar #toolHint{display:none}.header-history{display:none}.canvas-toolbar .zoom-controls,.canvas-toolbar .zoom-controls button{height:44px;min-height:44px}.layer .eye,.layer .lock{width:44px;min-width:44px}.layer-action-grid button{min-height:44px}.context-bar{gap:8px}.context-bar .context-selection>span{display:none}.local-note{font-size:9px}.header-actions #projects{display:block}}
@media(max-height:600px){:root{--studio-header:56px;--studio-options:50px}.brand>span{font-size:20px}.workspace-switch button{min-height:42px;min-width:68px}.header-actions .primary{padding:0 14px}.document input{font-size:12px}.inspector-head{height:46px}}
@media(max-width:700px){:root{--studio-header:56px;--studio-options:50px}header{padding:0 10px;gap:8px}.brand>span,.document,.header-actions #projects{display:none}.brand{width:30px}.brand svg{width:26px}.header-actions{margin-left:auto}.header-actions #help{display:none}.workspace-switch{padding:1px}.workspace-switch button{min-width:65px;padding:2px 8px;min-height:44px}.tool-identity{display:none}.context-bar{gap:6px}.canvas-toolbar .zoom-controls button{min-width:32px;padding:0 5px}.canvas-toolbar #fit{min-width:49px}.canvas-toolbar #toggleLayers,.canvas-toolbar #focusMode{min-width:40px;padding:0 5px}.context-color{padding:0 3px}.context-bar button{padding:0 5px}.alignment-grid{grid-template-columns:repeat(2,1fr)}}

.context-bar input[type=number],.context-bar input[type=range]{height:44px;min-height:44px}.context-color{min-width:44px;min-height:44px;justify-content:center}.layer .lock{color:#6d7565}@media(max-height:600px){.workspace-switch button{min-height:44px}}@media(max-width:1000px),(max-height:600px){.layer-current button{min-height:44px}}
.focus-controls{position:fixed;right:max(12px,env(safe-area-inset-right));top:max(12px,env(safe-area-inset-top));display:flex;align-items:center;gap:2px;padding:3px;border:1px solid var(--line);border-radius:10px;background:var(--panel);box-shadow:0 4px 18px #0001;z-index:30}.focus-controls>button{min-width:44px;min-height:44px;font-size:22px;padding:0 8px}.focus-controls .exit-focus{position:static;border:0;box-shadow:none;font-size:12px;min-width:0;gap:8px;border-left:1px solid var(--line);border-radius:0 7px 7px 0;margin-left:3px;padding:0 11px}@media(max-width:1000px),(max-height:600px){.inspector .local-note{display:none}.layer-current{display:none}.layer-action-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:2px}.layer-action-grid button{font-size:9px;padding:0 1px;min-height:44px}.layer-actions{padding:8px 12px}.layer-title{height:44px}}
@media(max-width:1000px),(max-height:600px){.layer-action-grid button{font-size:10px}}
.context-group button[aria-pressed=true]{background:#edd9df;color:#763d50;border-color:#c68c9d}.context-group #paintOpacity{width:66px;padding-left:8px;padding-right:4px}.paint-panel{margin-top:16px}.transparent-board{background-color:white;background-image:conic-gradient(#dedbd7 25%,transparent 0 50%,#dedbd7 0 75%,transparent 0);background-size:20px 20px}.transparent-board #canvas{background:transparent}
.shape-source-label{display:flex;align-items:center;gap:16px;font-size:13px;margin:18px 0}.shape-source-label select{min-width:0;flex:1;max-width:100%;height:44px;border:1px solid var(--line);border-radius:8px;background:white;padding:0 10px;font-size:16px;color:var(--ink)}.shape-operations{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.shape-operations button{min-height:82px;display:flex;flex-direction:column;align-items:center;justify-content:center;border:1px solid var(--line);font-size:12px;gap:2px}.shape-operations [aria-pressed=true]{border-color:#a84863;background:#f3e7eb;color:#763d50}.shape-preview{height:180px;border:1px solid var(--line);border-radius:10px;background-color:white;background-image:conic-gradient(#f0ede9 25%,transparent 0 50%,#f0ede9 0 75%,transparent 0);background-size:20px 20px;padding:16px}.shape-preview svg{display:block;width:100%;height:100%}.shape-open{margin-top:14px;border:1px solid var(--line);min-height:44px}.shape-panel{margin-top:16px}@media(max-height:600px){.shape-preview{height:116px}.shape-operations button{min-height:64px}.shape-operations svg{height:30px}}

.shape-root-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.shape-root-actions button{font-size:10px;min-height:44px;border:1px solid var(--line);padding:0 3px}.shape-root-actions [aria-pressed=true]{background:#f3e7eb;color:#763d50;border-color:#b86d83}
@media(max-height:600px) and (min-width:700px){
 #modal:has(#shapePreview){width:min(920px,96vw);max-height:96dvh;padding:10px 20px 14px}
 #modal:has(#shapePreview) .modal-heading{margin-bottom:4px}
 #modal:has(#shapePreview) #modalBody{display:grid;grid-template-columns:1.15fr 1fr;gap:6px 18px}
 #modal:has(#shapePreview) h1{grid-column:1;grid-row:1;margin:0;font-size:25px}
 #modal:has(#shapePreview) .shape-intro{grid-column:1;grid-row:2;font-size:10px;line-height:1.5;margin:0}
 #modal:has(#shapePreview) .shape-source-label{grid-column:1;grid-row:3;margin:0;font-size:11px;gap:10px}
 #modal:has(#shapePreview) .shape-operations{grid-column:1;grid-row:4;gap:5px}
 #modal:has(#shapePreview) .shape-operations button{min-height:58px;font-size:11px}
 #modal:has(#shapePreview) #shapeOperationHint{grid-column:1;grid-row:5;margin:0;font-size:10px;line-height:1.5}
 #modal:has(#shapePreview) .shape-preview{grid-column:2;grid-row:1/5;height:100%;min-height:170px;max-height:210px;padding:10px}
 #modal:has(#shapePreview) .shape-footnote{grid-column:2;grid-row:5;margin:0;font-size:9px;line-height:1.5}
 #modal:has(#shapePreview) .project-actions{grid-column:1/-1;grid-row:6;justify-content:flex-end;margin:0;gap:8px}
}
@media(min-height:601px) and (max-height:850px){#modal:has(#shapePreview) .shape-preview{height:140px}}
.photo-panel .wide-button{display:block;width:100%;min-height:44px}.photo-editor{display:grid;grid-template-columns:1.1fr 1fr;gap:24px}.photo-editor-preview{min-width:0;display:flex;flex-direction:column}.photo-preview-title{display:flex;align-items:center;justify-content:space-between;gap:6px;font-size:12px}.photo-preview-title button{font-size:11px;border:1px solid var(--line);padding:0 8px}.photo-preview-title [aria-pressed=true]{background:var(--soft);color:var(--pink)}.photo-preview-board{background-color:#e9e6e1;background-image:conic-gradient(#ddd9d3 25%,transparent 0 50%,#ddd9d3 0 75%,transparent 0);background-size:20px 20px;border-radius:10px;min-height:180px;height:330px;margin-top:10px;display:flex;align-items:center;justify-content:center;overflow:hidden}.photo-preview-board svg{width:100%;height:100%;display:block}.photo-editor-preview>p{font-size:10px}.photo-editor-settings{min-width:0}.photo-tabs{display:flex;border-bottom:1px solid var(--line);gap:5px}.photo-tabs button{flex:1;font-size:12px;border-radius:0}.photo-tabs [aria-selected=true]{border-bottom:2px solid var(--pink);color:var(--pink);font-weight:600}#photoControls{height:360px;overflow:auto;overscroll-behavior:contain;padding:6px 4px}.photo-control{margin:8px 0}.photo-control label{display:flex;justify-content:space-between;align-items:center;font-size:12px;min-height:20px}.photo-control output{font-size:11px;color:var(--muted);font-variant-numeric:tabular-nums}.photo-control>div{display:flex;align-items:center;gap:8px}.photo-control input{flex:1;min-width:0;min-height:36px;accent-color:var(--pink)}.photo-control button{min-width:44px;min-height:44px;padding:0;font-size:20px}#photoControls .muted{font-size:10px;line-height:1.6}.photo-preset{width:100%;border:1px solid var(--line);margin:4px 0;text-align:left}.photo-editor-footer{display:flex;align-items:center;gap:10px;margin-top:16px;border-top:1px solid var(--line);padding-top:12px}.photo-editor-footer>span{flex:1;font-size:10px;color:var(--muted)}.photo-editor-footer button{font-size:12px}#modal:has(#photoPreview){width:min(1000px,96vw)}@media(max-height:600px) and (min-width:700px){#modal:has(#photoPreview){padding:10px 20px;max-height:96dvh}#modal:has(#photoPreview) .modal-heading{margin-bottom:0}#modal:has(#photoPreview) h1{font-size:24px;margin:0 0 8px}.photo-preview-board{height:190px;min-height:120px}.photo-editor{gap:20px}#photoControls{height:195px}.photo-control{margin:3px 0}.photo-editor-footer{margin-top:5px;padding-top:5px}.photo-editor-preview>p{margin:4px 0}}@media(max-width:699px){.photo-editor{grid-template-columns:1fr;gap:10px}.photo-preview-board{height:180px}.photo-editor-footer>span{display:none}#photoControls{height:230px}.photo-editor-footer{justify-content:space-between}}
#paintTarget{height:44px;min-height:44px;max-width:160px;border:1px solid var(--line);border-radius:7px;background:var(--panel);color:var(--ink);font-size:12px;padding:0 6px}.local-adjustment-panel .wide-button{width:100%;display:block}.photo-editor-footer{flex-wrap:wrap}.photo-editor-footer>span{min-width:120px}@media(max-height:600px){.photo-editor-footer{flex-wrap:nowrap}.photo-editor-footer>span{display:none}.photo-editor-footer .primary{margin-left:auto}}
.brush-settings{max-width:440px}.brush-settings>input[type=range],.brush-settings>div>input[type=range]{width:100%;min-height:44px;accent-color:var(--pink)}.brush-settings label{display:flex;align-items:center;justify-content:space-between;font-size:13px;min-height:36px;margin:4px 0}.brush-settings select{min-height:44px;border:1px solid var(--line);border-radius:7px;max-width:190px;background:var(--panel);font-size:14px;padding:0 8px}.brush-settings output{font-size:12px;color:var(--muted)}
.photo-panel .primary{background:var(--ink);color:white}.photo-panel .primary:hover{background:#42463e}
.corrections-panel{margin-top:12px}.correction-row{display:flex;gap:4px;margin:4px 0;border:1px solid var(--line);border-radius:7px;overflow:hidden}.correction-row>button:first-child{flex:1;min-width:0;text-align:left;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}.correction-row>button:last-child{width:44px;min-width:44px;padding:0}.correction-row [aria-pressed=true]{background:var(--soft);color:var(--pink);font-weight:600}#photoCorrectionSettings{border-top:1px solid var(--line);margin-top:10px;padding:4px 0 10px}#photoCorrectionSettings>input[type=range]{width:100%;min-height:44px;accent-color:var(--pink)}#photoCorrectionSettings input[type=text]{width:160px;max-width:70%;min-height:44px;border:1px solid var(--line);padding:0 8px}.correction-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.correction-actions button{min-height:44px;border:1px solid var(--line);font-size:10px;padding:0 4px}.corrections-panel .wide-button{width:100%;min-height:44px}.corrections-panel .primary{background:var(--ink);color:white}.photo-editing-name{font-size:11px!important;color:var(--pink);margin:0 0 8px!important;overflow-wrap:anywhere}@media(max-height:600px) and (min-width:700px){#photoControls{height:170px}.photo-preview-board{height:165px}.photo-editing-name{margin-bottom:4px!important}.photo-editor-preview>p{font-size:9px;line-height:1.4}}
@media(min-height:601px) and (max-height:850px){#photoControls{height:320px}.photo-preview-board{height:290px}}
#contextArea select{min-width:0;max-width:140px;min-height:44px;border:1px solid var(--line);border-radius:7px;background:var(--panel);font-size:12px;padding:0 6px;color:var(--ink)}.selection-feather{display:flex;justify-content:space-between;font-size:13px;margin-top:18px}#selectionFeather{width:100%;min-height:44px;accent-color:var(--pink)}.selection-actions{display:grid;gap:10px;margin:16px 0}.selection-actions button{min-height:48px;border:1px solid var(--line);text-align:left;padding:0 16px}.selection-actions .primary{background:var(--ink);color:white}@media(max-height:600px){.selection-actions{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.selection-actions button{font-size:12px;padding:0 10px}}
@media(max-height:600px){#modal:has(#selectionFeather){padding:10px 20px;max-height:96dvh}#modal:has(#selectionFeather) .modal-heading{margin-bottom:0}#modal:has(#selectionFeather) h1{font-size:25px;margin:4px 0}#modal:has(#selectionFeather) #modalBody>p:first-of-type{display:none}#modal:has(#selectionFeather) .selection-feather{margin-top:6px}#modal:has(#selectionFeather) p{font-size:11px;line-height:1.5;margin:8px 0}#modal:has(#selectionFeather) .selection-actions{margin:8px 0}#modal:has(#selectionFeather) .project-actions{margin-top:8px}}
#stampStatus{font-size:11px;color:var(--muted);padding:0 6px}.retouch-panel .wide-button{display:block;width:100%;min-height:44px}#stampPickSource[aria-pressed=true]{background:var(--soft);color:var(--pink)}
@media(max-height:850px) and (min-width:700px){#modal:has(#stampSize){width:min(920px,96vw);padding:10px 20px;max-height:96dvh}#modal:has(#stampSize) .modal-heading{margin-bottom:0}#modal:has(#stampSize) h1{font-size:25px;margin:4px 0}#modal:has(#stampSize) .brush-settings{max-width:none;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px 16px}#modal:has(#stampSize) label:has(+ #stampSize){grid-column:1;grid-row:1}#modal:has(#stampSize) label:has(+ #stampOpacity){grid-column:2;grid-row:1}#modal:has(#stampSize) label:has(+ #stampSoftness){grid-column:3;grid-row:1}#stampSize{grid-column:1;grid-row:2}#stampOpacity{grid-column:2;grid-row:2}#stampSoftness{grid-column:3;grid-row:2}#modal:has(#stampSize) label:has(#stampAligned){grid-column:1/-1;grid-row:3;justify-content:flex-start;gap:12px}#modal:has(#stampSize) .brush-settings>p{grid-column:1/-1;grid-row:4;font-size:11px;line-height:1.5;margin:6px 0}#modal:has(#stampSize) .project-actions{margin-top:8px}}

.vector-style-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.vector-style-grid select{width:100%;min-height:44px}.vector-style-grid label{display:grid;gap:6px}#precisionLoupe{position:fixed;width:156px;height:112px;z-index:2000;border:3px solid #fffefa;border-radius:28px;overflow:hidden;background:repeating-conic-gradient(#eee 0 25%,#fff 0 50%) 0/14px 14px;box-shadow:0 5px 24px #292b2940,0 0 0 1px #a8486350;pointer-events:none}#precisionLoupe[hidden]{display:none}#loupeCanvas{width:100%;height:100%;display:block}#precisionLoupe small{position:absolute;right:10px;bottom:5px;background:#fffefadd;padding:1px 4px;border-radius:4px;font-size:10px}.loupe-cross{position:absolute;left:50%;top:50%;width:14px;height:14px;transform:translate(-50%,-50%)}.loupe-cross:before,.loupe-cross:after{content:'';position:absolute;background:#a84863;box-shadow:0 0 0 1px #fff9}.loupe-cross:before{width:14px;height:1px;top:7px}.loupe-cross:after{height:14px;width:1px;left:7px}#loupeMode{min-height:44px;margin-left:12px}#adobeExportStatus,#adobeImportStatus,#svgImportError{line-height:1.6;overflow-wrap:anywhere}
@media(max-height:600px){#modal:has(#vectorActionName){max-height:94dvh;padding:14px 22px}#modal:has(#vectorActionName) h1{font-size:27px;margin:7px 0}#modal:has(#vectorActionName) p{font-size:12px;margin:8px 0}.vector-style-grid{gap:6px}}

.prepared-download{display:inline-flex;min-height:44px;align-items:center;padding:10px 18px;text-decoration:none;border-radius:9px}.prepared-download[hidden]{display:none}
@media(max-height:850px) and (min-width:700px){
 #modal:has(#vectorActionName){width:min(920px,96vw);max-height:96dvh;padding:10px 20px}
 #modal:has(#vectorActionName) h1{font-size:27px;margin:6px 0}
 #modal:has(#vectorActionName) .modal-heading{margin-bottom:4px}
 #modal:has(#vectorActionName) p{font-size:12px;line-height:1.45;margin:6px 0}
 #modal:has(#vectorActionName) .project-actions{margin-top:8px;gap:6px}
 #modal:has(#vectorActionName) .vector-style-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-top:6px}
 #modal:has(#vectorActionName) .vector-style-grid label{font-size:12px;gap:3px}
 #modal:has(#vectorActionName) select{font-size:13px}
}

#multiToggle[aria-pressed=true]{background:#f0dbe0;color:#763d50}.layer.multi-picked{background:#f6e9ee;box-shadow:inset 3px 0 #a84863}#activeContour{width:100%;min-height:44px}.multi-help{font-size:12px;line-height:1.5}

#pastedSVG{display:block;width:100%;resize:vertical;min-height:120px;max-height:40dvh;font:12px/1.5 monospace;padding:12px;border:1px solid #ddd4d6;border-radius:8px}#pasteSVGError{font-size:13px;color:#763d50}.multi-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
@media(max-height:850px) and (min-width:700px){#modal:has(#multiDone){width:min(980px,96vw);max-height:96dvh;padding:10px 20px}#modal:has(#multiDone) h1{font-size:27px;margin:6px 0}#modal:has(#multiDone) .modal-heading{margin-bottom:4px}#modal:has(#multiDone) p{font-size:12px;line-height:1.35;margin:5px 0}#modal:has(#multiDone) .multi-actions{grid-template-columns:repeat(6,minmax(0,1fr));margin:7px 0}#modal:has(#multiDone) button{font-size:12px;min-height:44px;padding:6px 8px}#modal:has(#multiDone) .alignment-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;margin-top:7px}#modal:has(#multiDone) .project-actions{margin-top:7px}}

#pdfExportPreview{margin:12px 0}#pdfExportPreview canvas{display:block;max-width:100%;height:auto;border:1px solid #ddd4d6;background:#fff}#pdfExportPreview small{display:block;margin-top:5px;color:#777;font-size:11px}

.ai-warning{padding:12px 14px;border-left:3px solid #a84863;background:#f8edf1;font-size:13px;line-height:1.6}.ai-source-export{border-top:1px solid #e5d8dc;margin-top:20px;padding-top:8px}#aiArchiveStatus{font-size:12px;overflow-wrap:anywhere}#aiSourceName{font-weight:600;overflow-wrap:anywhere}#modal:has(#aiSourceName) p{line-height:1.55}#pdfImportMode{display:block;width:100%;min-height:44px;margin-top:6px}
.ai-native-details{padding:8px 12px;border:1px solid #e7d8dd;border-radius:8px;margin:8px 0}.ai-native-details summary{min-height:36px;display:list-item;align-content:center;cursor:pointer;font-size:14px}.ai-native-details p{font-size:13px}@media(max-height:600px) and (min-width:700px){#modal:has(#aiSourceName){width:min(920px,96vw);padding:10px 20px;max-height:96dvh}#modal:has(#aiSourceName) h1{font-size:27px;margin:6px 0}#modal:has(#aiSourceName) p{font-size:12px;line-height:1.4;margin:6px 0}#modal:has(#aiSourceName) .modal-heading{margin-bottom:4px}#modal:has(#aiSourceName) .project-actions{margin-top:8px}#modal:has(#aiSourceName) .ai-native-details{margin:6px 0;padding:4px 10px}}

.ai-edit-report{margin:12px 0;padding:12px;border:1px solid #dfd5d8;border-radius:8px}.ai-edit-report p{font-size:13px;margin:8px 0}.ai-edit-report label{font-size:13px;line-height:1.5;display:flex;gap:9px;align-items:flex-start}.ai-edit-report [hidden]{display:none}.ai-edit-report input{min-width:22px;min-height:22px;margin-top:0}.ai-native-details summary{min-height:44px}

#modal:has(#fxPreview){width:min(1050px,96vw)}#fxControls{height:350px;overflow:auto;overscroll-behavior:contain;padding:8px 4px}.fx-select-label{display:block;font-size:12px}.fx-select-label select{width:100%;min-height:44px;margin:8px 0 12px;padding:0 10px;background:var(--panel);border:1px solid var(--line);border-radius:7px;color:var(--ink)}.fx-look-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px}.fx-look-grid button{font-size:12px;min-height:44px;margin:0}.fx-look-grid [aria-pressed=true]{border-color:var(--pink);background:var(--soft);color:var(--pink)}.fx-global{display:flex;flex-wrap:wrap;gap:10px;align-items:center;border-top:1px solid var(--line);padding-top:12px;margin-top:12px;font-size:12px}.fx-global label{display:flex;align-items:center;gap:8px;min-height:44px}.fx-global input[type=range]{flex:1;min-width:100px;max-width:200px;min-height:44px;accent-color:var(--pink)}.fx-global input[type=checkbox]{width:20px;height:20px;accent-color:var(--pink)}.fx-global .primary{margin-left:auto}.fx-tabs button{padding:0 6px;font-size:11px;min-height:44px}#fxHelp,#fxControls .muted{font-size:11px;line-height:1.6}#fxStrengthValue{font-variant-numeric:tabular-nums}.fx-preview-board svg{touch-action:manipulation}.fx-preview-board:has(svg){cursor:crosshair}@media(max-height:600px) and (min-width:700px){#modal:has(#fxPreview){padding:10px 18px;max-height:96dvh}#modal:has(#fxPreview) h1{font-size:24px;margin:0 0 6px}#modal:has(#fxPreview) .modal-heading{margin-bottom:0}#fxControls{height:185px}.fx-preview-board{height:200px;min-height:100px}#fxHelp{font-size:10px;margin:4px 0}.fx-global{margin-top:5px;padding-top:4px;gap:8px}.fx-global button{font-size:11px;padding:0 10px}.fx-global label{font-size:11px}.fx-global input[type=range]{max-width:140px}}@media(max-width:699px){#fxControls{height:230px}.fx-preview-board{height:180px}.fx-global input[type=range]{max-width:120px}.fx-global label{font-size:11px}.fx-global{gap:6px}.fx-global button{font-size:11px;padding:0 10px}}
@media(max-height:600px) and (min-width:700px){#modal:has(#fxPreview) .fx-preview-board{height:145px;min-height:90px}#fxControls{height:165px}#fxHelp{font-size:9px;line-height:1.35;margin:3px 0}.fx-global{position:sticky;bottom:-10px;background:var(--panel);z-index:2}}
