:root{--black:#111516;--red:#d71920;--green:#087a3d;--white:#fff;--bg:#f5f7f6;--line:#dfe4e1;--muted:#66706b}*{box-sizing:border-box}body{margin:0;font-family:Inter,Arial,sans-serif;background:var(--bg);color:#17201b}a{text-decoration:none;color:inherit}.app-shell{min-height:100vh;display:grid;grid-template-columns:220px 1fr}.sidebar{background:linear-gradient(180deg,#14191a,#0d1213);color:#fff;display:flex;flex-direction:column;min-height:100vh}.brand,.login-brand{display:flex;align-items:center;gap:10px}.brand{padding:22px 18px;border-bottom:1px solid #29302f}.brand strong,.login-brand strong{display:block;font-size:13px}.brand span,.login-brand span{display:block;font-size:10px;color:#7dd49b;font-weight:700}.crest{width:38px;height:38px;border-radius:50%;background:linear-gradient(135deg,var(--red) 0 33%,var(--black) 33% 66%,var(--green) 66%);display:grid;place-items:center;color:white;font-weight:800;border:2px solid white}.crest.large{width:54px;height:54px}.sidebar nav{padding:16px 0}.sidebar nav a{display:flex;gap:12px;padding:13px 20px;color:#e8efeb;font-size:14px}.sidebar nav a.active,.sidebar nav a:hover{background:var(--red);color:#fff}.sidebar-footer{margin-top:auto;border-top:1px solid #29302f;padding:14px}.logout{background:none;border:0;color:#fff;cursor:pointer}.main{min-width:0}.topbar{height:82px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 28px}.topbar h1{margin:0;font-size:23px}.user-chip{display:flex;align-items:center;gap:10px}.avatar{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:var(--black);color:#fff;font-weight:800}.user-chip small{display:block;color:var(--muted);font-size:11px}.content{padding:28px}.stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin-bottom:22px}.stat{padding:22px;border-radius:8px;color:#fff;min-height:112px;display:flex;flex-direction:column;justify-content:center}.stat b{font-size:28px}.stat span{font-size:13px;margin-top:6px}.dark{background:var(--black)}.red{background:var(--red)}.green{background:var(--green)}.light{background:#fff;color:#111;border:1px solid var(--line)}.panel,.form-panel{background:#fff;border:1px solid var(--line);border-radius:10px;box-shadow:0 3px 14px rgba(0,0,0,.03)}.panel-head{display:flex;align-items:center;justify-content:space-between;padding:18px 20px;border-bottom:1px solid var(--line)}.panel-head.standalone{border:0;padding:0 0 18px}.panel-head h2,.form-panel h2{margin:0}.muted{color:var(--muted);font-size:13px;margin:5px 0}.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse;font-size:13px}th,td{padding:14px 18px;border-bottom:1px solid #edf0ee;text-align:left}th{background:#fafbfa;color:#4d5752;font-size:12px}.status{color:var(--green);font-weight:700}.btn{display:inline-flex;align-items:center;justify-content:center;border-radius:5px;padding:10px 15px;border:1px solid transparent;font-weight:700;font-size:12px;cursor:pointer}.btn.primary{background:var(--green);color:#fff}.btn.secondary{background:#fff;border-color:var(--line);color:#222}.full{width:100%}.form-panel{max-width:700px;padding:24px}.form-panel.wide{max-width:900px}.form-panel form p{display:flex;flex-direction:column;gap:7px}label{font-size:12px;font-weight:700}input,select,textarea{width:100%;border:1px solid #ccd4d0;border-radius:5px;padding:11px 12px;background:#fff}input[type=checkbox]{width:auto}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.field{display:flex;flex-direction:column;gap:7px}.span-2{grid-column:span 2}.field-error,.error{color:var(--red)}.form-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}.action-row{display:flex;gap:10px;justify-content:flex-end;margin-bottom:18px}.folder-grid,.dept-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}.folder-card,.dept-card{background:#fff;border:1px solid var(--line);border-radius:8px;padding:18px;transition:.15s}.folder-card:hover,.dept-card:hover{transform:translateY(-2px);box-shadow:0 5px 16px rgba(0,0,0,.06)}.folder-shape{font-size:31px;color:var(--green)}.folder-card h3,.dept-card h3{margin:10px 0 4px;font-size:14px}.folder-card p,.dept-card p{margin:0;color:var(--muted);font-size:12px}.folder-icon{display:inline-grid;place-items:center;background:var(--green);color:#fff;border-radius:6px;padding:7px;font-weight:800}.message{padding:12px 14px;border-left:4px solid var(--green);background:#eaf7ef;margin-bottom:16px}.login-page{min-height:100vh;background:linear-gradient(130deg,#f4f5f4 0 55%,#0a2c20 55%);display:grid;place-items:center}.login-wrap{width:min(1060px,92vw);min-height:610px;display:grid;grid-template-columns:1.15fr .85fr;background:#fff;border-radius:15px;overflow:hidden;box-shadow:0 24px 60px rgba(0,0,0,.18)}.login-visual{padding:34px;position:relative;background:linear-gradient(150deg,rgba(10,20,14,.15),rgba(7,92,48,.94)),linear-gradient(25deg,#b71c1c 0 10%,#111 10% 22%,#0a6839 22% 100%);color:#fff}.visual-copy{position:absolute;bottom:55px;left:45px}.visual-copy h2{font-size:38px;margin:0}.login-card{padding:58px 56px;display:flex;flex-direction:column;justify-content:center}.centered{justify-content:center}.login-card h1{text-align:center;font-size:18px;margin:22px 0 5px}.login-card form{display:flex;flex-direction:column;gap:9px;margin:22px 0}.login-card small{text-align:center;color:var(--muted)}
@media(max-width:900px){.app-shell{grid-template-columns:72px 1fr}.brand div:not(.crest),.sidebar nav span{display:none}.sidebar nav a{justify-content:center}.stat-grid,.folder-grid,.dept-grid{grid-template-columns:repeat(2,1fr)}.login-wrap{grid-template-columns:1fr}.login-visual{display:none}.form-grid{grid-template-columns:1fr}.span-2{grid-column:auto}}@media(max-width:600px){.content{padding:16px}.topbar{padding:0 14px}.stat-grid,.folder-grid,.dept-grid{grid-template-columns:1fr}.user-chip div{display:none}.login-card{padding:36px 24px}.app-shell{grid-template-columns:58px 1fr}}


/* ==========================================================
   TANA RIVER COUNTY ASSEMBLY DMS
   PROFESSIONAL LOGIN — V1
   ========================================================== */

:root {
    --kenya-black: #111315;
    --kenya-black-soft: #1b1f22;
    --kenya-red: #bb0a16;
    --kenya-red-bright: #d71920;
    --kenya-green: #006b3f;
    --kenya-green-dark: #004d2d;
    --kenya-white: #ffffff;

    --surface: #ffffff;
    --surface-soft: #f6f8f7;
    --line: #dde4e0;

    --text: #17211c;
    --text-soft: #6c756f;

    --login-shadow: 0 24px 80px rgba(0, 0, 0, .13);
}


.dms-login-body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% 10%, rgba(0,107,63,.07), transparent 35%),
        linear-gradient(135deg, #f7f9f8 0%, #edf2ef 100%);
    color: var(--text);
    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}


.dms-login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(420px, .95fr) minmax(520px, 1.05fr);
}


/* LEFT SIDE */

.dms-login-brand {
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 70px clamp(45px, 6vw, 100px);
    box-sizing: border-box;

    background:
        radial-gradient(
            circle at 15% 15%,
            rgba(215,25,32,.18),
            transparent 30%
        ),
        radial-gradient(
            circle at 80% 75%,
            rgba(0,107,63,.30),
            transparent 42%
        ),
        linear-gradient(
            135deg,
            #090b0c 0%,
            #131719 48%,
            #003b23 100%
        );
}


.dms-login-brand::before {
    content: "";
    position: absolute;
    width: 520px;
    height: 520px;
    border-radius: 50%;
    right: -250px;
    top: -210px;
    border: 70px solid rgba(255,255,255,.025);
}


.dms-login-brand::after {
    content: "";
    position: absolute;
    width: 330px;
    height: 330px;
    border-radius: 50%;
    left: -190px;
    bottom: -150px;
    border: 55px solid rgba(215,25,32,.08);
}


.dms-login-brand-overlay {
    position: absolute;
    inset: 0;

    background:
        linear-gradient(
            115deg,
            transparent 0%,
            transparent 66%,
            rgba(255,255,255,.025) 66%,
            rgba(255,255,255,.025) 67%,
            transparent 67%
        );

    pointer-events: none;
}


.dms-brand-content {
    position: relative;
    z-index: 2;
    max-width: 610px;
}


.dms-brand-mark {
    width: 92px;
    height: 92px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.dms-brand-mark img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}


.dms-brand-heading {
    color: white;
}


.dms-brand-small {
    display: block;
    margin-bottom: 3px;

    font-size: 22px;
    font-weight: 600;
    letter-spacing: .11em;
}


.dms-brand-heading h1 {
    margin: 0;

    font-size: clamp(40px, 4vw, 66px);
    line-height: 1;
    font-weight: 800;
    letter-spacing: -.04em;
}


.dms-brand-divider {
    width: 74px;
    height: 5px;
    margin: 28px 0 28px;

    border-radius: 999px;
    background: var(--kenya-red-bright);
}


.dms-brand-content h2 {
    margin: 0;

    color: white;

    font-size: clamp(26px, 2.1vw, 36px);
    line-height: 1.2;
    font-weight: 650;
}


.dms-brand-description {
    max-width: 560px;
    margin: 19px 0 0;

    color: rgba(255,255,255,.72);

    font-size: 17px;
    line-height: 1.72;
}


.dms-brand-values {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;

    margin-top: 32px;
}


.dms-brand-values span {
    padding: 9px 15px;

    border: 1px solid rgba(255,255,255,.15);
    border-radius: 999px;

    background: rgba(255,255,255,.055);
    color: white;

    font-size: 13px;
    font-weight: 650;
    letter-spacing: .02em;
}


.kenya-stripes {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;

    z-index: 4;
}


.kenya-stripes > div {
    width: 100%;
}


.stripe-black {
    height: 7px;
    background: #0a0a0a;
}

.stripe-white {
    height: 3px;
    background: white;
}

.stripe-red {
    height: 8px;
    background: var(--kenya-red-bright);
}

.stripe-green {
    height: 9px;
    background: var(--kenya-green);
}


/* RIGHT SIDE */

.dms-login-panel {
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 50px 40px;
    box-sizing: border-box;
}


.dms-login-card {
    width: 100%;
    max-width: 510px;

    padding: 48px 48px 34px;

    border: 1px solid rgba(15,40,28,.08);
    border-radius: 22px;

    background: rgba(255,255,255,.94);

    box-shadow: var(--login-shadow);

    backdrop-filter: blur(15px);
}


.dms-login-logo {
    min-height: 78px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 26px;
}


.dms-login-logo img {
    display: block;

    max-width: 310px;
    max-height: 92px;

    object-fit: contain;
}


.dms-login-title {
    text-align: center;
    margin-bottom: 31px;
}


.dms-login-title h2 {
    margin: 0 0 7px;

    color: var(--kenya-black);

    font-size: 30px;
    line-height: 1.15;
    font-weight: 750;
    letter-spacing: -.025em;
}


.dms-login-title p {
    margin: 0;

    color: var(--text-soft);

    font-size: 14px;
    line-height: 1.55;
}


.dms-login-form {
    display: flex;
    flex-direction: column;
    gap: 21px;
}


.dms-field label {
    display: block;
    margin-bottom: 8px;

    color: #26322b;

    font-size: 13px;
    font-weight: 700;
}


.dms-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}


.dms-input-wrap {
    position: relative;
}


.dms-input-wrap input {
    width: 100%;
    height: 54px;

    box-sizing: border-box;

    padding: 0 48px 0 47px;

    border: 1px solid #d7dfda;
    border-radius: 11px;
    outline: none;

    background: #fbfcfb;
    color: var(--text);

    font-size: 14px;

    transition:
        border-color .18s ease,
        box-shadow .18s ease,
        background .18s ease;
}


.dms-input-wrap input::placeholder {
    color: #a1aaa5;
}


.dms-input-wrap input:focus {
    border-color: var(--kenya-green);

    background: white;

    box-shadow:
        0 0 0 4px rgba(0,107,63,.09);
}


.dms-input-icon {
    position: absolute;
    left: 16px;
    top: 50%;

    width: 19px;
    height: 19px;

    transform: translateY(-50%);

    display: flex;
    align-items: center;
    justify-content: center;

    pointer-events: none;
}


.dms-input-icon svg {
    width: 18px;
    height: 18px;

    fill: #89948e;
}


.dms-password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;

    width: 35px;
    height: 35px;

    transform: translateY(-50%);

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 0;
    border-radius: 8px;

    background: transparent;

    cursor: pointer;
}


.dms-password-toggle:hover {
    background: #eef3f0;
}


.dms-password-toggle svg {
    width: 19px;
    height: 19px;

    fill: #78837d;
}


.dms-password-toggle.active svg {
    fill: var(--kenya-green);
}


.dms-signin-button {
    height: 55px;
    width: 100%;

    margin-top: 5px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 11px;

    border: 0;
    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            var(--kenya-green) 0%,
            #008650 100%
        );

    color: white;

    font-size: 14px;
    font-weight: 750;
    letter-spacing: .01em;

    cursor: pointer;

    box-shadow:
        0 8px 18px rgba(0,107,63,.18);

    transition:
        transform .15s ease,
        box-shadow .15s ease,
        filter .15s ease;
}


.dms-signin-button:hover {
    transform: translateY(-1px);

    box-shadow:
        0 11px 24px rgba(0,107,63,.24);

    filter: brightness(1.03);
}


.dms-signin-button:active {
    transform: translateY(0);
}


.dms-signin-button svg {
    width: 19px;
    height: 19px;

    fill: currentColor;
}


