/* ============================================================
   DESIGN TOKENS — Unified Color System
   Change primary/secondary here to re-theme the entire app.
   ============================================================ */
:root {
    --clr-primary: #99582a;
    --clr-primary-hover: #7a4420;
    --clr-primary-active: #6b3818;
    --clr-primary-rgb: 153, 88, 42;
    --clr-secondary: #c9922a;
    --clr-banner-start: #a86532;
    --clr-banner-mid: #8b4c22;
    --clr-banner-end: #6b3818;
    --clr-dm-accent: #c9922a;
    --clr-dm-banner-start: #7a4420;
    --clr-dm-banner-mid: #5e3318;
    --clr-dm-banner-end: #3d2010;
    --clr-nav-border: #6b3d1c;
    --clr-text-on-primary: #5a3416;
}

[data-color-theme="Greenlight_Theme"] {
    --clr-primary: #000;
    --clr-primary-hover: #1a1a1a;
    --clr-primary-active: #333;
    --clr-primary-rgb: 0, 0, 0;
    --clr-secondary: #e0fd03;
    --clr-banner-start: #222;
    --clr-banner-mid: #111;
    --clr-banner-end: #000;
    --clr-dm-accent: #e0fd03;
    --clr-dm-banner-start: #1a1a1a;
    --clr-dm-banner-mid: #111;
    --clr-dm-banner-end: #000;
    --clr-nav-border: #333;
    --clr-text-on-primary: #222;
}

[data-color-theme="Green_Theme"] {
    --clr-primary: #83c5be;
    --clr-primary-hover: #6aada5;
    --clr-primary-active: #54968e;
    --clr-primary-rgb: 131, 197, 190;
    --clr-secondary: #edf6f9;
    --clr-banner-start: #8dd0c9;
    --clr-banner-mid: #71b5ad;
    --clr-banner-end: #5a9f97;
    --clr-dm-accent: #a3d8d2;
    --clr-dm-banner-start: #5a9f97;
    --clr-dm-banner-mid: #487f79;
    --clr-dm-banner-end: #36605b;
    --clr-nav-border: #54968e;
    --clr-text-on-primary: #2c6b64;
}

[data-color-theme="Rose_Theme"] {
    --clr-primary: #ef476f;
    --clr-primary-hover: #d93a5f;
    --clr-primary-active: #c32e50;
    --clr-primary-rgb: 239, 71, 111;
    --clr-secondary: #ffd166;
    --clr-banner-start: #f05a7e;
    --clr-banner-mid: #e04068;
    --clr-banner-end: #cc2d55;
    --clr-dm-accent: #ffd166;
    --clr-dm-banner-start: #c32e50;
    --clr-dm-banner-mid: #a22443;
    --clr-dm-banner-end: #801a35;
    --clr-nav-border: #c32e50;
    --clr-text-on-primary: #8b1d3a;
}

[data-color-theme="Cyan_Theme"] {
    --clr-primary: #01c0c8;
    --clr-primary-hover: #01a3a9;
    --clr-primary-active: #01888e;
    --clr-primary-rgb: 1, 192, 200;
    --clr-secondary: #fb9678;
    --clr-banner-start: #15ccd3;
    --clr-banner-mid: #01b0b7;
    --clr-banner-end: #01949a;
    --clr-dm-accent: #fb9678;
    --clr-dm-banner-start: #01949a;
    --clr-dm-banner-mid: #017a7f;
    --clr-dm-banner-end: #016064;
    --clr-nav-border: #01888e;
    --clr-text-on-primary: #015f63;
}

[data-color-theme="Orange_Theme"] {
    --clr-primary: #fa896b;
    --clr-primary-hover: #e5745a;
    --clr-primary-active: #d0604a;
    --clr-primary-rgb: 250, 137, 107;
    --clr-secondary: #0074ba;
    --clr-banner-start: #fb9678;
    --clr-banner-mid: #e88063;
    --clr-banner-end: #d56b50;
    --clr-dm-accent: #fbb098;
    --clr-dm-banner-start: #d0604a;
    --clr-dm-banner-mid: #b5503e;
    --clr-dm-banner-end: #9a4033;
    --clr-nav-border: #d0604a;
    --clr-text-on-primary: #8a3828;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
        /* الوضعية الأصلية */
    }

    50% {
        transform: translateY(-10px);
        /* تحريك النص للأعلى */
    }
}

.problem-text {
    color: #ff0000;
    /* لون النص */
    font-weight: bold;
    /* يجعل النص عريض */
    text-align: center;
    /* يضع النص في المركز */
    font-size: 18px;
    /* حجم النص */
    margin-top: 20px;
    /* مسافة من الأعلى */
    animation: bounce 1.5s infinite;
    /* تطبيق الحركة */
}

.validation-summary-errors {
    position: relative;
    padding: .75rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: .25rem;
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

.input-validation-error {
    border-color: #F64E60;
    padding-right: calc(1.5em + 1.3rem);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23F64E60' viewBox='0 0 12 12'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23F64E60' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: left calc(0.375em + 0.325rem) center;
    background-size: calc(0.75em + 0.65rem) calc(0.75em + 0.65rem);
}

.input-validation-error:invalid:focus,
.input-validation-error.is-invalid:focus {
    border-color: #F64E60;
    -webkit-box-shadow: 0 0 0 0.2rem rgba(246, 78, 96, 0.25);
    box-shadow: 0 0 0 0.2rem rgba(246, 78, 96, 0.25);
}


.bg-diagonal-title {
    position: relative;
}

.ribbon-ver .ribbon-target {
    min-width: 15rem !important;
    max-width: 15rem !important;
}

.card-title-shift {
    -webkit-box-pack: center !important;
    -ms-flex-pack: center !important;
    justify-content: center !important;
}

.form-control {
    padding: 0.45rem 1rem;
}


/** {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: consolas;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: #111;
}*/

.scan {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgb(98 95 95 / 80%);
    z-index: 1000;
    height: 100%;
}

.scan .fingerprint {
    position: relative;
    width: 300px;
    height: 380px;
    background: rgb(131 131 131 / 0%) url(../../assets/media/fingerprint_1.png);
    background-size: 300px;
}

.scan .fingerprint::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgb(105 92 126 / 11%) url(../../assets/media/fingerPrint_2.png);
    background-size: 300px;
    animation: animate 5s ease-in-out infinite;
}

@keyframes animate {

    0%,
    100% {
        height: 0;
    }

    50% {
        height: 100%;
    }
}

.scan .fingerprint::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 8px;
    background: #3fefef;
    border-radius: 8px;
    filter: drop-shadow(0 0 20px #3fefef) drop-shadow(0 0 60px #3fefef);
    animation: animate_line 5s ease-in-out infinite;
}

@keyframes animate_line {

    0%,
    100% {
        top: 0;
    }

    50% {
        top: 100%;
    }
}

.scan h3 {
    text-transform: uppercase;
    font-size: 2em;
    letter-spacing: 2px;
    margin-top: 20px;
    color: #3fefef;
    filter: drop-shadow(0 0 20px #3fefef) drop-shadow(0 0 60px #3fefef);
    animation: animate_text 0.5s steps(1) infinite;
}

@keyframes animate_text {

    0%,
    100% {
        opacity: 0;
    }

    50% {
        opacity: 1;
    }
}

.timeline.timeline-5 .timeline-item .timeline-label {
    width: 70px !important;
}

.timeline.timeline-5:before {
    right: 92.5px !important;
}

.out-fingerprint {
    transform: rotate(183deg)
}


.table-bordered-custom {
    border: 1px solid #5c5c5c !important;
}


.label.radio input-validation-error {
    border: 1px solid #ccc;
}

.table thead th,
.table thead td {
    font-weight: bolder !important;
}

.mb-no {
    margin-bottom: 0rem !important;
}

.label-solid {
    background-color: #F3F6F9 !important;
}


.form-control-label {
    /* border-radius: 0.675rem;*/
    display: block;
    width: 100%;
    height: calc(1.5em + 1.3rem + 2px);
    padding: 0.65rem 1rem;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: #3F4254;
    -webkit-box-shadow: none;
    box-shadow: none;
    -webkit-transition: border-color 0.15s ease-in-out, -webkit-box-shadow 0.15s ease-in-out;
    transition: border-color 0.15s ease-in-out, -webkit-box-shadow 0.15s ease-in-out;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, -webkit-box-shadow 0.15s ease-in-out;
    border: 0px solid #E4E6EF !important;
}

@media (prefers-reduced-motion: reduce) {
    .form-control-label {
        -webkit-transition: none;
        transition: none;
    }
}

.textarea-label {
    height: auto;
    overflow: auto;
    resize: vertical;
    margin: 0;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    text-rendering: auto;
    color: fieldtext;
    letter-spacing: normal;
    word-spacing: normal;
    line-height: normal;
    text-transform: none;
    text-indent: 0px;
    text-shadow: none;
    display: inline-block;
    text-align: start;
    appearance: auto;
    -webkit-rtl-ordering: logical;
    resize: auto;
    cursor: text;
    overflow-wrap: break-word;
    background-color: field;
    column-count: initial !important;
    margin: 0em;
    padding: 2px;
    white-space: pre-wrap;
}

.table thead th,
.table thead td {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

select .form-control-sm {
    height: 1rem;
}

.bootstrap-select.form-control-sm .dropdown-toggle {

    padding: 0.65rem 1rem !important;
}

.dropzone.dropzone-multi .dropzone-item {
    margin-top: 0;
}


input[readonly] {
    background-color: transparent;
    border: 0;
    font-size: 1em;
}


.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8) url('../assets/media/loader/Preloader_3.gif') center center no-repeat;
    z-index: 1000;
    overflow-x: hidden;
    overflow-y: auto;
}

