/* Drawing compare: the shared viewer shell (site/apps/viewer.css: toolbar, buttons, drop card, dialog, status; the More menu is ../toolbar.css)
   first, then only .dc rules: two file slots, the summary, the picture area and the list of changed areas. */
/* ../viewer.css and ../toolbar.css are linked by the page before this file (site/sitegen/apps.py SHARED_CSS). */

.dc{--dc-stage:#e9ebee}
.dc-body{position:relative;min-height:440px;background:var(--stage,var(--bg2))}
.dc-pick{display:flex;align-items:center;justify-content:center;min-height:440px;padding:16px}
.dc-slots[hidden],.dc-pick[hidden],.dc-res[hidden],.dc-err[hidden],.dc-page[hidden],.dc-text[hidden],.dc-toolhint[hidden]{display:none}
.dc-drop{max-width:640px}
.dc-slots{display:flex;align-items:stretch;gap:8px;margin:4px 0 16px}
.dc-slot{flex:1 1 0;min-width:0;display:flex;flex-direction:column;gap:6px;text-align:left}
.dc-slot-k{font:600 12px/1.2 var(--sans);letter-spacing:.06em;text-transform:uppercase;color:var(--ink)}
.dc-slot-k::before{content:"";display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:6px;vertical-align:-1px;background:rgb(214,40,40)}
.dc-slot[data-slot="neu"] .dc-slot-k::before{background:rgb(28,98,222)}
.dc-slot-b{display:flex;flex-direction:column;align-items:flex-start;gap:4px;min-height:96px;padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--bg);color:var(--ink);text-align:left;width:100%}
.dc-slot-b:hover{border-color:var(--accent)}
.dc-slot.on .dc-slot-b{border-color:color-mix(in srgb,var(--accent) 50%,var(--line));background:var(--accent-bg)}
.dc-slot-name{font-size:14.5px;overflow-wrap:anywhere}
.dc-slot-sub{font-size:12.5px;color:var(--muted)}
.dc-page{display:flex;gap:6px;align-items:center;font-size:13px;color:var(--muted)}
.dc-page select{flex:1;min-height:36px;border:1px solid var(--line);border-radius:8px;background:var(--bg);color:var(--ink);font:inherit}
.dc-swap{align-self:center;min-height:44px;min-width:44px;padding:0;border-radius:50%;background:var(--bg2);border:1px solid var(--line);margin-top:18px}
.dc-err{margin:16px;padding:12px 16px;border:1px solid color-mix(in srgb,var(--bad,#c0392b) 40%,var(--line));border-radius:12px;background:var(--card)}
.dc-err p{margin:4px 0}
.dc-sum{padding:12px 16px 8px;border-bottom:1px solid var(--line);background:var(--card)}
.dc-note{font-size:13.5px;margin:6px 0 0;padding:6px 10px;border-radius:8px;background:color-mix(in srgb,#f5a400 14%,var(--card));display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.dc-main{display:grid;grid-template-columns:minmax(0,1fr) 320px;min-height:560px}
.dc-stage{position:relative;min-height:560px;background:var(--dc-stage);overflow:hidden;touch-action:none}
.dc-stage.dc-tool .dc-cv{cursor:crosshair}
.dc-cv{position:absolute;inset:0;width:100%;height:100%;cursor:grab;outline:none}
.dc-cv:focus-visible{box-shadow:inset 0 0 0 3px var(--accent)}
.dc-legend{position:absolute;left:8px;bottom:8px;z-index:2;display:flex;flex-wrap:wrap;gap:10px;font-size:12.5px;background:color-mix(in srgb,var(--card) 90%,transparent);border:1px solid var(--line);border-radius:999px;padding:4px 12px;pointer-events:none}
.dc-legend i{display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:5px;vertical-align:-1px}
.dc-toolhint{position:absolute;top:8px;left:50%;transform:translateX(-50%);z-index:2;margin:0;font-size:13px;background:#1e2229;color:#fff;border-radius:999px;padding:6px 14px;max-width:90%;text-align:center;pointer-events:none}
.dc-list{border-left:1px solid var(--line);overflow-y:auto;max-height:640px;background:var(--card);padding:10px 0}
.dc-list h3{font:600 12px/1.3 var(--sans);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);margin:2px 14px 8px}
.dc-items{list-style:none;margin:0;padding:0}
.dc-item{display:flex;align-items:stretch;border-top:1px solid var(--line)}
.dc-item.on{background:var(--accent-bg)}
.dc-item-b{flex:1;display:flex;justify-content:flex-start;gap:10px;align-items:flex-start;text-align:left;padding:10px 6px 10px 14px;border:0;border-radius:0;background:transparent;color:var(--ink);min-height:44px;font-size:14px}
.dc-item-t{display:flex;flex-direction:column;gap:2px;min-width:0}
.dc-item-t em{font-style:normal;font-family:var(--mono,monospace);font-size:12.5px;overflow-wrap:anywhere}
.dc-item-t small{color:var(--muted);font-size:12px}
.dc-item-x{display:flex;align-items:center;gap:4px;border:0;background:transparent;min-width:44px;padding:0 10px;color:var(--muted);border-radius:0;font-size:12.5px}
.dc-sum:not(:has(p,button:not([hidden]))){display:none}.dc-assist .as-btn{margin-top:4px}
.dc-n{flex:0 0 auto;min-width:24px;height:24px;border-radius:6px;color:#fff;font:600 13px/24px var(--sans);text-align:center}
.dc-added{background:rgb(28,98,222)}.dc-removed{background:rgb(214,40,40)}.dc-changed{background:rgb(140,60,190)}
.dc-none{padding:12px 14px;color:var(--muted);font-size:14px;border-top:1px solid var(--line)}
.dc-ign{padding:0 14px}
.dc-ign .v3-small{margin:4px 4px 0 0}
.dc-text{margin:10px 14px 0;font-size:13.5px}
.dc-text summary{cursor:pointer;font-weight:600;min-height:32px;display:flex;align-items:center}
.dc-text-l{list-style:none;margin:4px 0 0;padding:0}
.dc-text-l button{display:block;border:0;background:transparent;color:var(--ink);text-align:left;padding:6px 0;min-height:36px;font:12.5px var(--mono,monospace);width:100%}
@media (max-width:760px){
  .dc-main{grid-template-columns:1fr}
  .dc-stage{min-height:62vh}
  .dc-list{border-left:0;border-top:1px solid var(--line);max-height:none}
  .dc-drop > p:not(.v3-private){display:none}
  .dc-slots{gap:4px;margin-bottom:12px}
  .dc-slot-b{min-height:64px;padding:8px}
  .dc-slot-b svg{display:none}
  .dc-swap{min-width:36px;min-height:44px;margin-top:16px}
}
/* the list hint sits above the list it explains, never over the drawing (title blocks are at the bottom of the sheet) */
.dc-tip{margin:0 14px 8px;font-size:13.5px;line-height:1.35;color:var(--muted,#6b6b6b)}
.dc-tip[hidden]{display:none}