.dms-login-alert {
    display: flex;
    align-items: flex-start;
    gap: 11px;

    margin-bottom: 22px;
    padding: 13px 15px;

    border: 1px solid rgba(187,10,22,.18);
    border-radius: 10px;

    background: rgba(187,10,22,.055);
    color: #771019;

    font-size: 13px;
}


.dms-login-alert strong {
    display: block;
    margin-bottom: 2px;
}


.dms-login-alert p {
    margin: 0;
}


.dms-alert-icon {
    flex: 0 0 23px;

    width: 23px;
    height: 23px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: var(--kenya-red);
    color: white;

    font-weight: 800;
}


.dms-login-security {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    margin-top: 25px;

    color: #77827c;

    font-size: 12px;
    font-weight: 600;
}


.dms-login-security svg {
    width: 15px;
    height: 15px;

    fill: var(--kenya-green);
}


.dms-login-footer {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;

    margin-top: 30px;
    padding-top: 21px;

    border-top: 1px solid #edf0ee;

    color: #939b97;

    font-size: 11px;
}


.footer-dot {
    color: var(--kenya-red);
}


/* TABLET */

@media (max-width: 1050px) {

    .dms-login-shell {
        grid-template-columns: 420px 1fr;
    }

    .dms-login-brand {
        padding: 60px 40px;
    }

    .dms-brand-heading h1 {
        font-size: 45px;
    }

}


/* MOBILE */

@media (max-width: 820px) {

    .dms-login-shell {
        display: block;
    }

    .dms-login-brand {
        min-height: auto;

        padding:
            36px
            26px
            43px;
    }

    .dms-brand-mark {
        width: 58px;
        height: 58px;

        margin-bottom: 15px;
    }

    .dms-brand-small {
        font-size: 14px;
    }

    .dms-brand-heading h1 {
        font-size: 31px;
    }

    .dms-brand-divider {
        width: 52px;
        height: 4px;

        margin: 19px 0;
    }

    .dms-brand-content h2 {
        font-size: 21px;
    }

    .dms-brand-description {
        display: none;
    }

    .dms-brand-values {
        margin-top: 19px;
    }

    .dms-brand-values span {
        padding: 6px 11px;
        font-size: 11px;
    }

    .dms-login-panel {
        min-height: auto;

        padding: 28px 18px 38px;
    }

    .dms-login-card {
        max-width: none;

        padding: 32px 24px 26px;

        border-radius: 17px;

        box-shadow:
            0 15px 45px rgba(0,0,0,.09);
    }

    .dms-login-logo img {
        max-width: 260px;
        max-height: 77px;
    }

}


/* SMALL MOBILE */

@media (max-width: 420px) {

    .dms-login-brand {
        padding-left: 20px;
        padding-right: 20px;
    }

    .dms-login-card {
        padding-left: 19px;
        padding-right: 19px;
    }

    .dms-login-title h2 {
        font-size: 27px;
    }

    .dms-input-wrap input {
        height: 52px;
    }

}

/* ==========================================================
   LOGIN V1.1 — CENTRE INSTITUTIONAL PANEL CONTENT
   ========================================================== */

.dms-login-brand {
    justify-content: center;
}

.dms-brand-content {
    width: 100%;
    max-width: 680px;
    margin: 0 auto;
    text-align: center;
}

.dms-brand-mark {
    margin-left: auto;
    margin-right: auto;
}

.dms-brand-divider {
    margin-left: auto;
    margin-right: auto;
}

.dms-brand-description {
    margin-left: auto;
    margin-right: auto;
    max-width: 590px;
}

.dms-brand-values {
    justify-content: center;
}

/* Keep the institutional heading visually balanced */
.dms-brand-heading,
.dms-brand-content h2 {
    text-align: center;
}


/* Mobile remains centred */
@media (max-width: 820px) {

    .dms-login-brand {
        justify-content: center;
        text-align: center;
    }

    .dms-brand-content {
        margin-left: auto;
        margin-right: auto;
    }

    .dms-brand-values {
        justify-content: center;
    }
}



/* ==========================================================
   STEP 1 FINAL — RESPONSIVE / NO-SCROLL LOGIN
   APPROVED PRODUCTION DESIGN
   ========================================================== */

/* ---------- Global viewport control ---------- */

html,
body.dms-login-body {
    width: 100%;
    height: 100%;
    min-height: 100%;
    margin: 0;
}

body.dms-login-body {
    overflow: hidden;
}

.dms-login-shell {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;

    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);

    overflow: hidden;
}


/* ==========================================================
   LEFT INSTITUTIONAL PANEL
   ========================================================== */

.dms-login-brand {
    position: relative;

    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: center;

    padding:
        clamp(34px, 5vh, 64px)
        clamp(38px, 5vw, 82px);

    overflow: hidden;
}


.dms-brand-content {
    width: 100%;
    max-width: 650px;

    margin: 0 auto;

    display: flex;
    flex-direction: column;
    align-items: center;

    text-align: center;

    position: relative;
    z-index: 3;
}


.dms-brand-mark {
    width: clamp(64px, 8vh, 94px);
    height: clamp(64px, 8vh, 94px);

    margin:
        0
        auto
        clamp(14px, 2.2vh, 24px);
}


.dms-brand-heading {
    width: 100%;
    text-align: center;
}


.dms-brand-small {
    margin: 0 0 clamp(3px, .6vh, 7px);

    font-size: clamp(15px, 2.2vh, 22px);
    line-height: 1.1;
}


.dms-brand-heading h1 {
    margin: 0;

    font-size: clamp(34px, 5.3vw, 64px);
    line-height: .98;

    white-space: nowrap;
}


.dms-brand-divider {
    width: clamp(52px, 6vw, 74px);
    height: 5px;

    margin:
        clamp(18px, 2.6vh, 28px)
        auto;
}


.dms-brand-content h2 {
    margin: 0;

    text-align: center;

    font-size: clamp(24px, 3vh, 34px);
    line-height: 1.16;
}


.dms-brand-description {
    max-width: 590px;

    margin:
        clamp(13px, 1.9vh, 19px)
        auto
        0;

    text-align: center;

    font-size: clamp(13px, 1.8vh, 16px);
    line-height: 1.65;
}


.dms-brand-values {
    width: 100%;

    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;

    gap: 10px;

    margin-top: clamp(18px, 3vh, 30px);
}


.dms-brand-values span {
    padding:
        clamp(7px, 1vh, 10px)
        clamp(13px, 1.3vw, 18px);

    font-size: clamp(11px, 1.45vh, 13px);
}


.kenya-stripes {
    flex: none;
}


/* ==========================================================
   RIGHT LOGIN PANEL
   ========================================================== */

.dms-login-panel {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: center;

    padding:
        clamp(20px, 4vh, 44px)
        clamp(24px, 4vw, 54px);

    overflow: hidden;
}


.dms-login-card {
    width: min(100%, 510px);
    max-height: calc(100dvh - 40px);

    box-sizing: border-box;

    padding:
        clamp(28px, 4.2vh, 46px)
        clamp(28px, 3vw, 46px)
        clamp(24px, 3.2vh, 34px);

    overflow: hidden;
}


.dms-login-logo {
    min-height: 0;

    margin-bottom: clamp(16px, 2.5vh, 25px);
}


.dms-login-logo img {
    max-width: min(78%, 285px);
    max-height: clamp(62px, 9vh, 88px);
}


.dms-login-title {
    margin-bottom: clamp(20px, 3.1vh, 30px);
}


.dms-login-title h2 {
    font-size: clamp(25px, 3.2vh, 30px);
}


.dms-login-title p {
    font-size: clamp(12px, 1.6vh, 14px);
}


.dms-login-form {
    gap: clamp(15px, 2.2vh, 21px);
}


.dms-field label {
    margin-bottom: 7px;

    font-size: clamp(12px, 1.5vh, 13px);
}


.dms-input-wrap input {
    height: clamp(48px, 6.5vh, 54px);
}


.dms-signin-button {
    height: clamp(49px, 6.5vh, 55px);
}


.dms-login-security {
    margin-top: clamp(16px, 2.4vh, 24px);
}


.dms-login-footer {
    margin-top: clamp(18px, 2.8vh, 28px);
    padding-top: clamp(15px, 2vh, 20px);
}


/* ==========================================================
   SHORT LAPTOP / SMALL DESKTOP HEIGHT
   ========================================================== */

@media (min-width: 821px) and (max-height: 760px) {

    .dms-login-brand {
        padding-top: 26px;
        padding-bottom: 30px;
    }

    .dms-brand-mark {
        width: 64px;
        height: 64px;
        margin-bottom: 12px;
    }

    .dms-brand-small {
        font-size: 15px;
    }

    .dms-brand-heading h1 {
        font-size: clamp(34px, 4vw, 48px);
    }

    .dms-brand-divider {
        margin-top: 15px;
        margin-bottom: 15px;
    }

    .dms-brand-content h2 {
        font-size: 23px;
    }

    .dms-brand-description {
        font-size: 13px;
        margin-top: 10px;
        line-height: 1.45;
    }

    .dms-brand-values {
        margin-top: 14px;
    }

    .dms-brand-values span {
        padding: 6px 12px;
        font-size: 11px;
    }


    .dms-login-panel {
        padding-top: 20px;
        padding-bottom: 20px;
    }

    .dms-login-card {
        padding-top: 24px;
        padding-bottom: 20px;
    }

    .dms-login-logo {
        margin-bottom: 13px;
    }

    .dms-login-logo img {
        max-height: 62px;
    }

    .dms-login-title {
        margin-bottom: 18px;
    }

    .dms-login-title h2 {
        font-size: 24px;
    }

    .dms-login-form {
        gap: 13px;
    }

    .dms-input-wrap input {
        height: 47px;
    }

    .dms-signin-button {
        height: 48px;
    }

    .dms-login-security {
        margin-top: 14px;
    }

    .dms-login-footer {
        margin-top: 15px;
        padding-top: 13px;
    }
}


/* ==========================================================
   TABLET
   ========================================================== */

@media (max-width: 1100px) and (min-width: 821px) {

    .dms-login-shell {
        grid-template-columns: .9fr 1.1fr;
    }

    .dms-login-brand {
        padding-left: 34px;
        padding-right: 34px;
    }

    .dms-brand-heading h1 {
        font-size: clamp(36px, 4.5vw, 48px);
    }

    .dms-brand-description {
        max-width: 430px;
    }

    .dms-login-panel {
        padding-left: 25px;
        padding-right: 25px;
    }
}


/* ==========================================================
   MOBILE
   Clean single-column login
   ========================================================== */

@media (max-width: 820px) {

    html,
    body.dms-login-body {
        width: 100%;
        min-height: 100%;
        height: 100%;
    }

    body.dms-login-body {
        overflow: hidden;
    }

    .dms-login-shell {
        display: block;

        width: 100%;
        height: 100vh;
        height: 100dvh;

        min-height: 0;

        overflow: hidden;
    }


    /* Hide the large desktop institutional panel.
       Branding remains inside the login card. */
    .dms-login-brand {
        display: none;
    }


    .dms-login-panel {
        width: 100%;
        height: 100vh;
        height: 100dvh;

        min-height: 0;

        display: flex;
        align-items: center;
        justify-content: center;

        padding:
            max(12px, env(safe-area-inset-top))
            16px
            max(12px, env(safe-area-inset-bottom));

        box-sizing: border-box;

        overflow: hidden;
    }


    .dms-login-card {
        width: 100%;
        max-width: 440px;

        max-height: calc(
            100dvh
            - max(24px, env(safe-area-inset-top))
            - max(24px, env(safe-area-inset-bottom))
        );

        margin: 0;

        padding:
            clamp(22px, 4vh, 32px)
            clamp(20px, 6vw, 30px)
            clamp(18px, 3vh, 26px);

        border-radius: 18px;

        overflow: hidden;
    }


    .dms-login-logo {
        margin-bottom: clamp(11px, 2.2vh, 18px);
    }


    .dms-login-logo img {
        max-width: 235px;
        max-height: clamp(57px, 9vh, 74px);
    }


    .dms-login-title {
        margin-bottom: clamp(16px, 3vh, 23px);
    }


    .dms-login-title h2 {
        margin-bottom: 5px;

        font-size: clamp(24px, 6vw, 29px);
    }


    .dms-login-title p {
        font-size: 12px;
        line-height: 1.4;
    }


    .dms-login-form {
        gap: clamp(13px, 2.4vh, 18px);
    }


    .dms-field label {
        margin-bottom: 6px;

        font-size: 12px;
    }


    .dms-input-wrap input {
        height: clamp(47px, 7vh, 52px);

        padding-left: 43px;

        font-size: 14px;
    }


    .dms-signin-button {
        height: clamp(48px, 7vh, 53px);

        margin-top: 0;
    }


    .dms-login-security {
        margin-top: clamp(13px, 2.5vh, 19px);

        font-size: 11px;
    }


    .dms-login-footer {
        margin-top: clamp(14px, 2.6vh, 20px);
        padding-top: clamp(12px, 2vh, 16px);

        font-size: 10px;
        line-height: 1.35;
    }

}


/* ==========================================================
   SMALL MOBILE / SHORT MOBILE
   ========================================================== */

@media (max-width: 430px) {

    .dms-login-panel {
        padding-left: 12px;
        padding-right: 12px;
    }

    .dms-login-card {
        max-width: none;

        padding-left: 18px;
        padding-right: 18px;
    }

}


/* Short-height phones */
@media (max-width: 820px) and (max-height: 690px) {

    .dms-login-card {
        padding-top: 15px;
        padding-bottom: 14px;
    }

    .dms-login-logo {
        margin-bottom: 8px;
    }

    .dms-login-logo img {
        max-height: 48px;
    }

    .dms-login-title {
        margin-bottom: 12px;
    }

    .dms-login-title h2 {
        font-size: 22px;
    }

    .dms-login-title p {
        font-size: 11px;
    }

    .dms-login-form {
        gap: 10px;
    }

    .dms-field label {
        margin-bottom: 4px;
    }

    .dms-input-wrap input {
        height: 43px;
    }

    .dms-signin-button {
        height: 44px;
    }

    .dms-login-security {
        margin-top: 10px;
    }

    .dms-login-footer {
        margin-top: 10px;
        padding-top: 9px;
    }
}


