/* Signal visual authoring: tools stay next to the silhouette, advanced data is opt-in. */
#pfSectionsDialog{width:min(1100px,calc(100vw - 24px))}
#pfShapeModes{display:flex;gap:6px;flex-shrink:0;margin:14px 0 12px}
#pfShapeModes button{flex:1;min-height:44px}
#pfSectionsDialog[data-shape-mode]:not([data-shape-mode=advanced]) #pfSectionsShapeTools,
#pfSectionsDialog[data-shape-mode]:not([data-shape-mode=advanced]) #pfSectionsFootprint,
#pfSectionsDialog[data-shape-mode]:not([data-shape-mode=advanced]) .pf-sections-controls>label:has(#pfSectionsTransition){display:none}
#pfSectionsDialog[data-shape-tab=parts] #pfShapeVisual{display:none}
#pfSectionsDialog .pf-sections-controls{display:flex;flex-direction:column;min-width:0}
#pfSectionsDialog .pf-sections-controls>label:has(#pfSectionsName){order:-2}
#pfSectionsDialog .pf-sections-tabs{order:-1;position:static;margin:8px 0}
#pfSectionsDialog .pf-sections-tabs button{flex:1;min-height:44px}
#pfSectionsDialog #pfSectionsTabShape{font-size:0}
#pfSectionsDialog #pfSectionsTabShape:after{content:'Forma';font-size:13px}
#pfShapeVisual{min-width:0}
.pf-shape-heading{display:flex;gap:8px;align-items:flex-start;justify-content:space-between}
#pfShapeVisual h3{font-size:16px;margin:4px 0}
#pfShapeVisual p{font-size:12px;line-height:1.5;color:#afc1d6;margin:5px 0 10px}
.pf-shape-history{display:flex;gap:4px;flex-shrink:0}
#pfSectionsDialog .pf-shape-history button{min-width:40px;height:40px;font-size:22px}
#pfShapePresets{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;margin:8px 0}
#pfShapePresets button{padding:6px 3px;font-size:12px;min-height:44px}
.pf-shape-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));align-items:end;gap:8px;margin:8px 0}
#pfSectionsDialog .pf-shape-fields label{min-width:0;font-size:11px;margin:0}
#pfSectionsDialog .pf-shape-fields input{min-width:0;min-height:42px;font-size:14px}
#pfShapeViews{display:flex;align-items:center;gap:6px;margin:10px 0 6px}
#pfShapeViews button{min-height:40px}
#pfShapeViews span{margin-left:auto;font-size:11px;color:#afc1d6}
#pfShapeSilhouette{width:100%;height:300px;background:#101725;border:1px solid #425875;border-radius:12px;touch-action:none;box-sizing:border-box;display:block}
#pfShapeSilhouette text{fill:#a7c5d0;font:11px system-ui;pointer-events:none}
.pf-shape-axis{stroke:#71899c;stroke-width:1;stroke-dasharray:4 4}
.pf-shape-outline{fill:#62e9df16;stroke:#62e9df;stroke-width:1.6;pointer-events:none}
.pf-shape-level{stroke:#b7a2ff;stroke-width:.7;stroke-dasharray:3 5;pointer-events:none}
.pf-shape-hit{fill:transparent;cursor:move}
.pf-shape-dot{fill:#101725;stroke:#62e9df;stroke-width:2;pointer-events:none}
#pfShapeSilhouette .selected .pf-shape-dot{fill:#62e9df;stroke:#fff}
#pfShapeSilhouette g:focus{outline:none}
#pfShapeSilhouette g:focus .pf-shape-dot{stroke:#fff;stroke-width:4;fill:#b7a2ff}
.pf-shape-actions{display:flex;gap:8px}
.pf-shape-actions button{flex:1;min-height:44px}
#pfSectionsDialog #pfShapeDelete{min-height:42px;padding:5px}
#pfShapeConvert{padding:14px;border:1px solid #b7a2ff;border-radius:10px}
#pfShapePhoto{width:100%;min-height:40px}
#pfShapeMeta{margin-top:16px;display:grid;gap:8px}
#pfSectionsDialog[data-shape-mode=advanced] #pfShapeMeta #pfShapeDimensions,#pfSectionsDialog[data-shape-mode=advanced] #pfShapePhoto{display:none}
.pf-shape-stroke{fill:none;stroke:#b7a2ff;stroke-width:3;pointer-events:none}
.pf-shape-tangent-line{fill:none;stroke:#b7a2ff;stroke-width:1;pointer-events:none}.pf-shape-tangent-dot{fill:#b7a2ff;stroke:#fff;stroke-width:1;pointer-events:none}
.pf-shape-center{fill:#b7a2ff;stroke:#fff;stroke-width:1.5;pointer-events:none}
#pfShapeSymmetry{margin-left:auto;max-width:52%;font-size:12px}
#pfShapePointType{display:flex;align-items:center;gap:5px;flex-wrap:wrap;margin:8px 0}#pfShapePointType span{font-size:11px;color:#afc1d6}#pfShapePointType button{min-height:40px;padding:6px 10px}
#pfSectionsDialog #pfShapePointType button[aria-pressed=true]{border-color:#b7a2ff!important;background:#453a64!important}
#pfSectionsDialog #pfShapeSilhouette{height:clamp(220px,30vh,300px)}
#pfSectionsDialog #pfShapeModes button[aria-pressed=true],#pfSectionsDialog #pfShapeViews button[aria-pressed=true]{background:#16444e!important;border-color:#62e9df!important;color:#e8fffd!important;box-shadow:inset 0 0 16px #62e9df15}
#pfPhotoChoice{width:min(720px,calc(100vw - 24px));box-sizing:border-box;border:1px solid #425875;border-radius:16px;background:#101725;color:#ecf2fa;padding:24px;max-height:92dvh;overflow:auto}
#pfPhotoChoice::backdrop{background:#050c18ce}
#pfPhotoChoice header{display:flex;align-items:center;justify-content:space-between;gap:12px;background:none;position:static;padding:0}
#pfPhotoChoice h2{font-size:23px;margin:0}
#pfPhotoChoice p,#pfPhotoChoice small{color:#afc1d6;line-height:1.5}
.pf-photo-choice-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:20px 0}
.pf-photo-choice-grid button{display:flex;flex-direction:column;gap:14px;text-align:left;padding:24px 18px;border:1px solid #425875;border-radius:12px;background:linear-gradient(145deg,#1d2b42,#111c2d);color:#ecf2fa}
.pf-photo-choice-grid button:hover,.pf-photo-choice-grid button:focus-visible{border-color:#62e9df}
.pf-photo-choice-grid strong{color:#62e9df;font-size:18px}.pf-photo-choice-grid span{font-size:13px;line-height:1.5}
#pfPhotoToShape{min-height:44px}
#pfShapePhotoReference{padding:10px;border:1px solid #425875;border-radius:8px;margin-top:10px}#pfShapePhotoReference img{display:block;max-width:100%;max-height:240px;margin:10px auto;object-fit:contain}
#pfSectionsDialog:not([data-shape-mode=advanced]) #pfSectionsCanvas{height:410px}
#pfSectionsDialog:not([data-shape-mode=advanced]) .pf-sections-work{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
#pfSectionsDialog[data-shape-mode=profile] #pfShapeSilhouette{height:350px}
@media(max-width:650px){
 .pf-photo-choice-grid{grid-template-columns:1fr}#pfPhotoChoice{padding:16px}#pfPhotoChoice h2{font-size:20px}
 #pfSectionsDialog{width:calc(100vw - 12px);max-height:calc(100dvh - 12px);padding:10px}
 #pfShapeModes{gap:4px;margin:9px 0}#pfShapeModes button{padding:7px 3px;font-size:12px}
 #pfSectionsDialog:not([data-shape-mode=advanced]) .pf-sections-work{display:flex;flex-direction:column;overflow:auto;padding-right:0;gap:10px}
 #pfSectionsDialog:not([data-shape-mode=advanced]) .pf-sections-view,#pfSectionsDialog:not([data-shape-mode=advanced]) .pf-sections-controls{overflow:visible;flex:none}
 #pfSectionsDialog:not([data-shape-mode=advanced]) #pfSectionsCanvas{height:180px}
 #pfSectionsDialog #pfShapeSilhouette{height:300px}
 #pfSectionsDims{font-size:13px;margin-top:6px}.pf-shape-fields{gap:6px}
 #pfSectionsDialog .pf-sections-tabs button{font-size:12px}
 #pfShapeViews span{font-size:10px}#pfSectionsDialog footer{margin-top:8px}
}