.plLoading {
    position: fixed;

    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8) url('assets/media/loader/Preloader_2.gif') center center no-repeat;
    z-index: 1000;
    overflow-x: hidden;
    overflow-y: auto;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
        /* الوضعية الأصلية */
    }

    50% {
        transform: translateY(-10px);
        /* تحريك النص للأعلى */
    }
}

.problem-text {
    color: #ff0000;
    /* لون النص */
    font-weight: bold;
    /* يجعل النص عريض */
    text-align: center;
    /* يضع النص في المركز */
    font-size: 18px;
    /* حجم النص */
    margin-top: 20px;
    /* مسافة من الأعلى */
    animation: bounce 1.5s infinite;
    /* تطبيق الحركة */
}

.watermark {
    /*     position: relative;*/
    font-size: 30rem;
    color: #ff1515;
    opacity: 0.03;
    z-index: 1;
}

.watermark::before {
    content: attr(data-text);
    /* Use the content attribute to set the text from the element */
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0.5;
    /* Adjust opacity for the watermark effect */
    z-index: -1;
    /* Ensure the watermark is behind the actual text */
}

/* Additional styling for the main text (optional) */
.watermark>* {
    /* position: relative;*/
    z-index: 1;
}

.watermark span {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    /* Adjust rotation angle as needed */
    white-space: nowrap;
}


.loader,
.preloader {
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    position: fixed;
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(255, 255, 255, .85);
    backdrop-filter: blur(6px);
}

.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
}

.loader-logo {
    width: 140px;
    height: auto;
    object-fit: contain;
    animation: loaderPulse 1.5s ease-in-out infinite;
    filter: drop-shadow(0 4px 16px rgba(var(--clr-primary-rgb), .2));
}

@keyframes loaderPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.08);
        opacity: .7;
    }
}

.loader-dots {
    display: flex;
    gap: 8px;
}

.loader-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--clr-primary);
    animation: loaderDot 1.2s ease-in-out infinite;
}

.loader-dots span:nth-child(2) {
    animation-delay: .15s;
}

.loader-dots span:nth-child(3) {
    animation-delay: .3s;
}

@keyframes loaderDot {

    0%,
    80%,
    100% {
        transform: scale(.4);
        opacity: .3;
    }

    40% {
        transform: scale(1);
        opacity: 1;
    }
}

[data-bs-theme="dark"] .loader,
[data-bs-theme="dark"] .preloader {
    background: rgba(30, 30, 45, .9);
}

[data-bs-theme="dark"] .loader-dots span {
    background: var(--clr-secondary);
}

/* ============================================================
   DASHBOARD STYLES - Enhanced
   ============================================================ */

/* --- Animations --- */
@keyframes dashFadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes dashShimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

@keyframes dashPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }
}

@keyframes dashBarGrow {
    from {
        width: 0%;
    }
}

/* --- General Card --- */
.dash-card {
    border: 1px solid rgba(0, 0, 0, .06) !important;
    border-radius: 16px !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, .04) !important;
    overflow: hidden;
    animation: dashFadeUp .4s ease both;
}

.dash-card .card-body {
    padding: 1.5rem !important;
}

/* ========== 1. WELCOME BANNER ========== */
.dash-banner {
    position: relative;
    border-radius: 16px !important;
    overflow: hidden;
    animation: dashFadeUp .35s ease both;
}

.dash-banner-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--clr-banner-start) 0%, var(--clr-banner-mid) 40%, var(--clr-banner-end) 100%) !important;
    z-index: 0;
}

.dash-banner-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 80% 15%, rgba(255, 255, 255, .15) 0%, transparent 50%),
        radial-gradient(circle at 20% 85%, rgba(255, 255, 255, .08) 0%, transparent 45%);
    pointer-events: none;
}

/* Subtle cross pattern overlay */
.dash-banner-pattern {
    position: absolute;
    inset: 0;
    opacity: .035;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

/* Wave bottom edge */
.dash-banner-wave {
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 20px;
    z-index: 1;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 20C240 0 480 40 720 20C960 0 1200 40 1440 20V40H0Z' fill='%23ffffff'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: cover;
    pointer-events: none;
}

[data-bs-theme="dark"] .dash-banner-wave {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 20C240 0 480 40 720 20C960 0 1200 40 1440 20V40H0Z' fill='%23111c2d'/%3E%3C/svg%3E") !important;
}

.dash-banner-content {
    position: relative;
    z-index: 2;
    padding: 1.75rem 2rem 2.25rem;
}

.dash-banner-top {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

/* Avatar */
.dash-avatar-wrap {
    position: relative;
    width: 72px;
    height: 72px;
    flex-shrink: 0;
}

.dash-avatar-wrap img {
    width: 72px !important;
    height: 72px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid rgba(255, 255, 255, .5) !important;
    display: block;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .25);
}

/* Initials fallback when no photo */
.dash-avatar-initials {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--clr-primary);
    background: rgba(255, 255, 255, .92);
    border: 3px solid rgba(255, 255, 255, .5);
    box-shadow: 0 6px 20px rgba(0, 0, 0, .25);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.dash-verified {
    position: absolute;
    bottom: 0;
    right: 0;
    background: #22b783;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .18);
    z-index: 2;
    border: 2px solid #fff;
    animation: dashPulse 2.5s ease infinite;
}

.dash-verified i {
    font-size: 16px;
    color: #fff;
}

/* Greeting Text */
.dash-banner-greet {
    text-align: center;
}

.dash-banner-hello {
    font-size: .88rem;
    color: rgba(255, 255, 255, .7);
    display: block;
    letter-spacing: .5px;
    margin-bottom: 2px;
}

.dash-banner-name {
    font-size: 1.4rem !important;
    font-weight: 700 !important;
    color: #fff !important;
    margin: 0 !important;
    line-height: 1.3;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .15);
}

/* Info Pills */
.dash-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    padding-top: .25rem;
}

.dash-pill {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    background: rgba(255, 255, 255, .13) !important;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, .15) !important;
    border-radius: 24px !important;
    padding: 7px 16px !important;
    font-size: .8rem !important;
    color: #fff !important;
    white-space: nowrap;
    transition: background .2s, transform .15s;
}

.dash-pill:hover {
    background: rgba(255, 255, 255, .22) !important;
    transform: translateY(-1px);
}

.dash-pill-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .2);
    font-size: .88rem;
    flex-shrink: 0;
}

.dash-pill-divider {
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, .3);
    flex-shrink: 0;
}

.dash-pill-text {
    opacity: .8;
    font-size: .78rem;
}

.dash-pill-val {
    font-weight: 700;
    letter-spacing: .3px;
    font-size: .82rem;
}

/* ========== 2. STAT CARDS ========== */
.dash-stat {
    border-radius: 14px !important;
    padding: 1.25rem 1rem !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center;
    gap: .5rem;
    background: #fff !important;
    border: 1px solid rgba(0, 0, 0, .06) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .04) !important;
    transition: all .25s ease !important;
    cursor: pointer;
    text-decoration: none !important;
    color: #333 !important;
    animation: dashFadeUp .4s ease both;
    position: relative;
    overflow: hidden;
}

.dash-stat::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    opacity: 0;
    transition: opacity .25s;
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .05), rgba(var(--clr-primary-rgb), .02));
}

.dash-stat:hover::before {
    opacity: 1;
}

.dash-stat:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, .08) !important;
    transform: translateY(-3px);
}

/* Icon Circles */
.dash-stat-icon-wrap {
    width: 52px;
    height: 52px;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1.4rem;
    flex-shrink: 0;
    transition: transform .25s;
}

.dash-stat:hover .dash-stat-icon-wrap {
    transform: scale(1.08);
}

.dash-stat-icon-primary {
    background: rgba(var(--clr-primary-rgb), .12) !important;
    color: var(--clr-primary) !important;
}

.dash-stat-icon-info {
    background: rgba(59, 130, 246, .1) !important;
    color: #3b82f6 !important;
}

.dash-stat-icon-success {
    background: rgba(34, 197, 94, .1) !important;
    color: #22c55e !important;
}

.dash-stat-icon-warning {
    background: rgba(245, 158, 11, .1) !important;
    color: #f59e0b !important;
}

/* Active (Inbox) */
.dash-stat-active {
    background: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-hover) 100%) !important;
    color: #fff !important;
    border-color: var(--clr-primary) !important;
    box-shadow: 0 6px 20px rgba(var(--clr-primary-rgb), .25) !important;
    position: relative;
    overflow: hidden;
}

.dash-stat-active::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .12), transparent);
    animation: dashShimmer 3s ease-in-out infinite;
}

.dash-stat-active::before {
    display: none;
}

.dash-stat-active .dash-stat-icon-wrap {
    background: rgba(255, 255, 255, .2) !important;
    color: #fff !important;
}

.dash-stat-active .dash-stat-num,
.dash-stat-active .dash-stat-lbl {
    color: #fff !important;
}

/* Stat Info */
.dash-stat-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

/* Stat Text */
.dash-stat-num {
    font-size: 1.65rem !important;
    font-weight: 800 !important;
    line-height: 1.1;
    color: #1e293b;
}

.dash-stat-lbl {
    font-size: .8rem;
    color: #64748b;
    margin-top: 0;
}

/* Stagger animation for stat cards */
.row>.col-6:nth-child(1) .dash-stat,
.row>.col-lg-3:nth-child(1) .dash-stat {
    animation-delay: .05s;
}

.row>.col-6:nth-child(2) .dash-stat,
.row>.col-lg-3:nth-child(2) .dash-stat {
    animation-delay: .12s;
}