/* ==========================================================
   VERY WIDE DESKTOP
   ========================================================== */

@media (min-width: 1600px) {

    .dms-login-shell {
        grid-template-columns: 1fr 1fr;
    }

    .dms-login-card {
        max-width: 525px;
    }

}



/* ==========================================================
   STEP 2 — SYSTEM ADMINISTRATOR DASHBOARD
   ========================================================== */

:root {
    --dms-sidebar-width: 252px;

    --dms-black: #101315;
    --dms-black-2: #171b1d;
    --dms-red: #d71920;
    --dms-green: #007a45;
    --dms-green-2: #008b50;

    --dms-bg: #f4f7f5;
    --dms-surface: #ffffff;
    --dms-border: #e1e7e3;

    --dms-text: #17211c;
    --dms-muted: #758078;
}


.dms-app-body {
    margin: 0;

    min-height: 100vh;

    background: var(--dms-bg);
    color: var(--dms-text);

    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}


.dms-app-shell {
    min-height: 100vh;

    display: grid;
    grid-template-columns: var(--dms-sidebar-width) minmax(0, 1fr);
}


/* ==========================================================
   SIDEBAR
   ========================================================== */

.dms-sidebar {
    position: sticky;
    top: 0;

    width: var(--dms-sidebar-width);
    height: 100vh;

    box-sizing: border-box;

    display: flex;
    flex-direction: column;

    background:
        linear-gradient(
            180deg,
            #111416 0%,
            #0c0f10 100%
        );

    color: white;

    overflow: hidden;

    z-index: 30;
}


.dms-sidebar-brand {
    min-height: 87px;

    display: flex;
    align-items: center;
    gap: 12px;

    box-sizing: border-box;

    padding: 17px 19px 10px;
}


.dms-sidebar-coat {
    width: 43px;
    height: 43px;

    object-fit: contain;

    flex: 0 0 auto;
}


.dms-sidebar-brand-text {
    display: flex;
    flex-direction: column;

    line-height: 1.2;
}


.dms-sidebar-brand-text strong {
    font-size: 13px;
    letter-spacing: .05em;
}


.dms-sidebar-brand-text span {
    margin-top: 3px;

    color: #b9c1bd;

    font-size: 10px;
    font-weight: 650;

    letter-spacing: .02em;
}


.dms-sidebar-system-name {
    margin: 0 18px 17px;

    padding: 10px 12px;

    border-top: 1px solid rgba(255,255,255,.08);
    border-bottom: 1px solid rgba(255,255,255,.08);

    color: #858f89;

    font-size: 10px;
    line-height: 1.45;

    text-transform: uppercase;
    letter-spacing: .075em;
}


/* NAV */

.dms-nav {
    display: flex;
    flex-direction: column;

    gap: 3px;

    padding: 0 12px;
}


.dms-nav-item {
    min-height: 46px;

    display: flex;
    align-items: center;
    gap: 12px;

    padding: 0 13px;

    border-radius: 8px;

    color: #cfd6d2;

    text-decoration: none;

    font-size: 13px;
    font-weight: 600;

    transition:
        background .15s ease,
        color .15s ease;
}


.dms-nav-item:hover {
    background: rgba(255,255,255,.065);
    color: white;
}


.dms-nav-item.active {
    background: var(--dms-red);
    color: white;

    box-shadow:
        0 6px 16px rgba(215,25,32,.2);
}


.nav-icon {
    width: 19px;
    height: 19px;

    flex: 0 0 19px;

    display: flex;
    align-items: center;
    justify-content: center;
}


.nav-icon svg {
    width: 18px;
    height: 18px;

    fill: currentColor;
}


/* SIDEBAR BOTTOM */

.dms-sidebar-bottom {
    margin-top: auto;

    padding:
        16px
        14px
        18px;

    border-top: 1px solid rgba(255,255,255,.08);
}


.dms-sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;

    margin-bottom: 13px;
}


.dms-avatar {
    width: 38px;
    height: 38px;

    flex: 0 0 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #0d1112;
    color: white;

    font-size: 13px;
    font-weight: 750;

    border: 1px solid rgba(255,255,255,.16);
}


.dms-sidebar-user-text {
    min-width: 0;

    display: flex;
    flex-direction: column;
}


.dms-sidebar-user-text strong {
    max-width: 155px;

    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;

    font-size: 12px;
}


.dms-sidebar-user-text span {
    margin-top: 3px;

    color: #858f89;

    font-size: 10px;
}


.dms-logout-button {
    width: 100%;
    height: 39px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    border: 1px solid rgba(255,255,255,.09);
    border-radius: 7px;

    background: rgba(255,255,255,.03);
    color: #dce1de;

    cursor: pointer;

    font-size: 11px;
    font-weight: 650;
}


.dms-logout-button:hover {
    background: rgba(215,25,32,.13);
    color: white;
}


.dms-logout-button svg {
    width: 16px;
    height: 16px;

    fill: var(--dms-red);
}


/* ==========================================================
   MAIN
   ========================================================== */

.dms-main {
    min-width: 0;
    min-height: 100vh;
}


/* TOP BAR */

.dms-topbar {
    height: 76px;

    position: sticky;
    top: 0;

    z-index: 20;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    box-sizing: border-box;

    padding: 0 28px;

    background: rgba(255,255,255,.96);

    border-bottom: 1px solid var(--dms-border);

    backdrop-filter: blur(12px);
}


.dms-page-heading h1 {
    margin: 0;

    font-size: 23px;
    line-height: 1.15;

    letter-spacing: -.02em;
}


.dms-page-heading p {
    margin: 4px 0 0;

    color: var(--dms-muted);

    font-size: 11px;
}


.dms-topbar-right {
    display: flex;
    align-items: center;

    gap: 16px;
}


.dms-top-icon {
    position: relative;

    width: 39px;
    height: 39px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 1px solid var(--dms-border);
    border-radius: 9px;

    background: white;

    cursor: pointer;
}


.dms-top-icon svg {
    width: 18px;
    height: 18px;

    fill: #313b35;
}


.notification-dot {
    position: absolute;

    width: 7px;
    height: 7px;

    right: 7px;
    top: 6px;

    border-radius: 50%;

    border: 2px solid white;

    background: var(--dms-red);
}


.dms-top-user {
    display: flex;
    align-items: center;

    gap: 10px;
}


.dms-top-user .dms-avatar {
    width: 37px;
    height: 37px;

    flex-basis: 37px;

    background: var(--dms-black);
}


.dms-top-user-text {
    display: flex;
    flex-direction: column;
}


.dms-top-user-text strong {
    font-size: 11px;
}


.dms-top-user-text span {
    margin-top: 2px;

    color: var(--dms-muted);

    font-size: 9px;
}


/* MOBILE MENU */

.dms-mobile-menu {
    display: none;

    width: 39px;
    height: 39px;

    align-items: center;
    justify-content: center;

    padding: 0;

    border: 1px solid var(--dms-border);
    border-radius: 8px;

    background: white;

    cursor: pointer;
}


.dms-mobile-menu svg {
    width: 20px;
    height: 20px;

    fill: var(--dms-text);
}


/* ==========================================================
   DASHBOARD CONTENT
   ========================================================== */

.dms-dashboard-content {
    box-sizing: border-box;

    padding: 24px 28px 16px;
}


/* STATS */

.dms-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));

    gap: 15px;
}


.dms-stat-card {
    position: relative;

    min-height: 145px;

    box-sizing: border-box;

    display: flex;
    flex-direction: column;

    padding: 18px;

    border-radius: 12px;

    text-decoration: none;
    color: white;

    overflow: hidden;

    box-shadow:
        0 8px 26px rgba(16,30,22,.08);

    transition:
        transform .16s ease,
        box-shadow .16s ease;
}


a.dms-stat-card:hover {
    transform: translateY(-2px);

    box-shadow:
        0 13px 30px rgba(16,30,22,.14);
}


.dms-stat-card::after {
    content: "";

    position: absolute;

    width: 110px;
    height: 110px;

    border-radius: 50%;

    right: -37px;
    bottom: -50px;

    background: rgba(255,255,255,.07);
}


.stat-black {
    background:
        linear-gradient(
            135deg,
            #111416,
            #222829
        );
}


.stat-red {
    background:
        linear-gradient(
            135deg,
            #c70f18,
            #e11d27
        );
}


.stat-green {
    background:
        linear-gradient(
            135deg,
            #006d3e,
            #009253
        );
}


.stat-storage {
    background:
        linear-gradient(
            135deg,
            #282d2f,
            #3a4143
        );
}


.stat-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}


.stat-label {
    font-size: 11px;
    font-weight: 650;

    color: rgba(255,255,255,.83);
}


.stat-icon {
    width: 31px;
    height: 31px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;

    background: rgba(255,255,255,.11);
}


.stat-icon svg {
    width: 16px;
    height: 16px;

    fill: white;
}


.stat-number {
    margin-top: 15px;

    font-size: 29px;
    line-height: 1;

    letter-spacing: -.035em;
}


.stat-footer {
    margin-top: auto;

    color: rgba(255,255,255,.7);

    font-size: 10px;
}


/* ==========================================================
   LOWER DASHBOARD
   ========================================================== */

.dms-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(280px, .75fr);

    gap: 15px;

    margin-top: 15px;
}


.dms-panel {
    min-width: 0;

    border: 1px solid var(--dms-border);
    border-radius: 12px;

    background: white;

    box-shadow:
        0 5px 18px rgba(16,30,22,.035);
}


.dms-panel-header {
    min-height: 67px;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    padding: 15px 18px;

    border-bottom: 1px solid #edf1ee;
}


.dms-panel-header h2 {
    margin: 0;

    font-size: 15px;
    line-height: 1.2;
}


.dms-panel-header p {
    margin: 4px 0 0;

    color: var(--dms-muted);

    font-size: 10px;
}


.panel-link {
    color: var(--dms-green);

    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
}


/* RECENT ACTIVITY */

.dms-activity-list {
    min-height: 295px;
}


.activity-row {
    min-height: 57px;

    display: grid;
    grid-template-columns: 35px minmax(0, 1fr) auto;

    gap: 11px;

    align-items: center;

    padding: 9px 18px;

    border-bottom: 1px solid #f0f3f1;
}


.activity-row:last-child {
    border-bottom: 0;
}


.activity-icon {
    width: 33px;
    height: 33px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;
}


.activity-document {
    background: rgba(0,122,69,.09);
}


.activity-icon svg {
    width: 16px;
    height: 16px;

    fill: var(--dms-green);
}


.activity-copy {
    min-width: 0;

    display: flex;
    flex-direction: column;
}


.activity-copy strong {
    font-size: 11px;
}


.activity-copy span {
    max-width: 500px;

    margin-top: 3px;

    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;

    color: var(--dms-muted);

    font-size: 10px;
}


.activity-row time {
    color: #8a948e;

    font-size: 9px;
    white-space: nowrap;
}


/* EMPTY */

.dms-empty-state {
    min-height: 285px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;

    padding: 20px;
}


.empty-icon {
    width: 47px;
    height: 47px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 11px;

    border-radius: 12px;

    background: #f2f6f3;
}


.empty-icon svg {
    width: 21px;
    height: 21px;

    fill: var(--dms-green);
}


.dms-empty-state strong {
    font-size: 12px;
}


.dms-empty-state span {
    margin-top: 5px;

    color: var(--dms-muted);

    font-size: 10px;
}


/* QUICK ACTIONS */

.dms-quick-actions {
    display: flex;
    flex-direction: column;

    gap: 0;
}


.quick-action {
    min-height: 78px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 13px;

    padding: 12px 17px;

    text-decoration: none;
    color: var(--dms-text);

    border-bottom: 1px solid #edf1ee;
}


.quick-action:last-child {
    border-bottom: 0;
}


.quick-action:hover {
    background: #fafcfb;
}


.quick-icon {
    width: 38px;
    height: 38px;

    flex: 0 0 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;
}


.quick-green {
    background: rgba(0,122,69,.09);
    color: var(--dms-green);
}


.quick-red {
    background: rgba(215,25,32,.08);
    color: var(--dms-red);
}


.quick-black {
    background: rgba(17,20,22,.07);
    color: var(--dms-black);
}


.quick-icon svg {
    width: 18px;
    height: 18px;

    fill: currentColor;
}


.quick-action > span:last-child {
    display: flex;
    flex-direction: column;
}


.quick-action strong {
    font-size: 11px;
}


.quick-action small {
    margin-top: 4px;

    color: var(--dms-muted);

    font-size: 9px;
}


/* FOOTER */

.dms-dashboard-footer {
    min-height: 44px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    padding: 0 3px;

    color: #939c97;

    font-size: 9px;
}


/* ==========================================================
   RESPONSIVE
   ========================================================== */

.dms-sidebar-overlay {
    display: none;
}


@media (max-width: 1150px) {

    .dms-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dms-dashboard-grid {
        grid-template-columns: 1fr;
    }

}


@media (max-width: 900px) {

    .dms-app-shell {
        display: block;
    }

    .dms-sidebar {
        position: fixed;
        left: 0;
        top: 0;

        transform: translateX(-102%);

        transition: transform .2s ease;

        box-shadow:
            10px 0 40px rgba(0,0,0,.18);
    }

    .dms-sidebar.mobile-open {
        transform: translateX(0);
    }

    .dms-sidebar-overlay {
        position: fixed;
        inset: 0;

        z-index: 25;

        background: rgba(0,0,0,.37);

        opacity: 0;
        pointer-events: none;

        display: block;

        transition: opacity .2s ease;
    }

    .dms-sidebar-overlay.visible {
        opacity: 1;
        pointer-events: auto;
    }

    .dms-mobile-menu {
        display: flex;
    }

    .dms-topbar {
        padding-left: 16px;
        padding-right: 16px;
    }

    .dms-page-heading {
        margin-right: auto;
    }

    .dms-dashboard-content {
        padding:
            18px
            16px
            13px;
    }

}


