/* Temporary Pre feature. All page styles are scoped here for clean removal. */
.pre-page [hidden]{display:none!important}
.pre-body{position:absolute;inset:92px 2vw 20px;display:flex;flex-direction:column;gap:10px}
.pre-dropzone{flex:1;min-height:0;width:100%;border:1px dashed #aaa;border-radius:0;background:transparent;color:inherit;font:inherit;font-size:clamp(16px,1.5vw,22px);cursor:pointer;transition:border-color 160ms,background-color 160ms}
.pre-dropzone:hover{border-color:currentColor;background:rgba(128,128,128,.04)}
.pre-page button:focus-visible,.pre-page a:focus-visible{outline:2px solid currentColor;outline-offset:5px}
.pre-page-label{display:flex;align-items:center;justify-content:space-between;gap:18px}
.pre-page-label h2{flex:0 0 auto}
.pre-reader{flex:1;min-height:0;display:flex;flex-direction:column}
.pre-toolbar{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:8px 16px;font-size:12px;min-width:0}
#pre-filename{min-width:0;max-width:22vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-right:auto}
.pre-actions{display:flex;align-items:center;gap:clamp(8px,1.15vw,16px);flex-wrap:wrap}
.pre-actions button,.pre-actions a{background:transparent;border:0;padding:4px 0;font:inherit;color:inherit;text-decoration:none;cursor:pointer}
.pre-actions button:hover,.pre-actions a:hover{font-weight:bold}
.pre-actions button:disabled{opacity:.35;cursor:default;font-weight:normal}
.pre-actions select{background:transparent;color:inherit;border:1px solid #bcbcb8;padding:3px;font:inherit}
.pre-actions select option{color:#171717;background:#dce0e5}
.pre-document{flex:1;min-height:0;border:1px solid #bcbcb8;background:#ccd1d7;overflow:auto;overscroll-behavior:contain;padding:8px;scrollbar-width:thin;color:#171717}
.pre-document canvas{display:block;margin:0 auto;background:#fff;box-shadow:0 1px 5px #0002}
.pre-document:focus-visible{outline:2px solid currentColor;outline-offset:3px}
.pre-feedback{margin:0;font-size:12px;line-height:1.5}
.pre-feedback:empty{display:none}
.pre-drop-overlay{display:none;position:absolute;inset:0;border:2px dashed currentColor;background:rgba(220,224,229,.96);place-items:center;font-size:20px;z-index:2;pointer-events:none}
.pre-page.is-dragging .pre-drop-overlay{display:grid;pointer-events:auto}
.works-mode .pre-drop-overlay{background:rgba(0,0,0,.96)}
/* This small-screen adjustment exists only while the temporary nav link exists. */
@media(max-width:1000px){.pre-page-label{align-items:flex-start;flex-direction:column;gap:8px}.pre-toolbar{justify-content:flex-start;width:100%}#pre-filename{max-width:100%;width:100%}}
@media(min-width:701px) and (max-width:1000px){.pre-body{inset:145px 3vw 18px}}
@media(max-width:700px){header:has([data-pre-nav]:not([hidden])) nav{gap:clamp(10px,3vw,20px)}header:has([data-pre-nav]:not([hidden])) .brand{flex-shrink:0}header:has([data-pre-nav]:not([hidden])) nav a{font-size:clamp(12px,3.5vw,14px)}.pre-body{inset:115px 4vw 18px}.pre-actions{gap:14px}.pre-document{padding:5px}}

/* Temporary Pre: digital theme overrides stay inside this removable feature. */
.digital-theme .pre-body{top:218px;bottom:20px}
.digital-theme .pre-dropzone{border-color:#434b4e;color:#a3a9ac;font-size:clamp(13px,1.4vw,20px)}
.digital-theme .pre-dropzone:hover{border-color:#97a1a6;background:#111617}
.digital-theme .pre-page-label{gap:16px}
.digital-theme .pre-toolbar{font:400 11px/1.5 Arial,Helvetica,sans-serif}
.digital-theme .pre-actions select{border-color:#525b60}
.digital-theme .pre-actions select option{background:#15191a;color:#eee}
.digital-theme .pre-document{border-color:#303739;background:#111516}
.digital-theme .pre-drop-overlay{background:rgba(9,10,10,.96)}
@media(max-width:1000px){.digital-theme .pre-page-label{align-items:flex-start}.digital-theme .pre-body{top:255px}}
@media(max-width:700px){.digital-theme .pre-body{top:238px;left:4vw;right:4vw}}
@media(max-height:550px) and (min-width:701px){.digital-theme .pre-body{top:180px}}
