.subject-removal-controls{display:grid;gap:10px;min-width:0}
.subject-auto-panel{display:grid;gap:10px;padding:12px;border:1px solid #690730;border-radius:12px;background:#fff;min-width:0}
.subject-status{margin:0;font-size:12px;line-height:1.6;color:#ab5a7c;overflow-wrap:anywhere}
.subject-thumbnail{display:block;max-width:100%;width:100%;height:180px;object-fit:contain;border:1px solid #740634;border-radius:8px;background-color:#fff;background-image:conic-gradient(#e6ebe9 25%,transparent 0 50%,#e6ebe9 0 75%,transparent 0);background-size:16px 16px}
.subject-panel-actions{display:flex;gap:8px;flex-wrap:wrap}
.subject-panel-actions .button{min-height:42px;white-space:normal;line-height:1.5}
.subject-local-note{font-size:11px;line-height:1.6;color:#7a8998}
.subject-dialog{box-sizing:border-box;width:min(1080px,calc(100% - 24px));height:min(940px,calc(100dvh - 24px));max-height:calc(100dvh - 24px);margin:auto;padding:0;border:1px solid #85083c;border-radius:20px;background:#fff;color:#26344e;overflow:hidden}
.subject-dialog[open]{display:flex;flex-direction:column}
.subject-dialog::backdrop{background:#182536a6}
.subject-editor-heading{display:flex;justify-content:space-between;gap:16px;padding:18px 20px;border-bottom:1px solid #740533;flex-shrink:0}
.subject-eyebrow{font-size:10px;letter-spacing:2px;font-weight:750;color:#ce97ad;margin:0 0 6px}
.subject-editor-heading h2{font-size:22px;line-height:1.4;margin:0 0 5px}
.subject-editor-heading p:not(.subject-eyebrow){font-size:12px;line-height:1.6;color:#788699;margin:0;max-width:680px}
.subject-editor-heading>.button{flex-shrink:0;align-self:flex-start}
.subject-editor-heading>div{min-width:0;flex:1}
.subject-editor-heading>.button[aria-label]{font-size:20px;min-width:40px;padding:3px 10px}
.subject-editor-body{display:flex;flex:1;flex-direction:column;gap:10px;min-height:0;overflow:auto;overscroll-behavior:contain;padding:14px 20px;background:#fbfdfc}
.subject-edit-tools,.subject-editor-actions,.subject-editor-zoom{display:flex;gap:7px;flex-wrap:wrap;flex-shrink:0}
.subject-edit-tools{display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}
.subject-editor-more{flex-shrink:0;border-top:1px solid #740533;padding-top:8px;font-size:12px;color:#451b2c}
.subject-editor-more summary{cursor:pointer;padding:8px 0;min-height:28px;box-sizing:border-box}
.subject-editor-more .subject-editor-actions{margin:6px 0 8px}
.subject-dialog .button{min-height:40px;border-radius:9px;padding:8px 12px;border:1px solid #690730;background:#fff;color:#a65677;font:inherit;font-size:12px;line-height:1.5;cursor:pointer;touch-action:manipulation}
.subject-dialog .button[aria-pressed=true]{background:#e60a66;border-color:#972555;color:#cda6b6}
.subject-dialog .button.primary{background:#d49fb5;color:#fff;border-color:#d49fb5}
.subject-dialog .button:disabled{opacity:.4;cursor:default}
.subject-dialog .button:focus-visible{outline:3px solid #b52360;outline-offset:2px}
.subject-editor-settings{display:flex;align-items:center;flex-shrink:0}
.subject-editor-settings label{display:flex;align-items:center;gap:10px;font-size:12px;color:#66798b;flex-wrap:wrap}
.subject-editor-settings input{max-width:140px;accent-color:#d49fb5}
.subject-editor-zoom>span{align-self:center;min-width:45px;text-align:center;font-size:12px;font-weight:700;color:#63788c}
.subject-editor-help{margin:0;font-size:11px;line-height:1.6;color:#77899a;flex-shrink:0}
.subject-editor-viewport{min-height:180px;flex:1 1 240px;overflow:auto;position:relative;padding:10px;box-sizing:border-box;border:1px solid #85083c;border-radius:12px;background:#edf2f0;overscroll-behavior:contain;overflow-anchor:none}
.subject-edit-canvas{display:block;max-width:none;max-height:none;margin:auto;background-color:#fff;background-image:conic-gradient(#5e042a 25%,transparent 0 50%,#5e042a 0 75%,transparent 0);background-size:20px 20px;touch-action:none;user-select:none;-webkit-user-select:none}
.subject-editor-footer{padding:12px 20px;display:flex;justify-content:space-between;gap:12px;align-items:center;border-top:1px solid #780635;background:#fff;flex-shrink:0}
.subject-editor-status{font-size:11px;line-height:1.6;color:#6d8294;margin:0}
.subject-editor-footer-actions{display:flex;gap:8px;flex-shrink:0}
@media(max-width:600px){
 .subject-dialog{width:calc(100% - 16px);height:calc(100dvh - 16px);max-height:calc(100dvh - 16px);border-radius:16px}
 .subject-editor-heading{padding:14px 12px;gap:8px;flex-wrap:nowrap}
 .subject-editor-heading h2{font-size:19px}
 .subject-editor-heading>.button{min-height:40px}
 .subject-editor-body{padding:12px;gap:8px}
 .subject-edit-tools{display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}
 .subject-dialog .button{min-height:44px;padding:7px 8px;font-size:12px}
 .subject-editor-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
 .subject-editor-footer{padding:10px 12px max(10px,env(safe-area-inset-bottom));flex-direction:column;align-items:stretch;gap:8px}
 .subject-editor-footer-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
}