@media (max-width: 650px) {

    .dms-topbar {
        height: 67px;
    }

    .dms-page-heading h1 {
        font-size: 19px;
    }

    .dms-page-heading p {
        display: none;
    }

    .dms-top-user-text {
        display: none;
    }

    .dms-stats-grid {
        grid-template-columns: 1fr 1fr;

        gap: 10px;
    }

    .dms-stat-card {
        min-height: 125px;

        padding: 15px;
    }

    .stat-number {
        font-size: 25px;
    }

    .dms-dashboard-grid {
        margin-top: 10px;
        gap: 10px;
    }

    .activity-row {
        grid-template-columns: 34px minmax(0,1fr);

        padding-left: 14px;
        padding-right: 14px;
    }

    .activity-row time {
        display: none;
    }

    .dms-dashboard-footer {
        flex-direction: column;
        align-items: flex-start;

        justify-content: center;

        padding: 10px 2px;
    }

}


@media (max-width: 420px) {

    .dms-stats-grid {
        grid-template-columns: 1fr;
    }

    .dms-stat-card {
        min-height: 112px;
    }

}



/* ==========================================================
   SHARED AUTHENTICATED BRAND — INSTITUTION LOGO
   ========================================================== */

.crest-logo {
    display: flex !important;
    align-items: center;
    justify-content: center;

    background: transparent !important;
    border: 0 !important;

    overflow: visible;
}

.crest-logo img {
    width: 100%;
    max-width: 46px;
    height: 46px;

    object-fit: contain;
    display: block;
}



/* ==========================================================
   STEP 3 — DEPARTMENTS MANAGEMENT
   ========================================================== */

.dms-department-page {
    box-sizing: border-box;
    padding: 24px 28px 16px;
}


.dept-page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 18px;
}


.dept-page-heading h2 {
    margin: 0;

    font-size: 20px;
    line-height: 1.2;

    letter-spacing: -.02em;
}


.dept-page-heading p {
    margin: 5px 0 0;

    color: var(--dms-muted);

    font-size: 11px;
}


.dept-add-button {
    min-height: 42px;

    box-sizing: border-box;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    padding: 0 16px;

    border-radius: 8px;

    background: var(--dms-green);
    color: white;

    text-decoration: none;

    font-size: 11px;
    font-weight: 700;

    box-shadow:
        0 5px 15px rgba(0,122,69,.16);

    transition:
        background .15s ease,
        transform .15s ease;
}


.dept-add-button:hover {
    background: #00653a;
    transform: translateY(-1px);
}


.dept-add-button svg {
    width: 17px;
    height: 17px;

    fill: currentColor;
}


/* ==========================================================
   MESSAGES
   ========================================================== */

.dept-messages {
    display: flex;
    flex-direction: column;

    gap: 8px;

    margin-bottom: 15px;
}


.dept-message {
    padding: 11px 14px;

    border: 1px solid #dfe6e1;
    border-radius: 8px;

    background: white;

    font-size: 11px;
    line-height: 1.5;
}


.dept-message.success {
    border-color: #b9dfcb;

    background: #f2fbf6;
    color: #00683b;
}


.dept-message.error {
    border-color: #efc3c5;

    background: #fff5f5;
    color: #ad151b;
}


/* ==========================================================
   SUMMARY
   ========================================================== */

.dept-summary-grid {
    display: grid;
    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 12px;

    margin-bottom: 15px;
}


.dept-summary-card {
    min-height: 91px;

    box-sizing: border-box;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 16px 18px;

    border: 1px solid var(--dms-border);
    border-radius: 10px;

    background: white;

    box-shadow:
        0 4px 14px rgba(15,30,22,.025);
}


.dept-summary-card span {
    color: var(--dms-muted);

    font-size: 10px;
    font-weight: 600;
}


.dept-summary-card strong {
    margin-top: 6px;

    font-size: 25px;
    line-height: 1;

    letter-spacing: -.035em;
}


.dept-summary-active {
    border-left:
        4px solid var(--dms-green);
}


.dept-summary-active strong {
    color: var(--dms-green);
}


.dept-summary-inactive {
    border-left:
        4px solid #8c9590;
}


/* ==========================================================
   MAIN PANEL
   ========================================================== */

.dept-panel {
    border: 1px solid var(--dms-border);
    border-radius: 11px;

    background: white;

    overflow: hidden;

    box-shadow:
        0 5px 18px rgba(16,30,22,.035);
}


.dept-panel-toolbar {
    min-height: 73px;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 18px;

    padding: 14px 17px;

    border-bottom:
        1px solid #edf1ee;
}


.dept-panel-toolbar h3 {
    margin: 0;

    font-size: 14px;
}


.dept-panel-toolbar p {
    margin: 4px 0 0;

    color: var(--dms-muted);

    font-size: 9px;
}


/* ==========================================================
   SEARCH
   ========================================================== */

.dept-search-form {
    display: flex;
    align-items: center;

    gap: 8px;
}


.dept-search {
    width: 265px;
    height: 39px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 8px;

    padding: 0 11px;

    border:
        1px solid #dfe6e1;
    border-radius: 8px;

    background: #fafcfb;

    transition:
        border-color .15s ease,
        box-shadow .15s ease;
}


.dept-search:focus-within {
    border-color: rgba(0,122,69,.52);

    box-shadow:
        0 0 0 3px rgba(0,122,69,.07);
}


.dept-search svg {
    width: 16px;
    height: 16px;

    flex: 0 0 16px;

    fill: #8b958f;
}


.dept-search input {
    width: 100%;

    padding: 0;

    border: 0;
    outline: 0;

    background: transparent;

    color: var(--dms-text);

    font: inherit;
    font-size: 11px;
}


.dept-clear-search {
    color: var(--dms-red);

    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
}


/* ==========================================================
   TABLE
   ========================================================== */

.dept-table-wrap {
    width: 100%;

    overflow-x: auto;
}


.dept-table {
    width: 100%;

    border-collapse: collapse;

    min-width: 930px;
}


.dept-table th {
    height: 43px;

    padding: 0 14px;

    background: #f8faf9;

    border-bottom:
        1px solid #e9eeeb;

    color: #747f78;

    text-align: left;

    font-size: 9px;
    font-weight: 750;

    text-transform: uppercase;
    letter-spacing: .045em;
}


.dept-table td {
    height: 67px;

    padding: 8px 14px;

    border-bottom:
        1px solid #edf1ee;

    color: #3d4741;

    font-size: 10px;

    vertical-align: middle;
}


.dept-table tbody tr:last-child td {
    border-bottom: 0;
}


.dept-table tbody tr:hover {
    background: #fbfcfb;
}


/* NAME */

.dept-name-cell {
    min-width: 270px;

    display: flex;
    align-items: center;

    gap: 11px;
}


.dept-code-avatar {
    width: 38px;
    height: 38px;

    flex: 0 0 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #eef6f1;
    color: var(--dms-green);

    font-size: 9px;
    font-weight: 800;
}


.dept-name-cell > div:last-child {
    min-width: 0;

    display: flex;
    flex-direction: column;
}


.dept-name-cell strong {
    color: #1d2722;

    font-size: 11px;
}


.dept-name-cell span {
    max-width: 340px;

    margin-top: 4px;

    color: #8a948e;

    font-size: 9px;
    line-height: 1.35;
}


/* CODE */

.dept-code-pill {
    display: inline-flex;

    padding: 5px 8px;

    border-radius: 5px;

    background: #f1f4f2;

    color: #58635d;

    font-size: 9px;
    font-weight: 750;
}


/* STATUS */

.dept-status {
    display: inline-flex;
    align-items: center;

    gap: 6px;

    font-size: 9px;
    font-weight: 700;
}


.dept-status i {
    width: 7px;
    height: 7px;

    border-radius: 50%;
}


.dept-status.active {
    color: var(--dms-green);
}


.dept-status.active i {
    background: var(--dms-green);
}


.dept-status.inactive {
    color: #7e8882;
}


.dept-status.inactive i {
    background: #9ca49f;
}


/* ==========================================================
   ACTIONS
   ========================================================== */

.dept-actions-heading {
    text-align: right !important;
}


.dept-row-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 5px;
}


.dept-status-form {
    margin: 0;
}


.dept-action-btn {
    min-height: 30px;

    box-sizing: border-box;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 9px;

    border:
        1px solid #dde4df;
    border-radius: 6px;

    background: white;
    color: #4f5a54;

    text-decoration: none;

    font-family: inherit;
    font-size: 9px;
    font-weight: 650;

    cursor: pointer;
}


.dept-action-btn:hover {
    border-color: #bac6bf;

    background: #f8faf9;

    color: #202923;
}


.dept-deactivate {
    color: #ba171d;

    border-color: #efced0;
}


.dept-deactivate:hover {
    background: #fff5f5;

    border-color: #e9b6b8;

    color: #a70f15;
}


.dept-activate {
    color: var(--dms-green);

    border-color: #c2dfd0;
}


.dept-activate:hover {
    background: #f2fbf6;
}


/* ==========================================================
   EMPTY STATE
   ========================================================== */

.dept-empty {
    min-height: 250px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}


.dept-empty-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 11px;

    border-radius: 11px;

    background: #f0f5f2;
}


.dept-empty-icon svg {
    width: 20px;
    height: 20px;

    fill: var(--dms-green);
}


.dept-empty strong {
    font-size: 12px;
}


.dept-empty span {
    margin-top: 5px;

    color: var(--dms-muted);

    font-size: 10px;
}


.dept-empty a {
    margin-top: 9px;

    color: var(--dms-green);

    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
}


/* ==========================================================
   RESPONSIVE
   ========================================================== */

@media (max-width: 900px) {

    .dms-department-page {
        padding:
            18px
            16px
            14px;
    }

}


@media (max-width: 700px) {

    .dept-page-heading {
        align-items: flex-start;
    }


    .dept-page-heading h2 {
        font-size: 18px;
    }


    .dept-add-button {
        min-height: 39px;

        padding: 0 12px;

        font-size: 10px;
    }


    .dept-summary-grid {
        grid-template-columns:
            repeat(3, 1fr);

        gap: 8px;
    }


    .dept-summary-card {
        min-height: 77px;

        padding: 12px;
    }


    .dept-summary-card span {
        font-size: 8px;
    }


    .dept-summary-card strong {
        font-size: 21px;
    }


    .dept-panel-toolbar {
        align-items: stretch;
        flex-direction: column;

        gap: 11px;

        padding: 13px;
    }


    .dept-search-form {
        width: 100%;
    }


    .dept-search {
        width: 100%;

        flex: 1;
    }

}


@media (max-width: 480px) {

    .dept-page-heading {
        flex-direction: column;

        gap: 12px;
    }


    .dept-add-button {
        width: 100%;
    }


    .dept-summary-grid {
        grid-template-columns: 1fr;
    }


    .dept-summary-card {
        min-height: 68px;

        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }


    .dept-summary-card strong {
        margin-top: 0;
    }

}



/* ==========================================================
   STEP 4 — ADD / EDIT DEPARTMENT
   ========================================================== */

.department-form-page {
    box-sizing: border-box;

    padding:
        22px
        28px
        16px;
}


/* BREADCRUMB */

.department-form-breadcrumb {
    display: flex;
    align-items: center;

    gap: 7px;

    margin-bottom: 15px;

    color: #89938d;

    font-size: 10px;
}


.department-form-breadcrumb a {
    color: var(--dms-green);

    text-decoration: none;

    font-weight: 650;
}


.department-form-breadcrumb strong {
    color: #58625c;

    font-weight: 650;
}


/* ==========================================================
   LAYOUT
   ========================================================== */

.department-form-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 760px)
        minmax(250px, 330px);

    gap: 16px;

    align-items: start;
}


/* ==========================================================
   MAIN CARD
   ========================================================== */

.department-form-card {
    border:
        1px solid var(--dms-border);

    border-radius: 12px;

    background: white;

    overflow: hidden;

    box-shadow:
        0 5px 18px
        rgba(16,30,22,.035);
}


.department-form-header {
    min-height: 82px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 13px;

    padding:
        16px
        20px;

    border-bottom:
        1px solid #edf1ee;
}


.department-form-icon {
    width: 42px;
    height: 42px;

    flex:
        0 0 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background:
        rgba(0,122,69,.08);
}


.department-form-icon svg {
    width: 19px;
    height: 19px;

    fill:
        var(--dms-green);
}


.department-form-header h2 {
    margin: 0;

    font-size: 15px;
}


.department-form-header p {
    margin:
        4px
        0
        0;

    color:
        var(--dms-muted);

    font-size: 10px;

    line-height: 1.45;
}


/* ==========================================================
   FORM
   ========================================================== */

.department-management-form {
    padding:
        20px;
}


.department-field {
    margin-bottom:
        18px;
}


.department-field label {
    display: block;

    margin-bottom:
        7px;

    color:
        #26312b;

    font-size: 10px;

    font-weight: 700;
}


.required {
    color:
        var(--dms-red);
}


.dms-form-control {
    width: 100%;
    height: 43px;

    box-sizing: border-box;

    padding:
        0
        12px;

    border:
        1px solid #dce4df;

    border-radius:
        8px;

    outline: none;

    background:
        #fbfcfb;

    color:
        #1c2621;

    font-family:
        inherit;

    font-size:
        11px;

    transition:
        border-color .15s ease,
        box-shadow .15s ease,
        background .15s ease;
}


.dms-form-control:focus {
    border-color:
        rgba(0,122,69,.55);

    background:
        white;

    box-shadow:
        0 0 0 3px
        rgba(0,122,69,.07);
}


.dms-form-textarea {
    min-height:
        105px;

    resize:
        vertical;

    padding:
        11px 12px;

    line-height:
        1.5;
}


