/*! Copyright (c) 2026 Mark T. Fulwider. All rights reserved. */
/* Notes is the common document page, independent of submission format. */
body.document-page #main{padding:16px 22px;max-width:none;margin:0;min-width:0}
body.document-page .breadcrumbs{margin:0 0 20px;font-size:14px}
body.document-page .editor,body.document-page .edit-source{padding:0;background:#fff;border:1px solid var(--line);border-radius:2px}
body.document-page .shared-document-workbench{display:block;margin:0}
#main .page-edit-toolbar{gap:1px;margin:0;padding:3px;border-width:0 0 1px;min-height:36px;border-radius:0;flex-wrap:wrap;z-index:6;background:#f3f5f7}
#main .page-edit-toolbar button,#main .page-edit-toolbar select,#main .page-edit-toolbar summary{font:13px/20px var(--sans);min-height:28px;padding:3px 6px;margin:0;border:1px solid transparent;border-radius:2px;background:transparent;color:#213945;box-shadow:none;white-space:nowrap;cursor:pointer;width:auto}
#main .page-edit-toolbar button:hover,#main .page-edit-toolbar summary:hover{background:#e3e9ed;border-color:#bdcdd5}
#main .page-edit-toolbar button[aria-pressed=true]{background:#cbdce7;border-color:#8aaabb}
#main .page-edit-toolbar select{height:29px;padding:2px;max-width:100px;border:1px solid #d6dee3;background:white}
#main .page-edit-toolbar [data-page-format=font]{width:102px}#main .page-edit-toolbar [data-page-format=size]{width:51px}
#main .page-edit-toolbar [data-page-format=header]{width:80px}#main .page-edit-toolbar [data-page-format=align]{width:67px}
#main .page-color{position:relative;display:block;flex:0 0 25px;width:25px;padding:0;margin:0;font:bold 17px Georgia;text-align:center;text-decoration:underline;text-decoration-thickness:3px;text-decoration-color:#baa24e}
#main .page-color input{position:absolute;inset:0;width:100%;height:100%;opacity:0;padding:0;cursor:pointer}
#main .page-edit-toolbar>.page-menu{position:relative;margin:0;flex:0 0 auto}
#main .page-edit-toolbar>.page-menu[open]{position:relative;right:auto;top:auto;min-width:0;border:0;background:transparent;box-shadow:none}
.page-menu-body{position:absolute;right:0;top:100%;width:205px;display:grid;gap:5px;padding:10px;background:#fff;border:1px solid #bdcdd5;box-shadow:0 5px 12px #10253124;z-index:30}
#main .page-menu-body select{max-width:none;width:100%;height:32px}
#main .page-menu-body details{font-size:13px}
.document-title-row{display:flex;align-items:center;gap:10px;border-bottom:1px solid var(--line);padding:0 12px;position:relative;z-index:5}
#main .document-title-row #record-title{border:0;border-radius:0;background:white;margin:0;padding:8px 0;flex:1;min-width:0}
.document-index{flex:0 0 auto;position:relative;font:14px var(--sans)}
.document-index>summary{cursor:pointer;list-style:none;background:#183744;color:#fff;padding:5px 12px;white-space:nowrap}
.document-index-body{position:absolute;right:0;top:100%;width:min(360px,80vw);max-height:65dvh;overflow:auto;padding:16px;display:grid;gap:10px;background:white;border:1px solid #bdcdd5;box-shadow:0 5px 14px #142c392b;z-index:30}
.document-index-body .button{font-size:13px!important;min-height:28px!important;padding:4px!important;justify-content:flex-start}
.document-index-body>details{font-size:14px}.document-index-body .archive-lines{max-height:240px;overflow:auto;font-size:12px}
.document-index-body #save-status{display:block;font-size:12px}
.document-page .local-document-reader{margin:0!important;border:0;height:calc(100dvh - 290px);min-height:360px}
.document-page .local-document-reader[hidden],.document-page #record-body[hidden]{display:none!important}
.shared-page-sheet.ql-container{height:calc(100dvh - 290px);min-height:360px;overflow:auto;background:#dfe5e8;padding:24px;border:0;font:12pt/1.5 Georgia}
.shared-page-sheet .ql-editor{height:auto;overflow:visible;margin:0 auto;background:#fff;box-shadow:0 2px 7px #0004;line-height:1.5;color:#172a33;white-space:pre-wrap;width:100%;max-width:100%}
.shared-page-sheet .ql-editor p{margin:0 0 .65em}.shared-page-sheet .ql-editor h1{font-size:2em}.shared-page-sheet .ql-editor h2{font-size:1.5em}.shared-page-sheet .ql-editor h3{font-size:1.17em}
.shared-page-sheet .study-inline-image{break-inside:avoid;margin-top:1em;margin-bottom:1em;cursor:pointer;max-width:100%}
.shared-page-sheet .study-inline-image img{width:100%;height:auto;display:block}
.shared-page-sheet .study-inline-image:hover{outline:2px solid #6a99b4}
.page-editor-status:empty{display:none}.page-editor-status{margin:0;padding:5px 12px;font:12px/1.4 var(--sans);color:#57747f}
.page-image-tools{display:flex;align-items:center;gap:12px;flex-wrap:wrap;background:#edf2f5;border-top:1px solid var(--line);padding:6px 12px;font:13px var(--sans)}
.page-image-tools[hidden]{display:none!important}.page-image-tools label{display:flex;align-items:center;gap:8px;margin:0;font-size:13px}.page-image-tools input{width:110px;padding:0}.page-image-tools select{width:90px;font-size:13px;padding:3px}.page-image-tools button{font-size:13px;padding:4px 8px;border:1px solid #bccbd2;background:white}
body.document-page.note-expanded .left-rail{display:none}
body.document-page.note-expanded #main{padding:8px}
body.document-page.note-expanded .shared-page-sheet,body.document-page.note-expanded .local-document-reader{height:calc(100dvh - 185px)}
@media(max-width:1000px){#main .page-edit-toolbar{flex-wrap:wrap}body.document-page #main{padding-inline:18px}}
@media(max-width:760px){#main .page-edit-toolbar{flex-wrap:wrap}}
@media(max-width:600px){body.document-page .rail-inner{padding-inline:16px}body.document-page #main{padding:12px}.shared-page-sheet.ql-container{padding:10px}.shared-page-sheet .ql-editor{padding:20px!important;column-count:1!important}.document-title-row{padding-inline:8px}}

/* Keep the established rails and contain the document inside the center column. */
body.document-page .editor,body.document-page .edit-source{min-width:0;max-width:100%;box-shadow:0 3px 12px #10253126}
.shared-page-sheet .ql-editor{border:1px solid #c8d0d5;box-sizing:border-box}
.shared-page-sheet.ql-container{position:relative;background:#e9eef0;padding:44px 44px 60px}
.shared-page-sheet .ql-editor{box-shadow:0 2px 7px #0009,0 0 0 16px #808080,0 16px 0 16px #808080}
.document-page-number{position:absolute;top:52px;right:max(52px,calc((100% - var(--paper-width,8.5in))/2 + 8px));padding:0;border:0;background:transparent;color:#54636b;font:12px var(--sans);pointer-events:none;z-index:1}
.document-page .pdf-sheet{box-shadow:0 2px 7px #0009,0 0 0 16px #808080,0 16px 0 16px #808080}
@media(max-width:600px){.shared-page-sheet.ql-container{padding:44px 28px 60px}.document-page-number{right:36px}}
@media print{.document-page-number{display:none!important}.shared-page-sheet .ql-editor,.document-page .pdf-sheet{box-shadow:none!important}}
/* The shared document fills the desk down to the copyright strip. */
@media screen and (min-width:901px){
 body.document-page{height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden}
 body.document-page .masthead,body.document-page>footer{flex-shrink:0}
 body.document-page .workspace{flex:1;min-height:0;width:100%;overflow:hidden}
 body.document-page .left-rail,body.document-page .right-rail{position:relative;top:0;height:100%;min-height:0;overflow:auto}
 body.document-page #main{display:flex;flex-direction:column;min-height:0;overflow:hidden;padding-bottom:8px}
 body.document-page #main>.breadcrumbs{flex-shrink:0}
 body.document-page .shared-document-workbench{display:flex;flex:1;min-height:0}
 body.document-page .editor,body.document-page .edit-source{display:flex;flex-direction:column;flex:1;min-height:0;margin-bottom:0}
 body.document-page .editor>*,body.document-page .edit-source>*{flex-shrink:0}
 body.document-page .shared-page-sheet.ql-container,body.document-page .local-document-reader{flex:1 1 0;height:auto;min-height:0}
}
