/* Module identification belongs beside the compact EWS workspace. */
#content.ews-tool .ews-title-actions { display:flex; align-items:center; flex-wrap:wrap; gap:12px; }
#content.ews-tool .ews-reference-shortcut { color:#e4aabb; font-size:12px; white-space:nowrap; }
#content.ews-tool .ews-reference { margin-top:22px; border:1px solid var(--ews-line); border-radius:5px; background:var(--ews-surface); scroll-margin-top:100px; }
#content.ews-tool .ews-reference>summary { display:flex; align-items:center; gap:10px; padding:12px 14px; background:var(--ews-raised); cursor:pointer; border-radius:4px; list-style:none; }
#content.ews-tool .ews-reference>summary::-webkit-details-marker { display:none; }
#content.ews-tool .ews-reference>summary::before { content:""; width:7px; height:7px; border-right:2px solid #c8d2d9; border-bottom:2px solid #c8d2d9; transform:rotate(-45deg); flex:none; margin-right:3px; }
#content.ews-tool .ews-reference[open]>summary::before { transform:rotate(45deg); margin-top:-4px; }
#content.ews-tool .ews-reference>summary h2 { margin:0; font-size:16px; line-height:1.3; font-weight:650; }
#content.ews-tool .ews-reference>summary>span { margin-left:auto; color:var(--ews-muted); font-size:11px; }
#content.ews-tool .ews-reference-body { padding:13px; border-top:1px solid var(--ews-line); }
#content.ews-tool .ews-reference-intro { margin:0 0 10px; max-width:80ch; font-size:12px; line-height:1.6; color:#c8d2d9; }
#content.ews-tool .ews-reference-jump { display:flex; flex-wrap:wrap; gap:6px; margin-bottom:12px; }
#content.ews-tool .ews-reference-jump a { display:block; padding:5px 10px; border:1px solid #60717d; border-radius:3px; color:#e3eaf0; background:var(--ews-value); font-size:11px; }
#content.ews-tool .ews-reference-jump a:hover { background:#3c4b55; border-color:#e398aa; }
#content.ews-tool .ews-reference-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
#content.ews-tool .ews-reference-card { min-width:0; display:flex; flex-direction:column; border:1px solid #53616c; border-radius:4px; background:#253038; overflow:hidden; scroll-margin-top:100px; }
#content.ews-tool .ews-reference-card:target { outline:2px solid #ed7891; outline-offset:2px; }
#content.ews-tool .ews-reference-card>header { display:flex; align-items:center; gap:10px; padding:9px 11px; background:#35434d; border-bottom:1px solid #53616c; }
#content.ews-tool .ews-reference-card h3 { margin:0; font-size:16px; line-height:1.2; font-weight:650; letter-spacing:0; }
#content.ews-tool .ews-reference-card>header span { margin-left:auto; color:#c3d0d9; font-size:10px; text-align:right; }
#content.ews-tool .ews-reference-card-body { display:grid; grid-template-columns:minmax(125px,.78fr) minmax(0,1fr); align-items:start; gap:12px; padding:11px; flex:1; }
#content.ews-tool .ews-reference-photos { display:grid; gap:8px; min-width:0; }
#content.ews-tool .ews-reference figure { margin:0; min-width:0; }
#content.ews-tool .ews-reference-photo { position:relative; display:block; width:100%; background:#fff; border:1px solid #71818c; border-radius:3px; overflow:hidden; cursor:zoom-in; }
#content.ews-tool .ews-reference-photo img { display:block; width:100%; height:226px; object-fit:contain; margin:0; }
#content.ews-tool .ews-reference-photos-pair img { height:102px; }
#content.ews-tool .ews-photo-enlarge { position:absolute; bottom:5px; right:5px; background:#1e272de8; color:#fff; padding:3px 6px; border-radius:3px; font-size:10px; line-height:1.4; }
#content.ews-tool .ews-reference figcaption { color:#adbecb; font-size:10px; line-height:1.4; margin-top:4px; }
#content.ews-tool .ews-reference-facts { min-width:0; }
#content.ews-tool .ews-reference dl { margin:0; display:grid; gap:8px; }
#content.ews-tool .ews-reference dt { color:#aebfcb; font-size:10px; font-weight:400; line-height:1.3; margin:0 0 2px; }
#content.ews-tool .ews-reference dd { color:#edf3f7; font-size:12px; font-weight:500; line-height:1.45; margin:0; overflow-wrap:anywhere; }
#content.ews-tool .ews-reference-note { margin:10px 0 0; padding-top:8px; border-top:1px solid #43535e; color:#bfccd5; font-size:11px; line-height:1.5; }
#content.ews-tool .ews-reference-card>footer { display:flex; flex-wrap:wrap; gap:4px 9px; padding:8px 11px; border-top:1px solid #43535e; font-size:10px; line-height:1.5; color:#adbecb; }
#content.ews-tool .ews-reference a:not(.ews-reference-photo):not(.ews-reference-jump a),#content.ews-tool .ews-photo-dialog a { color:#efb5c4; text-decoration:underline; text-underline-offset:2px; }
#content.ews-tool .ews-reference-footnote { margin:12px 0 0; color:#aebfcb; font-size:10px; line-height:1.6; max-width:100ch; }
#content.ews-tool .ews-photo-dialog { width:min(1060px,calc(100% - 28px)); max-height:92vh; }
#content.ews-tool .ews-photo-dialog h2 { font-size:16px; }
#content.ews-tool .ews-photo-view { min-height:120px; background:#172027; padding:12px; }
#content.ews-tool .ews-photo-view img { display:block; width:100%; height:auto; max-height:calc(92vh - 155px); object-fit:contain; }
#content.ews-tool .ews-photo-dialog footer { flex-wrap:wrap; gap:8px 16px; }
#content.ews-tool #ews-photo-credit { margin-right:auto; font-size:11px; color:#c3d0d9; }
#content.ews-tool .ews-photo-fallback { padding:18px 10px; color:#35434d; font-size:12px; line-height:1.5; }
#content.ews-tool .ews-photo-fallback:not([hidden]) { display:block; }
#content.ews-tool .ews-reference [hidden],#content.ews-tool .ews-photo-dialog [hidden] { display:none !important; }
#content.ews-tool .ews-reference :focus-visible,#content.ews-tool .ews-reference-shortcut:focus-visible,#content.ews-tool .ews-photo-dialog :focus-visible { outline:2px solid #ed7891; outline-offset:3px; }
@media(max-width:1150px) {
 #content.ews-tool .ews-reference-grid { grid-template-columns:1fr; }
 #content.ews-tool .ews-reference-card-body { grid-template-columns:minmax(150px,.6fr) minmax(0,1fr); }
 #content.ews-tool .ews-reference-photos-pair { grid-template-columns:1fr 1fr; }
 #content.ews-tool .ews-reference-photos-pair img { height:226px; }
}
@media(max-width:540px) {
 #content.ews-tool .ews-reference>summary { flex-wrap:wrap; gap:7px; padding:11px; }
 #content.ews-tool .ews-reference>summary>span { margin-left:20px; flex-basis:100%; }
 #content.ews-tool .ews-reference-body { padding:10px; }
 #content.ews-tool .ews-reference-card-body { grid-template-columns:1fr; gap:11px; }
 #content.ews-tool .ews-reference-photos-pair img { height:170px; }
 #content.ews-tool .ews-reference dl { grid-template-columns:1fr 1fr; gap:10px; }
 #content.ews-tool .ews-reference dd { font-size:11px; }
 #content.ews-tool .ews-reference-note { font-size:11px; }
 #content.ews-tool .ews-photo-dialog h2 { font-size:14px; }
}