.field-help {
    display: block;

    margin-top:
        6px;

    color:
        #8a948e;

    font-size:
        9px;

    line-height:
        1.45;
}


.department-textarea-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;
}


.department-textarea-footer > small:last-child {
    margin-top:
        6px;

    color:
        #a0a8a3;

    font-size:
        8px;

    white-space:
        nowrap;
}


/* ERRORS */

.department-field-error,
.department-form-general-error {
    margin-top:
        6px;

    color:
        #b6131b;

    font-size:
        9px;

    line-height:
        1.45;
}


.department-form-general-error {
    margin:
        0
        0
        15px;

    padding:
        10px
        12px;

    border:
        1px solid #efcbcd;

    border-radius:
        7px;

    background:
        #fff5f5;
}


/* ==========================================================
   STATUS SWITCH
   ========================================================== */

.department-status-control {
    min-height:
        74px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        20px;

    margin-top:
        5px;

    padding:
        13px
        14px;

    border:
        1px solid #e2e8e4;

    border-radius:
        9px;

    background:
        #fafcfb;
}


.department-status-control > div {
    display:
        flex;

    flex-direction:
        column;
}


.department-status-control strong {
    font-size:
        10px;
}


.department-status-control span {
    max-width:
        460px;

    margin-top:
        4px;

    color:
        #858f89;

    font-size:
        9px;

    line-height:
        1.4;
}


.department-switch {
    display:
        flex;

    align-items:
        center;

    gap:
        8px;

    cursor:
        pointer;

    flex:
        0 0 auto;
}


.dms-form-checkbox {
    position:
        absolute;

    opacity:
        0;

    width:
        1px;

    height:
        1px;
}


.department-switch-track {
    position:
        relative;

    width:
        39px;

    height:
        22px;

    flex:
        0 0 39px;

    border-radius:
        999px;

    background:
        #b7c0ba;

    transition:
        background .18s ease;
}


.department-switch-thumb {
    position:
        absolute;

    width:
        16px;

    height:
        16px;

    left:
        3px;

    top:
        3px;

    margin:
        0;

    border-radius:
        50%;

    background:
        white;

    box-shadow:
        0 2px 5px
        rgba(0,0,0,.18);

    transition:
        transform .18s ease;
}


.dms-form-checkbox:checked
+
.department-switch-track {
    background:
        var(--dms-green);
}


.dms-form-checkbox:checked
+
.department-switch-track
.department-switch-thumb {
    transform:
        translateX(17px);
}


.department-switch-text {
    margin:
        0 !important;

    min-width:
        43px;

    color:
        #46524b !important;

    font-size:
        9px !important;

    font-weight:
        700;
}


/* ==========================================================
   ACTIONS
   ========================================================== */

.department-form-actions {
    display:
        flex;

    align-items:
        center;

    justify-content:
        flex-end;

    gap:
        8px;

    margin-top:
        22px;

    padding-top:
        16px;

    border-top:
        1px solid #edf1ee;
}


.department-cancel-btn,
.department-save-btn {
    min-height:
        40px;

    box-sizing:
        border-box;

    display:
        inline-flex;

    align-items:
        center;

    justify-content:
        center;

    padding:
        0
        16px;

    border-radius:
        7px;

    font-family:
        inherit;

    font-size:
        10px;

    font-weight:
        700;

    text-decoration:
        none;

    cursor:
        pointer;
}


.department-cancel-btn {
    border:
        1px solid #dce3df;

    background:
        white;

    color:
        #57625c;
}


.department-cancel-btn:hover {
    background:
        #f7f9f8;
}


.department-save-btn {
    border:
        1px solid
        var(--dms-green);

    background:
        var(--dms-green);

    color:
        white;

    box-shadow:
        0 5px 13px
        rgba(0,122,69,.15);
}


.department-save-btn:hover {
    background:
        #006a3c;
}


/* ==========================================================
   INFORMATION PANEL
   ========================================================== */

.department-form-info {
    display:
        flex;

    flex-direction:
        column;

    gap:
        12px;
}


.department-info-card,
.department-existing-card {
    border:
        1px solid var(--dms-border);

    border-radius:
        11px;

    background:
        white;

    padding:
        17px;

    box-shadow:
        0 5px 16px
        rgba(16,30,22,.025);
}


.department-info-heading {
    display:
        flex;

    align-items:
        center;

    gap:
        9px;
}


.department-info-icon {
    width:
        31px;

    height:
        31px;

    flex:
        0 0 31px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        8px;

    background:
        rgba(0,122,69,.08);
}


.department-info-icon svg {
    width:
        15px;

    height:
        15px;

    fill:
        var(--dms-green);
}


.department-info-heading strong {
    font-size:
        11px;
}


.department-info-card > p {
    margin:
        13px
        0
        0;

    color:
        #737e77;

    font-size:
        9px;

    line-height:
        1.55;
}


.department-info-card ul {
    margin:
        13px
        0
        0;

    padding-left:
        17px;

    color:
        #59645d;

    font-size:
        9px;

    line-height:
        1.6;
}


.department-info-card li
+
li {
    margin-top:
        7px;
}


.department-existing-card {
    display:
        flex;

    flex-direction:
        column;
}


.department-existing-card > span {
    color:
        var(--dms-muted);

    font-size:
        8px;

    text-transform:
        uppercase;

    letter-spacing:
        .06em;
}


.department-existing-card strong {
    margin-top:
        7px;

    color:
        #202a24;

    font-size:
        12px;
}


.department-existing-card small {
    margin-top:
        4px;

    color:
        var(--dms-green);

    font-size:
        9px;

    font-weight:
        700;
}


/* ==========================================================
   RESPONSIVE
   ========================================================== */

@media (max-width: 1050px) {

    .department-form-layout {
        grid-template-columns:
            minmax(0, 1fr)
            260px;
    }

}


@media (max-width: 850px) {

    .department-form-page {
        padding:
            18px
            16px
            14px;
    }


    .department-form-layout {
        grid-template-columns:
            1fr;
    }


    .department-form-info {
        order:
            2;
    }

}


@media (max-width: 560px) {

    .department-management-form {
        padding:
            15px;
    }


    .department-form-header {
        padding:
            14px
            15px;
    }


    .department-status-control {
        align-items:
            flex-start;

        flex-direction:
            column;

        gap:
            12px;
    }


    .department-form-actions {
        flex-direction:
            column-reverse;

        align-items:
            stretch;
    }


    .department-cancel-btn,
    .department-save-btn {
        width:
            100%;
    }

}



/* ==========================================================
   STEP 5 — USERS MANAGEMENT
   ========================================================== */

.dms-nav-disabled {
    opacity: .45;
    cursor: default;
}


.user-management-page,
.user-edit-page {
    box-sizing: border-box;

    padding:
        24px
        28px
        16px;
}


.user-page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 18px;

    margin-bottom: 18px;
}


.user-page-heading h2 {
    margin: 0;

    font-size: 20px;
    letter-spacing: -.02em;
}


.user-page-heading p {
    margin: 5px 0 0;

    color: var(--dms-muted);

    font-size: 10px;
}


.user-add-button {
    min-height: 42px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    box-sizing: border-box;

    padding: 0 16px;

    border-radius: 8px;

    background: var(--dms-green);
    color: white;

    text-decoration: none;

    font-size: 10px;
    font-weight: 700;
}


.user-add-button svg {
    width: 17px;
    height: 17px;

    fill: currentColor;
}


/* SUMMARY */

.user-summary-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0,1fr));

    gap: 11px;

    margin-bottom: 15px;
}


.user-summary-card {
    min-height: 88px;

    box-sizing: border-box;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 15px 17px;

    border:
        1px solid var(--dms-border);

    border-radius: 10px;

    background: white;
}


.user-summary-card span {
    color: var(--dms-muted);

    font-size: 9px;
    font-weight: 650;
}


.user-summary-card strong {
    margin-top: 7px;

    font-size: 24px;

    line-height: 1;

    letter-spacing: -.03em;
}


.user-summary-active {
    border-left:
        4px solid var(--dms-green);
}


.user-summary-active strong {
    color: var(--dms-green);
}


.user-summary-inactive {
    border-left:
        4px solid #9da59f;
}


.user-summary-admin {
    border-left:
        4px solid #111;
}


/* PANEL */

.user-panel {
    border:
        1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.user-panel-header {
    min-height: 65px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    padding:
        13px
        17px;

    border-bottom:
        1px solid #edf1ee;
}


.user-panel-header h3 {
    margin: 0;

    font-size: 14px;
}


.user-panel-header p {
    margin: 4px 0 0;

    color: var(--dms-muted);

    font-size: 9px;
}


/* FILTERS */

.user-filter-bar {
    display: grid;

    grid-template-columns:
        minmax(220px, 1.7fr)
        minmax(145px, .8fr)
        minmax(140px, .75fr)
        minmax(115px, .6fr)
        auto
        auto;

    gap: 8px;

    align-items: center;

    padding:
        12px
        15px;

    border-bottom:
        1px solid #edf1ee;

    background: #fafcfb;
}


.user-search {
    height: 38px;

    display: flex;
    align-items: center;

    gap: 8px;

    box-sizing: border-box;

    padding: 0 10px;

    border:
        1px solid #dce4df;

    border-radius: 7px;

    background: white;
}


.user-search svg {
    width: 15px;
    height: 15px;

    flex: 0 0 15px;

    fill: #8c9690;
}


.user-search input {
    width: 100%;

    border: 0;
    outline: 0;

    background: transparent;

    font: inherit;
    font-size: 9px;
}


.user-filter-select {
    width: 100%;
    height: 38px;

    box-sizing: border-box;

    padding: 0 9px;

    border:
        1px solid #dce4df;

    border-radius: 7px;

    background: white;

    color: #46514a;

    font-family: inherit;
    font-size: 9px;

    outline: none;
}


.user-filter-button {
    height: 38px;

    padding: 0 13px;

    border: 0;
    border-radius: 7px;

    background: #151a17;
    color: white;

    font-family: inherit;
    font-size: 9px;
    font-weight: 700;

    cursor: pointer;
}


.user-clear-filters {
    color: var(--dms-red);

    text-decoration: none;

    font-size: 9px;
    font-weight: 700;
}


/* TABLE */

.user-table-wrap {
    width: 100%;

    overflow-x: auto;
}


.user-table {
    width: 100%;

    min-width: 960px;

    border-collapse: collapse;
}


.user-table th {
    height: 42px;

    padding: 0 14px;

    border-bottom:
        1px solid #e9eeeb;

    background: #f8faf9;

    color: #747e78;

    text-align: left;

    font-size: 8px;
    font-weight: 750;

    text-transform: uppercase;

    letter-spacing: .045em;
}


.user-table td {
    height: 66px;

    padding:
        8px
        14px;

    border-bottom:
        1px solid #edf1ee;

    color: #3e4842;

    font-size: 9px;

    vertical-align: middle;
}


.user-table tbody tr:last-child td {
    border-bottom: 0;
}


.user-table tbody tr:hover {
    background: #fbfcfb;
}


/* USER IDENTITY */

.user-identity-cell {
    min-width: 220px;

    display: flex;
    align-items: center;

    gap: 10px;
}


.user-list-avatar {
    width: 37px;
    height: 37px;

    flex: 0 0 37px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background:
        rgba(0,122,69,.09);

    color: var(--dms-green);

    font-size: 10px;
    font-weight: 800;
}


.user-identity-cell > div:last-child {
    display: flex;
    flex-direction: column;

    min-width: 0;
}


.user-identity-cell strong {
    color: #202a24;

    font-size: 10px;
}


.user-identity-cell span {
    margin-top: 3px;

    color: #8b958f;

    font-size: 8px;
}


.user-username {
    font-weight: 650;
}


.user-department {
    color: #465149;
}


.user-all-departments {
    color: var(--dms-green);

    font-weight: 700;
}


/* ROLE */

.user-role-badge {
    display: inline-flex;

    padding:
        5px
        8px;

    border-radius: 5px;

    background: #f1f4f2;

    color: #59635d;

    font-size: 8px;
    font-weight: 700;
}


.user-role-badge.admin {
    background: #171a18;

    color: white;
}


.user-role-badge.senior {
    background: #e9f4ee;

    color: #006a3c;
}


.user-role-badge.hod {
    background: #fff1f1;

    color: #b2181e;
}


/* ACTIONS */

.user-actions-heading {
    text-align: right !important;
}


.user-row-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 5px;
}


.user-row-actions form {
    margin: 0;
}


.user-action-btn {
    min-height: 29px;

    box-sizing: border-box;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 9px;

    border:
        1px solid #dce4df;

    border-radius: 6px;

    background: white;

    color: #4e5952;

    text-decoration: none;

    font-family: inherit;
    font-size: 8px;
    font-weight: 700;

    cursor: pointer;
}


.user-deactivate-btn {
    color: #b81920;

    border-color: #efcfd1;
}


.user-activate-btn {
    color: var(--dms-green);

    border-color: #c4dfd1;
}


.user-action-disabled {
    background: #f3f5f4;

    color: #959d98;

    cursor: default;
}


/* EMPTY */

.user-empty-state {
    min-height: 220px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}


.user-empty-icon {
    width: 45px;
    height: 45px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 10px;

    border-radius: 10px;

    background: #eff5f1;
}


.user-empty-icon svg {
    width: 19px;
    height: 19px;

    fill: var(--dms-green);
}


.user-empty-state strong {
    font-size: 11px;
}


.user-empty-state span {
    margin-top: 5px;

    color: var(--dms-muted);

    font-size: 9px;
}


/* ==========================================================
   EDIT USER
   ========================================================== */

.user-edit-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 760px)
        minmax(250px, 320px);

    gap: 16px;

    align-items: start;
}