.row>.col-6:nth-child(3) .dash-stat,
.row>.col-lg-3:nth-child(3) .dash-stat {
    animation-delay: .19s;
}

.row>.col-6:nth-child(4) .dash-stat,
.row>.col-lg-3:nth-child(4) .dash-stat {
    animation-delay: .26s;
}

/* Stagger for summary cards */
.row>.col-6:nth-child(1) .dash-sum,
.row>.col-lg-3:nth-child(1) .dash-sum {
    animation-delay: .08s;
}

.row>.col-6:nth-child(2) .dash-sum,
.row>.col-lg-3:nth-child(2) .dash-sum {
    animation-delay: .16s;
}

.row>.col-6:nth-child(3) .dash-sum,
.row>.col-lg-3:nth-child(3) .dash-sum {
    animation-delay: .24s;
}

.row>.col-6:nth-child(4) .dash-sum,
.row>.col-lg-3:nth-child(4) .dash-sum {
    animation-delay: .32s;
}

/* ========== 3. SUMMARY CARDS ========== */
.dash-sum {
    border-radius: 14px !important;
    padding: 1.25rem 1rem !important;
    text-align: center !important;
    border: none !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: transform .2s, box-shadow .2s;
    animation: dashFadeUp .45s ease both;
}

.dash-sum:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, .06);
}

.dash-sum-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 4px;
}

.dash-sum-num {
    font-size: 1.75rem !important;
    font-weight: 800 !important;
    line-height: 1.2;
}

.dash-sum-lbl {
    font-size: .78rem;
    opacity: .85;
    font-weight: 500;
}

/* Color variants */
.dash-sum-total {
    background: linear-gradient(145deg, #fef8ee, #fef0d5) !important;
    color: #7c5e20 !important;
}

.dash-sum-total .dash-sum-icon {
    background: rgba(var(--clr-primary-rgb), .15);
    color: var(--clr-secondary);
}

.dash-sum-pending {
    background: linear-gradient(145deg, #fef2f4, #fde0e6) !important;
    color: #8b2d3a !important;
}

.dash-sum-pending .dash-sum-icon {
    background: rgba(212, 64, 88, .12);
    color: #d44058;
}

.dash-sum-done {
    background: linear-gradient(145deg, #f0faf4, #ddf5e7) !important;
    color: #1e6e3e !important;
}

.dash-sum-done .dash-sum-icon {
    background: rgba(42, 157, 92, .12);
    color: #2a9d5c;
}

.dash-sum-progress {
    background: linear-gradient(145deg, #fffaed, #fff2d0) !important;
    color: #7c6b1f !important;
}

.dash-sum-progress .dash-sum-icon {
    background: rgba(184, 150, 10, .12);
    color: #b8960a;
}

/* Summary progress bar */
.dash-sum-bar {
    width: 80%;
    height: 4px;
    background: rgba(0, 0, 0, .08);
    border-radius: 4px;
    margin-top: 6px;
    overflow: hidden;
}

.dash-sum-bar-fill {
    height: 100%;
    border-radius: 4px;
    animation: dashBarGrow .8s ease-out both;
    animation-delay: .4s;
}

.dash-sum-total .dash-sum-bar-fill {
    background: var(--clr-secondary);
}

.dash-sum-pending .dash-sum-bar-fill {
    background: #d44058;
}

.dash-sum-done .dash-sum-bar-fill {
    background: #2a9d5c;
}

.dash-sum-progress .dash-sum-bar-fill {
    background: #b8960a;
}

/* ========== CARD HEADER ACCENT ========== */
.dash-card-header h5 {
    position: relative;
    padding-inline-start: 12px;
}

.dash-card-header h5::before {
    content: '';
    position: absolute;
    inset-inline-start: 0;
    top: 2px;
    bottom: 2px;
    width: 3px;
    border-radius: 3px;
    background: var(--clr-primary);
}

/* ========== FILTER BAR ========== */
.dash-filter-bar {
    background: #f8f9fb;
    border-radius: 12px;
    padding: .75rem 1rem;
    border: 1px solid rgba(0, 0, 0, .04);
}

.dash-date-group {
    display: none;
    align-items: center;
    gap: 6px;
}

.dash-date-group.show {
    display: inline-flex;
}

.dash-date-group input {
    max-width: 150px;
    border-radius: 8px !important;
}

.dash-date-sep {
    color: #94a3b8;
    font-size: .85rem;
}

.dash-period-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.dash-period-tag {
    background: #fff !important;
    color: #5a6a85 !important;
    border: 1px solid #ddd !important;
    font-size: .8rem;
    font-weight: 500;
    padding: .3rem .75rem;
    transition: all .25s ease;
}

.dash-period-tag:hover {
    background: rgba(var(--clr-primary-rgb), .08) !important;
    color: var(--clr-primary) !important;
    border-color: var(--clr-primary) !important;
}

.dash-period-tag.active {
    background: var(--clr-primary) !important;
    color: #fff !important;
    border-color: var(--clr-primary) !important;
    box-shadow: 0 2px 8px rgba(var(--clr-primary-rgb), .3);
}

.dash-filter-btn {
    white-space: nowrap;
}

.dash-view-toggle .btn {
    border-radius: 8px !important;
    padding: .3rem .5rem;
    transition: all .2s ease;
}

.dash-view-toggle .btn.active {
    background: var(--clr-primary) !important;
    color: #fff !important;
    border-color: var(--clr-primary) !important;
}

/* ========== CHARTS LOADER ========== */
.dash-charts-loader {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .8);
    border-radius: .5rem;
}

.dash-charts-loader .spinner-border {
    width: 2.5rem;
    height: 2.5rem;
    color: var(--clr-primary) !important;
}

/* ========== COLLAPSE ICON ========== */
.dash-card-header {
    cursor: pointer;
    padding: .25rem 0;
    border-radius: 8px;
    transition: background .15s;
}

.dash-card-header:hover {
    background: rgba(0, 0, 0, .02);
}

.dash-collapse-ico {
    transition: transform .3s;
}

.collapsed .dash-collapse-ico {
    transform: rotate(180deg);
}

[dir="rtl"] .collapsed .dash-collapse-ico {
    transform: rotate(-180deg);
}

/* ========== PINNED PROCESSES ========== */
.dash-pin-item {
    padding: .85rem;
    border-radius: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, .04);
    transition: background .15s, transform .15s;
}

.dash-pin-item:last-child {
    border-bottom: none;
}

.dash-pin-item:hover {
    background: rgba(var(--clr-primary-rgb), .03);
    transform: translateX(-2px);
}

[dir="rtl"] .dash-pin-item:hover {
    transform: translateX(2px);
}

/* ========== EMPTY STATE ========== */
.dash-empty-state {
    text-align: center;
    padding: 3.5rem 1rem;
    color: #94a3b8;
    animation: dashFadeUp .5s ease both;
}

.dash-empty-state i {
    font-size: 3.5rem;
    display: block;
    margin-bottom: .75rem;
    opacity: .4;
    color: var(--clr-primary);
}

.dash-empty-state span {
    font-size: .95rem;
    font-weight: 500;
    display: block;
    margin-top: .25rem;
}

/* ========== PERIOD TOGGLES ========== */
.dash-period {
    border-radius: 20px !important;
    transition: all .2s !important;
}

/* ========== FILE CARDS ========== */
.file-card {
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: 12px !important;
    transition: transform .2s, box-shadow .2s;
    overflow: hidden;
}

.file-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, .08) !important;
}

.file-header {
    border-bottom: 1px solid rgba(0, 0, 0, .04);
}

.file-img-container {
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fb !important;
}

.file-details {
    border-top: 1px solid rgba(0, 0, 0, .04);
}

/* ========== OWL CAROUSEL DOTS ========== */
.dash-card .owl-dots {
    text-align: center;
    margin-top: 12px;
}

.dash-card .owl-dot span {
    width: 8px !important;
    height: 8px !important;
    background: rgba(var(--clr-primary-rgb), .2) !important;
    border-radius: 50% !important;
    transition: all .25s !important;
}

.dash-card .owl-dot.active span {
    background: var(--clr-primary) !important;
    width: 20px !important;
    border-radius: 4px !important;
}

.dash-card .owl-nav button {
    color: var(--clr-primary) !important;
    font-size: 1.4rem !important;
}

/* ========== ANNOUNCEMENT IMAGE ========== */
.img-adv-fluid {
    transition: transform .3s ease;
}

.img-adv-fluid:hover {
    transform: scale(1.02);
}

/* ========== SECTION TITLE ICONS ========== */
.card-title .ti {
    color: var(--clr-primary) !important;
}

/* ========== ANNOUNCEMENTS ENHANCED ========== */
.announce-card {
    overflow: hidden;
}

.announce-count-badge {
    background: rgba(var(--clr-primary-rgb), .1);
    color: var(--clr-primary);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
}

.announce-slide {
    overflow: hidden;
    border-radius: 12px;
    position: relative;
    cursor: pointer;
}

.announce-slide img {
    border-radius: 12px;
    transition: transform .4s ease;
}

.announce-slide:hover img {
    transform: scale(1.03);
}

/* Announcement overlay on slide */
.announce-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(0deg, rgba(0,0,0,.78) 0%, rgba(0,0,0,.4) 55%, transparent 100%);
    padding: 50px 16px 14px;
    border-radius: 0 0 12px 12px;
    pointer-events: none;
}

.announce-overlay-title {
    color: #fff;
    font-size: .95rem;
    font-weight: 600;
    margin: 0 0 4px;
    text-shadow: 0 1px 3px rgba(0,0,0,.4);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.announce-overlay-desc {
    color: rgba(255, 255, 255, .85);
    font-size: .78rem;
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0,0,0,.3);
}

