: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;
    }

}