.user-edit-card {
    border:
        1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.user-edit-header {
    min-height: 80px;

    display: flex;
    align-items: center;

    gap: 12px;

    box-sizing: border-box;

    padding:
        15px
        19px;

    border-bottom:
        1px solid #edf1ee;
}


.user-edit-avatar {
    width: 43px;
    height: 43px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 43px;

    border-radius: 50%;

    background:
        rgba(0,122,69,.09);

    color: var(--dms-green);

    font-size: 13px;
    font-weight: 800;
}


.user-edit-header h2 {
    margin: 0;

    font-size: 14px;
}


.user-edit-header p {
    margin: 4px 0 0;

    color: var(--dms-muted);

    font-size: 9px;
}


.user-edit-form {
    padding: 19px;
}


.user-form-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0,1fr));

    gap:
        0
        14px;
}


.dms-form-select {
    appearance: auto;
}


.user-account-status-box {
    min-height: 70px;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 15px;

    padding:
        12px
        13px;

    border:
        1px solid #e1e7e3;

    border-radius: 8px;

    background: #fafcfb;
}


.user-account-status-box > div {
    display: flex;
    flex-direction: column;
}


.user-account-status-box strong {
    font-size: 10px;
}


.user-account-status-box > div span {
    margin-top: 4px;

    color: #87918b;

    font-size: 8px;
}


.user-access-info {
    display: flex;
    flex-direction: column;

    gap: 12px;
}


.user-current-access-card {
    display: flex;
    flex-direction: column;

    padding: 16px;

    border:
        1px solid var(--dms-border);

    border-radius: 10px;

    background: white;
}


.user-current-access-card span {
    color: #89928d;

    font-size: 8px;

    text-transform: uppercase;
    letter-spacing: .06em;
}


.user-current-access-card strong {
    margin-top: 7px;

    font-size: 11px;
}


.user-current-access-card small {
    margin-top: 4px;

    color: var(--dms-green);

    font-size: 9px;
}


/* RESPONSIVE */

@media (max-width: 1050px) {

    .user-filter-bar {
        grid-template-columns:
            minmax(220px, 1fr)
            repeat(3, minmax(120px, .65fr))
            auto;
    }


    .user-clear-filters {
        grid-column:
            1 / -1;
    }


    .user-edit-layout {
        grid-template-columns:
            minmax(0,1fr)
            260px;
    }

}


@media (max-width: 850px) {

    .user-management-page,
    .user-edit-page {
        padding:
            18px
            16px
            14px;
    }


    .user-summary-grid {
        grid-template-columns:
            repeat(2, minmax(0,1fr));
    }


    .user-filter-bar {
        grid-template-columns:
            repeat(2, minmax(0,1fr));
    }


    .user-search {
        grid-column:
            1 / -1;
    }


    .user-edit-layout {
        grid-template-columns:
            1fr;
    }

}


@media (max-width: 560px) {

    .user-page-heading {
        flex-direction: column;
        align-items: stretch;
    }


    .user-add-button {
        width: 100%;
    }


    .user-summary-grid {
        grid-template-columns:
            1fr;
    }


    .user-summary-card {
        min-height: 65px;

        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }


    .user-summary-card strong {
        margin-top: 0;
    }


    .user-filter-bar {
        grid-template-columns:
            1fr;
    }


    .user-search,
    .user-clear-filters {
        grid-column: auto;
    }


    .user-form-grid {
        grid-template-columns:
            1fr;
    }


    .user-account-status-box {
        align-items: flex-start;

        flex-direction: column;
    }

}



/* ==========================================================
   STEP 6 — ADD USER
   ========================================================== */

.user-create-page {
    box-sizing: border-box;

    padding:
        22px
        28px
        16px;
}


.user-create-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 780px)
        minmax(250px, 320px);

    gap: 16px;

    align-items: start;
}


.user-create-card {
    border:
        1px solid var(--dms-border);

    border-radius:
        12px;

    background:
        white;

    overflow:
        hidden;

    box-shadow:
        0 5px 18px
        rgba(16,30,22,.035);
}


.user-create-header {
    min-height:
        82px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    gap:
        12px;

    padding:
        16px
        20px;

    border-bottom:
        1px solid #edf1ee;
}


.user-create-header-icon {
    width:
        42px;

    height:
        42px;

    flex:
        0 0 42px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        10px;

    background:
        rgba(0,122,69,.08);
}


.user-create-header-icon svg {
    width:
        19px;

    height:
        19px;

    fill:
        var(--dms-green);
}


.user-create-header h2 {
    margin:
        0;

    font-size:
        15px;
}


.user-create-header p {
    margin:
        4px
        0
        0;

    color:
        var(--dms-muted);

    font-size:
        9px;
}


.user-create-form {
    padding:
        20px;
}


.user-create-section-title {
    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        10px;

    margin:
        3px
        0
        15px;

    padding-bottom:
        9px;

    border-bottom:
        1px solid #edf1ee;
}


.user-create-section-title strong {
    color:
        #28322c;

    font-size:
        10px;

    text-transform:
        uppercase;

    letter-spacing:
        .035em;
}


.user-create-section-title span {
    color:
        #939c96;

    font-size:
        8px;
}


.user-create-grid {
    display:
        grid;

    grid-template-columns:
        repeat(2, minmax(0,1fr));

    gap:
        0
        14px;

    margin-bottom:
        6px;
}


.user-password-field {
    position:
        relative;
}


.user-password-field .dms-form-control {
    padding-right:
        55px;
}


.user-password-toggle {
    position:
        absolute;

    right:
        7px;

    top:
        50%;

    transform:
        translateY(-50%);

    min-width:
        40px;

    height:
        27px;

    padding:
        0
        7px;

    border:
        0;

    border-radius:
        5px;

    background:
        #edf3ef;

    color:
        var(--dms-green);

    font-family:
        inherit;

    font-size:
        8px;

    font-weight:
        700;

    cursor:
        pointer;
}


.user-password-rules {
    display:
        flex;

    align-items:
        center;

    gap:
        8px;

    margin:
        -3px
        0
        18px;

    padding:
        9px
        11px;

    border:
        1px solid #e2e9e4;

    border-radius:
        7px;

    background:
        #f8fbf9;
}


.user-password-rules strong {
    color:
        #49534d;

    font-size:
        8px;
}


.user-password-rules span {
    color:
        #858f89;

    font-size:
        8px;
}


.user-create-status {
    min-height:
        70px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        18px;

    padding:
        12px
        14px;

    border:
        1px solid #e1e7e3;

    border-radius:
        8px;

    background:
        #fafcfb;
}


.user-create-status > div {
    display:
        flex;

    flex-direction:
        column;
}


.user-create-status strong {
    font-size:
        10px;
}


.user-create-status > div span {
    margin-top:
        4px;

    color:
        #87918b;

    font-size:
        8px;
}


/* RIGHT INFORMATION PANEL */

.user-create-info {
    display:
        flex;

    flex-direction:
        column;

    gap:
        12px;
}


.user-role-guide {
    display:
        flex;

    flex-direction:
        column;

    gap:
        14px;

    margin-top:
        14px;
}


.user-role-guide > div {
    display:
        flex;

    align-items:
        flex-start;

    gap:
        9px;
}


.user-role-dot {
    width:
        8px;

    height:
        8px;

    flex:
        0 0 8px;

    margin-top:
        4px;

    border-radius:
        50%;
}


.user-role-dot.dept {
    background:
        #839087;
}


.user-role-dot.hod {
    background:
        #c52127;
}


.user-role-dot.senior {
    background:
        var(--dms-green);
}


.user-role-dot.admin {
    background:
        #151a17;
}


.user-role-guide p {
    display:
        flex;

    flex-direction:
        column;

    margin:
        0;
}


.user-role-guide strong {
    color:
        #39443d;

    font-size:
        9px;
}


.user-role-guide small {
    margin-top:
        3px;

    color:
        #7d8881;

    font-size:
        8px;

    line-height:
        1.45;
}


.user-security-card {
    padding:
        16px;

    border:
        1px solid var(--dms-border);

    border-radius:
        10px;

    background:
        #161a18;

    color:
        white;
}


.user-security-card strong {
    font-size:
        10px;
}


.user-security-card p {
    margin:
        7px
        0
        0;

    color:
        rgba(255,255,255,.72);

    font-size:
        8px;

    line-height:
        1.55;
}


/* RESPONSIVE */

@media (max-width: 1050px) {

    .user-create-layout {
        grid-template-columns:
            minmax(0,1fr)
            260px;
    }

}


@media (max-width: 850px) {

    .user-create-page {
        padding:
            18px
            16px
            14px;
    }


    .user-create-layout {
        grid-template-columns:
            1fr;
    }

}


@media (max-width: 560px) {

    .user-create-form {
        padding:
            15px;
    }


    .user-create-header {
        padding:
            14px
            15px;
    }


    .user-create-grid {
        grid-template-columns:
            1fr;
    }


    .user-create-section-title {
        align-items:
            flex-start;

        flex-direction:
            column;

        gap:
            3px;
    }


    .user-password-rules {
        align-items:
            flex-start;

        flex-direction:
            column;
    }


    .user-create-status {
        align-items:
            flex-start;

        flex-direction:
            column;
    }

}



/* ==========================================================
   STEP 7 — DEPARTMENT WORKSPACE
   ========================================================== */

.workspace-page {
    box-sizing: border-box;

    padding:
        22px
        28px
        16px;
}


/* HERO */

.workspace-hero {
    min-height:
        128px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        22px;

    padding:
        20px
        22px;

    margin-bottom:
        14px;

    border:
        1px solid var(--dms-border);

    border-radius:
        12px;

    background:
        linear-gradient(
            125deg,
            #ffffff 0%,
            #f8fbf9 66%,
            #f1f7f3 100%
        );

    box-shadow:
        0 5px 18px
        rgba(16,30,22,.03);
}


.workspace-hero-main {
    display:
        flex;

    align-items:
        center;

    gap:
        15px;

    min-width:
        0;
}


.workspace-dept-code {
    width:
        58px;

    height:
        58px;

    flex:
        0 0 58px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        11px;

    background:
        #151a17;

    color:
        white;

    font-size:
        13px;

    font-weight:
        800;

    letter-spacing:
        .04em;
}


.workspace-eyebrow {
    display:
        block;

    margin-bottom:
        3px;

    color:
        var(--dms-green);

    font-size:
        8px;

    font-weight:
        800;

    text-transform:
        uppercase;

    letter-spacing:
        .07em;
}


.workspace-hero h2 {
    margin:
        0;

    color:
        #1d2721;

    font-size:
        21px;

    line-height:
        1.15;

    letter-spacing:
        -.025em;
}


.workspace-hero p {
    max-width:
        660px;

    margin:
        6px
        0
        0;

    color:
        #78827c;

    font-size:
        9px;

    line-height:
        1.55;
}


.workspace-hero-actions {
    display:
        flex;

    align-items:
        center;

    gap:
        8px;

    flex:
        0 0 auto;
}


.workspace-primary-button,
.workspace-secondary-button {
    min-height:
        40px;

    box-sizing:
        border-box;

    display:
        inline-flex;

    align-items:
        center;

    justify-content:
        center;

    gap:
        7px;

    padding:
        0
        13px;

    border-radius:
        7px;

    text-decoration:
        none;

    font-size:
        9px;

    font-weight:
        750;
}


.workspace-primary-button svg,
.workspace-secondary-button svg {
    width:
        15px;

    height:
        15px;

    fill:
        currentColor;
}


.workspace-primary-button {
    border:
        1px solid var(--dms-green);

    background:
        var(--dms-green);

    color:
        white;
}


.workspace-secondary-button {
    border:
        1px solid #d7dfda;

    background:
        white;

    color:
        #4d5851;
}


/* STATS */

.workspace-stats-grid {
    display:
        grid;

    grid-template-columns:
        repeat(4, minmax(0,1fr));

    gap:
        11px;

    margin-bottom:
        14px;
}


.workspace-stat-card {
    min-height:
        82px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    gap:
        11px;

    padding:
        13px
        15px;

    border:
        1px solid var(--dms-border);

    border-radius:
        10px;

    background:
        white;
}


.workspace-stat-icon {
    width:
        36px;

    height:
        36px;

    flex:
        0 0 36px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        8px;
}


.workspace-stat-icon svg {
    width:
        17px;

    height:
        17px;

    fill:
        currentColor;
}


.workspace-stat-icon.folder {
    background:
        #edf7f1;

    color:
        var(--dms-green);
}


.workspace-stat-icon.document {
    background:
        #fff0f0;

    color:
        var(--dms-red);
}


.workspace-stat-icon.users {
    background:
        #f1f2f1;

    color:
        #171a18;
}


.workspace-stat-icon.storage {
    background:
        #f5f5ef;

    color:
        #756d23;
}


.workspace-stat-card > div:last-child {
    display:
        flex;

    flex-direction:
        column;
}


.workspace-stat-card span {
    color:
        #89938d;

    font-size:
        8px;

    font-weight:
        650;
}


.workspace-stat-card strong {
    margin-top:
        5px;

    color:
        #212b25;

    font-size:
        20px;

    line-height:
        1;
}


.workspace-storage-value {
    font-size:
        14px !important;
}


/* CONTENT */

.workspace-content-grid {
    display:
        grid;

    grid-template-columns:
        minmax(0,1fr)
        minmax(230px,290px);

    gap:
        14px;

    margin-bottom:
        14px;
}


.workspace-panel,
.workspace-quick-panel {
    border:
        1px solid var(--dms-border);

    border-radius:
        11px;

    background:
        white;

    overflow:
        hidden;
}


.workspace-panel-header {
    min-height:
        61px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        10px;

    padding:
        12px
        16px;

    border-bottom:
        1px solid #edf1ee;
}


.workspace-panel-header h3 {
    margin:
        0;

    color:
        #29332d;

    font-size:
        12px;
}


.workspace-panel-header p {
    margin:
        4px
        0
        0;

    color:
        #8b958e;

    font-size:
        8px;
}


.workspace-panel-header > a {
    color:
        var(--dms-green);

    text-decoration:
        none;

    font-size:
        8px;

    font-weight:
        750;
}


/* FOLDERS */

.workspace-folder-grid {
    display:
        grid;

    grid-template-columns:
        repeat(2, minmax(0,1fr));

    gap:
        9px;

    padding:
        13px;
}


