@font-face{font-family:MahjuzKufi;src:url('kufi-bold.ttf') format('truetype');font-display:swap}
.btn{transition:background .18s,color .18s,box-shadow .18s,transform .18s;position:relative}
.btn:hover{transform:translateY(-2px);box-shadow:0 6px 16px #173f6524;text-decoration:none}
.btn:active{transform:translateY(0);box-shadow:0 2px 6px #173f6518}
body[data-buttons=colorful] .toolbar>.btn.btn-outlined:nth-child(3n+1),body[data-buttons=colorful] .actions>.btn:nth-child(3n+1){background:#edf0ff;border-color:#cacdf5;color:#5542af}
body[data-buttons=colorful] .toolbar>.btn.btn-outlined:nth-child(3n+2),body[data-buttons=colorful] .actions>.btn:nth-child(3n+2){background:#e5f8ef;border-color:#bbdfcd;color:#08734a}
body[data-buttons=colorful] .toolbar>.btn.btn-outlined:nth-child(3n),body[data-buttons=colorful] .actions>.btn:nth-child(3n){background:#fff0e5;border-color:#ebd2bc;color:#9d4f13}
body[data-buttons=colorful] .btn-soft:hover{background:#7547ca;color:white}
body[data-buttons=colorful] .btn-primary:hover{background:#0b8c7a;color:white}
body[data-buttons=calm] .btn-soft{background:var(--surface);color:var(--primary);border:1px solid var(--primary)}
.theme-option{transition:border-color .2s,transform .2s,box-shadow .2s}
.theme-option:hover{transform:translateY(-3px);box-shadow:0 8px 20px #26375a15}
.theme-option:has(input:checked){border:2px solid var(--primary);background:var(--background)}
.footer-bottom{flex-wrap:wrap}.accessibility-bar{flex-wrap:wrap;justify-content:flex-end;max-width:100%}
.footer-select{display:flex;align-items:center;gap:6px}.footer-select select{background:#fff;color:#172744;border:0;border-radius:8px;padding:5px 9px;min-width:66px;max-width:160px;font-size:.8rem}
.item-cell{display:flex;align-items:center;gap:12px}.item-picture{width:58px;height:58px;object-fit:contain;flex:none;border:1px solid var(--border);border-radius:12px;background:var(--surface)}
.item-picture.placeholder{display:grid;place-items:center;background:var(--background);color:var(--primary)}
.document-card>.item-picture{width:100%;height:155px;border-radius:15px;margin-bottom:12px}
.reference-gallery,.upload-preview{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:12px;width:100%}
.reference-gallery figure,.upload-preview figure{margin:0}.reference-gallery img,.upload-preview img{width:100%;height:135px;object-fit:contain;border-radius:12px;background:var(--background);border:1px solid var(--border)}
.reference-gallery figcaption,.upload-preview figcaption{font-size:.75rem;overflow-wrap:anywhere}.upload-preview{margin-top:12px}.upload-preview>span{color:#b4233a;font-size:.8rem}
.registration-progress{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin:20px 0}.registration-progress button{border:1px solid var(--border);border-radius:12px;padding:12px 6px;background:var(--surface);color:var(--text);font-size:.85rem}
.registration-progress button.active{background:var(--primary);color:white;border-color:var(--primary)}
.registration-step{border:0;padding:0;margin:0}.registration-step h2{font-size:1.25rem;padding-bottom:8px}.registration-controls{display:flex;gap:12px;flex-wrap:wrap;justify-content:space-between;border-top:1px solid var(--border);padding-top:20px}
.password-checks{display:flex;flex-wrap:wrap;gap:8px}.password-checks span{border-radius:12px;padding:4px 10px;font-size:.78rem;background:var(--background);color:var(--muted)}.password-checks .pass{background:#e1f7ec;color:#087349}
.permission-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:15px;margin-bottom:20px}.permission-grid fieldset{padding:16px;border:1px solid var(--border);border-radius:14px}.permission-grid legend{color:var(--primary);font-weight:700}.permission-grid .checkbox-row{margin-bottom:8px}
body[data-density=compact] .panel{padding:18px}body[data-density=compact] .data-table td,body[data-density=compact] .data-table th{padding:8px 10px}body[data-density=compact] .side-link{padding-top:7px;padding-bottom:7px}
body[data-reduced-motion="1"] *,body[data-reduced-motion="1"] *:before,body[data-reduced-motion="1"] *:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
[hidden]{display:none!important}input:focus-visible,button:focus-visible,a:focus-visible,select:focus-visible,summary:focus-visible{outline:3px solid var(--accent);outline-offset:3px}
@media(max-width:760px){.permission-grid{grid-template-columns:1fr}.registration-progress{grid-template-columns:repeat(2,1fr)}.registration-progress button{padding:10px 8px}.footer-select select{max-width:125px}.accessibility-bar{justify-content:flex-start;gap:10px}.toolbar .btn,.actions .btn{white-space:normal;min-height:42px}.reference-gallery{grid-template-columns:repeat(2,1fr)}.data-table{font-size:.8rem}.utility-inner{flex-wrap:wrap;padding-top:5px;padding-bottom:5px}.date-block{flex-wrap:wrap}.form-grid input:not([type=checkbox]):not([type=radio]):not([type=hidden]),.form-grid select,.form-grid textarea{min-width:0;width:100%}.workspace-modal{width:calc(100vw - 16px);max-width:calc(100vw - 16px)}.report-paper{overflow-wrap:anywhere}}
@media print{.registration-progress,.accessibility-bar,.upload-preview{display:none!important}.btn{box-shadow:none!important;transform:none!important}.reference-gallery img{height:120px}}
.form-grid>*{min-width:0}.panel,.table-wrap{min-width:0;max-width:100%}
.auth-panel{direction:rtl;text-align:right}
.auth-panel .checkbox-row,.auth-panel .registration-options>label,.auth-panel .avatar-options>label{direction:rtl;justify-content:flex-start;text-align:right;min-width:0;max-width:100%;gap:10px;line-height:1.75}
.auth-panel .checkbox-row{display:grid;grid-template-columns:18px minmax(0,1fr);align-items:start;justify-self:stretch;width:100%}
.auth-panel input[type=checkbox],.auth-panel input[type=radio]{width:18px;min-width:18px;max-width:18px;height:18px;min-height:18px;margin:0;flex:0 0 18px;padding:0;align-self:start;margin-top:4px}
.auth-panel .checkbox-row>span,.auth-panel .registration-options>label>span,.auth-panel .avatar-options>label>span{min-width:0;overflow-wrap:anywhere;text-align:right}
.auth-panel .registration-options,.auth-panel .avatar-options{justify-content:flex-start;direction:rtl;row-gap:14px}
.auth-panel .registration-options>label,.auth-panel .avatar-options>label{cursor:pointer;min-height:40px}
.auth-panel .check-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 18px}
.auth-panel .auth-links{display:flex;flex-wrap:wrap;justify-content:flex-start;gap:12px 24px;margin-top:20px;direction:rtl}
.auth-panel .password-field{min-width:0;align-items:stretch}
.auth-panel .password-field>input{min-width:0;flex:1 1 0}
.auth-panel .reveal-password{flex:none}
.auth-panel fieldset{min-inline-size:0;max-width:100%}
@media(max-width:480px){.auth-panel .registration-options,.auth-panel .avatar-options{flex-direction:column;align-items:flex-start}.auth-panel .check-grid{grid-template-columns:minmax(0,1fr)}}
