:root{--plum:#66194e;--plum-dark:#441039;--rose:#a07091;--powder:#e7c3b9;--ink:#2a2028;--muted:#756a73;--line:#e8e0e5;--surface:#fff;--background:#f8f5f7;--success:#277a5a;--warning:#a66318;--danger:#a13d4d;--shadow:0 24px 60px rgba(68,16,57,.12)}
*{box-sizing:border-box}[hidden]{display:none!important}html{font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;color:var(--ink);background:var(--background)}body{margin:0}button,input,select{font:inherit}button{cursor:pointer}.skip-link{position:fixed;left:1rem;top:-5rem;z-index:99;background:#fff;padding:.75rem 1rem;color:var(--plum)}.skip-link:focus{top:1rem}.eyebrow{text-transform:uppercase;letter-spacing:.13em;font-size:.72rem;font-weight:800;color:var(--plum);margin:0 0 .6rem}.brand-mark{width:44px;height:44px;border-radius:14px;display:grid;place-items:center;background:linear-gradient(145deg,var(--plum),#8b376e);color:#fff;font-weight:900;box-shadow:0 10px 24px rgba(102,25,78,.2)}
.auth-shell{min-height:100vh;display:grid;grid-template-columns:minmax(22rem,1fr) minmax(22rem,34rem);grid-template-rows:auto 1fr;gap:2rem;padding:clamp(1.5rem,5vw,5rem);background:radial-gradient(circle at 10% 90%,rgba(231,195,185,.62),transparent 32%),linear-gradient(130deg,#fff 0 58%,#f3e9ef 58%)}.auth-brand{display:flex;align-items:center;gap:.85rem}.auth-brand div:last-child{display:flex;flex-direction:column}.auth-brand strong{font-size:1.05rem}.auth-brand span{font-size:.78rem;color:var(--muted)}.auth-copy{align-self:center;max-width:42rem}.auth-copy h1{font-family:Georgia,serif;font-size:clamp(2.6rem,5vw,5rem);line-height:.98;margin:.3rem 0 1.5rem;color:var(--plum-dark)}.auth-copy>p:not(.eyebrow){font-size:1.13rem;line-height:1.65;color:var(--muted);max-width:38rem}.auth-copy ul{list-style:none;padding:1rem 0 0;display:grid;gap:.9rem}.auth-copy li:before{content:"✓";display:inline-grid;place-items:center;width:1.6rem;height:1.6rem;margin-right:.7rem;border-radius:50%;background:#f0dfe9;color:var(--plum);font-weight:900}.auth-card{grid-column:2;grid-row:1/3;align-self:center;background:rgba(255,255,255,.94);padding:clamp(1.6rem,4vw,3.2rem);border:1px solid rgba(102,25,78,.1);border-radius:30px;box-shadow:var(--shadow);display:grid;gap:1.2rem}.auth-card h2{font-family:Georgia,serif;font-size:2.1rem;margin:0}.auth-card p{color:var(--muted)}label{display:grid;gap:.45rem;font-weight:700;font-size:.86rem}input,select{width:100%;border:1px solid var(--line);border-radius:12px;padding:.85rem 1rem;background:#fff;color:var(--ink);outline:none}input:focus,select:focus{border-color:var(--plum);box-shadow:0 0 0 3px rgba(102,25,78,.1)}label small,.auth-card>small{font-weight:400;color:var(--muted)}.button{border:0;border-radius:12px;padding:.82rem 1.1rem;font-weight:800;display:inline-flex;justify-content:center;align-items:center;gap:.5rem}.button.primary{color:#fff;background:var(--plum);box-shadow:0 9px 20px rgba(102,25,78,.18)}.button.primary:hover{background:#781f5e}.button.secondary{color:var(--plum);background:#f1e7ed}.button:disabled{opacity:.55;cursor:wait}.form-error{min-height:1.2rem;margin:0!important;color:var(--danger)!important;font-weight:700;font-size:.84rem}
.app-shell{min-height:100vh;display:grid;grid-template-columns:17rem 1fr}.sidebar{position:sticky;top:0;height:100vh;background:var(--plum-dark);color:#fff;padding:1.4rem 1rem;display:flex;flex-direction:column;z-index:20}.sidebar-brand{display:flex;gap:.8rem;align-items:center;padding:.2rem .5rem 1.6rem}.sidebar-brand div:last-child{display:flex;flex-direction:column}.sidebar-brand span{color:#d9bfd1;font-size:.75rem}.sidebar nav{display:grid;gap:.35rem}.nav-item{border:0;background:transparent;color:#dbc8d5;border-radius:12px;padding:.82rem .9rem;text-align:left;display:flex;gap:.8rem;align-items:center}.nav-item span{font-size:1.1rem;width:1.3rem;text-align:center}.nav-item:hover,.nav-item.active{background:rgba(255,255,255,.1);color:#fff}.sidebar-profile{margin-top:auto;padding:1rem .5rem .2rem;border-top:1px solid rgba(255,255,255,.12);display:grid;grid-template-columns:auto 1fr auto;gap:.7rem;align-items:center}.avatar{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:var(--powder);color:var(--plum-dark);font-weight:900}.sidebar-profile div:nth-child(2){min-width:0;display:flex;flex-direction:column}.sidebar-profile strong{font-size:.83rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sidebar-profile span{font-size:.7rem;color:#d9bfd1}.sidebar-profile button{border:0;background:transparent;color:#fff;font-size:1.1rem}.workspace{min-width:0;padding:0 clamp(1rem,4vw,4rem) 4rem}.topbar{height:5rem;display:flex;align-items:center;gap:1rem;border-bottom:1px solid var(--line);margin-bottom:2.2rem}.topbar>div{display:flex;align-items:center;gap:.7rem}.topbar span{font-size:.78rem;color:var(--muted)}.topbar select{padding:.55rem 2.4rem .55rem .8rem;max-width:22rem}.topbar .button{margin-left:auto}.menu-button{display:none;border:0;background:none;font-size:1.5rem}.view{display:none}.view.active{display:block}.page-heading{display:flex;justify-content:space-between;align-items:end;margin-bottom:1.8rem}.page-heading h1{font-family:Georgia,serif;font-size:clamp(2.1rem,4vw,3.5rem);margin:0;color:var(--plum-dark)}.page-heading p:last-child{color:var(--muted);margin:.6rem 0 0}.summary-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem;margin-bottom:1rem}.summary-card,.panel{background:var(--surface);border:1px solid var(--line);border-radius:20px}.summary-card{padding:1.25rem;display:grid;gap:.3rem}.summary-card span,.summary-card small{color:var(--muted)}.summary-card strong{font-family:Georgia,serif;font-size:2.3rem;color:var(--plum-dark)}.summary-card.accent{background:linear-gradient(135deg,var(--plum),#87366c);color:#fff;border:0}.summary-card.accent strong,.summary-card.accent span,.summary-card.accent small{color:#fff}.panel{padding:1.2rem;margin-top:1rem}.panel-heading{display:flex;justify-content:space-between;align-items:center;padding:.25rem .25rem 1rem}.panel-heading h2{margin:0;font-family:Georgia,serif}.panel-heading p{margin:.3rem 0 0;color:var(--muted);font-size:.85rem}.text-button{border:0;background:none;color:var(--plum);font-weight:800}.document-list{display:grid}.document-row{border-top:1px solid var(--line);padding:.9rem .25rem;display:grid;grid-template-columns:minmax(0,1.6fr) minmax(7rem,.6fr) minmax(7rem,.6fr);gap:1rem;align-items:center}.document-row:first-child{border-top:0}.document-name{min-width:0;display:flex;gap:.8rem;align-items:center}.file-mark{width:38px;height:44px;border-radius:8px;background:#f3e7ee;color:var(--plum);font-size:.65rem;font-weight:900;display:grid;place-items:center}.document-name div{min-width:0;display:flex;flex-direction:column}.document-name strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.document-name small,.document-row time{color:var(--muted);font-size:.78rem}.status{justify-self:start;border-radius:999px;padding:.35rem .65rem;background:#eee;color:#5e555c;font-size:.72rem;font-weight:800}.status.checking,.status.uploaded{background:#f5eadc;color:var(--warning)}.status.clarification,.status.rejected{background:#f7dfe3;color:var(--danger)}.status.accepted,.status.processed{background:#dff0e9;color:var(--success)}.empty-state{padding:2rem;text-align:center;color:var(--muted)}.filters{display:grid;grid-template-columns:minmax(15rem,1fr) 14rem;gap:1rem;padding-bottom:1rem}.upload-layout{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(16rem,.6fr);gap:1rem}.upload-form{margin:0;display:grid;gap:1rem}.form-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem}.form-grid.two{grid-template-columns:repeat(2,1fr)}.drop-zone{min-height:13rem;border:1.5px dashed #c8afbf;border-radius:18px;background:#fcf8fa;display:grid;place-items:center;align-content:center;text-align:center;padding:1.5rem;color:var(--muted);cursor:pointer}.drop-zone:hover,.drop-zone.dragging{border-color:var(--plum);background:#f7edf3}.drop-zone input{position:absolute;width:1px;height:1px;opacity:0}.drop-zone strong{color:var(--plum-dark);font-size:1.05rem}.upload-icon{width:48px;height:48px;border-radius:50%;background:#eee0e9;color:var(--plum);display:grid;place-items:center;font-size:1.5rem;margin-bottom:.6rem}.selected-files{display:grid;gap:.4rem}.selected-file{display:flex;justify-content:space-between;padding:.65rem .8rem;border-radius:10px;background:#f7f1f5;font-size:.82rem}.upload-progress{display:grid;gap:.5rem;color:var(--muted);font-size:.82rem}.upload-progress progress{width:100%;accent-color:var(--plum)}.form-actions{display:flex;justify-content:flex-end;gap:.7rem}.help-card{background:var(--plum-dark);color:#fff;border-radius:20px;padding:1.4rem;align-self:start}.help-card ul{padding-left:1.2rem;color:#e5d5df;line-height:1.6}.help-card p{color:#e5d5df;font-size:.86rem;line-height:1.5}.invite-form{max-width:56rem}.invitation-result{margin-top:1rem;padding:1rem;border-radius:12px;background:#e4f2ec;color:#255f49;overflow-wrap:anywhere}.toast{position:fixed;right:1.2rem;bottom:1.2rem;background:var(--plum-dark);color:#fff;padding:.9rem 1.1rem;border-radius:12px;box-shadow:var(--shadow);opacity:0;transform:translateY(1rem);pointer-events:none;transition:.2s;z-index:50}.toast.visible{opacity:1;transform:none}
@media(max-width:900px){.auth-shell{grid-template-columns:1fr;grid-template-rows:auto auto auto;background:var(--background)}.auth-copy{padding-top:2rem}.auth-copy h1{font-size:3rem}.auth-card{grid-column:1;grid-row:3}.app-shell{grid-template-columns:1fr}.sidebar{position:fixed;left:-18rem;width:17rem;transition:.2s}.sidebar.open{left:0}.workspace{padding:0 1rem 3rem}.menu-button{display:block}.summary-grid{grid-template-columns:1fr}.upload-layout{grid-template-columns:1fr}.form-grid,.form-grid.two{grid-template-columns:1fr}.topbar{height:auto;min-height:4.5rem;flex-wrap:wrap;padding:.7rem 0}.topbar>div{order:3;width:100%}.topbar select{max-width:none}.document-row{grid-template-columns:minmax(0,1fr) auto}.document-row time{display:none}.filters{grid-template-columns:1fr}.help-card{order:-1}}
@media(max-width:560px){.auth-shell{padding:1rem}.auth-copy h1{font-size:2.5rem}.auth-card{padding:1.25rem;border-radius:20px}.topbar .button{font-size:.78rem}.document-row{gap:.5rem}.status{font-size:.65rem}.page-heading h1{font-size:2.25rem}}
.document-row{grid-template-columns:minmax(0,1.6fr) minmax(7rem,.6fr) minmax(6rem,.45fr) minmax(6rem,.45fr)}.download-button{justify-self:start;border:0;border-radius:9px;background:#f1e7ed;color:var(--plum);padding:.5rem .7rem;font-weight:800;font-size:.72rem}.scan-note{color:var(--muted);font-size:.72rem}@media(max-width:900px){.document-row{grid-template-columns:minmax(0,1fr) auto}.download-button,.scan-note{grid-column:2}}
.publication-workspace{display:grid;grid-template-columns:minmax(22rem,.8fr) minmax(28rem,1.2fr);gap:1rem;align-items:start}.publication-workspace .panel{margin-top:0}.publication-form{display:grid;gap:1rem;position:sticky;top:1rem}.publication-form textarea{width:100%;resize:vertical;border:1px solid var(--line);border-radius:12px;padding:.85rem 1rem;background:#fff;color:var(--ink);font:inherit;line-height:1.55;outline:none}.publication-form textarea:focus{border-color:var(--plum);box-shadow:0 0 0 3px rgba(102,25,78,.1)}.publication-list{display:grid}.publication-item{border-top:1px solid var(--line);padding:1rem .25rem;display:grid;gap:.5rem}.publication-item:first-child{border-top:0}.publication-item h3{margin:0;color:var(--plum-dark)}.publication-item p{margin:0;color:var(--muted);font-size:.84rem;line-height:1.45}.publication-meta{display:flex;gap:.5rem;align-items:center;flex-wrap:wrap;font-size:.72rem;color:var(--muted)}.publication-meta .status{justify-self:auto}.publication-item button{justify-self:start}.status.draft{background:#f5eadc;color:var(--warning)}.status.published{background:#dff0e9;color:var(--success)}.status.archived{background:#eee;color:#5e555c}@media(max-width:1100px){.publication-workspace{grid-template-columns:1fr}.publication-form{position:static}}@media(max-width:560px){.page-heading{align-items:start;gap:1rem;flex-direction:column}.publication-workspace{grid-template-columns:minmax(0,1fr)}}
.rich-editor-field{display:grid;gap:.45rem}.field-label{font-weight:700;font-size:.86rem}.editor-toolbar{display:flex;gap:.35rem;flex-wrap:wrap;padding:.5rem;border:1px solid var(--line);border-bottom:0;border-radius:12px 12px 0 0;background:#f8f5f7}.editor-toolbar button{border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--plum-dark);padding:.42rem .6rem;font-size:.78rem;font-weight:700}.editor-toolbar button:hover{background:#f1e7ed}.publication-editor{min-height:18rem;max-height:36rem;overflow:auto;border:1px solid var(--line);border-radius:0 0 12px 12px;padding:1rem;background:#fff;line-height:1.65;outline:none}.publication-editor:focus{border-color:var(--plum);box-shadow:0 0 0 3px rgba(102,25,78,.1)}.publication-editor:empty:before{content:attr(data-placeholder);color:#a397a0}.publication-editor h2,.publication-editor h3{font-family:Georgia,serif;color:var(--plum-dark)}.publication-editor blockquote{margin:1rem 0;border-left:4px solid var(--plum);padding:.5rem 1rem;background:#faf5f8;color:var(--muted)}.publication-editor img,.article-body img{max-width:100%;height:auto;border-radius:14px;display:block;margin:1rem auto}.publication-preview-dialog{width:min(860px,calc(100% - 2rem));max-height:90vh;border:0;border-radius:22px;padding:0;box-shadow:var(--shadow)}.publication-preview-dialog::backdrop{background:rgba(42,32,40,.65)}.publication-preview-dialog article{padding:clamp(1.2rem,4vw,3rem)}.preview-actions{display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line);padding-bottom:1rem;margin-bottom:2rem}.preview-actions button{border:0;background:none;font-size:2rem;color:var(--plum)}.publication-preview-dialog h1{font-family:Georgia,serif;font-size:clamp(2rem,5vw,3.8rem);color:var(--plum-dark);margin:.5rem 0 1rem}.preview-excerpt{font-size:1.15rem;color:var(--muted);line-height:1.6}.publication-preview-dialog .article-body{line-height:1.75}.publication-preview-dialog .article-body blockquote{border-left:4px solid var(--plum);padding-left:1rem;color:var(--muted)}