.workspace-folder-card {
    min-height:
        64px;

    box-sizing:
        border-box;

    display:
        flex;

    align-items:
        center;

    gap:
        9px;

    padding:
        10px
        11px;

    border:
        1px solid #e6ebe8;

    border-radius:
        8px;

    background:
        #fbfcfb;

    color:
        inherit;

    text-decoration:
        none;
}


.workspace-folder-card:hover {
    border-color:
        rgba(0,122,69,.3);

    background:
        #f7faf8;
}


.workspace-folder-icon {
    width:
        33px;

    height:
        33px;

    flex:
        0 0 33px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        7px;

    background:
        #edf6f0;
}


.workspace-folder-icon svg {
    width:
        16px;

    height:
        16px;

    fill:
        var(--dms-green);
}


.workspace-folder-card > div:nth-child(2) {
    min-width:
        0;

    display:
        flex;

    flex-direction:
        column;

    flex:
        1;
}


.workspace-folder-card strong {
    color:
        #344039;

    font-size:
        9px;

    white-space:
        nowrap;

    overflow:
        hidden;

    text-overflow:
        ellipsis;
}


.workspace-folder-card span {
    margin-top:
        3px;

    color:
        #929b95;

    font-size:
        8px;
}


.workspace-folder-arrow {
    width:
        13px;

    height:
        13px;

    fill:
        none;

    stroke:
        #98a19b;

    stroke-width:
        2;

    flex:
        0 0 13px;
}


.workspace-empty-folders {
    grid-column:
        1 / -1;

    min-height:
        170px;

    display:
        flex;

    flex-direction:
        column;

    align-items:
        center;

    justify-content:
        center;

    text-align:
        center;
}


.workspace-empty-folders > div {
    width:
        42px;

    height:
        42px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        9px;

    background:
        #eef6f1;
}


.workspace-empty-folders svg {
    width:
        18px;

    height:
        18px;

    fill:
        var(--dms-green);
}


.workspace-empty-folders strong {
    margin-top:
        10px;

    font-size:
        10px;
}


.workspace-empty-folders span {
    margin-top:
        4px;

    color:
        #8b958f;

    font-size:
        8px;
}


.workspace-empty-folders a {
    margin-top:
        10px;

    color:
        var(--dms-green);

    text-decoration:
        none;

    font-size:
        8px;

    font-weight:
        750;
}


/* QUICK ACTIONS */

.workspace-action-list {
    display:
        flex;

    flex-direction:
        column;

    padding:
        7px
        13px
        13px;
}


.workspace-action-row {
    min-height:
        62px;

    display:
        flex;

    align-items:
        center;

    gap:
        10px;

    padding:
        7px
        0;

    border-bottom:
        1px solid #edf1ee;

    text-decoration:
        none;
}


.workspace-action-row:last-child {
    border-bottom:
        0;
}


.workspace-action-icon {
    width:
        34px;

    height:
        34px;

    flex:
        0 0 34px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        8px;
}


.workspace-action-icon svg {
    width:
        16px;

    height:
        16px;

    fill:
        currentColor;
}


.workspace-action-icon.green {
    background:
        #edf7f1;

    color:
        var(--dms-green);
}


.workspace-action-icon.red {
    background:
        #fff0f0;

    color:
        var(--dms-red);
}


.workspace-action-icon.black {
    background:
        #f0f1f0;

    color:
        #171a18;
}


.workspace-action-row > div {
    display:
        flex;

    flex-direction:
        column;
}


.workspace-action-row strong {
    color:
        #344038;

    font-size:
        9px;
}


.workspace-action-row small {
    margin-top:
        3px;

    color:
        #909a93;

    font-size:
        8px;
}


/* RECENT DOCUMENTS */

.workspace-recent-panel {
    margin-bottom:
        2px;
}


.workspace-recent-table-wrap {
    overflow-x:
        auto;
}


.workspace-recent-table {
    width:
        100%;

    min-width:
        720px;

    border-collapse:
        collapse;
}


.workspace-recent-table th {
    height:
        38px;

    padding:
        0
        14px;

    background:
        #f8faf9;

    border-bottom:
        1px solid #e9eeeb;

    color:
        #79837d;

    text-align:
        left;

    font-size:
        8px;

    font-weight:
        750;

    text-transform:
        uppercase;

    letter-spacing:
        .04em;
}


.workspace-recent-table td {
    height:
        58px;

    padding:
        8px
        14px;

    border-bottom:
        1px solid #edf1ee;

    color:
        #535f57;

    font-size:
        8px;
}


.workspace-recent-table tbody tr:last-child td {
    border-bottom:
        0;
}


.workspace-document-cell {
    display:
        flex;

    align-items:
        center;

    gap:
        9px;

    min-width:
        220px;
}


.workspace-document-icon {
    width:
        31px;

    height:
        31px;

    flex:
        0 0 31px;

    display:
        flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        7px;

    background:
        #fff0f0;
}


.workspace-document-icon svg {
    width:
        14px;

    height:
        14px;

    fill:
        var(--dms-red);
}


.workspace-document-cell > div {
    display:
        flex;

    flex-direction:
        column;
}


.workspace-document-cell strong {
    color:
        #313c35;

    font-size:
        9px;
}


.workspace-document-cell small {
    margin-top:
        2px;

    color:
        #969f99;

    font-size:
        7px;
}


.workspace-empty-documents {
    min-height:
        150px;

    display:
        flex;

    flex-direction:
        column;

    align-items:
        center;

    justify-content:
        center;

    text-align:
        center;
}


.workspace-empty-documents strong {
    color:
        #364139;

    font-size:
        10px;
}


.workspace-empty-documents span {
    margin-top:
        4px;

    color:
        #8c9690;

    font-size:
        8px;
}


.workspace-empty-documents a {
    margin-top:
        9px;

    color:
        var(--dms-green);

    text-decoration:
        none;

    font-size:
        8px;

    font-weight:
        750;
}


/* RESPONSIVE */

@media (max-width: 1050px) {

    .workspace-stats-grid {
        grid-template-columns:
            repeat(2, minmax(0,1fr));
    }


    .workspace-content-grid {
        grid-template-columns:
            minmax(0,1fr)
            250px;
    }

}


@media (max-width: 850px) {

    .workspace-page {
        padding:
            18px
            16px
            14px;
    }


    .workspace-hero {
        align-items:
            flex-start;

        flex-direction:
            column;
    }


    .workspace-hero-actions {
        width:
            100%;
    }


    .workspace-primary-button,
    .workspace-secondary-button {
        flex:
            1;
    }


    .workspace-content-grid {
        grid-template-columns:
            1fr;
    }

}


@media (max-width: 560px) {

    .workspace-hero-main {
        align-items:
            flex-start;
    }


    .workspace-dept-code {
        width:
            46px;

        height:
            46px;

        flex-basis:
            46px;

        font-size:
            10px;
    }


    .workspace-hero h2 {
        font-size:
            17px;
    }


    .workspace-hero-actions {
        flex-direction:
            column;
    }


    .workspace-primary-button,
    .workspace-secondary-button {
        width:
            100%;
    }


    .workspace-stats-grid {
        grid-template-columns:
            1fr;
    }


    .workspace-stat-card {
        min-height:
            66px;
    }


    .workspace-folder-grid {
        grid-template-columns:
            1fr;
    }

}



/* ==========================================================
   STEP 8 — FOLDER LIBRARY
   ========================================================== */

.folder-library-page,
.folder-form-page {
    box-sizing: border-box;

    padding:
        22px
        28px
        16px;
}


/* BREADCRUMBS */

.folder-breadcrumbs {
    display: flex;
    align-items: center;
    flex-wrap: wrap;

    gap: 6px;

    margin-bottom: 15px;

    color: #8b958f;

    font-size: 8px;
}


.folder-breadcrumbs a {
    color: #738078;

    text-decoration: none;
}


.folder-breadcrumbs a:hover {
    color: var(--dms-green);
}


.folder-breadcrumbs strong {
    color: #364139;
}


/* PAGE HEADING */

.folder-library-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 15px;
}


.folder-section-label {
    display: block;

    margin-bottom: 5px;

    color: var(--dms-green);

    font-size: 8px;
    font-weight: 800;

    text-transform: uppercase;

    letter-spacing: .07em;
}


.folder-library-heading h2 {
    margin: 0;

    color: #222d26;

    font-size: 20px;

    letter-spacing: -.025em;
}


.folder-library-heading p {
    margin: 5px 0 0;

    color: #828c86;

    font-size: 9px;
}


.folder-create-button {
    min-height: 40px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    box-sizing: border-box;

    padding: 0 14px;

    border-radius: 7px;

    background: var(--dms-green);
    color: white;

    text-decoration: none;

    font-size: 9px;
    font-weight: 750;
}


.folder-create-button svg {
    width: 15px;
    height: 15px;

    fill: currentColor;
}


/* SUMMARY */

.folder-summary-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0,1fr));

    gap: 10px;

    margin-bottom: 14px;
}


.folder-summary-card {
    min-height: 76px;

    box-sizing: border-box;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding: 13px 15px;

    border: 1px solid var(--dms-border);

    border-radius: 9px;

    background: white;
}


.folder-summary-card span {
    color: #8b958f;

    font-size: 8px;

    font-weight: 650;
}


.folder-summary-card strong {
    margin-top: 5px;

    color: #222c26;

    font-size: 19px;
}


.folder-summary-green {
    border-left: 4px solid var(--dms-green);
}


.folder-summary-red {
    border-left: 4px solid var(--dms-red);
}


.folder-level-label {
    font-size: 12px !important;
}


/* PANEL */

.folder-library-panel {
    border: 1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.folder-panel-header {
    min-height: 60px;

    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;

    padding: 12px 16px;

    border-bottom: 1px solid #edf1ee;
}


.folder-panel-header h3 {
    margin: 0;

    font-size: 12px;
}


.folder-panel-header p {
    margin: 4px 0 0;

    color: #8b958f;

    font-size: 8px;
}


.folder-up-button {
    color: var(--dms-green);

    text-decoration: none;

    font-size: 8px;

    font-weight: 750;
}


/* GRID */

.folder-library-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0,1fr));

    gap: 10px;

    padding: 14px;
}


.folder-library-card {
    min-height: 86px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 11px;

    padding: 12px;

    border: 1px solid #e3e9e5;

    border-radius: 9px;

    background: #fbfcfb;

    color: inherit;

    text-decoration: none;

    transition:
        border-color .15s ease,
        transform .15s ease,
        background .15s ease;
}


.folder-library-card:hover {
    border-color: rgba(0,122,69,.3);

    background: #f8fbf9;

    transform: translateY(-1px);
}


.folder-card-icon {
    width: 41px;
    height: 41px;

    flex: 0 0 41px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #edf6f0;
}


.folder-card-icon svg {
    width: 19px;
    height: 19px;

    fill: var(--dms-green);
}


.folder-card-body {
    min-width: 0;

    flex: 1;

    display: flex;
    flex-direction: column;
}


.folder-card-body strong {
    color: #303b34;

    font-size: 9px;

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


.folder-card-meta {
    display: flex;
    align-items: center;

    gap: 5px;

    margin-top: 5px;

    color: #8b958f;

    font-size: 7px;
}


.folder-card-meta i {
    width: 3px;
    height: 3px;

    border-radius: 50%;

    background: #b0b8b3;
}


.folder-card-arrow {
    width: 17px;
    height: 17px;

    flex: 0 0 17px;

    display: flex;
    align-items: center;
    justify-content: center;
}


.folder-card-arrow svg {
    width: 13px;
    height: 13px;

    fill: none;

    stroke: #9ba49e;

    stroke-width: 2;
}


/* EMPTY */

.folder-library-empty {
    grid-column: 1 / -1;

    min-height: 240px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}


.folder-empty-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background: #edf6f0;
}


.folder-empty-icon svg {
    width: 21px;
    height: 21px;

    fill: var(--dms-green);
}


.folder-library-empty strong {
    margin-top: 11px;

    color: #344039;

    font-size: 10px;
}


.folder-library-empty span {
    max-width: 390px;

    margin-top: 5px;

    color: #89938d;

    font-size: 8px;

    line-height: 1.5;
}


.folder-library-empty a {
    margin-top: 11px;

    color: var(--dms-green);

    text-decoration: none;

    font-size: 8px;

    font-weight: 750;
}


/* SECURITY */

.folder-security-note {
    min-height: 58px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 10px;

    margin-top: 12px;

    padding: 10px 13px;

    border: 1px solid #dce8e0;

    border-radius: 8px;

    background: #f7fbf8;
}


.folder-security-note svg {
    width: 18px;
    height: 18px;

    flex: 0 0 18px;

    fill: var(--dms-green);
}


.folder-security-note > div {
    display: flex;
    flex-direction: column;
}


.folder-security-note strong {
    color: #375144;

    font-size: 8px;
}


.folder-security-note span {
    margin-top: 2px;

    color: #809087;

    font-size: 8px;
}


/* ==========================================================
   CREATE FOLDER FORM
   ========================================================== */

.folder-form-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 680px)
        minmax(250px, 310px);

    gap: 16px;

    align-items: start;
}


