@font-face{font-family:'Ubuntu';font-style:normal;font-weight:400;font-display:swap;src:url('/index.php?asset=fontregular&v=3.3.0') format('woff')}
@font-face{font-family:'Ubuntu';font-style:normal;font-weight:500;font-display:swap;src:url('/index.php?asset=fontmedium&v=3.3.0') format('woff')}
@font-face{font-family:'Ubuntu';font-style:normal;font-weight:700;font-display:swap;src:url('/index.php?asset=fontbold&v=3.3.0') format('woff')}
:root{font:15px/1.6 'Ubuntu',Arial,sans-serif;color:#173543;background:#f3f6f8;--navy:#06354b;--teal:#087b7c;--muted:#657c88;--line:#dfe8ec}*{box-sizing:border-box}body{margin:0}header{height:100px;background:#fff;border-bottom:1px solid var(--line);padding:0 5%;display:flex;justify-content:space-between;align-items:center}.brand{display:flex;align-items:center;gap:15px}.mark{display:grid;place-items:center;width:54px;height:54px;border-radius:16px;background:var(--navy);color:#fff;font-size:21px;letter-spacing:-2px;box-shadow:0 6px 14px #06354b15}h1{font-size:24px;letter-spacing:-.8px;margin:0;font-weight:750}header span{font-size:12px;color:var(--muted)}main{max-width:1320px;margin:auto;padding:40px 32px}h2{font-size:32px;line-height:1.2;letter-spacing:-1px;margin:0 0 16px}h3{font-size:20px;line-height:1.35;letter-spacing:-.4px;margin:0 0 12px}p{color:var(--muted);margin:0 0 22px}.eyebrow{font-size:11px;font-weight:700;letter-spacing:2px;text-transform:uppercase;display:block;margin-bottom:24px;color:var(--teal)}button,.primary{font:600 14px/1.4 'Ubuntu',Arial,sans-serif;border:1px solid var(--line);border-radius:10px;padding:13px 20px;cursor:pointer;background:#fff;color:var(--navy);text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:12px;transition:background .15s,box-shadow .15s}button:hover{background:#eaf1f4}button:disabled{opacity:.5;cursor:default}.primary{background:var(--navy);color:white;border-color:var(--navy);box-shadow:0 5px 12px #06354b16}.primary:hover{background:#0b4c63}.msmark{display:grid;grid-template-columns:repeat(2,8px);gap:2px}.msmark i{width:8px;height:8px;background:#f25022}.msmark i:nth-child(2){background:#7fba00}.msmark i:nth-child(3){background:#00a4ef}.msmark i:nth-child(4){background:#ffb900}#login{display:grid;grid-template-columns:1.06fr 1fr;min-height:580px;border-radius:24px;overflow:hidden;background:white;box-shadow:0 22px 60px #153b4d09;border:1px solid var(--line);padding:0}.welcome-art{padding:56px;background:var(--navy);color:white;position:relative;overflow:hidden}.welcome-art .eyebrow{color:#83cfcb}.welcome-art h2{font-size:44px;line-height:1.16;max-width:370px;color:#fff}.welcome-art p{color:#b8ced8;max-width:330px}.welcome-art:after{content:'';position:absolute;width:280px;height:280px;border:1px solid #ffffff12;border-radius:50%;right:-160px;bottom:-70px;box-shadow:0 0 0 50px #ffffff04,0 0 0 100px #ffffff03}.module-list{margin-top:36px;display:grid;gap:12px}.module-preview{display:flex;align-items:center;gap:16px;padding:14px 18px;border:1px solid #ffffff18;border-radius:12px;background:#ffffff07}.module-preview b{font-size:14px;font-weight:600}.module-preview small{display:block;color:#a5c1cd;font-size:12px}.module-symbol{font-size:21px;color:#9ad7d1;width:26px}.login-content{padding:65px 56px;display:flex;flex-direction:column;justify-content:center}.login-content h2{font-size:34px}.login-content .primary{align-self:stretch;margin:12px 0 25px;padding:17px}.login-content .small{font-size:12px;line-height:1.7}.login-foot{border-top:1px solid var(--line);padding-top:22px;margin-top:26px;color:var(--muted);font-size:12px}.site-footer{padding:24px 0;text-align:center;color:#81939c;font-size:12px}nav{display:flex;gap:6px;flex-wrap:wrap;padding:7px;border:1px solid var(--line);background:#fff;border-radius:14px;margin-bottom:32px}nav button{border:0;background:transparent}nav button[aria-current=page]{background:var(--navy);color:white}#logout{margin-left:auto;color:#667c87}.view{background:#fff;border:1px solid var(--line);padding:32px;border-radius:18px}#overview{background:transparent;border:0;padding:0}.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin:28px 0}.card{border:1px solid var(--line);background:white;padding:28px;border-radius:18px;min-height:245px;position:relative}.card:before{content:'▤';display:grid;place-items:center;width:48px;height:48px;border-radius:12px;background:#e9f2f5;color:var(--navy);font-size:25px;margin-bottom:24px}.card:nth-child(2):before{content:'▱';background:#e9f4ef;color:#317a5f}.card:nth-child(3):before{content:'◎';background:#f3edf8;color:#7d608e}.card p{font-size:13px;margin:0}.badge{font-size:9px;letter-spacing:1px;font-weight:700;color:#54727e;position:absolute;top:36px;right:23px;background:#f3f6f8;padding:5px 9px;border-radius:6px}.muted,.small{color:var(--muted)}.small{font-size:12px}.chatgrid,.adminGrid{display:grid;grid-template-columns:260px minmax(0,1fr);gap:28px}.person{display:flex;gap:12px;align-items:center;width:100%;text-align:left;justify-content:flex-start;margin:8px 0;background:#f6f9fa;border:1px solid transparent}.person:hover{border-color:#aec9d3}.avatar{width:44px;height:44px;border-radius:50%;object-fit:cover;display:inline-flex;background:#e1eeef;color:#236067;align-items:center;justify-content:center;font-weight:600;flex-shrink:0;overflow:hidden}.dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:#b4c0ca;margin-right:6px}.online{background:#269978}label{display:block;margin:14px 0;font-size:13px;font-weight:600}input:not([type=checkbox]),textarea{display:block;width:100%;font:400 14px/1.5 'Ubuntu',Arial,sans-serif;padding:12px 14px;border:1px solid #cfdce2;border-radius:9px;margin-top:7px;background:#fbfcfd;color:var(--navy)}textarea{min-height:84px;resize:vertical}.check{display:flex;gap:8px}input[type=checkbox]{accent-color:var(--teal);width:16px;height:16px}#messages{height:360px;overflow:auto;background:#f3f6f8;padding:18px;border:1px solid var(--line);border-radius:12px;margin-bottom:14px}.bubble{white-space:pre-wrap;overflow-wrap:anywhere;background:white;padding:13px 16px;margin:12px 0;border-radius:12px;max-width:85%;border:1px solid #e1e9ec}.mine{background:#e0f0eb;border-color:#d5e8e0;margin-left:auto}.bubble .small{margin-top:6px}#chatForm{display:flex;gap:12px;align-items:stretch}#chatForm textarea{margin:0}#profileInfo .avatar{height:96px;width:96px;font-size:28px;margin-bottom:20px}#identity{display:flex;align-items:center;gap:10px}#grants{margin-top:32px}.tablewrap{overflow:auto;border:1px solid var(--line);border-radius:10px;margin:20px 0}table{border-collapse:collapse;width:100%;font-size:12px}td,th{padding:12px;border-bottom:1px solid var(--line);text-align:center}th{background:#f2f6f8;font-size:11px}td:first-child,th:first-child{text-align:left;min-width:190px}#notice:not(:empty){background:#fff6e6;color:#875c1f;border:1px solid #f1ddb8;padding:14px 20px;margin-bottom:24px;border-radius:10px;font-size:13px}.message-card{max-width:630px;margin:8vh auto;background:white;padding:44px;border:1px solid var(--line);border-radius:22px;box-shadow:0 20px 60px #153b4d08}.message-card .mark{margin-bottom:30px}.message-card p{margin:22px 0}.message-card a:not(.primary){color:var(--teal)}:focus-visible{outline:3px solid #2a9cad;outline-offset:3px}[hidden]{display:none!important}@media(max-width:900px){#login{grid-template-columns:1fr}.welcome-art{padding:36px}.welcome-art h2{font-size:34px;max-width:none}.module-list{grid-template-columns:repeat(3,1fr);margin-top:24px}.module-preview{padding:12px;gap:8px}.module-preview small{display:none}.login-content{padding:36px}.cards,.chatgrid,.adminGrid{grid-template-columns:1fr}.card{min-height:200px}.brand h1{font-size:20px}}@media(max-width:540px){header{height:84px;padding:0 20px}.brand span{display:none}main{padding:24px 16px}.module-list{grid-template-columns:1fr}.welcome-art{padding:28px}.welcome-art h2{font-size:32px}.login-content{padding:28px}.view{padding:22px}nav button{padding:10px 12px}#logout{margin-left:0}#identity span{max-width:95px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#chatForm{flex-direction:column}.message-card{margin:24px auto;padding:28px}}

.user-actions{margin:24px 0;padding:20px;background:#f5f8fa;border:1px solid var(--line);border-radius:12px}.user-actions p{margin:6px 0 16px}.action-buttons{display:flex;gap:10px;flex-wrap:wrap}.danger{color:#a13232;border-color:#e5bcbc;background:#fffafa}.danger:hover{background:#fcecec}.blocked-state{color:#a13232}.active-state{color:var(--navy)}.rights-group{border:1px solid var(--line);border-radius:12px;margin:12px 0;overflow:hidden;background:#fff}.rights-group summary{padding:17px 18px;cursor:pointer;font-weight:650;background:#f5f8fa;list-style-position:inside}.rights-group summary::marker{color:var(--teal)}.rights-count{float:right;font-size:11px;font-weight:400;color:var(--muted);margin-top:3px}.rights-group .tablewrap{margin:0;border:0;border-top:1px solid var(--line);border-radius:0}.rights-accordion{margin-bottom:20px}@media(max-width:540px){.rights-count{float:none;display:block;margin-left:18px}.action-buttons button{width:100%}}
body{min-height:100vh;min-height:100svh;display:flex;flex-direction:column}body>main{flex:1;width:100%}.site-footer{margin-top:auto;padding:24px 20px 28px;text-align:center}.favorite-button{position:absolute;right:16px;top:15px;padding:0;width:36px;height:36px;border:0;background:transparent;font-size:25px;color:#718792;box-shadow:none}.favorite-button[aria-pressed=true]{color:#ba8218;background:#fff5d9}.card .badge{right:62px;top:23px}.card>button:not(.favorite-button){margin-top:24px}.card[data-module=belege]:before{content:'▤';background:#e9f2f5;color:var(--navy)}.card[data-module=vertraege]:before{content:'▱';background:#e9f4ef;color:#317a5f}.card[data-module=hr]:before{content:'◎';background:#f3edf8;color:#7d608e}.section-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:20px}.section-heading .eyebrow{margin-bottom:10px}.document-toolbar,.document-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:20px}.upload-button{margin:0;cursor:pointer}.document-layout{display:grid;grid-template-columns:230px minmax(0,1fr);gap:24px;margin-top:20px}.document-layout aside{max-height:900px;overflow:auto}.document-item{display:flex;flex-direction:column;align-items:flex-start;gap:6px;width:100%;margin-bottom:8px;text-align:left;overflow-wrap:anywhere;word-break:break-word}.document-item.selected{background:#e7f2f3;border-color:#79b4b3}select{font:inherit;max-width:100%;padding:11px;border:1px solid #cfdce2;border-radius:9px;background:#fff;color:var(--navy)}.document-fields{display:grid;grid-template-columns:1fr;gap:0}.document-fields select{display:block;margin-top:6px;width:100%}#documentCenters{border:1px solid var(--line);border-radius:9px;padding:12px;margin:8px 0}#documentCenters summary{cursor:pointer;font-weight:600}#centerChoices{max-height:250px;overflow:auto}#documentPreview{border:1px solid var(--line);border-radius:12px;width:100%;height:720px;background:#f0f3f5}#documentName{overflow-wrap:anywhere}.secondary-link{color:var(--teal);font-size:13px}.document-actions button{font-size:12px;padding:11px 14px}.document-actions a.primary{font-size:12px}#documentStatus{padding:8px 0}#documentEmpty{padding:45px 25px;text-align:center;background:#f5f8fa;border-radius:14px}@media(max-width:850px){.document-layout{grid-template-columns:1fr}.document-layout aside{max-height:260px}#documentPreview{height:550px}.section-heading{flex-direction:column}} 
:root{--surface:#fff;--page:#f3f6f8;--soft:#f5f8fa;--ink:#173543;--accent:#06354b;color-scheme:light}html[data-theme=dark]{--surface:#152b37;--page:#0d1d27;--soft:#1a3341;--ink:#e6eef2;--navy:#d7e9f0;--muted:#a5bbc6;--line:#304753;--teal:#76cbc5;--accent:#087b7c;color-scheme:dark;background:var(--page);color:var(--ink)}body{background:var(--page);color:var(--ink)}header{position:sticky;top:0;z-index:50;background:var(--surface);gap:16px}.brand{color:var(--ink);text-decoration:none}.brand-logo{width:56px;height:56px;object-fit:contain;flex-shrink:0}.header-controls,.account-controls{display:flex;align-items:center;gap:13px}.icon-button{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;padding:8px;border:0;background:transparent;color:var(--navy)}.header-menu{position:relative}.header-menu summary{cursor:pointer;list-style:none}.header-menu summary::-webkit-details-marker{display:none}.menu-panel{position:absolute;right:0;top:52px;min-width:210px;background:var(--surface);border:1px solid var(--line);padding:8px;border-radius:12px;box-shadow:0 12px 35px #0002}.menu-panel button{width:100%;justify-content:flex-start;background:transparent;border:0;text-align:left}.menu-panel button:hover{background:var(--soft)}#logout{font-size:12px;white-space:nowrap;margin-left:0;background:transparent;color:var(--muted);border-color:var(--line);padding:10px 12px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.theme-switch{display:inline-flex;position:relative;align-items:center;margin:0;cursor:pointer}.theme-switch input{position:absolute;opacity:0;width:42px;height:24px;margin:0;z-index:2;cursor:pointer}.switch-track{width:42px;height:24px;background:#95a9b4;border-radius:20px;display:block;padding:3px;transition:background .2s}.switch-track:before{content:'';display:block;width:18px;height:18px;border-radius:50%;background:white;transition:transform .2s}.theme-switch input:checked+.switch-track{background:#087b7c}.theme-switch input:checked+.switch-track:before{transform:translateX(18px)}.theme-switch input:focus-visible+.switch-track{outline:3px solid #2a9cad;outline-offset:3px}.settings-card{padding:24px 0;border-bottom:1px solid var(--line);max-width:650px}.settings-card:last-child{border-bottom:0}.settings-card p{margin-bottom:12px}.settings-card select{display:block;margin-top:8px;min-width:220px}.chat-dock{position:fixed;right:0;top:100px;bottom:0;width:320px;z-index:30;background:var(--surface);border-left:1px solid var(--line);padding:25px 18px;display:flex;flex-direction:column;overflow:hidden}.chat-dock h2{font-size:21px;margin:0}.chat-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.chat-dock>p{margin-bottom:12px}.chat-dock .chatgrid{display:flex;flex-direction:column;min-height:0;flex:1;gap:16px}.chat-dock #people{max-height:190px;overflow:auto;flex-shrink:0}.chat-dock .chatgrid>article{display:flex;flex-direction:column;min-height:0;flex:1}.chat-dock #chatTitle{font-size:13px;line-height:1.5;margin-bottom:10px}.chat-dock #messages{height:auto;min-height:100px;flex:1;padding:10px}.chat-dock #chatForm{display:flex;flex-direction:column;gap:8px}.chat-dock #message{min-height:65px;max-height:110px;resize:vertical;font-size:13px}.chat-dock #send{align-self:flex-end;padding:9px 17px}.chat-dock .person{font-size:12px;padding:9px;gap:8px}.chat-dock .avatar{width:34px;height:34px}.chat-dock .bubble{font-size:12px}.chat-dock .small{font-size:10px}#chatToggle,#closeChat{display:none}body.authenticated>main{max-width:1320px;width:calc(100% - 320px);margin-left:auto;margin-right:320px;padding:36px 28px}body.authenticated>.site-footer{margin-right:320px}html[data-theme=dark] header,html[data-theme=dark] nav,html[data-theme=dark] .view,html[data-theme=dark] .card,html[data-theme=dark] .message-card,html[data-theme=dark] #login{background:var(--surface)}html[data-theme=dark] .welcome-art{background:#06354b}html[data-theme=dark] button,html[data-theme=dark] select,html[data-theme=dark] input:not([type=checkbox]),html[data-theme=dark] textarea{background:var(--soft);color:var(--ink);border-color:var(--line)}html[data-theme=dark] button:hover{background:#284959}html[data-theme=dark] .primary,html[data-theme=dark] nav button[aria-current=page]{background:var(--accent);color:white;border-color:var(--accent)}html[data-theme=dark] .person,html[data-theme=dark] #messages,html[data-theme=dark] .user-actions,html[data-theme=dark] .rights-group summary,html[data-theme=dark] th,html[data-theme=dark] #documentEmpty{background:var(--soft)}html[data-theme=dark] .rights-group,html[data-theme=dark] .bubble{background:var(--surface)}html[data-theme=dark] .mine{background:#18443f}html[data-theme=dark] .badge{background:#263f4c;color:#b8cdd6}html[data-theme=dark] .favorite-button{background:transparent;color:#b8cdd6}html[data-theme=dark] .favorite-button[aria-pressed=true]{color:#ffc04b;background:#443918}html[data-theme=dark] .avatar{background:#284954;color:#c9e8e7}html[data-theme=dark] .danger,html[data-theme=dark] .blocked-state{color:#ffaaa5}html[data-theme=dark] #notice:not(:empty){background:#3e3421;color:#f5cf8a;border-color:#655535}html[data-theme=dark] .document-item.selected{background:#20494c;border-color:#76cbc5}html[data-theme=dark] #overview{background:transparent}
@media(max-width:1200px){body.authenticated .cards{grid-template-columns:1fr}.header-controls,.account-controls{gap:8px}#identity span{font-size:12px}body.authenticated .document-layout{grid-template-columns:1fr}.brand span{display:none}}
@media(max-width:900px){body.authenticated>main{width:100%;margin:auto;padding:24px 20px}body.authenticated>.site-footer{margin-right:0}.chat-dock{display:none;top:100px;width:min(350px,100%);box-shadow:-12px 0 35px #0002}body.chat-open .chat-dock{display:flex}#chatToggle,#closeChat{display:inline-flex}#chatToggle{font-size:11px;width:auto}#identity span{display:none}.header-controls,.account-controls{gap:5px}.brand h1{font-size:19px}.brand-logo{width:44px;height:44px}.brand{gap:10px}}
@media(max-width:540px){header{height:auto;min-height:84px;position:sticky;padding:12px 14px;flex-wrap:wrap;gap:8px}.brand h1{font-size:18px}.brand-logo{width:40px;height:40px}.header-controls{margin-left:auto}#identity .avatar{width:30px;height:30px}#logout{font-size:10px;padding:8px}header .icon-button{width:32px;height:32px}.chat-dock{top:108px}.header-controls .account-controls{flex-wrap:nowrap}.theme-switch{margin-right:3px}.theme-switch input,.switch-track{width:38px}.theme-switch input:checked+.switch-track:before{transform:translateX(14px)}body.authenticated>main{padding:20px 14px}}

/* 3.3.2: flexible workspace, intrinsic sizing and accessible mobile controls. */
:root{--header-height:100px;--chat-width:320px}
header{height:auto;min-height:100px;padding:16px clamp(16px,3vw,48px);flex-shrink:0}
body>main{min-width:0;margin:0 auto}
body.authenticated>main{max-width:none;width:calc(100% - var(--chat-width));margin:0 var(--chat-width) 0 0;padding:clamp(20px,2.5vw,48px)}
body.authenticated>.site-footer{margin-right:var(--chat-width)}
.view,.card,.document-layout>* ,.adminGrid>* ,.chatgrid>* ,.login-content,.welcome-art{min-width:0}
.cards{grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr))}
body.authenticated .cards{grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr))}
body.authenticated .document-layout{grid-template-columns:minmax(180px,240px) minmax(0,1fr)}
.document-layout aside{max-height:65vh}
#documentPreview{display:block;height:clamp(360px,70dvh,1100px);max-width:100%}
.section-heading,.document-toolbar,.document-actions{flex-wrap:wrap}
h1,h2,h3,p,.person,.site-footer,#notice{overflow-wrap:anywhere}
.chat-dock{top:var(--header-height);width:var(--chat-width);padding-bottom:max(18px,env(safe-area-inset-bottom))}
.chat-dock #people{max-height:22dvh}.chat-dock #messages{min-height:60px}
.header-controls,.account-controls{flex-shrink:0}
button,.primary,.icon-button,header .icon-button,#logout{min-height:44px}
.icon-button,header .icon-button{min-width:44px}
input:not([type=checkbox]),textarea,select{min-width:0;max-width:100%}
.settings-card select{min-width:0;width:min(100%,320px)}
.check{align-items:flex-start}.check input{flex-shrink:0}
@media(max-width:1100px){
 body.authenticated>main{width:100%;margin:0;padding:24px}
 body.authenticated>.site-footer{margin-right:0}
 .chat-dock{display:none;width:min(360px,100%);box-shadow:-12px 0 35px #0002}
 body.chat-open .chat-dock{display:flex}
 #chatToggle,#closeChat{display:inline-flex}
 #chatToggle{width:auto}
 .adminGrid{grid-template-columns:1fr}
}
@media(max-width:760px){
 header{min-height:84px;flex-wrap:wrap;gap:10px;padding:12px 16px}
 .header-controls{margin-left:auto;flex-wrap:wrap;gap:6px}
 .account-controls{gap:4px}
 .brand span{display:none}
 body.authenticated>main{padding:20px 16px}
 body.authenticated .document-layout{grid-template-columns:minmax(0,1fr)}
 .document-layout aside{max-height:220px}
 .view{padding:20px}
 .section-heading{flex-direction:column}
 .document-toolbar>*{max-width:100%}
 input:not([type=checkbox]),textarea,select{font-size:16px}
 h2{font-size:28px}
 #documentPreview{height:65dvh;min-height:320px}
 .chat-dock{top:var(--header-height)}
}
@media(max-width:420px){
 header .brand{width:100%}
 .header-controls{width:100%;justify-content:flex-end}
 .card{padding:22px}
 .document-actions>*{flex:1 1 130px}
 .login-content,.welcome-art{padding:24px}
 .login-content h2,.welcome-art h2{font-size:28px}
 .menu-panel{min-width:200px;max-width:calc(100vw - 32px)}
}

.menu-version{margin:4px 8px 8px;padding:8px 0 12px;border-bottom:1px solid var(--line);font-size:12px;color:var(--muted)}
.document-navigation,.document-footer{display:flex;gap:10px;flex-wrap:wrap;margin:20px 0}.document-footer{margin-top:32px;padding-top:20px;border-top:1px solid var(--line)}
#documentHint{position:fixed;margin:0;max-width:min(440px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow:auto;padding:28px;border:1px solid var(--line);border-radius:16px;background:var(--surface);color:var(--ink);box-shadow:0 18px 60px #0003}
#documentHint::backdrop{background:#0003}#hintText{white-space:pre-line}#documentHint form{text-align:right}

#downloadLinks a{display:block;overflow-wrap:anywhere;margin:8px 0}

#serverCheckResult{white-space:pre-wrap;overflow-wrap:anywhere;font-size:12px}

.analysis-panel{background:var(--soft);border:1px solid var(--line);border-radius:12px;padding:18px;margin:18px 0}.analysis-panel h3{font-size:17px}.analysis-panel p{margin-bottom:12px}.analysis-panel summary{cursor:pointer;font-size:13px}#analysisDetails{font-size:13px;padding-left:20px;overflow-wrap:anywhere}

.archive-filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:12px;align-items:end;margin:20px 0}.archive-filters label{margin:0}.archive-filters select{display:block;width:100%;margin-top:7px}.protocol-link{padding:0;border:0;background:transparent;color:var(--teal);text-decoration:underline;text-align:left;justify-content:flex-start;overflow-wrap:anywhere}

.mail-toolbar{margin:18px 0;padding:16px;background:var(--soft);border:1px solid var(--line);border-radius:12px}.mail-toolbar label{font-weight:400}

/* Collapsible chat at every viewport; personal preference is applied after login. */
.chat-dock{display:none}
body.chat-open .chat-dock{display:flex}
#chatToggle,#closeChat{display:inline-flex}
#chatToggle{width:auto;font-size:12px}
body.authenticated>main{width:100%;margin:0}
body.authenticated>.site-footer{margin-right:0}
@media(min-width:1101px){
 body.authenticated.chat-open>main{width:calc(100% - var(--chat-width));margin-right:var(--chat-width)}
 body.authenticated.chat-open>.site-footer{margin-right:var(--chat-width)}
}
body.authenticated .document-layout{grid-template-columns:minmax(0,1fr)}
.document-layout>aside{max-height:170px;overflow:auto}
#documentList{display:flex;gap:8px;overflow:auto}
#documentList .document-item{width:220px;flex-shrink:0}
#documentEditor{display:grid;grid-template-columns:minmax(260px,.8fr) minmax(0,1.5fr);gap:24px;align-items:start}
.document-controls,.document-preview-pane{min-width:0}
.document-preview-pane{position:sticky;top:calc(var(--header-height) + 16px)}
@media(max-width:850px){
 #documentEditor{grid-template-columns:minmax(0,1fr)}
 .document-preview-pane{position:static}
}

/* Settings: short personal row followed by two administrative cards. */
#settings{max-width:1280px;margin-inline:auto}
.settings-heading{margin-bottom:28px}
.settings-heading h2{margin-bottom:8px}
.settings-heading p{margin:0}
#settings .settings-card{max-width:none;padding:24px;border:1px solid var(--line);border-radius:14px;background:var(--surface);min-width:0}
#settings .settings-personal{display:grid;grid-template-columns:minmax(0,1fr) minmax(220px,360px);align-items:center;gap:24px;background:var(--soft)}
#settings .settings-personal h3{margin-bottom:6px}
#settings .settings-personal p{margin:0}
#settings .settings-control label{margin:0 0 6px}
#settings .settings-control select{width:100%;margin:0}
#settings .settings-control #themeStatus:not(:empty){margin-top:8px}
.settings-group-title{font-size:13px;text-transform:uppercase;letter-spacing:1.2px;color:var(--muted);margin:32px 0 12px}
.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;align-items:start}
.settings-card-heading{display:flex;align-items:center;gap:12px;margin-bottom:18px}
.settings-card-heading h3{margin:0}
.settings-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:10px;background:var(--soft);color:var(--teal);font-size:21px;flex-shrink:0}
#settings .settings-card p{margin-bottom:14px}
#settings .mailbox-address{font-weight:500;color:var(--ink);overflow-wrap:anywhere}
.settings-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px}
.connection-status{font-size:13px;display:flex;gap:8px;align-items:baseline}
.connection-status:before{content:'';width:8px;height:8px;flex-shrink:0;border-radius:50%;background:#9aabb3}
.connection-status[data-connected=true]:before{background:#279d78}
#settings input[type=file]{padding:10px;width:100%}
#settings input[type=file]::file-selector-button{font:inherit;border:0;border-radius:5px;padding:7px 10px;background:var(--soft);color:var(--ink);margin-right:10px;cursor:pointer}
.update-history{margin-top:22px;padding-top:16px;border-top:1px solid var(--line);font-size:13px;color:var(--muted)}
.update-history summary{cursor:pointer}
.update-history ul{padding-left:18px}
#updateReview{margin-top:18px;padding:16px;border-radius:10px;background:var(--soft)}
#reloadAfterUpdate{margin-top:12px}
@media(max-width:900px){.settings-grid{grid-template-columns:minmax(0,1fr)}}
@media(max-width:600px){#settings .settings-personal{grid-template-columns:minmax(0,1fr);gap:16px}#settings .settings-card{padding:18px}.settings-actions>*{flex:1 1 auto}}

/* Personal account */
#profile{max-width:1180px;margin-inline:auto}
.account-heading{margin-bottom:28px}
.account-heading h2{margin-bottom:8px}
.account-heading p{margin:0}
.account-grid{display:grid;grid-template-columns:minmax(240px,.8fr) minmax(0,1.6fr);gap:24px;align-items:start}
.account-card{border:1px solid var(--line);border-radius:16px;padding:26px;background:var(--surface);min-width:0}
.account-identity{text-align:center;background:var(--soft)}
#profileInfo{display:flex;flex-direction:column;align-items:center;gap:18px}
#profileInfo .avatar{width:96px;height:96px;font-size:30px}
.account-person{min-width:0;width:100%}
.account-person h3{margin-bottom:7px;font-size:22px}
#profile .account-email{font-size:13px;overflow-wrap:anywhere;margin-bottom:14px}
.account-role{display:inline-block;border:1px solid var(--line);border-radius:20px;padding:4px 11px;font-size:12px;color:var(--teal);background:var(--surface)}
.account-photo{margin-top:24px}
.account-photo button{width:100%}
.account-photo p{margin:9px 0 0;font-size:12px}
#profile .account-signin{margin:24px 0 0;padding-top:18px;border-top:1px solid var(--line);font-size:12px}
.account-options{display:grid;gap:20px;min-width:0}
.account-options h3{margin-bottom:20px}
.account-option{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:16px 0}
.account-option+.account-option{border-top:1px solid var(--line)}
.account-option label{margin:0;font-size:14px}
.account-option p{font-size:13px;margin:5px 0 0}
.account-option select{flex:0 0 180px;width:180px;font-size:14px}
.account-option .theme-switch{flex-shrink:0}
.account-options [role=status]:empty{display:none}
.account-options [role=status]{margin:0;font-size:12px}
#chatPreferenceStatus:not(:empty){margin-top:8px}
.account-module{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 0;border-top:1px solid var(--line);font-size:14px}
.account-module:first-child{border-top:0;padding-top:0}
.account-module:last-child{padding-bottom:0}
.account-module-state{font-size:12px;color:var(--teal);white-space:nowrap}
@media(max-width:850px){.account-grid{grid-template-columns:minmax(0,1fr)}#profileInfo{flex-direction:row;text-align:left}.account-photo{max-width:300px;margin-inline:auto}.account-identity{padding:22px}}
@media(max-width:480px){#profileInfo{flex-direction:column;text-align:center}.account-card{padding:20px}.account-option{gap:12px;flex-wrap:wrap}.account-option select{flex:1 1 100%;width:100%}.account-option:has(.theme-switch){flex-wrap:nowrap}.account-module{flex-wrap:wrap}.account-options h3{font-size:18px}}

/* Receipt workspace */
.receipt-heading{margin-bottom:24px;display:flex;align-items:flex-start;justify-content:space-between;gap:16px;flex-wrap:wrap}
#backToReceipts{margin-left:auto;flex-shrink:0}
.receipt-heading h2{margin-bottom:8px}
.receipt-heading p{margin:0}
.receipt-toolbar{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;padding:16px;background:var(--soft);border:1px solid var(--line);border-radius:14px}
.receipt-import,.receipt-filter{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.receipt-filter select{min-height:44px}
.receipt-mail-options{display:flex;align-items:baseline;gap:18px;flex-wrap:wrap;padding:12px 4px 16px;font-size:12px;color:var(--muted)}
.receipt-mail-options summary{cursor:pointer;font-weight:500;color:var(--ink)}
.receipt-mail-options label{font-size:12px;font-weight:400;margin:12px 0 4px}
.receipt-mail-options p{margin:0}
.receipt-mail-options #mailStatus{flex:1 1 260px;overflow-wrap:anywhere}
.receipt-counts{display:flex;gap:8px;flex-wrap:wrap;padding:4px 0 0!important}
.receipt-count{display:inline-block;border-radius:20px;background:var(--soft);padding:5px 11px;color:var(--muted);font-size:12px}
#documents .document-navigation{align-items:center;margin:16px 0;gap:8px}
#processBatch{margin-left:auto}
#documents .document-layout{gap:18px}
#documents #documentListPane{max-height:150px}
#documents #documentList{padding:3px 0}
#documents .document-item{border-color:var(--line);padding:12px 14px;border-radius:10px;margin:0}
#documents .document-item strong{font-size:13px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
#documents .document-item.selected{border-color:var(--teal)}
#documents #documentEmpty{padding:36px 20px;margin-top:18px;border:1px dashed var(--line);background:var(--soft)}
.receipt-empty-icon{display:grid;place-items:center;width:48px;height:48px;margin:0 auto 16px;border-radius:12px;background:var(--surface);color:var(--teal);font-size:24px}
#documents #documentEmpty h3{font-size:20px;margin-bottom:8px}
#documents #documentEmpty p{margin:0;font-size:14px}
#documents #documentEditor{gap:22px;grid-template-columns:minmax(260px,.7fr) minmax(0,1.5fr)}
#documents .document-controls{padding:20px;border:1px solid var(--line);border-radius:14px}
#documents #documentName{font-size:18px;margin-bottom:8px}
#documents #documentState{margin-bottom:16px}
#documents .analysis-panel{padding:14px;margin:16px 0}
#documents .analysis-panel h3{font-size:15px}
#documents .analysis-panel p:empty{display:none}
#documents #analysisStatus{font-weight:500;color:var(--ink)}
#documents .document-preview-pane #previewCaption{margin:0 0 10px;font-size:12px}
#documents .document-actions{gap:8px}
#documents .document-footer{margin:24px 0 0;padding-top:18px;gap:10px}
#documents .document-footer button{background:transparent}
#documents #protocolPanel{margin-top:20px}
@media(max-width:900px){#documents #documentEditor{grid-template-columns:minmax(0,1fr)}#documents .document-preview-pane{position:static}}
@media(max-width:600px){.receipt-toolbar{padding:12px;align-items:stretch}.receipt-import,.receipt-filter{width:100%}.receipt-import button,.receipt-filter select{flex:1 1 auto}.receipt-filter button{flex:0 0 auto}#processBatch{margin-left:0}#documents .document-navigation button{flex:1 1 140px}#documents .document-controls{padding:16px}#documents #documentEmpty{padding:28px 16px}.receipt-mail-options{gap:8px}}

/* Preview starts next to the tools instead of below the document list. */
#documents{container-type:inline-size}
.receipt-workspace{display:grid;grid-template-columns:minmax(320px,.75fr) minmax(0,1.5fr);gap:24px;align-items:start}
.receipt-sidebar{min-width:0}
.receipt-workspace>.document-preview-pane{min-width:0;position:sticky;top:calc(var(--header-height) + 12px)}
#documents .receipt-workspace #documentEditor{display:block}
#documents .receipt-toolbar{padding:12px;gap:12px}
#documents .receipt-import,#documents .receipt-filter{width:100%}
#documents .receipt-import button{flex:1 1 120px}
#documents .receipt-filter select{flex:1;min-width:0}
#documents .receipt-mail-options{font-size:12px;padding-bottom:12px}
#documents #archiveFilters{display:block;padding:16px;margin:4px 0 14px;border:1px solid var(--line);border-radius:12px;background:var(--soft)}
#archiveFilters h3{font-size:18px;margin:0 0 12px}
#archiveFilters label{margin:10px 0}
#archiveMore{margin-top:12px}
#archiveMore select{width:100%}
#archiveMore button{width:100%;margin-top:8px}
#documents #documentListPane{max-height:280px}
#documents #documentList{display:flex;flex-direction:column;gap:8px;overflow:auto}
#documents #documentList .document-item{width:100%;flex-shrink:0}
#documents .document-navigation{margin:12px 0}
#documents .document-navigation button{padding:10px 12px;font-size:12px;flex:1 1 auto}
#documents #processBatch{margin-left:0}
#documents #documentEmpty{margin-top:0;min-height:300px;display:flex;flex-direction:column;justify-content:center}
#documents #documentPreview{height:calc(100dvh - var(--header-height) - 70px);min-height:440px}
@container(max-width:850px){
 .receipt-workspace{grid-template-columns:minmax(0,1fr)}
 .receipt-workspace>.document-preview-pane{position:static}
 #documents #documentPreview{height:70dvh;min-height:340px}
}
@media(max-width:700px){.receipt-workspace{grid-template-columns:minmax(0,1fr)}.receipt-workspace>.document-preview-pane{position:static}#documents #documentPreview{height:70dvh;min-height:340px}}
/* Compact document navigation replaces the individual file tiles. */
#documents #documentList label{display:block;min-width:0;width:100%}
#documentChooser{display:block;width:100%;min-width:0;margin-top:6px;text-overflow:ellipsis}

.avatar>.avatar-image{display:block;width:100%;height:100%;max-width:none;object-fit:cover;border-radius:inherit;margin:0;flex-shrink:0}
#settingsButton svg{display:block;flex:none}
#photoCropDialog{width:min(440px,calc(100vw - 32px));max-height:90svh;overflow:auto;padding:28px;border:1px solid var(--line);border-radius:18px;background:var(--surface,#fff);color:var(--navy)}
#photoCropDialog::backdrop{background:rgb(0 20 30 / 55%)}
#photoCropDialog h2{font-size:24px}#photoCropCanvas{display:block;width:min(256px,100%);height:auto;margin:0 auto 24px;border-radius:50%;background:#e1eeef}
#photoCropDialog label{display:block;margin-top:12px}#photoCropDialog input[type=range]{display:block;width:100%;accent-color:var(--teal)}
#photoCropDialog .document-actions{margin:20px 0 0;justify-content:flex-end}
html[data-theme=dark] #photoCropDialog{background:#102a36;color:#e0edf3}

/* Identical icon controls for settings, account menu and logout. */
#settingsButton,#accountMenu>summary.icon-button,#logout.icon-button{display:inline-flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;height:44px;min-width:44px;min-height:44px;margin:0;padding:11px;border:0;border-radius:10px;background:transparent;color:var(--navy);box-shadow:none;line-height:1;cursor:pointer;list-style:none;transition:background-color .15s ease,color .15s ease}
#accountMenu>summary::marker{content:''}#accountMenu>summary::-webkit-details-marker{display:none}
#settingsButton svg,#accountMenu>summary svg,#logout svg{display:block;width:22px;height:22px;flex:none}
#settingsButton:hover,#accountMenu>summary.icon-button:hover,#logout.icon-button:hover{background:#eaf1f4}
#settingsButton:focus-visible,#accountMenu>summary:focus-visible,#logout:focus-visible{outline:2px solid var(--teal);outline-offset:3px}
html[data-theme=dark] #settingsButton,html[data-theme=dark] #accountMenu>summary.icon-button,html[data-theme=dark] #logout.icon-button{color:var(--ink);background:transparent}
html[data-theme=dark] #settingsButton:hover,html[data-theme=dark] #accountMenu>summary.icon-button:hover,html[data-theme=dark] #logout.icon-button:hover{background:#284959}
@media(prefers-reduced-motion:reduce){#settingsButton,#accountMenu>summary.icon-button,#logout.icon-button{transition:none}}

/* Module identity stays attached to the module, including favorite sorting. */
.card[data-module]::before{content:none;display:none}
.module-tile-icon{display:grid;place-items:center;width:48px;height:48px;border-radius:12px;margin-bottom:24px}
.card[data-module=belege] .module-tile-icon{background:#e9f2f5;color:var(--navy)}
.card[data-module=vertraege] .module-tile-icon{background:#e9f4ef;color:#317a5f}
.card[data-module=hr] .module-tile-icon{background:#f3edf8;color:#7d608e}
.module-tile-icon svg{display:block}
.card .favorite-button{display:inline-flex;align-items:center;justify-content:center;border-radius:50%;width:40px;height:40px}
.favorite-button svg{width:23px;height:23px;display:block;fill:none;transition:fill .15s ease}
.favorite-button[aria-pressed=true] svg{fill:currentColor}
.favorite-button:focus-visible{outline:2px solid var(--teal);outline-offset:2px}
@media(prefers-reduced-motion:reduce){.favorite-button svg{transition:none}}

.mail-automation{margin-top:20px;padding-top:20px;border-top:1px solid var(--border,#dbe5eb)}
.mail-automation h4{margin:0 0 14px}

/* Vertragsmanager */
.contract-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:24px}.contract-heading h2,.contract-heading h3{margin:0}.contract-tiles{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}.contract-tile{display:flex;flex-direction:column;align-items:flex-start;gap:12px}.contract-tile svg{width:48px;height:48px;padding:10px;border-radius:14px;background:#e7f4ef;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;fill:none}.contract-tile p{margin:0}.contract-tile button{margin-top:auto}.contract-toolbar{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.contract-toolbar label{flex:1;min-width:170px}.contract-layout{display:grid;grid-template-columns:240px minmax(0,1fr);gap:24px;align-items:start}.contract-list-item{display:flex;flex-direction:column;text-align:left;width:100%;gap:8px;margin-bottom:10px;overflow-wrap:anywhere}.contract-list-item[aria-current=true]{border-color:#169cae;background:#eaf5f7}.contract-detail-grid{display:grid;grid-template-columns:minmax(270px,1fr) minmax(300px,1.1fr);gap:22px}.contract-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.contract-fields label{min-width:0}.contract-fields label:first-child,.contract-fields label:last-child{grid-column:1/-1}.contract-fields input,.contract-fields select,.contract-fields textarea{width:100%;box-sizing:border-box}.contract-centers{max-height:230px;overflow:auto}.contract-centers label{display:flex;gap:8px;align-items:center;margin:8px 0}.contract-centers input{width:auto}#contractForm fieldset{border:1px solid #d9e6eb;border-radius:12px;margin:18px 0;padding:14px}#contractPreview{width:100%;height:850px;border:1px solid #d9e6eb;border-radius:14px}.contract-analysis{border-top:1px solid #d9e6eb;margin-top:24px;padding-top:20px}.contract-suggestion{padding:14px;border:1px solid #d9e6eb;border-radius:12px;margin-top:12px;overflow-wrap:anywhere}.contract-due{color:#a45100}#contractDetail{min-width:0}html[data-theme=dark] .contract-list-item[aria-current=true]{background:#163d48}html[data-theme=dark] .contract-tile svg{background:#163d48}@media(max-width:1200px){.contract-tiles{grid-template-columns:repeat(2,minmax(0,1fr))}.contract-layout{grid-template-columns:190px minmax(0,1fr)}.contract-detail-grid{grid-template-columns:1fr}#contractPreview{height:650px}}@media(max-width:650px){.contract-tiles,.contract-layout,.contract-fields{grid-template-columns:1fr}.contract-heading{align-items:flex-start;flex-direction:column}.contract-detail-grid{grid-template-columns:minmax(0,1fr)}#contractList{max-height:240px;overflow:auto}}

/* Contract cards use their own SVGs, without the legacy generated icons. */
.card.contract-tile::before{content:none;display:none}
.contract-tile svg{flex:none;padding:8px;stroke-width:1.7;shape-rendering:geometricPrecision}

/* Main navigation belongs to the header. */
header{gap:24px}header #mainNavigation{margin:0 auto;padding:4px;border:0;border-radius:0;background:transparent;justify-content:center;flex-wrap:wrap;gap:6px}header #mainNavigation button{white-space:nowrap;padding:12px 16px}header .header-controls{margin-left:0}
@media(max-width:1100px){header{flex-wrap:wrap;gap:12px}header .header-controls{margin-left:auto}header #mainNavigation{order:3;flex-basis:100%;justify-content:flex-start;margin:0;padding:0}}
@media(max-width:480px){header #mainNavigation{gap:4px}header #mainNavigation button{padding:10px 11px;font-size:12px;flex:1 1 auto}}

#photoFocusCanvas{display:block;width:320px;max-width:100%;height:auto;margin:0 auto 16px;border:1px solid var(--line);border-radius:12px;cursor:crosshair;background:#eef3f5}#photoCropCanvas{display:block;clip-path:circle(50%);border-radius:50%;margin:12px auto}#photoCropDialog{max-height:90dvh;overflow:auto}

/* Consistent contract form rhythm and aligned controls. */
#contractFields{gap:20px 16px;align-items:start}#contractFields .contract-field{display:flex;flex-direction:column;gap:8px;margin:0;min-width:0}#contractFields .contract-field-label{display:block;min-height:2.8em;line-height:1.4;align-content:end}#contractFields .contract-field-wide{grid-column:1/-1}#contractFields .contract-field-wide .contract-field-label{min-height:0}#contractFields input,#contractFields select{height:48px;min-height:48px;margin:0;padding:10px 12px;line-height:1.4}#contractFields textarea{min-height:112px;margin:0;padding:12px;line-height:1.5;resize:vertical}#contractFields .contract-field-hint{font-weight:400;line-height:1.4;color:var(--muted)}.contract-save-actions{display:flex;gap:12px;flex-wrap:wrap;margin-top:16px}.contract-read-status{margin-bottom:20px}.contract-read-status button{font-size:12px;padding:8px 12px}.contract-read-status p{margin-bottom:8px}@media(max-width:650px){#contractFields .contract-field-label{min-height:0}}

#contractCenters{max-height:none;overflow:visible;display:grid;gap:10px}.contract-center-row{display:flex;gap:10px;align-items:center}.contract-center-row select{flex:1;min-width:0;height:48px;margin:0}.contract-center-row button,.contract-center-add{height:44px;min-width:44px;padding:8px;font-size:22px}.contract-center-add{justify-self:start}#cf_notice{min-height:150px}

/* Contract overview, filters and status actions. */
.contract-overview-actions{display:flex;gap:12px;flex-wrap:wrap;margin-bottom:20px}.contract-toolbar{display:grid;grid-template-columns:minmax(180px,1.5fr) repeat(3,minmax(130px,1fr)) auto;gap:16px;align-items:end}.contract-toolbar label{display:flex;flex-direction:column;gap:8px;min-width:0;margin:0}.contract-toolbar input,.contract-toolbar select{height:48px;width:100%;margin:0}.contract-layout{display:block}#contractList{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:16px;max-height:none;overflow:visible;margin:20px 0 28px}.contract-list-item{align-items:flex-start;justify-content:flex-start;min-height:170px;border-radius:16px;padding:22px;margin:0;gap:10px}.contract-tile-status{border-radius:8px;padding:4px 8px;background:#e7f4ef;color:#173543;margin-top:auto}#contractState{position:static}#contractDetail{border-top:1px solid var(--line);padding-top:24px}@media(max-width:1100px){.contract-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:600px){.contract-toolbar{grid-template-columns:1fr}}

.contract-center-row button{flex-shrink:0}

/* Separate contract overview and detail screens. */
#contractWorkspace.is-detail>.contract-toolbar,#contractWorkspace.is-detail>#contractGroupTitle,#contractWorkspace.is-detail>#contractCount,#contractWorkspace.is-detail #contractList,#contractWorkspace.is-detail #contractEmpty{display:none}
#contractDetail{border:0;padding-top:0}#contractDetailBack{margin-bottom:24px}#contractDetail .contract-heading{margin-bottom:24px}
#contractList{grid-template-columns:repeat(auto-fill,minmax(min(100%,290px),1fr));gap:22px}
#contractList .contract-list-item{display:flex;flex-direction:column;align-items:stretch;text-align:left;min-height:290px;padding:24px;gap:12px;background:var(--surface);border:1px solid var(--line);box-shadow:0 4px 16px #06354b08;transition:box-shadow .15s,border-color .15s}
#contractList .contract-list-item:hover{border-color:var(--teal);box-shadow:0 8px 24px #06354b18}
.contract-card-top{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:4px}.contract-category-icon{width:50px;height:50px;padding:9px;flex-shrink:0;border-radius:14px;background:var(--soft);color:var(--teal);fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.contract-status{display:inline-flex;align-items:center;gap:7px;font-size:12px;font-weight:600;white-space:nowrap;color:var(--ink)}.contract-status-dot{width:9px;height:9px;border-radius:50%;background:#7c8992;flex-shrink:0}.status-active .contract-status-dot{background:#209966}.status-draft .contract-status-dot{background:#e0aa20}
.contract-card-category{color:var(--muted);font-size:11px;font-weight:500}.contract-card-title{font-size:19px;line-height:1.35;overflow-wrap:anywhere}.contract-card-partner{font-size:13px;font-weight:400;color:var(--muted)}.contract-card-store{font-size:12px;font-weight:400;line-height:1.5;padding-top:12px;border-top:1px solid var(--line)}.contract-card-open{color:var(--teal);font-size:12px;margin-top:auto;padding-top:8px}#contractState{padding:0;background:none;letter-spacing:normal}
#contractForm .contract-save-actions{display:flex;flex-wrap:nowrap;gap:10px;overflow-x:auto;padding:4px 2px 12px;align-items:center}#contractForm .contract-save-actions button{height:48px;min-height:48px;flex:0 0 auto;margin:0;padding:0 16px;font-size:14px;line-height:1.4;border-radius:10px;white-space:nowrap}
.contract-detail-grid>div{min-width:0}

#notice.notice-success:not(:empty){background:#eaf6ee;color:#256342;border-color:#bdddc8}html[data-theme=dark] #notice.notice-success:not(:empty){background:#193b2c;color:#c3e8cf;border-color:#346348}

.archive-search-actions{display:flex;gap:10px}.archive-search-actions button{flex:1;min-height:48px}#archiveResults{display:grid;gap:10px;margin:16px 0}.archive-result{text-align:left;justify-content:flex-start;overflow-wrap:anywhere}.archive-result[aria-pressed=true]{border-color:var(--teal);background:var(--soft)}#exportDocument{font-size:12px;min-height:44px}