/* Announcement detail modal */
.announce-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
    backdrop-filter: blur(4px);
}

.announce-modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.announce-modal {
    background: #fff;
    border-radius: 16px;
    width: 92%;
    max-width: 560px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 28px 24px 24px;
    position: relative;
    transform: translateY(30px) scale(.96);
    transition: transform .3s ease;
    box-shadow: 0 20px 60px rgba(0,0,0,.25);
}

.announce-modal-backdrop.active .announce-modal {
    transform: translateY(0) scale(1);
}

.announce-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 1.6rem;
    line-height: 1;
    color: #666;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background .2s, color .2s;
}

[dir="rtl"] .announce-modal-close {
    right: auto;
    left: 14px;
}

.announce-modal-close:hover {
    background: rgba(0,0,0,.08);
    color: #333;
}

.announce-modal-title {
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--clr-primary);
    margin-bottom: 14px;
    padding-right: 30px;
}

[dir="rtl"] .announce-modal-title {
    padding-right: 0;
    padding-left: 30px;
}

.announce-modal-content {
    font-size: .92rem;
    line-height: 1.7;
    color: #444;
}

/* Dark mode */
[data-bs-theme="dark"] .announce-modal {
    background: #1e1e2d;
}

[data-bs-theme="dark"] .announce-modal-close {
    color: #aaa;
}

[data-bs-theme="dark"] .announce-modal-close:hover {
    background: rgba(255,255,255,.1);
    color: #fff;
}

[data-bs-theme="dark"] .announce-modal-content {
    color: #bbb;
}

/* ========== DOCUMENTS / LICENSES — SIDEBAR + THUMBNAILS ========== */
.license-count-badge {
    background: rgba(var(--clr-primary-rgb), .1);
    color: var(--clr-primary);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
}

/* --- Sidebar --- */
.license-sidebar {
    border-right: 1px solid rgba(0, 0, 0, .08);
    padding-right: 16px;
    max-height: 380px;
    overflow-y: auto;
}

[dir="rtl"] .license-sidebar {
    border-right: 0;
    border-left: 1px solid rgba(0, 0, 0, .08);
    padding-right: 0;
    padding-left: 16px;
}

.license-sidebar-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #5a6a85;
    transition: all .2s ease;
    margin-bottom: 4px;
    position: relative;
}

.license-sidebar-item:hover {
    background: rgba(var(--clr-primary-rgb), .06);
    color: #2a3547;
}

.license-sidebar-item.active {
    background: rgba(var(--clr-primary-rgb), .1);
    color: var(--clr-primary);
    font-weight: 600;
}

.license-sidebar-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--clr-primary);
    border-radius: 0 3px 3px 0;
}

[dir="rtl"] .license-sidebar-item.active::before {
    left: auto;
    right: 0;
    border-radius: 3px 0 0 3px;
}

.license-sidebar-label {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.license-sidebar-count {
    margin-left: auto;
    padding-left: 8px;
    font-size: 11px;
    font-weight: 600;
    color: var(--clr-primary);
    background: rgba(var(--clr-primary-rgb), .08);
    min-width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    padding: 0 6px;
}

[dir="rtl"] .license-sidebar-count {
    margin-left: 0;
    margin-right: auto;
    padding-left: 0;
    padding-right: 8px;
}

/* --- Thumbnail Grid --- */
.license-thumb-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding-left: 16px;
    align-content: flex-start;
    min-height: 100px;
}

[dir="rtl"] .license-thumb-grid {
    padding-left: 0;
    padding-right: 16px;
}

.license-thumb-item {
    position: relative;
    width: 90px;
    height: 108px;
    flex-shrink: 0;
}

.license-thumb-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 90px;
    height: 90px;
    border-radius: 10px;
    overflow: hidden;
    background: #f8f6f4;
    border: 2px solid transparent;
    transition: all .25s ease;
    text-decoration: none;
    position: relative;
}

.license-thumb-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s ease;
}

.license-thumb-link:hover {
    border-color: var(--clr-primary);
    box-shadow: 0 4px 16px rgba(var(--clr-primary-rgb), .2);
    transform: translateY(-3px);
}

.license-thumb-link:hover img {
    transform: scale(1.08);
}

.license-thumb-file {
    align-items: center;
    justify-content: center;
}

.license-thumb-pdf {
    overflow: hidden;
}

.pdf-thumb-canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.license-thumb-icon-sm {
    font-size: 2rem;
    color: var(--clr-primary);
    line-height: 1;
}

.license-thumb-name {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 3px 5px;
    font-size: 9px;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(transparent, rgba(0,0,0,.65));
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.license-thumb-file .license-thumb-name {
    color: #5a6a85;
    background: rgba(0,0,0,.05);
}

.license-thumb-dl {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 22px;
    height: 22px;
    border-radius: 6px 0 10px 0;
    background: var(--clr-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .7rem;
    opacity: 0;
    transition: opacity .2s ease;
    text-decoration: none;
}

[dir="rtl"] .license-thumb-dl {
    right: auto;
    left: 0;
    border-radius: 0 6px 0 10px;
}

.license-thumb-item:hover .license-thumb-dl {
    opacity: 1;
}

.license-thumb-dl:hover {
    background: var(--clr-primary-hover);
    color: #fff;
}

/* ========== FILE PREVIEW MODAL ========== */
.file-preview-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .6);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
    backdrop-filter: blur(4px);
}

.file-preview-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.file-preview-modal {
    background: #fff;
    border-radius: 16px;
    width: 94%;
    max-width: 900px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(30px) scale(.96);
    transition: transform .3s ease;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .3);
}

.file-preview-backdrop.active .file-preview-modal {
    transform: translateY(0) scale(1);
}

.file-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, .08);
    flex-shrink: 0;
}

.file-preview-title {
    margin: 0;
    font-weight: 700;
    font-size: 1rem;
    color: var(--clr-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    padding-inline-end: 12px;
}

.file-preview-close {
    background: none;
    border: none;
    font-size: 1.6rem;
    line-height: 1;
    color: #666;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background .2s, color .2s;
    flex-shrink: 0;
}

.file-preview-close:hover {
    background: rgba(0, 0, 0, .08);
    color: #333;
}

.file-preview-body {
    flex: 1;
    overflow: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    min-height: 300px;
}

.file-preview-img {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, .1);
}

.file-preview-iframe {
    width: 100%;
    height: 75vh;
    border: none;
    border-radius: 8px;
}

.file-preview-fallback {
    text-align: center;
    color: #888;
    padding: 40px 20px;
}

.file-preview-fallback i {
    font-size: 3.5rem;
    color: var(--clr-primary);
    display: block;
    margin-bottom: 12px;
}

.file-preview-fallback p {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 8px;
}

/* Dark mode */
[data-bs-theme="dark"] .file-preview-modal {
    background: #1e1e2d;
}

[data-bs-theme="dark"] .file-preview-header {
    border-bottom-color: rgba(255, 255, 255, .08);
}

[data-bs-theme="dark"] .file-preview-close {
    color: #aaa;
}

[data-bs-theme="dark"] .file-preview-close:hover {
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

[data-bs-theme="dark"] .file-preview-fallback {
    color: #bbb;
}

/* ========== RTL FIXES ========== */
[dir="rtl"] .dash-date-sep i {
    transform: rotate(180deg);
}

[dir="rtl"] .me-1 {
    margin-right: 0 !important;
    margin-left: .25rem !important;
}

[dir="rtl"] .me-2 {
    margin-right: 0 !important;
    margin-left: .5rem !important;
}

[dir="rtl"] .ms-auto {
    margin-left: 0 !important;
    margin-right: auto !important;
}

/* ========== DARK MODE ========== */
[data-bs-theme="dark"] .dash-banner-bg {
    background: linear-gradient(135deg, var(--clr-dm-banner-start) 0%, var(--clr-dm-banner-mid) 50%, var(--clr-dm-banner-end) 100%) !important;
}

[data-bs-theme="dark"] .dash-avatar-initials {
    background: rgba(255, 255, 255, .85);
    color: var(--clr-primary-hover);
}

[data-bs-theme="dark"] .dash-card {
    background: #1e1e2d !important;
    border-color: rgba(255, 255, 255, .06) !important;
}

[data-bs-theme="dark"] .dash-stat {
    background: #1e1e2d !important;
    border-color: rgba(255, 255, 255, .06) !important;
    color: #ddd !important;
}

[data-bs-theme="dark"] .dash-stat::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, .02), transparent);
}

[data-bs-theme="dark"] .dash-stat-num {
    color: #eee !important;
}

[data-bs-theme="dark"] .dash-stat:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, .3) !important;
}

[data-bs-theme="dark"] .dash-filter-bar {
    background: rgba(255, 255, 255, .04);
    border-color: rgba(255, 255, 255, .06);
}

[data-bs-theme="dark"] .dash-period-tag {
    background: rgba(255, 255, 255, .06) !important;
    color: #ccc !important;
    border-color: rgba(255, 255, 255, .1) !important;
}

[data-bs-theme="dark"] .dash-period-tag:hover {
    background: rgba(var(--clr-primary-rgb), .15) !important;
    color: var(--clr-dm-accent) !important;
    border-color: var(--clr-dm-accent) !important;
}

[data-bs-theme="dark"] .dash-period-tag.active {
    background: var(--clr-primary) !important;
    color: #fff !important;
    border-color: var(--clr-primary) !important;
}