.folder-form-card {
    border: 1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.folder-form-header {
    min-height: 76px;

    box-sizing: border-box;

    display: flex;
    align-items: center;

    gap: 11px;

    padding: 14px 18px;

    border-bottom: 1px solid #edf1ee;
}


.folder-form-icon {
    width: 39px;
    height: 39px;

    flex: 0 0 39px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #edf6f0;
}


.folder-form-icon svg {
    width: 18px;
    height: 18px;

    fill: var(--dms-green);
}


.folder-form-header h2 {
    margin: 0;

    font-size: 14px;
}


.folder-form-header p {
    margin: 4px 0 0;

    color: #89938d;

    font-size: 8px;
}


.folder-create-form {
    padding: 19px;
}


.folder-location-box {
    margin-top: 5px;

    padding: 12px 13px;

    border: 1px solid #e1e7e3;

    border-radius: 8px;

    background: #fafcfb;
}


.folder-location-box > span {
    display: block;

    color: #929b95;

    font-size: 8px;

    text-transform: uppercase;

    letter-spacing: .05em;
}


.folder-location-box > strong {
    display: block;

    margin-top: 5px;

    color: #354139;

    font-size: 10px;
}


.folder-location-path {
    display: flex;
    align-items: center;
    flex-wrap: wrap;

    gap: 5px;

    margin-top: 6px;

    color: #7d8981;

    font-size: 8px;
}


.folder-location-path i {
    color: #a9b1ac;

    font-style: normal;
}


.folder-form-info {
    display: flex;
    flex-direction: column;

    gap: 12px;
}


.folder-parent-card {
    display: flex;
    flex-direction: column;

    padding: 15px;

    border: 1px solid var(--dms-border);

    border-radius: 9px;

    background: white;
}


.folder-parent-card span {
    color: #909993;

    font-size: 8px;

    text-transform: uppercase;

    letter-spacing: .05em;
}


.folder-parent-card strong {
    margin-top: 6px;

    color: #303b34;

    font-size: 11px;
}


.folder-parent-card small {
    margin-top: 4px;

    color: var(--dms-green);

    font-size: 8px;
}


/* RESPONSIVE */

@media (max-width: 1050px) {

    .folder-library-grid {
        grid-template-columns:
            repeat(2, minmax(0,1fr));
    }


    .folder-form-layout {
        grid-template-columns:
            minmax(0,1fr)
            260px;
    }

}


@media (max-width: 850px) {

    .folder-library-page,
    .folder-form-page {
        padding:
            18px
            16px
            14px;
    }


    .folder-summary-grid {
        grid-template-columns:
            repeat(2, minmax(0,1fr));
    }


    .folder-form-layout {
        grid-template-columns:
            1fr;
    }

}


@media (max-width: 560px) {

    .folder-library-heading {
        align-items: stretch;

        flex-direction: column;
    }


    .folder-create-button {
        width: 100%;
    }


    .folder-summary-grid {
        grid-template-columns:
            1fr;
    }


    .folder-summary-card {
        min-height: 62px;

        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }


    .folder-summary-card strong {
        margin-top: 0;
    }


    .folder-library-grid {
        grid-template-columns:
            1fr;
    }


    .folder-panel-header {
        align-items: flex-start;

        flex-direction: column;
    }


    .folder-create-form {
        padding: 15px;
    }

}



/* ==========================================================
   STEP 9 — DOCUMENT LIBRARY & SECURE UPLOAD
   ========================================================== */

.document-library-page,
.document-upload-page {
    box-sizing: border-box;
    padding: 22px 28px 16px;
}


.document-library-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 18px;

    margin-bottom: 15px;
}


.document-section-label {
    display: block;

    margin-bottom: 5px;

    color: var(--dms-green);

    font-size: 8px;
    font-weight: 800;

    text-transform: uppercase;

    letter-spacing: .07em;
}


.document-library-heading h2 {
    margin: 0;

    color: #222d26;

    font-size: 20px;
}


.document-library-heading p {
    margin: 5px 0 0;

    color: #838d87;

    font-size: 9px;
}


.document-upload-button {
    min-height: 40px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    box-sizing: border-box;

    padding: 0 14px;

    border-radius: 7px;

    background: var(--dms-green);
    color: white;

    text-decoration: none;

    font-size: 9px;
    font-weight: 750;
}


.document-upload-button svg {
    width: 15px;
    height: 15px;

    fill: currentColor;
}


.document-summary-grid {
    display: grid;

    grid-template-columns:
        180px
        180px
        minmax(0,1fr);

    gap: 10px;

    margin-bottom: 14px;
}


.document-summary-card {
    min-height: 72px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    box-sizing: border-box;

    padding: 12px 14px;

    border: 1px solid var(--dms-border);

    border-radius: 9px;

    background: white;
}


.document-summary-card span {
    color: #89938d;

    font-size: 8px;
}


.document-summary-card strong {
    margin-top: 5px;

    color: #27312b;

    font-size: 18px;
}


.document-summary-red {
    border-left: 4px solid var(--dms-red);
}


.document-summary-name {
    font-size: 11px !important;
}


.document-library-panel {
    border: 1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.document-toolbar {
    padding: 11px 13px;

    border-bottom: 1px solid #edf1ee;

    background: #fbfcfb;
}


.document-search-form {
    display: flex;
    align-items: center;

    gap: 8px;
}


.document-search-box {
    min-width: 240px;

    flex: 1;

    position: relative;
}


.document-search-box svg {
    width: 14px;
    height: 14px;

    position: absolute;

    left: 11px;
    top: 50%;

    transform: translateY(-50%);

    fill: #919b95;
}


.document-search-box input {
    width: 100%;
    height: 37px;

    box-sizing: border-box;

    padding: 0 11px 0 34px;

    border: 1px solid #dce3df;

    border-radius: 7px;

    outline: none;

    background: white;

    color: #303b34;

    font-size: 9px;
}


.document-search-box input:focus {
    border-color: var(--dms-green);
}


.document-filter-select {
    height: 37px;

    min-width: 125px;

    padding: 0 9px;

    border: 1px solid #dce3df;

    border-radius: 7px;

    background: white;

    font-size: 9px;
}


.document-filter-button,
.document-clear-button {
    min-height: 37px;

    box-sizing: border-box;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 12px;

    border-radius: 7px;

    font-size: 8px;
    font-weight: 750;
}


.document-filter-button {
    border: 1px solid #1e2822;

    background: #1e2822;
    color: white;

    cursor: pointer;
}


.document-clear-button {
    border: 1px solid #dce3df;

    background: white;
    color: #626e67;

    text-decoration: none;
}


.document-table-wrap {
    overflow-x: auto;
}


.document-library-table {
    width: 100%;

    min-width: 920px;

    border-collapse: collapse;
}


.document-library-table th {
    height: 39px;

    padding: 0 13px;

    border-bottom: 1px solid #e9eeeb;

    background: #f8faf9;

    color: #78837c;

    text-align: left;

    font-size: 8px;
    font-weight: 750;

    text-transform: uppercase;

    letter-spacing: .04em;
}


.document-library-table td {
    padding: 10px 13px;

    border-bottom: 1px solid #edf1ee;

    color: #566159;

    font-size: 8px;

    vertical-align: middle;
}


.document-library-table tbody tr:last-child td {
    border-bottom: 0;
}


.document-row-archived {
    background: #fafafa;
}


.document-row-archived .document-title-cell strong {
    color: #7b837e;
}


.document-title-cell {
    min-width: 230px;

    display: flex;
    align-items: center;

    gap: 9px;
}


.document-file-icon {
    width: 34px;
    height: 34px;

    flex: 0 0 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;

    background: #fff0f0;
}


.document-file-icon svg {
    width: 15px;
    height: 15px;

    fill: var(--dms-red);
}


.document-title-cell > div {
    min-width: 0;

    display: flex;
    flex-direction: column;
}


.document-title-cell strong {
    max-width: 290px;

    color: #303b34;

    font-size: 9px;

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


.document-title-cell small {
    margin-top: 3px;

    color: #979f9a;

    font-size: 7px;
}


.document-type-badge {
    display: inline-flex;

    padding: 4px 7px;

    border-radius: 5px;

    background: #f0f4f1;

    color: #58635c;

    font-size: 7px;
    font-weight: 700;
}


.document-actions-heading {
    text-align: right !important;
}


.document-row-actions {
    min-width: 215px;

    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 6px;
}


.document-action-link {
    color: var(--dms-green);

    text-decoration: none;

    font-size: 8px;
    font-weight: 700;
}


.document-archive-form {
    margin: 0;
}


.document-archive-button,
.document-restore-button {
    border: 0;

    padding: 5px 7px;

    border-radius: 5px;

    cursor: pointer;

    font-size: 7px;
    font-weight: 700;
}


.document-archive-button {
    background: #fff1f1;
    color: #a32727;
}


.document-restore-button {
    background: #edf7f1;
    color: var(--dms-green);
}


.document-library-empty {
    min-height: 220px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}


.document-empty-icon {
    width: 46px;
    height: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background: #fff0f0;
}


.document-empty-icon svg {
    width: 19px;
    height: 19px;

    fill: var(--dms-red);
}


.document-library-empty strong {
    margin-top: 10px;

    color: #354039;

    font-size: 10px;
}


.document-library-empty span {
    margin-top: 4px;

    color: #8b958f;

    font-size: 8px;
}


.document-library-empty a {
    margin-top: 10px;

    color: var(--dms-green);

    text-decoration: none;

    font-size: 8px;
    font-weight: 750;
}


.document-upload-layout {
    display: grid;

    grid-template-columns:
        minmax(0,700px)
        minmax(250px,310px);

    gap: 16px;

    align-items: start;
}


.document-upload-card {
    border: 1px solid var(--dms-border);

    border-radius: 11px;

    background: white;

    overflow: hidden;
}


.document-upload-header {
    min-height: 78px;

    display: flex;
    align-items: center;

    gap: 11px;

    box-sizing: border-box;

    padding: 14px 18px;

    border-bottom: 1px solid #edf1ee;
}


.document-upload-header-icon {
    width: 40px;
    height: 40px;

    flex: 0 0 40px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #edf6f0;
}


.document-upload-header-icon svg {
    width: 18px;
    height: 18px;

    fill: var(--dms-green);
}


.document-upload-header h2 {
    margin: 0;

    font-size: 14px;
}


.document-upload-header p {
    margin: 4px 0 0;

    color: #89938d;

    font-size: 8px;
}


.document-upload-form {
    padding: 19px;
}


.document-file-drop {
    min-height: 120px;

    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    padding: 18px;

    border: 1px dashed #bfcac3;

    border-radius: 9px;

    background: #fafcfb;

    text-align: center;
}


.document-file-input {
    max-width: 100%;

    position: absolute;

    inset: 0;

    width: 100%;
    height: 100%;

    opacity: 0;

    cursor: pointer;
}


.document-file-drop-info {
    pointer-events: none;

    display: flex;
    flex-direction: column;
    align-items: center;
}


.document-file-drop-info strong {
    max-width: 420px;

    color: #354139;

    font-size: 10px;

    overflow-wrap: anywhere;
}


.document-file-drop-info span {
    margin-top: 5px;

    color: #7f8b83;

    font-size: 8px;
}


.document-file-drop-info small {
    margin-top: 4px;

    color: #a0a9a3;

    font-size: 7px;
}


.document-upload-binding {
    display: flex;
    flex-direction: column;

    margin-top: 8px;

    padding: 12px 13px;

    border: 1px solid #dce8e0;

    border-radius: 8px;

    background: #f7fbf8;
}


.document-upload-binding span {
    color: #87928b;

    font-size: 7px;

    text-transform: uppercase;

    letter-spacing: .05em;
}


.document-upload-binding strong {
    margin-top: 4px;

    color: #345040;

    font-size: 10px;
}


.document-upload-binding small {
    margin-top: 5px;

    color: #819088;

    font-size: 8px;

    line-height: 1.45;
}


.document-upload-info {
    display: flex;
    flex-direction: column;

    gap: 12px;
}


.document-security-card {
    display: flex;
    flex-direction: column;

    padding: 15px;

    border: 1px solid #dce8e0;

    border-radius: 9px;

    background: #f7fbf8;
}


.document-security-card strong {
    color: #345040;

    font-size: 9px;
}


.document-security-card span {
    margin-top: 5px;

    color: #7e8e85;

    font-size: 8px;

    line-height: 1.5;
}


@media (max-width: 1000px) {

    .document-upload-layout {
        grid-template-columns:
            minmax(0,1fr)
            260px;
    }

}


@media (max-width: 850px) {

    .document-library-page,
    .document-upload-page {
        padding: 18px 16px 14px;
    }


    .document-upload-layout {
        grid-template-columns: 1fr;
    }


    .document-summary-grid {
        grid-template-columns:
            repeat(2,minmax(0,1fr));
    }


    .document-summary-card:last-child {
        grid-column: 1 / -1;
    }


    .document-search-form {
        flex-wrap: wrap;
    }


    .document-search-box {
        flex-basis: 100%;
    }

}


@media (max-width: 560px) {

    .document-library-heading {
        align-items: stretch;

        flex-direction: column;
    }


    .document-upload-button {
        width: 100%;
    }


    .document-summary-grid {
        grid-template-columns: 1fr;
    }


    .document-summary-card:last-child {
        grid-column: auto;
    }


    .document-summary-card {
        min-height: 60px;

        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }


    .document-summary-card strong {
        margin-top: 0;
    }


    .document-filter-select,
    .document-filter-button,
    .document-clear-button {
        flex: 1;
    }


    .document-upload-form {
        padding: 15px;
    }

}



/* ==========================================================
   STEP 9B — DOCUMENT NAVIGATION LINKS
   ========================================================== */

.workspace-document-title-link {
    color: inherit;
    text-decoration: none;
}


.workspace-document-title-link:hover {
    color: var(--dms-green);
    text-decoration: underline;
}


.document-folder-link {
    color: var(--dms-green);
    text-decoration: none;
    font-weight: 700;
}


.document-folder-link:hover {
    text-decoration: underline;
}



/* ==========================================================
   STEP 9C — GLOBAL DOCUMENT REPOSITORY
   ========================================================== */

.global-document-search {
    grid-template-columns:
        minmax(230px, 1fr)
        minmax(190px, 260px)
        minmax(130px, 170px)
        auto
        auto;
}


.dashboard-document-link {
    color: inherit;
    text-decoration: none;
}


.dashboard-document-link:hover {
    color: var(--dms-green);
    text-decoration: underline;
}


@media (max-width: 1000px) {

    .global-document-search {
        grid-template-columns:
            1fr
            1fr;
    }

}


@media (max-width: 620px) {

    .global-document-search {
        grid-template-columns:
            1fr;
    }

}