[data-bs-theme="dark"] .dash-sum-total {
    background: linear-gradient(145deg, #3d3520, #352e18) !important;
    color: #f5d98a !important;
}

[data-bs-theme="dark"] .dash-sum-pending {
    background: linear-gradient(145deg, #3d1f28, #351a22) !important;
    color: #f5a0b0 !important;
}

[data-bs-theme="dark"] .dash-sum-done {
    background: linear-gradient(145deg, #1a3d28, #153520) !important;
    color: #7ee0a0 !important;
}

[data-bs-theme="dark"] .dash-sum-progress {
    background: linear-gradient(145deg, #3d3518, #352e12) !important;
    color: #f5d580 !important;
}

[data-bs-theme="dark"] .dash-pin-item:hover {
    background: rgba(255, 255, 255, .04);
}

[data-bs-theme="dark"] .dash-empty-state {
    color: #4a5568;
}

[data-bs-theme="dark"] .dash-empty-state i {
    color: var(--clr-dm-accent);
}

[data-bs-theme="dark"] .file-card {
    border-color: rgba(255, 255, 255, .06);
    background: #1e1e2d;
}

[data-bs-theme="dark"] .file-img-container {
    background: rgba(255, 255, 255, .03) !important;
}

/* ============================================================
   GLOBAL DESIGN ENHANCEMENTS
   ============================================================ */

/* ========== LOGIN PAGE ========== */
.login-logo {
    transition: transform .3s ease;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, .08));
}

.login-logo:hover {
    transform: scale(1.05);
}

.login-divider {
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, var(--clr-primary), var(--clr-secondary));
    border-radius: 3px;
    margin: 0 auto;
}

.login-submit-btn {
    background: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-hover) 100%) !important;
    border: none !important;
    font-weight: 600 !important;
    letter-spacing: .3px;
    box-shadow: 0 4px 15px rgba(var(--clr-primary-rgb), .3) !important;
    transition: all .25s ease !important;
}

.login-submit-btn:hover {
    box-shadow: 0 6px 20px rgba(var(--clr-primary-rgb), .4) !important;
    transform: translateY(-1px);
}

.login-help-btn {
    box-shadow: 0 4px 15px rgba(var(--clr-primary-rgb), .25) !important;
}

.authentication-login .form-control:focus {
    border-color: var(--clr-primary) !important;
    box-shadow: 0 0 0 .2rem rgba(var(--clr-primary-rgb), .15) !important;
}

/* ========== GLOBAL PAGE HEADER / BREADCRUMB ========== */
.body-wrapper .shadow-none.position-relative.border-bottom {
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .03), rgba(var(--clr-primary-rgb), .01)) !important;
    border-bottom: 2px solid rgba(var(--clr-primary-rgb), .08) !important;
    transition: background .3s;
}

.body-wrapper .shadow-none.position-relative.border-bottom h4,
.body-wrapper .shadow-none.position-relative.border-bottom h5 {
    position: relative;
    padding-inline-start: 14px;
}

.body-wrapper .shadow-none.position-relative.border-bottom h4::before,
.body-wrapper .shadow-none.position-relative.border-bottom h5::before {
    content: '';
    position: absolute;
    inset-inline-start: 0;
    top: 3px;
    bottom: 3px;
    width: 3px;
    border-radius: 3px;
    background: linear-gradient(180deg, var(--clr-primary), var(--clr-secondary));
}

.breadcrumb a {
    transition: color .2s;
}

.breadcrumb a:hover {
    color: var(--clr-primary) !important;
}

/* ========== GLOBAL CARD POLISH ========== */
.card {
    border-radius: 12px !important;
    transition: box-shadow .25s ease !important;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, .06) !important;
}

.card .card-title {
    font-weight: 600 !important;
}

/* ========== GLOBAL BUTTONS ========== */
.btn-primary {
    background-color: var(--clr-primary) !important;
    border-color: var(--clr-primary) !important;
    transition: all .2s ease !important;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--clr-primary-hover) !important;
    border-color: var(--clr-primary-hover) !important;
    box-shadow: 0 4px 12px rgba(var(--clr-primary-rgb), .25) !important;
}

.btn-primary:active {
    background-color: var(--clr-primary-active) !important;
    transform: translateY(1px);
}

.bg-primary-subtle {
    background-color: rgba(var(--clr-primary-rgb), .1) !important;
}

.text-primary {
    color: var(--clr-primary) !important;
}

.badge.text-bg-primary {
    background-color: var(--clr-primary) !important;
}

.bg-primary {
    background-color: var(--clr-primary) !important;
}

/* ========== GLOBAL TABLE ENHANCEMENTS ========== */
.datatables .card {
    border: none !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, .04) !important;
}

.table thead th {
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .06), rgba(var(--clr-primary-rgb), .03)) !important;
    font-weight: 700 !important;
    font-size: .82rem;
    text-transform: uppercase;
    letter-spacing: .3px;
    border-bottom: 2px solid rgba(var(--clr-primary-rgb), .1) !important;
}

.table tbody tr {
    transition: background .15s ease;
}

.table tbody tr:hover {
    background: rgba(var(--clr-primary-rgb), .03) !important;
}

.table .badge {
    font-weight: 600;
    border-radius: 6px;
    padding: .35em .65em;
}

/* ========== MOBILE TABLE-CARD OVERFLOW FIX ========== */
@media (max-width: 767.98px) {
    .table-card {
        overflow: hidden !important;
    }

    .table-card table {
        width: 100% !important;
        min-width: 0 !important;
        table-layout: fixed !important;
    }

    .table-card table.text-nowrap {
        white-space: normal !important;
    }

    .table-card tr {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box;
    }

    .table-card td {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box;
    }

    /* Keep buttons/icons at their natural fixed size */
    .table-card td>.btn,
    .table-card td>a.btn {
        flex: 0 0 auto !important;
        max-width: fit-content !important;
        word-break: normal !important;
        white-space: nowrap !important;
    }

    /* Timeline inside table cards */
    .table-card .timeline-wrapper,
    .table-card .timeline-containers-scroll,
    .table-card .timeline-container,
    .table-card .timeline-item {
        max-width: 100% !important;
        overflow: hidden;
        word-break: break-word;
    }

    /* Fix card-based inbox/outbox items */
    .trans-item .card-body {
        word-break: break-word;
    }

    .trans-item .note-title {
        width: 100% !important;
        white-space: normal;
    }
}

/* ========== CUSTOM SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(var(--clr-primary-rgb), .2);
    border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(var(--clr-primary-rgb), .35);
}

/* ========== SIDEBAR SCROLLBAR — Always Visible ========== */
.left-sidebar .scroll-sidebar .simplebar-scrollbar::before {
    background: rgba(var(--clr-primary-rgb), .25) !important;
    opacity: 1 !important;
    transition: opacity .2s !important;
}

.left-sidebar .scroll-sidebar .simplebar-scrollbar.simplebar-visible::before {
    background: rgba(var(--clr-primary-rgb), .45) !important;
}

.left-sidebar .scroll-sidebar .simplebar-track.simplebar-vertical {
    width: 7px !important;
    right: 2px;
}

[dir="rtl"] .left-sidebar .scroll-sidebar .simplebar-track.simplebar-vertical {
    right: auto;
    left: 2px;
}

/* ========== SIDEBAR ENHANCEMENTS ========== */
.left-sidebar .sidebar-item .sidebar-link.active,
.left-sidebar .sidebar-item .sidebar-link:hover {
    color: var(--clr-primary) !important;
}

.left-sidebar .sidebar-item .sidebar-link.active::before {
    content: '';
    position: absolute;
    inset-inline-start: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--clr-primary);
    border-radius: 0 3px 3px 0;
}

.sidebar-nav .sidebar-item .sidebar-link {
    position: relative;
    transition: all .2s ease !important;
}

/* ========== FORM ENHANCEMENTS ========== */
.form-control {
    border-radius: 8px !important;
    transition: border-color .2s, box-shadow .2s !important;
}

.form-control:focus {
    border-color: var(--clr-primary) !important;
    box-shadow: 0 0 0 .2rem rgba(var(--clr-primary-rgb), .12) !important;
}

.form-select:focus {
    border-color: var(--clr-primary) !important;
    box-shadow: 0 0 0 .2rem rgba(var(--clr-primary-rgb), .12) !important;
}

.form-check-input:checked {
    background-color: var(--clr-primary) !important;
    border-color: var(--clr-primary) !important;
}

/* ========== NOTIFICATIONS BADGE ========== */
.badge.rounded-4 {
    font-weight: 700;
    letter-spacing: .3px;
}

/* ========== OFFCANVAS / PINNED PANEL ========== */
.offcanvas .offcanvas-title {
    font-weight: 700 !important;
    color: var(--clr-primary);
}

#btnPin {
    background: linear-gradient(135deg, var(--clr-primary), var(--clr-primary-hover)) !important;
    border: none !important;
    box-shadow: 0 4px 15px rgba(var(--clr-primary-rgb), .3) !important;
    transition: all .25s !important;
}

#btnPin:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 20px rgba(var(--clr-primary-rgb), .4) !important;
}

/* ========== TOOLTIP STYLING ========== */
.tooltip-inner {
    border-radius: 8px;
    padding: .4rem .75rem;
    font-size: .8rem;
}

/* ========== SWEETALERT BROWN THEME ========== */
.swal2-confirm.swal2-styled {
    background: linear-gradient(135deg, var(--clr-primary), var(--clr-primary-hover)) !important;
    border-radius: 8px !important;
    box-shadow: 0 3px 12px rgba(var(--clr-primary-rgb), .25) !important;
}

/* ========== PAGE BODY TRANSITIONS ========== */
.body-wrapper {
    animation: dashFadeUp .3s ease both;
}

/* Ensure flex-column-fluid children take full width */
.d-flex.flex-column-fluid {
    width: 100%;
}

.d-flex.flex-column-fluid > .container-fluid {
    width: 100%;
    max-width: 100%;
}

/* ========== SELECT2 THEME ========== */
body .select2-container {
    border: 1px solid rgba(var(--clr-primary-rgb), .2) !important;
    border-radius: 8px !important;
    transition: border-color .2s, box-shadow .2s;
}

body .select2-container--default .select2-selection--single,
body .select2-container--default .select2-selection--multiple,
body .select2-container--classic .select2-selection--single {
    border: none !important;
    border-radius: 8px !important;
}

body .select2-container:hover {
    border-color: rgba(var(--clr-primary-rgb), .35) !important;
}

body .select2-container--default.select2-container--open,
body .select2-container--default.select2-container--focus {
    border-color: var(--clr-primary) !important;
    box-shadow: 0 0 0 .15rem rgba(var(--clr-primary-rgb), .12) !important;
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background-color: var(--clr-primary) !important;
}

/* ========== DARK MODE GLOBAL ========== */
[data-bs-theme="dark"] .body-wrapper .shadow-none.position-relative.border-bottom {
    background: rgba(255, 255, 255, .02) !important;
    border-bottom-color: rgba(255, 255, 255, .06) !important;
}

[data-bs-theme="dark"] .body-wrapper .shadow-none.position-relative.border-bottom h4::before,
[data-bs-theme="dark"] .body-wrapper .shadow-none.position-relative.border-bottom h5::before {
    background: linear-gradient(180deg, var(--clr-secondary), var(--clr-primary));
}

[data-bs-theme="dark"] .table thead th {
    background: rgba(255, 255, 255, .03) !important;
    border-bottom-color: rgba(255, 255, 255, .08) !important;
}

[data-bs-theme="dark"] .table tbody tr:hover {
    background: rgba(255, 255, 255, .03) !important;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .12);
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, .2);
}

[data-bs-theme="dark"] .login-submit-btn {
    background: linear-gradient(135deg, var(--clr-dm-accent), var(--clr-primary)) !important;
}

/* ============================================================
   SEND REQUEST PAGE (reqPage) ENHANCEMENTS
   ============================================================ */

/* Main card */
.reqPage .req-card {
    border: none !important;
    box-shadow: 0 2px 16px rgba(var(--clr-primary-rgb), .06) !important;
    border-radius: 16px !important;
    overflow: hidden;
}

/* Section boxes */
.reqPage .req-section {
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .025), rgba(var(--clr-primary-rgb), .01));
    border-radius: 12px;
    padding: 1.25rem;
    border: 1px solid rgba(var(--clr-primary-rgb), .06);
}

/* Divider */
.reqPage .req-divider {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(var(--clr-primary-rgb), .15), transparent);
}

/* Swap icon between category & process */
.reqPage .req-swap-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .08), rgba(var(--clr-primary-rgb), .04));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--clr-primary);
    border: 1px solid rgba(var(--clr-primary-rgb), .1);
    margin-bottom: .5rem;
    transition: all .3s ease;
}

.reqPage .req-swap-icon:hover {
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .14), rgba(var(--clr-primary-rgb), .08));
    transform: rotate(180deg);
}

/* Process type label with icon */
.reqPage .req-type-label {
    font-size: .95rem;
    color: var(--clr-text-on-primary);
    letter-spacing: .2px;
}

/* Process type section */
.reqPage .req-type-section {
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .03), rgba(var(--clr-primary-rgb), .015));
}

/* New request button */
.reqPage .req-new-btn {
    border-radius: 10px !important;
    padding: .6rem 1.5rem !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 14px rgba(var(--clr-primary-rgb), .2) !important;
    transition: all .25s ease !important;
}

.reqPage .req-new-btn:hover {
    box-shadow: 0 6px 20px rgba(var(--clr-primary-rgb), .35) !important;
    transform: translateY(-2px);
}

/* Enhanced process-option radio cards */
.reqPage .process-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border: 2px solid rgba(var(--clr-primary-rgb), .12);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    font-weight: 500;
    color: #4a3520;
    transition: all .25s ease;
    position: relative;
    overflow: hidden;
    min-width: 160px;
}

.reqPage .process-option::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .06), transparent);
    opacity: 0;
    transition: opacity .25s ease;
}

.reqPage .process-option:hover {
    border-color: rgba(var(--clr-primary-rgb), .25);
    box-shadow: 0 3px 12px rgba(var(--clr-primary-rgb), .1);
    transform: translateY(-1px);
}

.reqPage .process-option:hover::before {
    opacity: 1;
}

.reqPage .process-option input[type="radio"] {
    accent-color: var(--clr-primary);
    margin: 0;
}

.reqPage .process-option input[type="radio"]:checked+span {
    font-weight: 700;
    color: var(--clr-primary);
}

.reqPage .process-option:has(input[type="radio"]:checked) {
    border-color: var(--clr-primary);
    background: linear-gradient(135deg, rgba(var(--clr-primary-rgb), .06), rgba(var(--clr-primary-rgb), .02));
    box-shadow: 0 3px 14px rgba(var(--clr-primary-rgb), .12);
}

.reqPage .process-option:has(input[type="radio"]:checked)::before {
    opacity: 1;
}

.reqPage .process-option span {
    display: inline-flex;
    align-items: center;
    position: relative;
    z-index: 1;
    white-space: nowrap;
}

.reqPage .process-option span i {
    font-size: 1.1rem;
    opacity: .7;
    transition: opacity .2s;
}

.reqPage .process-option:has(input[type="radio"]:checked) span i {
    opacity: 1;
    color: var(--clr-primary);
}

/* Category label styling */
.reqPage .col-form-label {
    font-weight: 600;
    color: var(--clr-text-on-primary);
    font-size: .88rem;
    letter-spacing: .2px;
}

/* Select2 inside reqPage */
.reqPage .select2-container--default .select2-selection--single {
    border-radius: 10px !important;
    border: 1px solid rgba(var(--clr-primary-rgb), .15) !important;
    height: 44px !important;
    padding-top: 6px !important;
    transition: border-color .2s, box-shadow .2s;
}

.reqPage .select2-container--default .select2-selection--single:hover {
    border-color: rgba(var(--clr-primary-rgb), .3) !important;
}

/* Skeleton loading brown tint */
.reqPage .skeleton-box {
    background-color: rgba(var(--clr-primary-rgb), .08) !important;
    border-radius: 8px !important;
}

/* Dark mode */
[data-bs-theme="dark"] .reqPage .req-card {
    background: #1e1e2d !important;
    box-shadow: 0 2px 16px rgba(0, 0, 0, .2) !important;
}

[data-bs-theme="dark"] .reqPage .req-section {
    background: rgba(255, 255, 255, .02);
    border-color: rgba(255, 255, 255, .05);
}

[data-bs-theme="dark"] .reqPage .req-divider {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .08), transparent);
}

[data-bs-theme="dark"] .reqPage .process-option {
    background: rgba(255, 255, 255, .03);
    border-color: rgba(255, 255, 255, .08);
    color: #c5b9ae;
}

[data-bs-theme="dark"] .reqPage .process-option:hover {
    border-color: rgba(var(--clr-primary-rgb), .4);
    background: rgba(var(--clr-primary-rgb), .08);
}

[data-bs-theme="dark"] .reqPage .process-option:has(input[type="radio"]:checked) {
    border-color: var(--clr-primary);
    background: rgba(var(--clr-primary-rgb), .1);
}

[data-bs-theme="dark"] .reqPage .req-swap-icon {
    background: rgba(var(--clr-primary-rgb), .12);
    border-color: rgba(var(--clr-primary-rgb), .15);
}

[data-bs-theme="dark"] .reqPage .col-form-label,
[data-bs-theme="dark"] .reqPage .req-type-label {
    color: #c5b9ae;
}

[data-bs-theme="dark"] .reqPage .skeleton-box {
    background-color: rgba(255, 255, 255, .06) !important;
}

/* ============================================================
   COMPREHENSIVE RESPONSIVE - ALL DEVICES
   ============================================================ */

/* ========== LARGE DESKTOP (>=1400px) ========== */
@media (min-width: 1400px) {
    .dash-banner-content {
        padding: 2rem 2.5rem 2.5rem;
    }

    .dash-banner-name {
        font-size: 1.5rem !important;
    }

    .dash-stat-num {
        font-size: 1.8rem !important;
    }

    .dash-sum-num {
        font-size: 1.9rem !important;
    }
}

/* ========== DESKTOP (1200px - 1399px) ========== */
@media (max-width: 1399.98px) {
    .dash-banner-content {
        padding: 1.5rem 1.75rem 2rem;
    }

    .dash-stat {
        padding: 1.1rem .85rem !important;
    }

    .dash-stat-num {
        font-size: 1.5rem !important;
    }

    .dash-sum-num {
        font-size: 1.5rem !important;
    }

    .file-card {
        max-width: 100% !important;
    }
}

/* ========== TABLET LANDSCAPE (992px - 1199px) ========== */
@media (max-width: 1199.98px) {
    .dash-banner-content {
        padding: 1.25rem 1.5rem 1.75rem;
    }

    .dash-banner-name {
        font-size: 1.2rem !important;
    }

    .dash-pills-row {
        gap: 6px;
    }

    .dash-pill {
        padding: 6px 12px !important;
        font-size: .76rem !important;
    }

    .dash-stat {
        padding: 1rem .75rem !important;
    }

    .dash-stat-icon-wrap {
        width: 46px;
        height: 46px;
        font-size: 1.2rem;
    }

    .dash-stat-num {
        font-size: 1.4rem !important;
    }

    .dash-stat-lbl {
        font-size: .75rem;
    }

    .dash-sum {
        padding: 1rem .75rem !important;
    }

    .dash-sum-num {
        font-size: 1.4rem !important;
    }

    .dash-sum-icon {
        width: 38px;
        height: 38px;
        font-size: 1.1rem;
    }

    .dash-sum-lbl {
        font-size: .73rem;
    }

    #chart {
        min-height: 250px;
    }
}

/* ========== TABLET PORTRAIT (768px - 991px) ========== */
@media (max-width: 991.98px) {
    .dash-banner-content {
        padding: 1.25rem 1.25rem 1.75rem;
    }

    .dash-banner-name {
        font-size: 1.15rem !important;
    }

    .dash-avatar-wrap {
        width: 64px;
        height: 64px;
    }

    .dash-avatar-wrap img {
        width: 64px !important;
        height: 64px !important;
    }

    .dash-avatar-initials {
        width: 64px;
        height: 64px;
        font-size: 1.35rem;
    }

    /* Charts stack vertically on tablet */
    .collapse .row .col-lg-8,
    .collapse .row .col-lg-4 {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    #chart {
        min-height: 280px;
    }

    #chart-radial-multiple {
        max-width: 300px;
        margin: 0 auto;
    }

    /* Announcements & Pinned stack */
    .row.g-4>[class*="col-lg-5"],
    .row.g-4>[class*="col-lg-7"] {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    /* Page headers */
    .body-wrapper .shadow-none.position-relative.border-bottom h4,
    .body-wrapper .shadow-none.position-relative.border-bottom h5 {
        font-size: 1rem !important;
    }

    /* Page header: stack title & button on tablet */
    .body-wrapper .shadow-none .row .col-md-6 {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    .body-wrapper .shadow-none .row .col-md-6 .d-flex.justify-content-end {
        justify-content: flex-start !important;
        margin-top: .5rem;
    }

    /* Prevent overflow-hidden from clipping breadcrumb area */
    .body-wrapper .shadow-none.position-relative.border-bottom {
        overflow: visible !important;
    }

    /* Login page */
    .auth-container-bg {
        display: none !important;
    }

    .authentication-login .col-lg-5 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    .card .card-body {
        padding: 1.15rem !important;
    }

    .d-flex.justify-content-end.gap-2 {
        justify-content: center !important;
        flex-wrap: wrap;
    }
}

/* ========== TABLET-ONLY TABLE SCROLL (768px - 991px) ========== */
@media (min-width: 768px) and (max-width: 991.98px) {
    .table-responsive,
    .datatables .card-body,
    .card-custom .card-body {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table {
        min-width: 700px;
    }

    .table.text-nowrap {
        white-space: normal !important;
    }

    .table.text-nowrap td,
    .table.text-nowrap th {
        white-space: normal !important;
    }
}

/* ========== MOBILE LANDSCAPE (576px - 767px) ========== */
@media (max-width: 767.98px) {

    /* Banner */
    .dash-banner-content {
        padding: 1.15rem 1rem 1.5rem;
        text-align: center;
    }

    .dash-banner-top {
        flex-direction: column;
        gap: .5rem;
    }

    .dash-avatar-wrap {
        width: 60px;
        height: 60px;
    }

    .dash-avatar-wrap img {
        width: 60px !important;
        height: 60px !important;
    }

    .dash-avatar-initials {
        width: 60px;
        height: 60px;
        font-size: 1.3rem;
    }

    .dash-banner-name {
        font-size: 1.1rem !important;
    }

    .dash-banner-wave {
        height: 14px;
    }

    /* Pills stack */
    .dash-pills-row {
        gap: 6px;
        flex-direction: column;
        align-items: center;
    }

    .dash-pill {
        font-size: .75rem !important;
        padding: 5px 14px !important;
        width: fit-content;
    }

    .dash-pill-divider {
        height: 12px;
    }

    /* Stat cards */
    .dash-stat {
        padding: .9rem .6rem !important;
        gap: .4rem;
    }

    .dash-stat-num {
        font-size: 1.25rem !important;
    }

    .dash-stat-icon-wrap {
        width: 42px;
        height: 42px;
        font-size: 1.15rem;
    }

    .dash-stat-lbl {
        font-size: .72rem;
    }

    /* Summary cards */
    .dash-sum {
        padding: 1rem .6rem !important;
    }

    .dash-sum-num {
        font-size: 1.3rem !important;
    }

    .dash-sum-icon {
        width: 34px;
        height: 34px;
        font-size: 1rem;
    }

    .dash-sum-lbl {
        font-size: .72rem;
    }

    .dash-sum-bar {
        width: 90%;
    }

    /* Filter bar stacks */
    .dash-filter-bar {
        padding: .75rem !important;
    }

    .dash-filter-bar>.d-flex {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 10px !important;
    }

    .dash-period-tags {
        width: 100%;
        justify-content: center;
    }

    .dash-period-tag {
        font-size: .72rem;
        padding: .25rem .55rem;
    }

    .dash-date-group.show {
        display: flex !important;
        width: 100% !important;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
    }

    .dash-date-group.show input[type="date"] {
        flex: 1;
        min-width: 0;
        max-width: none !important;
    }

    .dash-date-group.show .dash-filter-btn {
        width: 100% !important;
        display: flex !important;
        justify-content: center !important;
        margin-top: 4px;
    }

    .dash-date-sep {
        flex-shrink: 0;
        display: flex;
        align-items: center;
    }

    .dash-view-toggle {
        align-self: center !important;
        margin: 0 !important;
    }

    /* Cards */
    .dash-card .card-body {
        padding: 1rem !important;
    }

    .dash-card-header h5 {
        font-size: .95rem !important;
    }

    /* Period toggles */
    .dash-period {
        font-size: .75rem !important;
        padding: .3rem .65rem !important;
    }

    /* Pinned items */
    .dash-pin-item {
        padding: .7rem .5rem;
    }

    .dash-pin-item .badge {
        font-size: .65rem !important;
        max-width: 150px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .dash-empty-state {
        padding: 2rem .75rem;
    }

    .dash-empty-state i {
        font-size: 2.5rem;
    }

    .file-card {
        max-width: 100% !important;
    }

    /* License sidebar — keep vertical on mobile, compact */
    .license-sidebar {
        padding-right: 8px !important;
        max-height: 300px !important;
        font-size: 11px;
    }

    [dir="rtl"] .license-sidebar {
        padding-right: 0 !important;
        padding-left: 8px !important;
    }

    .license-sidebar-item {
        padding: 6px 8px;
        font-size: 11px;
        margin-bottom: 2px;
    }

    .license-sidebar-item .ti {
        display: none;
    }

    .license-sidebar-label {
        font-size: 11px;
    }

    .license-sidebar-count {
        min-width: 18px;
        height: 18px;
        font-size: 10px;
        padding: 0 4px;
    }

    /* Thumbnails: small grid on mobile */
    .license-thumb-grid {
        padding-left: 8px !important;
        gap: 6px;
    }

    [dir="rtl"] .license-thumb-grid {
        padding-left: 0 !important;
        padding-right: 8px !important;
    }

    .license-thumb-item {
        width: 60px;
        height: 78px;
    }

    .license-thumb-link {
        width: 60px;
        height: 60px;
        border-radius: 8px;
    }

    .license-thumb-name {
        font-size: 8px;
        padding: 2px 3px;
    }

    .license-thumb-dl {
        opacity: 1;
        width: 20px;
        height: 20px;
        font-size: .65rem;
    }

    .license-thumb-icon-sm {
        font-size: 1.8rem;
    }

    .license-count-badge,
    .announce-count-badge {
        font-size: 11px;
        padding: 3px 10px;
    }

    /* Page headers */
    .body-wrapper .shadow-none.position-relative.border-bottom h4,
    .body-wrapper .shadow-none.position-relative.border-bottom h5 {
        font-size: .95rem !important;
    }

    .body-wrapper .shadow-none .card-body {
        padding: .75rem !important;
    }

    .body-wrapper .shadow-none .row .col-md-6,
    .body-wrapper .shadow-none .row .col-md-3 {
        text-align: center;
    }

    .body-wrapper .shadow-none .row .col-md-6 .d-flex {
        justify-content: center !important;
    }

    /* Buttons */
    .btn {
        font-size: .85rem;
    }

    .btn-sm {
        font-size: .78rem;
        padding: .3rem .6rem;
    }

    .card .card-body {
        padding: 1rem !important;
    }

    /* Table scroll */
    .datatables .card-body {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding: .5rem !important;
    }

    .table-card .table {
        min-width: 0 !important;
    }

    .table thead th {
        font-size: .75rem !important;
        padding: .5rem .4rem !important;
    }

    .table td {
        padding: .5rem .4rem !important;
        font-size: .8rem;
    }

    .modal-dialog {
        margin: .5rem;
    }

    .offcanvas {
        width: 85% !important;
    }

    .container-fluid {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    /* Login */
    .authentication-login {
        padding: 1.5rem !important;
    }

    .auth-max-width {
        padding: 0 .5rem !important;
    }

    .login-logo {
        height: 45px !important;
    }
}

/* ========== MOBILE PORTRAIT (<=575px) ========== */
@media (max-width: 575.98px) {
    .dash-banner-content {
        padding: 1rem .75rem 1.25rem;
    }

    .dash-banner-name {
        font-size: .95rem !important;
    }

    .dash-banner-hello {
        font-size: .78rem;
    }

    .dash-banner-wave {
        height: 10px;
    }

    .dash-avatar-wrap {
        width: 54px;
        height: 54px;
    }

    .dash-avatar-wrap img {
        width: 54px !important;
        height: 54px !important;
    }

    .dash-avatar-initials {
        width: 54px;
        height: 54px;
        font-size: 1.15rem;
    }

    .dash-verified {
        width: 20px;
        height: 20px;
    }

    .dash-verified i {
        font-size: 16px;
    }

    .dash-pill-icon {
        display: none;
    }

    .dash-pill-divider {
        height: 10px;
    }

    .dash-pill {
        font-size: .72rem !important;
        padding: 4px 10px !important;
    }

    .dash-pill-text {
        font-size: .7rem;
    }

    /* Stat cards compact */
    .dash-stat {
        padding: .75rem .5rem !important;
        gap: .3rem;
        border-radius: 10px !important;
    }

    .dash-stat-num {
        font-size: 1.05rem !important;
    }

    .dash-stat-icon-wrap {
        width: 36px;
        height: 36px;
        font-size: .95rem;
    }

    .dash-stat-lbl {
        font-size: .68rem;
    }

    /* Summary compact */
    .dash-sum {
        padding: .75rem .4rem !important;
        gap: 2px;
        border-radius: 10px !important;
    }

    .dash-sum-num {
        font-size: 1.1rem !important;
    }

    .dash-sum-icon {
        width: 30px;
        height: 30px;
        font-size: .9rem;
    }

    .dash-sum-lbl {
        font-size: .65rem;
        line-height: 1.2;
    }

    .dash-sum-bar {
        width: 95%;
        height: 3px;
    }

    /* Filter */
    .dash-date-group input {
        font-size: .78rem !important;
        padding: .3rem .4rem !important;
    }

    .dash-view-toggle .btn {
        padding: .2rem .4rem !important;
        font-size: .8rem;
    }

    .dash-card .card-body {
        padding: .75rem !important;
    }

    .dash-card-header h5 {
        font-size: .88rem !important;
    }

    .dash-pin-item {
        padding: .6rem .5rem;
    }

    .dash-pin-item h6 {
        font-size: .8rem !important;
    }

    .dash-pin-item .badge {
        font-size: .6rem !important;
        max-width: 120px;
    }

    #chart {
        min-height: 200px;
    }

    .card-title {
        font-size: .9rem !important;
    }

    .card-title small {
        display: block;
        margin-top: 4px;
    }

    .body-wrapper .shadow-none .card-body {
        padding: .5rem !important;
    }

    .breadcrumb {
        font-size: .8rem;
        margin-bottom: .25rem !important;
    }

    /* Table compact */
    .table {
        font-size: .78rem;
    }

    .table thead th {
        font-size: .7rem !important;
        padding: .4rem .3rem !important;
        letter-spacing: 0;
    }

    .table td {
        padding: .4rem .3rem !important;
        font-size: .75rem;
    }

    /* Login compact */
    .authentication-login {
        padding: 1rem !important;
    }

    .auth-max-width h2 {
        font-size: 1.2rem !important;
    }

    .login-logo {
        height: 40px !important;
    }

    .login-submit-btn {
        padding: .6rem !important;
        font-size: .9rem !important;
    }

    .btn {
        font-size: .8rem;
        padding: .4rem .7rem;
    }

    .btn-sm {
        font-size: .72rem;
        padding: .25rem .5rem;
    }

    .select2-container .select2-selection--single {
        height: 34px !important;
    }

    .container-fluid {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .row.g-3 {
        --bs-gutter-x: .5rem;
        --bs-gutter-y: .5rem;
    }

    .row.g-4 {
        --bs-gutter-x: .75rem;
        --bs-gutter-y: .75rem;
    }

    /* File card compact */
    .file-header {
        padding: .4rem !important;
    }

    .file-header .badge {
        font-size: .65rem !important;
    }

    .file-header .btn-group .btn {
        padding: .15rem .3rem !important;
    }

    .file-img-container {
        min-height: 60px;
        padding: .5rem !important;
    }

    .file-img-container img,
    .file-img-container canvas {
        height: 70px !important;
    }
}

/* ========== VERY SMALL SCREENS (<=400px) ========== */
@media (max-width: 400px) {
    .dash-banner-content {
        padding: .85rem .6rem 1rem;
    }

    .dash-avatar-wrap {
        width: 48px;
        height: 48px;
    }

    .dash-avatar-wrap img {
        width: 48px !important;
        height: 48px !important;
    }

    .dash-avatar-initials {
        width: 48px;
        height: 48px;
        font-size: 1rem;
    }

    .dash-banner-name {
        font-size: .88rem !important;
    }

    .dash-pill {
        font-size: .65rem !important;
        padding: 3px 8px !important;
    }

    .dash-pill-divider {
        display: none;
    }

    .dash-stat-num {
        font-size: .95rem !important;
    }

    .dash-stat-icon-wrap {
        width: 32px;
        height: 32px;
        font-size: .85rem;
    }

    .dash-stat-lbl {
        font-size: .62rem;
    }

    .dash-sum-num {
        font-size: .95rem !important;
    }

    .dash-sum-icon {
        width: 26px;
        height: 26px;
        font-size: .8rem;
    }

    .dash-sum-lbl {
        font-size: .6rem;
    }

    /* Date group stacks */
    .dash-date-group.show {
        flex-direction: column !important;
        gap: 4px !important;
    }

    .dash-date-sep {
        display: none !important;
    }

    .dash-pin-item h6 {
        font-size: .75rem !important;
    }

    .dash-pin-item .fs-2 {
        font-size: .65rem !important;
    }

    .d-flex.justify-content-end.gap-2,
    .d-flex.justify-content-center.gap-2 {
        gap: 4px !important;
    }

    .dash-period {
        font-size: .68rem !important;
        padding: .25rem .5rem !important;
    }

    .dash-period i {
        display: none;
    }

    .body-wrapper .shadow-none.position-relative.border-bottom h4 {
        font-size: .85rem !important;
    }

    .table {
        font-size: .72rem;
    }

    .table-card .table {
        min-width: 0 !important;
    }

    .auth-max-width h2 {
        font-size: 1.05rem !important;
    }

    .login-logo {
        height: 35px !important;
    }

    .btn {
        font-size: .75rem;
        padding: .35rem .6rem;
    }

    .container-fluid {
        padding-left: 6px !important;
        padding-right: 6px !important;
    }
}

/* ========== LANDSCAPE ORIENTATION FIX ========== */
@media (max-height: 500px) and (orientation: landscape) {
    .dash-banner-content {
        padding: .75rem 1rem 1rem;
    }

    .dash-banner-top {
        flex-direction: row;
        gap: .75rem;
    }

    .dash-avatar-wrap {
        width: 44px;
        height: 44px;
    }

    .dash-avatar-wrap img {
        width: 44px !important;
        height: 44px !important;
    }

    .dash-avatar-initials {
        width: 44px;
        height: 44px;
        font-size: .95rem;
    }

    .dash-banner-name {
        font-size: .95rem !important;
    }

    .dash-pills-row {
        flex-direction: row;
        gap: 6px;
    }

    .dash-banner-wave {
        height: 8px;
    }

    .authentication-login {
        padding: .5rem !important;
    }

    .dash-stat {
        padding: .6rem .4rem !important;
    }
}

/* ========== VERTICAL SECTION NAVIGATOR ========== */
.dash-section-nav {
    position: fixed;
    top: 70px;
    left: 0;
    z-index: 1040;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 8px 4px;
}

[dir="rtl"] .dash-section-nav {
    left: auto;
    right: 0;
    align-items: flex-end;
}

.dash-section-nav-item {
    display: block;
    text-decoration: none !important;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    white-space: nowrap;
    background: #e8e4e0;
    color: #6c6c6c;
    font-size: 11.5px;
    font-weight: 500;
    padding: 10px 6px;
    border-radius: 0 8px 8px 0;
    transition: all .25s ease;
    max-height: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    border-left: 3px solid transparent;
    letter-spacing: .3px;
}

[dir="rtl"] .dash-section-nav-item {
    border-radius: 8px 0 0 8px;
    border-left: none;
    border-right: 3px solid transparent;
}

.dash-section-nav-item:hover {
    background: #d9cfc6;
    color: #4a3520;
}

.dash-section-nav-item.active {
    background: var(--clr-primary);
    color: #fff;
    border-left-color: var(--clr-nav-border);
    font-weight: 600;
    box-shadow: 2px 2px 8px rgba(var(--clr-primary-rgb), .3);
}

[dir="rtl"] .dash-section-nav-item.active {
    border-left-color: transparent;
    border-right-color: var(--clr-nav-border);
    box-shadow: -2px 2px 8px rgba(var(--clr-primary-rgb), .3);
}

.dash-section-nav-text {
    pointer-events: none;
}

.dash-section-nav-top {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e8e4e0;
    color: #6c6c6c;
    font-size: 14px;
    margin-bottom: 2px;
    transition: all .25s ease;
    cursor: pointer;
    text-decoration: none !important;
    align-self: center;
}

.dash-section-nav-top:hover {
    background: var(--clr-primary);
    color: #fff;
}

/* Hide on mobile */
@media (max-width: 991.98px) {
    .dash-section-nav {
        display: none !important;
    }
}

/* ========== PRINT STYLES ========== */
@media print {

    .dash-banner,
    .dash-filter-bar,
    .dash-view-toggle,
    .dash-period,
    .dash-collapse-ico,
    #btnPin,
    .offcanvas,
    .left-sidebar,
    .topbar,
    .dash-section-nav {
        display: none !important;
    }

    .body-wrapper {
        animation: none !important;
    }

    .dash-card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
        break-inside: avoid;
    }

    .page-wrapper {
        margin: 0 !important;
        padding: 0 !important;
    }
}