*
{
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* =========================================
   HOME PAGE
   ========================================= */

.home-page {
    min-height: calc(100vh - 57px);
    width: 100%;
    position: relative;

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

    padding: 40px 20px;

    overflow: hidden;

    background:
        radial-gradient(
            circle at 15% 20%,
            rgba(255, 193, 7, 0.15),
            transparent 35%
        ),
        radial-gradient(
            circle at 85% 80%,
            rgba(0, 123, 255, 0.12),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #f8f9fa 0%,
            #eef1f5 100%
        );
}


/* Decorative background circles */

.home-page::before,
.home-page::after {
    content: "";
    position: absolute;

    border-radius: 50%;

    pointer-events: none;
}

.home-page::before {
    width: 350px;
    height: 350px;

    top: -150px;
    left: -120px;

    border: 60px solid rgba(255, 193, 7, 0.08);
}

.home-page::after {
    width: 450px;
    height: 450px;

    bottom: -250px;
    right: -180px;

    border: 80px solid rgba(0, 123, 255, 0.06);
}


/* Main content */

.home-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 500px;
}


/* =========================================
   WELCOME CARD
   ========================================= */

.welcome-card {
    position: relative;

    background: rgba(255, 255, 255, 0.96);

    border-radius: 24px;

    padding: 45px 40px 40px;

    text-align: center;

    border: 1px solid rgba(255, 255, 255, 0.8);

    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.10),
        0 5px 15px rgba(0, 0, 0, 0.05);

    backdrop-filter: blur(12px);

    animation: homeCardIn 0.7s ease-out;
}


/* =========================================
   LOGO
   ========================================= */

.logo-wrapper {
    width: 125px;
    height: 125px;

    margin: 0 auto 25px;

    padding: 12px;

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

    background: #ffffff;

    border-radius: 50%;

    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.12);

    border: 4px solid rgba(255, 193, 7, 0.35);

    transition: all 0.3s ease;
}


.logo-wrapper:hover {
    transform: translateY(-5px) scale(1.03);

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.16);
}


.app-logo {
    width: 100%;
    height: 100%;

    object-fit: contain;

    border-radius: 50%;
}


/* =========================================
   TEXT
   ========================================= */

.welcome-label {
    display: block;

    margin-bottom: 8px;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 12px;

    font-weight: 700;

    letter-spacing: 3px;

    color: #6c757d;
}


.welcome-body h1 {
    margin: 0;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

    font-size: 30px;

    font-weight: 700;

    line-height: 1.25;

    text-transform: uppercase;
}


.welcome-line {
    width: 55px;
    height: 4px;

    margin: 18px auto;

    border-radius: 10px;

    background: #ffc107;
}


.welcome-body p {
    margin: 0 auto 30px;

    max-width: 350px;

    color: #6c757d;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 16px;

    font-weight: 400;

    line-height: 1.6;
}


/* =========================================
   GET STARTED BUTTON
   ========================================= */

.get-started-btn {
    display: inline-flex;

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

    gap: 12px;

    min-width: 200px;

    padding: 14px 24px;

    border-radius: 50px;

    background: #ffc107;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 14px;

    font-weight: 700;

    letter-spacing: 1px;

    text-decoration: none !important;

    box-shadow:
        0 8px 20px rgba(255, 193, 7, 0.30);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        background 0.25s ease;
}


.get-started-btn i {
    font-size: 13px;

    transition: transform 0.25s ease;
}


.get-started-btn:hover {
    background: #e0a800;

    transform: translateY(-3px);

    box-shadow:
        0 12px 25px rgba(255, 193, 7, 0.40);
}


.get-started-btn:hover i {
    transform: translateX(5px);
}


.get-started-btn:active {
    transform: translateY(-1px);
}


/* =========================================
   ANIMATION
   ========================================= */

@keyframes homeCardIn {

    from {
        opacity: 0;
        transform: translateY(30px) scale(0.97);
    }

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

}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 576px) {

    .home-page {
        min-height: calc(100vh - 50px);

        padding: 25px 15px;
    }


    .welcome-card {
        padding: 35px 25px 30px;

        border-radius: 20px;
    }


    .logo-wrapper {
        width: 105px;
        height: 105px;

        margin-bottom: 20px;
    }


    .welcome-body h1 {
        font-size: 24px;
    }


    .welcome-body p {
        font-size: 15px;

        margin-bottom: 25px;
    }


    .get-started-btn {
        width: 100%;
    }

}

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

.main-footer {
    position: relative;

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

    flex-wrap: wrap;
    gap: 10px;

    padding: 14px 24px;

    background: #ffffff;

    border-top: 1px solid rgba(0, 0, 0, 0.06);

    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.04);

    font-family: "Source Sans Pro", sans-serif;

    color: #6c757d;
}

/* Remove the inline opacity:0.8 in the PHP — this handles contrast instead */

.main-footer a {
    color: #212529;

    font-weight: 600;

    text-decoration: none;

    transition: color 0.2s ease;
}

.main-footer a:hover {
    color: #e0a800;
}


/* Right-side cluster (Contact Us + version) */

.main-footer .float-right {
    display: flex;
    align-items: center;
    gap: 10px;

    margin: 0 !important;
}


/* Contact Us trigger */

.main-footer .float-right > a[data-toggle="dropdown"] {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    padding: 6px 14px;

    border-radius: 50px;

    background: rgba(255, 193, 7, 0.12);

    color: #212529;

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

    transition: background 0.2s ease, transform 0.2s ease;
}

.main-footer .float-right > a[data-toggle="dropdown"]:hover {
    background: rgba(255, 193, 7, 0.25);

    transform: translateY(-1px);
}

.main-footer .float-right > a[data-toggle="dropdown"] .fa-caret-up {
    transition: transform 0.2s ease;
}

.main-footer .float-right > a[data-toggle="dropdown"][aria-expanded="true"] .fa-caret-up {
    transform: rotate(180deg);
}


/* Footer dropdown container */

.main-footer .dropup {
    position: relative;
}

/* Dropdown hidden by default — Bootstrap's own CSS isn't loaded, so we do this ourselves */

.main-footer .dropdown-menu {
    display: none;
}

.main-footer .dropdown-menu.show {
    display: block;
}

/* Dropdown menu card - force it to float above, never affect layout */

.main-footer .dropdown-menu {
    display: none;

    position: absolute !important;

    top: auto !important;
    bottom: 100% !important;
    right: 0 !important;
    left: auto !important;

    transform: none !important;

    margin: 0 0 12px !important;

    min-width: 240px;

    max-height: 70vh;
    overflow-y: auto;

    background: #ffffff;

    border: none;
    border-radius: 14px;

    padding: 8px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.06);

    animation: footerDropIn 0.2s ease-out;
}

.main-footer .dropdown-menu.show {
    display: block;
}

.main-footer .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 9px 12px;

    border-radius: 8px;

    font-size: 14px;
    font-weight: 400;

    color: #212529;
}

.main-footer .dropdown-item i {
    width: 16px;

    color: #ffc107;

    text-align: center;
}

.main-footer .dropdown-item:hover {
    background: rgba(255, 193, 7, 0.10);

    color: #212529;
}

.main-footer .dropdown-divider {
    margin: 6px 4px;

    border-top: 1px solid rgba(0, 0, 0, 0.06);
}


/* Version badge */

.main-footer .float-right > b {
    font-weight: 700;
}


@keyframes footerDropIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 576px) {

    .main-footer {
        flex-direction: column;

        text-align: center;

        padding: 16px;
    }

    .main-footer .float-right {
        justify-content: center;

        width: 100%;
    }

}

/* =========================================
   LOGIN PAGE
   ========================================= */

.login-page {
    min-height: calc(100vh - 57px);
    width: 100%;
    position: relative;

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

    padding: 40px 20px;

    background:
        radial-gradient(
            circle at 15% 20%,
            rgba(255, 193, 7, 0.15),
            transparent 35%
        ),
        radial-gradient(
            circle at 85% 80%,
            rgba(0, 123, 255, 0.12),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #f8f9fa 0%,
            #eef1f5 100%
        );
}

.login-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 440px;
}


/* Card */

.login-card {
    position: relative;

    background: rgba(255, 255, 255, 0.96);

    border-radius: 24px;

    padding: 45px 40px 40px;

    text-align: center;

    border: 1px solid rgba(255, 255, 255, 0.8);

    box-shadow:
        0 25px 60px rgba(0, 0, 0, 0.10),
        0 5px 15px rgba(0, 0, 0, 0.05);

    backdrop-filter: blur(12px);
}


/* Avatar */

.login-avatar-wrapper {
    width: 95px;
    height: 95px;

    margin: 0 auto 22px;

    padding: 6px;

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

    background: #ffffff;

    border-radius: 50%;

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);

    border: 4px solid rgba(255, 193, 7, 0.35);
}

.login-avatar {
    width: 100%;
    height: 100%;

    object-fit: cover;

    border-radius: 50%;
}


/* Heading */

.login-heading {
    margin: 0;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

    font-size: 26px;

    font-weight: 700;

    line-height: 1.25;
}

.login-body .welcome-line {
    margin: 16px auto 26px;
}


/* Input group — built from scratch, no Bootstrap CSS dependency */

.login-input-group {
    display: flex;
    align-items: stretch;

    width: 100%;
}

.login-input-group .form-control {
    flex: 1 1 auto;

    width: auto;

    height: 48px;

    margin: 0;

    border-radius: 50px 0 0 50px;

    border: 1px solid #dee2e6;
    border-right: none;

    outline: none;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 15px;

    color: #212529;

    padding: 0 0 0 20px;

    background: #ffffff;
}

.login-input-group .form-control::placeholder {
    color: #adb5bd;
}

.login-input-group .form-control:focus {
    border-color: #ffc107;
}

.login-input-group .input-group-append {
    display: flex;
    flex: 0 0 auto;
}

.login-input-group .input-group-text {
    display: flex;
    align-items: center;
    justify-content: center;

    height: 48px;
    width: 48px;

    border-radius: 0 50px 50px 0;

    border: 1px solid #dee2e6;
    border-left: none;

    background: #ffffff;
}

.login-input-group .input-group-text .fa-envelope {
    color: #ffc107;

    font-size: 15px;
}

.login-input-group .form-control:focus ~ .input-group-append .input-group-text {
    border-color: #ffc107;
}


/* Button — reset browser button defaults, then reuse .get-started-btn look */

button.get-started-btn {
    width: 100%;

    margin-top: 6px;

    border: none;
    outline: none;

    cursor: pointer;

    font: inherit;

    -webkit-appearance: none;
    appearance: none;
}


/* OTP link */

.login-otp-link {
    display: block;

    margin-top: 18px;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 13px;

    color: #6c757d !important;

    transition: color 0.2s ease;
}

.login-otp-link:hover {
    color: #e0a800 !important;
}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 576px) {

    .login-page {
        padding: 25px 15px;
    }

    .login-card {
        padding: 35px 25px 30px;

        border-radius: 20px;
    }

    .login-avatar-wrapper {
        width: 85px;
        height: 85px;
    }

    .login-heading {
        font-size: 22px;
    }

}

/* =========================================
   MAIN HEADER (TOP NAVBAR)
   ========================================= */

.main-header {
    position: fixed;
    top: 0;
    left: 250px;
    right: 0;

    z-index: 1030;

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

    height: 57px;

    padding: 0 20px;

    background: #ffffff;

    border-bottom: 1px solid rgba(0, 0, 0, 0.06);

    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.04);

    font-family: "Source Sans Pro", sans-serif;

    transition: left 0.3s ease;
}

.main-header .navbar-nav {
    display: flex;
    align-items: center;

    list-style: none;

    margin: 0;
    padding: 0;

    height: 100%;
}

.main-header .nav-item {
    height: 100%;

    display: flex;
    align-items: center;
}

.main-header .nav-link {
    display: flex;
    align-items: center;
    gap: 6px;

    height: 100%;
    padding: 0 12px;

    color: #212529;

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

    text-decoration: none !important;

    transition: color 0.2s ease;
}

.main-header .nav-link:hover {
    color: #e0a800;
}

.main-header .nav-link[data-widget="pushmenu"] {
    font-size: 16px;

    padding: 0 16px 0 0;
}


/* Notification badge */

.main-header .navbar-badge {
    position: relative;

    top: -8px;
    left: -4px;

    padding: 2px 5px;

    border-radius: 50px;

    background: #ffc107;

    color: #212529;

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


/* Logout button */

.main-header .log-out-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    padding: 7px 16px !important;

    border-radius: 10px;

    background: #dc3545;

    color: #ffffff !important;

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

    height: auto !important;

    transition: background 0.2s ease, transform 0.2s ease;
}

.main-header .log-out-link:hover {
    background: #c82333;

    transform: translateY(-1px);
}


/* Header dropdown (notifications bell) */

.main-header .dropdown {
    position: relative;

    height: 100%;

    display: flex;
    align-items: center;
    
}

.main-header .dropdown-menu {
    display: none;

    position: absolute !important;

    top: 100% !important;
    right: 0 !important;
    left: auto !important;

    transform: none !important;

    margin-top: 8px !important;

    min-width: 260px;

    background: #ffffff;

    border: none;
    border-radius: 14px;

    padding: 8px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.06);

    animation: footerDropIn 0.2s ease-out;
}

.main-header .dropdown-menu.show {
    display: block;
}

.main-header .dropdown-header {
    display: block;

    padding: 10px 12px;

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

    color: #212529;

    border-radius: 8px;
}

.main-header .dropdown-header:hover {
    background: rgba(255, 193, 7, 0.10);
}

.main-header .dropdown-divider {
    margin: 6px 4px 0;

    border-top: 1px solid rgba(0, 0, 0, 0.06);
}


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

.main-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;

    z-index: 1040;

    width: 250px;

    display: flex;
    flex-direction: column;

    background: #212529;

    overflow: hidden;

    transition: width 0.3s ease, margin-left 0.3s ease;
}


/* Brand */

.brand-link {
    display: flex;
    align-items: center;
    gap: 12px;

    flex: 0 0 auto;

    height: 57px;

    padding: 0 16px;

    background: rgba(0, 0, 0, 0.15);

    border-bottom: 1px solid rgba(255, 255, 255, 0.08);

    text-decoration: none !important;

    white-space: nowrap;
    overflow: hidden;
}

.brand-image {
    width: 32px;
    height: 32px;

    object-fit: contain;

    border-radius: 50%;

    flex: 0 0 auto;
}

.brand-text {
    color: #ffffff;

    font-family: Georgia, "Times New Roman", Times, serif;

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

    text-transform: uppercase;

    letter-spacing: 0.5px;
}


/* Scrollable nav area */

.main-sidebar .sidebar {
    flex: 1 1 auto;

    overflow-y: auto;

    padding-bottom: 20px;
}

.main-sidebar .sidebar::-webkit-scrollbar {
    width: 5px;
}

.main-sidebar .sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);

    border-radius: 10px;
}


/* User panel */

.user-panel {
    display: flex;
    align-items: center;
    gap: 12px;

    padding: 18px 16px;

    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.user-panel .image img {
    width: 40px;
    height: 40px;

    object-fit: cover;

    border-radius: 50%;

    border: 2px solid rgba(255, 193, 7, 0.5);
}

.user-panel .info a {
    color: #ffffff;

    font-family: "Source Sans Pro", sans-serif;

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

    text-decoration: none !important;

    word-break: break-all;
}


/* Nav list */

.nav-sidebar {
    list-style: none;

    margin: 0;
    padding: 10px 12px 0;
}

.nav-sidebar .nav-header {
    margin: 18px 4px 6px;

    color: rgba(255, 255, 255, 0.4);

    font-family: "Source Sans Pro", sans-serif;

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

    letter-spacing: 1.5px;
}

.nav-sidebar .nav-item {
    margin-bottom: 2px;
}

.nav-sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 12px;

    padding: 10px 12px;

    border-radius: 10px;

    color: rgba(255, 255, 255, 0.75);

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;
    font-weight: 500;

    text-decoration: none !important;

    transition: background 0.2s ease, color 0.2s ease;
}

.nav-sidebar .nav-link:hover {
    background: rgba(255, 255, 255, 0.06);

    color: #ffffff;
}

.nav-sidebar .nav-link.active {
    background: rgba(255, 193, 7, 0.15);

    color: #ffc107;
}

.nav-sidebar .nav-icon {
    width: 18px;

    text-align: center;

    font-size: 15px;
}

.nav-sidebar .nav-link p {
    margin: 0;
}


/* =========================================
   CONTENT OFFSET (pushed by fixed header/sidebar)
   ========================================= */

body.is-authed .content-wrapper {
    margin-left: 250px;
    margin-top: 57px;

    transition: margin-left 0.3s ease;
}

body.is-authed .main-footer {
    margin-left: 250px;

    transition: margin-left 0.3s ease;
}

/* =========================================
   SIDEBAR COLLAPSE (toggled by AdminLTE JS via data-widget="pushmenu")
   ========================================= */

body.is-authed.sidebar-collapse .main-sidebar {
    margin-left: -250px;
}

body.is-authed.sidebar-collapse .content-wrapper,
body.is-authed.sidebar-collapse .main-footer,
body.is-authed.sidebar-collapse .main-header {
    margin-left: 0;
    left: 0;
}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 991px) {

    .main-sidebar {
        margin-left: -250px;
    }

    .main-header {
        left: 0;
    }

    body.is-authed .content-wrapper,
    body.is-authed .main-footer {
        margin-left: 0;
    }

    body.is-authed.sidebar-open .main-sidebar {
        margin-left: 0;
    }

}

/* =========================================
   AUTHENTICATED CONTENT AREA
   ========================================= */

body.is-authed .content-wrapper {
    background: #f4f5f7;

    min-height: calc(100vh - 57px);
}

body.is-authed .content-wrapper .content {
    padding: 24px;
}

@media (max-width: 576px) {

    body.is-authed .content-wrapper .content {
        padding: 16px;
    }

}

/* =========================================
   GRID (minimal — only classes actually in use)
   ========================================= */

.row {
    display: flex;
    flex-wrap: wrap;

    margin-left: -10px;
    margin-right: -10px;
}

.row > [class*="col-"] {
    padding-left: 10px;
    padding-right: 10px;
}

.col-6      { flex: 0 0 50%;  max-width: 50%; }
.col-sm-6   { flex: 0 0 50%;  max-width: 50%; }
.col-md-12  { flex: 0 0 100%; max-width: 100%; }
.col-lg-4   { flex: 0 0 33.333%; max-width: 33.333%; }

@media (max-width: 991px) {
    .col-lg-4 { flex: 0 0 50%; max-width: 50%; }
}

@media (max-width: 576px) {
    .col-lg-4,
    .col-sm-6 { flex: 0 0 100%; max-width: 100%; }
}

.mb-2 { margin-bottom: 12px; }
.m-0  { margin: 0; }
.mt-1 { margin-top: 6px; }


/* =========================================
   STAT BOXES (small-box)
   ========================================= */

.small-box {
    position: relative;

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

    background: #ffffff;

    border-radius: 18px;

    padding: 20px 22px;

    margin-bottom: 20px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.06),
        0 3px 10px rgba(0, 0, 0, 0.04);

    overflow: hidden;

    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.small-box:hover {
    transform: translateY(-4px);

    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.09),
        0 5px 12px rgba(0, 0, 0, 0.05);
}

.small-box .inner h3 {
    margin: 0 0 4px;

    padding: 10px 20px;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.small-box .inner p {
    margin: 0;

    color: #6c757d;

    font-family: "Source Sans Pro", sans-serif;

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

    text-transform: uppercase;

    letter-spacing: 0.5px;
}

.small-box .icon {
    flex: 0 0 auto;

    width: 48px;
    height: 48px;

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

    border-radius: 50%;

    background: rgba(255, 193, 7, 0.12);

    color: #ffc107;

    font-size: 20px;
}


/* =========================================
   CARD — refined
   ========================================= */

.card {
    background: #ffffff;

    border-radius: 18px;

    margin-bottom: 24px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.06),
        0 3px 10px rgba(0, 0, 0, 0.04);

    overflow: hidden;

    border-top: 3px solid #ffc107;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 20px 24px;

    background: linear-gradient(180deg, #fcfcfd 0%, #ffffff 100%);

    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.card-title {
    margin: 0;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.card-title::before {
    content: "";

    display: inline-block;

    width: 6px;
    height: 6px;

    margin-right: 10px;

    border-radius: 50%;

    background: #ffc107;
}


/* =========================================
   STAT BOXES — refined
   ========================================= */

.small-box {
    position: relative;

    background: #ffffff;

    border-radius: 18px;

    padding: 22px;

    margin-bottom: 20px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.06),
        0 3px 10px rgba(0, 0, 0, 0.04);

    overflow: hidden;

    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.small-box::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;
    right: 0;

    height: 3px;

    background: linear-gradient(90deg, #ffc107, rgba(255, 193, 7, 0.2));
}

.small-box:hover {
    transform: translateY(-4px);

    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.09),
        0 5px 12px rgba(0, 0, 0, 0.05);
}

.small-box .inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.small-box .inner h3 {
    margin: 0 0 4px;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.small-box .inner p {
    margin: 0;

    color: #6c757d;

    font-family: "Source Sans Pro", sans-serif;

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

    text-transform: uppercase;

    letter-spacing: 0.6px;
}

.small-box .icon {
    flex: 0 0 auto;

    width: 52px;
    height: 52px;

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

    border-radius: 16px;

    background: rgba(255, 193, 7, 0.12);

    color: #ffc107;

    font-size: 21px;
}


/* =========================================
   TABLE — refined
   ========================================= */

.table-responsive {
    width: 100%;

    overflow-x: auto;

    border-radius: 12px;

    padding: 20px;
}

.table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 14px;

    color: #212529;
}

.table thead th {
    padding: 13px 16px;

    text-align: left;

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

    text-transform: uppercase;

    letter-spacing: 0.6px;

    color: #6c757d;

    background: #f8f9fa;

    border-bottom: 2px solid rgba(0, 0, 0, 0.06);

    white-space: nowrap;
}

.table thead th:first-child {
    border-top-left-radius: 12px;
}

.table thead th:last-child {
    border-top-right-radius: 12px;
}

.table td {
    padding: 14px 16px;

    border-bottom: 1px solid rgba(0, 0, 0, 0.05);

    vertical-align: middle;
}

.table-striped tbody tr:nth-of-type(odd) {
    background: rgba(0, 0, 0, 0.015);
}

.table-hover tbody tr {
    position: relative;

    transition: background 0.15s ease;
}

.table-hover tbody tr:hover {
    background: rgba(255, 193, 7, 0.06);
}

.table-hover tbody tr:hover td:first-child::before {
    content: "";

    position: absolute;

    left: 0;
    top: 0;
    bottom: 0;

    width: 3px;

    background: #ffc107;
}

.table-sm td,
.table-sm th {
    padding: 9px 14px;
}

.table th[scope="row"] {
    color: #adb5bd;

    font-weight: 700;

    font-size: 13px;
}

.text-primary {
    color: #007bff;

    font-weight: 600;
}

.text-primary:hover {
    color: #0056b3;
}

.text-lowercase {
    text-transform: lowercase;

    color: #495057;
}

.cursor-pointer {
    cursor: pointer;
}



/* =========================================
   BADGE
   ========================================= */

.badge {
    display: inline-block;

    padding: 4px 10px;

    border-radius: 10px;

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

    text-transform: uppercase;

    letter-spacing: 0.4px;

    color: #ffffff;
}

.badge-primary   { background: #007bff; }
.badge-secondary { background: #6c757d; }
.badge-success   { background: #28a745; }
.badge-danger    { background: #dc3545; }
.badge-warning   { background: #ffc107; color: #212529; }
.badge-info      { background: #17a2b8; }
.badge-light     { background: #f1f3f5; color: #212529; }
.badge-dark      { background: #212529; }


/* =========================================
   IN-CONTENT DROPDOWNS (opens below, not dropup)
   ========================================= */

.dropdown {
    position: relative;

    display: inline-block;
}

.dropdown .dropdown-menu {
    display: none;

    position: absolute !important;

    top: 100% !important;
    left: 0 !important;
    right: auto !important;
    bottom: auto !important;

    transform: none !important;

    margin-top: 8px !important;

    min-width: 220px;

    background: #ffffff;

    border: none;
    border-radius: 14px;

    padding: 8px;

    z-index: 1071;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.06);

    animation: footerDropIn 0.2s ease-out;
}

.dropdown .dropdown-menu.show {
    display: block;
}

.dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 9px 12px;

    border-radius: 8px;

    font-size: 14px;
    font-weight: 400;

    color: #212529;

    text-decoration: none !important;

    cursor: pointer;
}

.dropdown .dropdown-item i {
    width: 16px;

    color: #ffc107;

    text-align: center;
}

.dropdown .dropdown-item:hover {
    background: rgba(255, 193, 7, 0.10);
}

.dropdown .dropdown-divider {
    margin: 6px 4px;

    border-top: 1px solid rgba(0, 0, 0, 0.06);
}


/* =========================================================
   DASHBOARD DATATABLE
   ========================================================= */

.dashboard-table-top {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 0 0 18px 0;
}

/* =========================================================
   EXCEL BUTTON
   ========================================================= */

.dashboard-table-buttons {
    display: flex;
    align-items: center;
}

.dashboard-excel-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;

    height: 40px !important;
    padding: 0 18px !important;

    border: 0 !important;
    border-radius: 10px !important;

    background: #0a6504 !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    cursor: pointer !important;

    transition: all 0.2s ease !important;
}

.dashboard-excel-btn:hover {
    background: #084d03 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
}

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

.dashboard-table-search {
    display: flex;
    align-items: center;
}

.dashboard-table-search label {
    display: flex !important;
    align-items: center !important;
    margin: 0 !important;
}

.dashboard-table-search input {
    width: 250px !important;
    height: 40px !important;

    margin: 0 !important;
    padding: 0 18px !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 50px !important;

    background: #ffffff !important;
    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;

    outline: none !important;

    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04) !important;

    transition: all 0.2s ease !important;
}

.dashboard-table-search input::placeholder {
    color: #adb5bd !important;
    opacity: 1 !important;
}

.dashboard-table-search input:focus {
    border-color: #ffc107 !important;

    box-shadow:
        0 0 0 3px rgba(255, 193, 7, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.04) !important;
}

/* =========================================================
   BOTTOM AREA
   ========================================================= */

.dashboard-table-bottom {
    width: 100%;

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

    gap: 20px;

    padding: 18px 20px 8px;

    margin-top: 5px;

    border-top: 1px solid rgba(0, 0, 0, 0.06);

    font-family: "Source Sans Pro", sans-serif;
}

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

.dashboard-table-info {
    color: #6c757d;
    font-size: 13px;
    font-weight: 500;
}

.dashboard-table-info .dataTables_info {
    padding: 0 !important;
    margin: 0 !important;

    color: #6c757d !important;
}

/* =========================================================
   PAGINATION CONTAINER
   ========================================================= */

.dashboard-table-pagination {
    margin-left: auto;
}

.dashboard-table-pagination .dataTables_paginate {
    display: flex !important;
    align-items: center !important;
    gap: 5px !important;

    padding: 0 !important;
    margin: 0 !important;

    float: none !important;
}

/* =========================================================
   PAGINATION CONTAINER
   ========================================================= */

.dashboard-table-pagination {
    margin-left: auto;
}

.dashboard-table-pagination .dataTables_paginate {
    padding: 0 !important;
    margin: 0 !important;
    float: none !important;
}

/* Reset the <ul class="pagination"> Bootstrap-style wrapper */

.dashboard-table-pagination .pagination {
    display: flex !important;
    align-items: center !important;
    flex-wrap: wrap;

    list-style: none !important;

    margin: 0 !important;
    padding: 0 !important;

    gap: 5px;
}

.dashboard-table-pagination .page-item {
    display: flex;

    list-style: none;
}


/* =========================================================
   PAGINATION BUTTONS — target both markup variants
   ========================================================= */

.dashboard-table-pagination .page-link,
.dashboard-table-pagination .paginate_button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    min-width: 36px !important;
    height: 36px !important;

    padding: 0 11px !important;
    margin: 0 !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 9px !important;

    background: #ffffff !important;
    background-image: none !important;

    color: #495057 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 600 !important;

    text-decoration: none !important;
    cursor: pointer !important;

    box-shadow: none !important;
    outline: none !important;

    transition:
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease !important;
}


/* HOVER */

.dashboard-table-pagination .page-link:hover,
.dashboard-table-pagination .paginate_button:hover {
    background: #fff8df !important;
    background-image: none !important;

    border-color: #ffc107 !important;

    color: #212529 !important;

    transform: translateY(-1px);

    box-shadow: none !important;
}


/* ACTIVE PAGE */

.dashboard-table-pagination .page-item.active .page-link,
.dashboard-table-pagination .paginate_button.current {
    background: #ffc107 !important;
    background-image: none !important;

    border-color: #ffc107 !important;

    color: #212529 !important;

    font-weight: 700 !important;

    box-shadow: 0 5px 12px rgba(255, 193, 7, 0.25) !important;
}

.dashboard-table-pagination .page-item.active .page-link:hover,
.dashboard-table-pagination .paginate_button.current:hover {
    background: #e0a800 !important;
    background-image: none !important;

    border-color: #e0a800 !important;

    color: #212529 !important;
}


/* PREVIOUS / NEXT */

.dashboard-table-pagination .page-item.previous .page-link,
.dashboard-table-pagination .page-item.next .page-link,
.dashboard-table-pagination .paginate_button.previous,
.dashboard-table-pagination .paginate_button.next {
    min-width: 80px !important;

    padding: 0 15px !important;

    font-weight: 600 !important;
}


/* DISABLED */

.dashboard-table-pagination .page-item.disabled .page-link,
.dashboard-table-pagination .paginate_button.disabled,
.dashboard-table-pagination .paginate_button.disabled:hover {
    background: #f8f9fa !important;
    background-image: none !important;

    border-color: #e9ecef !important;

    color: #adb5bd !important;

    cursor: not-allowed !important;

    transform: none !important;

    box-shadow: none !important;
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 576px) {

    .dashboard-table-top {
        flex-direction: column;
        align-items: stretch;
    }

    .dashboard-table-search {
        width: 100%;
    }

    .dashboard-table-search input {
        width: 100% !important;
    }

    .dashboard-table-bottom {
        flex-direction: column;
        align-items: center;

        gap: 15px;

        padding: 16px 10px 5px;
    }

    .dashboard-table-pagination {
        width: 100%;
        margin-left: 0;

        display: flex;
        justify-content: center;
    }

    .dashboard-table-pagination .pagination {
        flex-wrap: wrap;
        justify-content: center;
    }

    .dashboard-table-pagination .page-link,
    .dashboard-table-pagination .paginate_button {
        min-width: 34px !important;
        height: 34px !important;
        font-size: 12px !important;
    }

}

/* =========================================================
   LENGTH MENU (records-per-page dropdown)
   ========================================================= */

.dashboard-table-length {
    display: flex;
    align-items: center;
}

.dashboard-table-length label {
    display: flex !important;
    align-items: center !important;
    gap: 8px;

    margin: 0 !important;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    color: #6c757d;
}

.dashboard-table-length select {
    height: 40px !important;

    padding: 0 30px 0 14px !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 10px !important;

    background: #ffffff !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;

    outline: none !important;

    cursor: pointer;

    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04) !important;

    transition: border-color 0.2s ease !important;
}

.dashboard-table-length select:focus {
    border-color: #ffc107 !important;
}


/* =========================================================
   COLVIS (Filter Columns) BUTTON + its popup
   ========================================================= */

.dashboard-colvis-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 10px !important;

    background: #ffffff !important;
    background-image: none !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    cursor: pointer !important;

    margin-left: 8px !important;

    transition: all 0.2s ease !important;
}

.dashboard-colvis-btn:hover {
    background: rgba(255, 193, 7, 0.12) !important;

    border-color: #ffc107 !important;
}

/* DataTables injects its own dropdown div for colvis, separate from Bootstrap dropdowns */

.dt-button-collection {
    display: none;

    position: absolute;

    z-index: 1071;

    min-width: 200px;

    margin-top: 8px;

    padding: 8px;

    background: #ffffff;

    border: none;
    border-radius: 14px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.06);
}

.dt-button-collection.dtb-collection-closeable {
    display: block;
}

.dt-button-collection .dt-button {
    display: flex !important;
    align-items: center;
    gap: 8px;

    width: 100%;

    padding: 9px 12px !important;

    border: none !important;
    border-radius: 8px !important;

    background: transparent !important;

    color: #212529 !important;

    font-size: 14px !important;
    font-weight: 400 !important;

    text-align: left;

    cursor: pointer;

    transition: background 0.15s ease;
}

.dt-button-collection .dt-button:hover {
    background: rgba(255, 193, 7, 0.10) !important;
}

.dt-button-collection .dt-button.dt-button-active {
    font-weight: 700 !important;
}

.dt-button-collection .dt-button.dt-button-active::before {
    content: "\f00c";

    font-family: "Font Awesome 5 Pro", "Font Awesome 5 Free";
    font-weight: 900;

    color: #ffc107;

    margin-right: 4px;
}


/* =========================================================
   CONTENT HEADER (page title bar above cards)
   ========================================================= */

.content-header {
    padding-bottom: 20px;
}

.container-fluid {
    width: 100%;
}

.breadcrumb-item {
    font-family: Georgia, "Times New Roman", Times, serif;

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

    color: #212529;

    letter-spacing: 0.5px;
}


/* =========================================================
   ADD NEW CASE BUTTON
   ========================================================= */

.card-header .btn-warning {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    width: 100% !important;

    height: 40px !important;

    padding: 0 16px !important;

    border: none !important;
    border-radius: 10px !important;

    background: #ffc107 !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    letter-spacing: 0.4px;

    cursor: pointer !important;

    white-space: nowrap;

    transition: background 0.2s ease, transform 0.2s ease !important;
}

.card-header .btn-warning:hover {
    background: #e0a800 !important;

    transform: translateY(-1px);
}

.float-right {
    float: right;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 576px) {

    .dashboard-table-length {
        width: 100%;
    }

    .dashboard-table-length select {
        flex: 1;
    }

    .card-header .row {
        justify-content: stretch !important;
    }

    .card-header .col-md-2 {
        max-width: 100%;
        flex: 0 0 100%;

        margin-top: 10px;
    }

}

/* =========================================================
   BUTTONS ROW — force side-by-side with gap
   ========================================================= */

.dashboard-table-buttons {
    display: flex !important;
    align-items: center;
    gap: 10px;
}

.dashboard-table-buttons .dt-buttons {
    display: flex !important;
    align-items: center;
    gap: 10px;
}


/* =========================================================
   FILTER COLUMNS — add dropdown caret
   ========================================================= */

.dashboard-colvis-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 16px !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 10px !important;

    background: #ffffff !important;
    background-image: none !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    cursor: pointer !important;

    margin-left: 0 !important;

    transition: all 0.2s ease !important;
}

.dashboard-colvis-btn:hover {
    background: rgba(255, 193, 7, 0.12) !important;

    border-color: #ffc107 !important;
}

.dashboard-colvis-btn::after {
    content: "\f107";

    font-family: "Font Awesome 5 Pro", "Font Awesome 5 Free";
    font-weight: 900;

    font-size: 11px;

    margin-left: 2px;

    transition: transform 0.2s ease;
}

.dashboard-colvis-btn[aria-expanded="true"]::after {
    transform: rotate(180deg);
}


/* =========================================================
   REMOVE UNDERLINES FROM DROPDOWN / COLVIS ITEMS
   ========================================================= */

.dt-button-collection .dt-button,
.dt-button-collection .dt-button * {
    text-decoration: none !important;
}

.dt-button-collection a {
    text-decoration: none !important;

    color: inherit !important;
}

.dropdown-item,
.dropdown-item * {
    text-decoration: none !important;
}

/* =========================================================
   PDF EXPORT BUTTON
   ========================================================= */

.dashboard-pdf-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: 0 !important;
    border-radius: 10px !important;

    background: #c9302c !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    text-decoration: none !important;

    cursor: pointer !important;

    transition: all 0.2s ease !important;
}

.dashboard-pdf-btn:hover {
    background: #a5241f !important;

    color: #ffffff !important;

    transform: translateY(-2px);
}

/* =========================================================
   BULK UPLOAD CARD
   ========================================================= */

.text-muted {
    color: #6c757d;

    font-family: "Source Sans Pro", sans-serif;

    font-size: 13px;

    line-height: 1.7;
}

.mb-3 {
    margin-bottom: 18px;
    padding: 20px;
}


/* File input + upload button group */

.bulk-upload-cases-form .input-group {
    display: flex;
    align-items: stretch;

    width: 100%;

    max-width: 520px;
}

.bulk-upload-cases-form .form-control[type="file"] {
    flex: 1 1 auto;

    height: 46px;

    padding: 10px 14px;

    border: 1px solid #dee2e6;
    border-right: none;

    border-radius: 10px 0 0 10px;

    background: #ffffff;

    color: #495057;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;

    outline: none;

    cursor: pointer;
}

.bulk-upload-cases-form .form-control[type="file"]::file-selector-button {
    margin-right: 12px;

    padding: 6px 14px;

    border: none;
    border-radius: 6px;

    background: rgba(255, 193, 7, 0.15);

    color: #212529;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 12px;
    font-weight: 700;

    cursor: pointer;

    transition: background 0.2s ease;
}

.bulk-upload-cases-form .form-control[type="file"]:hover::file-selector-button {
    background: rgba(255, 193, 7, 0.3);
}

.bulk-upload-cases-form .btn-primary {
    flex: 0 0 auto;

    height: 46px;

    padding: 0 22px;

    border: none;
    outline: none;

    border-radius: 0 10px 10px 0;

    background: #212529;

    color: #ffffff;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 700;

    letter-spacing: 0.4px;

    cursor: pointer;

    transition: background 0.2s ease;
}

.bulk-upload-cases-form .btn-primary:hover {
    background: #000000;
}


/* Upload result alert */

#uploadAlert {
    margin-top: 14px;
}

#uploadAlert .alert {
    padding: 12px 16px;

    border-radius: 10px;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 500;
}

#uploadAlert .alert-success {
    background: rgba(40, 167, 69, 0.1);

    color: #1e7e34;

    border: 1px solid rgba(40, 167, 69, 0.25);
}

#uploadAlert .alert-danger {
    background: rgba(220, 53, 69, 0.1);

    color: #a71d2a;

    border: 1px solid rgba(220, 53, 69, 0.25);
}


/* =========================================================
   WIDE TABLE — horizontal scroll affordance
   ========================================================= */

.table-responsive {
    position: relative;
}

/* DataTables scrollX wraps the table in its own containers */

.dataTables_scroll {
    width: 100%;
}

.dataTables_scrollHead {
    overflow: hidden;
}

.dataTables_scrollBody {
    overflow-x: auto !important;

    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.dataTables_scrollBody::-webkit-scrollbar {
    height: 8px;
}

.dataTables_scrollBody::-webkit-scrollbar-thumb {
    background: rgba(255, 193, 7, 0.4);

    border-radius: 10px;
}

.dataTables_scrollBody::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 193, 7, 0.7);
}

.dataTables_scrollBody::-webkit-scrollbar-track {
    background: #f4f5f7;

    border-radius: 10px;
}

/* Keep header cells aligned with scrolled body in scrollX mode */

.dataTables_scrollHead table,
.dataTables_scrollBody table {
    margin: 0 !important;
}

/* =========================================================
   CARD HEADER — inline button variant (no row/col wrapper)
   ========================================================= */

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    font-family: Georgia, "Times New Roman", Times, serif;
    font-size: 16px;
    font-weight: 700;

    color: #212529;
}

.card-header .btn-warning.float-right {
    float: none;
}


/* =========================================================
   MODAL — modernized
   Replace your existing .modal / .modal-dialog / .modal-content /
   .modal-header / .modal-title / .modal-header .close / .modal-body /
   .modal-backdrop block with everything below.
   ========================================================= */

.swal2-container {
    z-index: 1080 !important;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;

    z-index: 1070;

    display: none;

    overflow-x: hidden;
    overflow-y: auto;

    outline: 0;

    padding: 24px;
}

.modal.show {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.modal-dialog {
    position: relative;

    width: 900px;
    max-width: 100%;

    margin: 40px auto;

    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal.fade .modal-dialog {
    transform: translateY(-24px) scale(0.97);
    opacity: 0;
}

.modal.show .modal-dialog {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.modal-content {
    position: relative;

    display: flex;
    flex-direction: column;

    width: 100%;

    background: #ffffff;

    border: 1px solid rgba(0, 0, 0, 0.04);
    border-radius: 22px;

    box-shadow:
        0 30px 70px rgba(0, 0, 0, 0.22),
        0 12px 28px rgba(0, 0, 0, 0.10);

    overflow: hidden;

    outline: 0;
}

/* Slim accent bar across the top, echoing .card's border-top treatment */
.modal-content::before {
    content: "";

    display: block;

    height: 4px;
    width: 100%;

    background: linear-gradient(90deg, #ffc107, rgba(255, 193, 7, 0.25));
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 22px 26px;

    border-bottom: 1px solid rgba(0, 0, 0, 0.06);

    background: linear-gradient(180deg, #fcfcfd 0%, #ffffff 100%);
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 10px;

    margin: 0;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.modal-title i {
    color: #ffc107;
    font-size: 16px;
}

.modal-header .close {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    padding: 0;

    border: none;
    outline: none;

    border-radius: 50%;

    background: rgba(0, 0, 0, 0.045);

    color: #6c757d;

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

    cursor: pointer;

    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.modal-header .close:hover {
    background: rgba(220, 53, 69, 0.12);

    color: #dc3545;

    transform: rotate(90deg);
}

.modal-body {
    padding: 26px;

    max-height: 70vh;

    overflow-y: auto;
}

.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: rgba(255, 193, 7, 0.35);

    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 193, 7, 0.6);
}

/* Optional footer — for modals with Save/Cancel actions */
.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 10px;

    padding: 18px 26px;

    border-top: 1px solid rgba(0, 0, 0, 0.06);

    background: #fcfcfd;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;

    z-index: 1060;

    background: rgba(33, 37, 41, 0.55);

    backdrop-filter: blur(3px);

    opacity: 0;

    transition: opacity 0.25s ease;
}

.modal-backdrop.show {
    opacity: 1;
}

/* =========================================================
   MOBILE — near-fullscreen sheet feel
   ========================================================= */

@media (max-width: 576px) {

    .modal {
        padding: 0;
    }

    .modal.show {
        align-items: stretch;
    }

    .modal-dialog {
        width: 100%;

        margin: 0;

        min-height: 100%;
    }

    .modal-content {
        border-radius: 0;

        min-height: 100vh;
    }

    .modal-header {
        padding: 18px 20px;
    }

    .modal-body {
        padding: 20px;

        max-height: none;
    }

    .modal-footer {
        padding: 16px 20px;

        flex-direction: column-reverse;
        align-items: stretch;
    }

}

/* =========================================================
   FORMS — labels, inputs, selects
   ========================================================= */

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;

    margin-bottom: 7px;

    color: #212529;

    font-family: "Source Sans Pro", sans-serif;

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

.form-group label .text-danger {
    color: #dc3545;

    margin-right: 3px;
}

.form-control {
    display: block;

    width: 100%;

    height: 46px;

    padding: 0 16px;

    border: 1px solid #dee2e6;
    border-radius: 10px;

    background: #ffffff;

    color: #212529;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;

    outline: none;

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

.form-control::placeholder {
    color: #adb5bd;
}

.form-control:focus {
    border-color: #ffc107;

    box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.12);
}

select.form-control {
    appearance: none;
    -webkit-appearance: none;

    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2'%3e%3cpath d='M6 9l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 16px;

    padding-right: 40px;

    cursor: pointer;
}


/* =========================================================
   SELECT2 — override to match theme
   ========================================================= */

.select2-container {
    width: 100% !important;
}

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

    border: 1px solid #dee2e6 !important;
    border-radius: 10px !important;

    background: #ffffff !important;

    display: flex;
    align-items: center;
}

.select2-container .select2-selection--single .select2-selection__rendered {
    padding-left: 16px !important;

    color: #212529;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;

    line-height: normal !important;
}

.select2-container .select2-selection--single .select2-selection__arrow {
    height: 44px !important;

    right: 10px !important;
}

.select2-container--default.select2-container--open .select2-selection--single,
.select2-container--focus .select2-selection--single {
    border-color: #ffc107 !important;

    box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.12);
}

.select2-dropdown {
    border: 1px solid #dee2e6 !important;
    border-radius: 10px !important;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.12),
        0 5px 15px rgba(0, 0, 0, 0.06);

    overflow: hidden;
}

.select2-search--dropdown .select2-search__field {
    border: 1px solid #dee2e6 !important;
    border-radius: 8px !important;

    padding: 6px 10px !important;

    outline: none !important;
}

.select2-results__option {
    padding: 10px 14px !important;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background: rgba(255, 193, 7, 0.15) !important;

    color: #212529 !important;
}

.select2-container--default .select2-results__option[aria-selected="true"] {
    background: rgba(255, 193, 7, 0.3) !important;

    color: #212529 !important;
}


/* =========================================================
   FORM SUBMIT BUTTON (SAVE)
   ========================================================= */

.btn-form {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;

    width: 100%;

    height: 46px;

    border: none;
    outline: none;

    border-radius:10px;

    padding: 20px 30px;

    background: #ffc107;

    color: #212529;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;
    font-weight: 700;

    letter-spacing: 0.5px;

    cursor: pointer;

    transition: background 0.2s ease, transform 0.2s ease;
}

.btn-form:hover {
    background: #e0a800;

    transform: translateY(-2px);
}

.btn-form:disabled,
.btn-form[disabled] {
    background: #e9ecef !important;
    color: #adb5bd !important;

    cursor: not-allowed !important;

    transform: none !important;
    box-shadow: none !important;
}

.btn-form:disabled:hover,
.btn-form[disabled]:hover {
    background: #e9ecef !important;
    transform: none !important;
}

/* =========================================================
   INLINE ACTION BUTTONS (edit / delete icons in table rows)
   ========================================================= */

.btn-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    padding: 0;

    border: none;
    outline: none;

    border-radius: 8px;

    background: transparent;

    font-size: 15px;

    cursor: pointer;

    transition: background 0.2s ease;
}

.btn-link.text-danger {
    color: #dc3545;
}

.btn-link.text-danger:hover {
    background: rgba(220, 53, 69, 0.1);
}

.btn-link.text-primary {
    color: #007bff;
}

.btn-link.text-primary:hover {
    background: rgba(0, 123, 255, 0.1);
}

.border-right {
    margin-right: 4px;
}

/* =========================================================
   FIX: scrollX creates a hidden helper <thead> for column
   sizing — collapse it so only the real header shows
   ========================================================= */

.dataTables_scrollBody thead tr,
.dt-scroll-body thead tr {
    height: 0 !important;
}

.dataTables_scrollBody thead th,
.dataTables_scrollBody thead td,
.dt-scroll-body thead th,
.dt-scroll-body thead td {
    padding: 0 !important;
    border: none !important;

    height: 0 !important;
    line-height: 0 !important;

    font-size: 0 !important;

    overflow: hidden;
}

/* =========================================================
   CARD VARIANT — colored top border + icon title
   ========================================================= */

.card-warning.card-outline {
    border-top: 3px solid #ffc107;
}

.card-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-title i {
    color: #ffc107;
}

.card-title::before {
    display: none; /* suppress the dot bullet from the generic .card-title rule when an icon is already present */
}


/* =========================================================
   VERTICAL PILL TABS (Settings menu)
   ========================================================= */

.nav {
    list-style: none;

    margin: 0;
    padding: 0;
}

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

    gap: 4px;

    border-right: 1px solid rgba(0, 0, 0, 0.06);

    padding-right: 16px;
}

.nav-tabs .nav-link {
    display: block;

    padding: 11px 16px;

    border-radius: 10px;

    color: #495057;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;
    font-weight: 600;

    text-decoration: none !important;

    cursor: pointer;

    transition: background 0.2s ease, color 0.2s ease;
}

.nav-tabs .nav-link:hover {
    background: rgba(255, 193, 7, 0.08);

    color: #212529;
}

.nav-tabs .nav-link.active {
    background: #ffc107;

    color: #212529;
}

.h-100 {
    height: 100%;
}


/* =========================================================
   TAB CONTENT
   ========================================================= */

.tab-content {
    padding-left: 20px;
}

.tab-pane {
    display: none;
}

.tab-pane.active,
.tab-pane.show {
    display: block;
}

.text-left {
    text-align: left;
}


/* =========================================================
   SETTINGS SUB-PANEL HEADER ROW (title + add button)
   ========================================================= */

.row h6 {
    margin: 0;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.btn-xs {
    height: 32px !important;

    padding: 0 14px !important;

    font-size: 12px !important;
}

.ml-3 {
    margin-left: 14px;
}

.mr-1 {
    margin-right: 5px;
}


/* Outline variant of the warning button (Add Sub Offence) */

.btn-outline-warning {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid #ffc107;
    border-radius: 10px;

    background: transparent;

    color: #b98900;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: background 0.2s ease, color 0.2s ease;
}

.btn-outline-warning:hover {
    background: #ffc107;

    color: #212529;
}


/* =========================================================
   NESTED SUB-OFFENCE TABLE (compact list inside a <td>)
   ========================================================= */

td table {
    width: 100%;

    border-collapse: collapse;
}

td table td {
    padding: 6px 0;

    border-bottom: 1px dashed rgba(0, 0, 0, 0.08);

    font-size: 13px;

    color: #495057;
}

td table tr:last-child td {
    border-bottom: none;
}

td table .btn-link {
    width: 28px;
    height: 28px;

    font-size: 13px;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 576px) {

    .nav-tabs.flex-column {
        border-right: none;
        border-bottom: 1px solid rgba(0, 0, 0, 0.06);

        padding-right: 0;
        padding-bottom: 12px;

        margin-bottom: 12px;
    }

    .tab-content {
        padding-left: 0;
    }

}

/* =========================================================
   SETTINGS PANEL HEADER — title + action buttons, spaced out
   ========================================================= */

.settings-panel-header {
    display: flex !important;
    align-items: center;
    justify-content: space-between;

    flex-wrap: wrap;

    gap: 14px;

    margin-bottom: 20px;
}

.settings-panel-header > [class*="col-"] {
    flex: 0 0 auto;
    max-width: none;
    padding: 0;
}

.settings-panel-header .float-right {
    float: none;
}

.settings-panel-header > div:last-child {
    display: flex;
    align-items: center;
    gap: 10px;

    margin-left: auto;
}

.settings-panel-header button {
    margin-bottom: 0 !important;
    border: none;
    background-color: #e0a800;
    border-radius: 10px;
    padding: 20px 30px;
}

/* =========================================================
   TABLE ACTION BUTTONS (Edit / Delete) — pill style with room
   ========================================================= */

.table .btn-link {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;

    width: auto !important;
    height: 34px !important;

    padding: 0 14px !important;

    border-radius: 8px !important;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 600;

    white-space: nowrap;
}

.table .btn-link.text-primary {
    background: rgba(0, 123, 255, 0.08);
}

.table .btn-link.text-primary:hover {
    background: rgba(0, 123, 255, 0.18);
}

.table .btn-link.text-danger {
    background: rgba(220, 53, 69, 0.08);
}

.table .btn-link.text-danger:hover {
    background: rgba(220, 53, 69, 0.18);
}

/* Action button group in the last column */

.table td:last-child {
    white-space: nowrap;
}

.table td:last-child .btn-link {
    margin-right: 8px;
}

.table td:last-child .btn-link:last-child {
    margin-right: 0;
}

.table .btn-link.border-right {
    border-right: none; /* retire the old hack now that gap/margin handles spacing */
}

/* =========================================================
   OFFENCES TABLE — force column proportions so
   Sub Offence sits aside, not pushed below
   ========================================================= */

.settings-offences-table {
    table-layout: fixed;
}

.settings-offences-table th:nth-child(1),
.settings-offences-table td:nth-child(1) {
    width: 5% !important;
}

.settings-offences-table th:nth-child(2),
.settings-offences-table td:nth-child(2) {
    width: 25% !important;

    vertical-align: top;
}

.settings-offences-table th:nth-child(3),
.settings-offences-table td:nth-child(3) {
    width: 45% !important;

    vertical-align: top;
}

.settings-offences-table th:nth-child(4),
.settings-offences-table td:nth-child(4) {
    width: 25% !important;

    vertical-align: top;
}

.settings-card
{
    padding: 20px!important;
}
.settings-card h4
{
    padding-bottom: 20px;
}

.settings-panel-header > div:last-child {
    display: flex;
    align-items: center;
    flex-wrap: wrap;

    gap: 10px;

    margin-left: auto;

    max-width: 100%;
}

body.is-authed .content-wrapper {
    overflow-x: hidden;
}

.settings-panel-header button.btn-xs {
    max-width: 100%;

    white-space: nowrap;
}
/* =========================================
   REPORTS FORM
   ========================================= */

.reports-form {
    width: 100%;
}


/* =========================================
   TWO COLUMN GRID
   ========================================= */

.reports-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 30px;
    row-gap: 22px;
    width: 100%;
}


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

.report-form-group {
    width: 100%;
    min-width: 0;
}


/* =========================================
   LABEL
   ========================================= */

.report-form-group label {
    display: block;

    margin-bottom: 8px;

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

    color: #333;
}


/* =========================================
   INPUTS
   ========================================= */

.report-form-group input,
.report-form-group select {
    display: block;

    width: 100%;
    max-width: 100%;

    min-height: 45px;

    padding: 10px 14px;

    box-sizing: border-box;

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

    color: #333;
    background-color: #fff;

    border: 1px solid #ced4da;
    border-radius: 5px;

    outline: none;

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


/* =========================================
   INPUT FOCUS
   ========================================= */

.report-form-group input:focus,
.report-form-group select:focus {
    border-color: #80bdff;

    box-shadow:
        0 0 0 0.2rem rgba(0, 123, 255, 0.15);
}


/* =========================================
   SELECT2
   ========================================= */

/*
   Select2 sometimes ignores the width of the
   parent container. These rules force it to
   occupy the full column.
*/

.report-form-group .select2-container {
    width: 100% !important;
}

.report-form-group .select2-selection {
    width: 100% !important;

    min-height: 45px !important;

    border: 1px solid #ced4da !important;
    border-radius: 5px !important;
}

.report-form-group
.select2-container--default
.select2-selection--single {

    height: 45px;
}

.report-form-group
.select2-container--default
.select2-selection--single
.select2-selection__rendered {

    line-height: 43px;

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

    color: #333;
}

.report-form-group
.select2-container--default
.select2-selection--single
.select2-selection__arrow {

    height: 43px;
}


/* =========================================
   SELECT2 FOCUS
   ========================================= */

.report-form-group
.select2-container--default.select2-container--focus
.select2-selection--single {

    border-color: #80bdff !important;

    box-shadow:
        0 0 0 0.2rem rgba(0, 123, 255, 0.15);
}


/* =========================================
   LONG DROPDOWN OPTIONS
   ========================================= */

.select2-results__option {
    white-space: normal !important;
    word-wrap: break-word;
    overflow-wrap: break-word;

    line-height: 1.5;
    padding: 10px 12px;
}


/* =========================================
   SUB-OFFENCES
   ========================================= */

.sub-offences-div {
    width: 100%;
}


/* =========================================
   GENERATE BUTTON AREA
   ========================================= */

.report-form-actions {
    display: flex;

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

    width: 100%;

    margin-top: 30px;
}


/* =========================================
   GENERATE BUTTON
   ========================================= */

.generate-report-btn {
    display: flex;

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

    gap: 8px;

    min-width: 220px;

    padding: 12px 25px;

    border: none;
    border-radius: 5px;

    background-color: #ffc107;
    color: #212529;

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

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


.generate-report-btn:hover {
    background-color: #e0a800;

    transform: translateY(-1px);

    box-shadow:
        0 4px 10px rgba(0, 0, 0, 0.12);
}


.generate-report-btn i {
    font-size: 14px;
}


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

@media (max-width: 900px) {

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

}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 576px) {

    .reports-form-grid {
        grid-template-columns: 1fr;

        row-gap: 18px;
    }

    .report-form-actions {
        margin-top: 25px;
    }

    .generate-report-btn {
        width: 100%;
    }

}

/* =========================================
   REPORT FILTER FORM
   ========================================= */

.reports-form {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

/* Two-column form layout */
.reports-form .form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 30px;
}

/* Individual form field */
.reports-form .form-group {
    width: 100%;
    min-width: 0;
}

/* Labels */
.reports-form .form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    line-height: 1.4;
}

/* Standard inputs and selects */
.reports-form .form-control {
    width: 100%;
    height: 46px;
    padding: 0 14px;

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

    background-color: #fff;
    color: #333;

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

    outline: none;
    transition: all 0.2s ease;
}

/* Input focus */
.reports-form .form-control:focus {
    border-color: #f0ad4e;
    box-shadow: 0 0 0 3px rgba(240, 173, 78, 0.12);
}

/* Placeholder */
.reports-form .form-control::placeholder {
    color: #999;
}

/* Month inputs */
.reports-form input[type="month"] {
    cursor: pointer;
}

/* =========================================
   SELECT2
   ========================================= */

.reports-form .select2-container {
    width: 100% !important;
}

/* Select2 visible box */
.reports-form .select2-container .select2-selection--single {
    width: 100%;
    height: 46px;

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

    background-color: #fff;

    display: flex;
    align-items: center;

    transition: all 0.2s ease;
}

/* Select2 text */
.reports-form
.select2-container
.select2-selection--single
.select2-selection__rendered {
    padding-left: 14px;
    padding-right: 40px;

    color: #333;
    font-size: 14px;

    line-height: 44px;

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

/* Select2 arrow */
.reports-form
.select2-container
.select2-selection--single
.select2-selection__arrow {
    height: 44px;
    width: 40px;
    right: 5px;
}

/* Focused Select2 */
.reports-form
.select2-container--focus
.select2-selection--single,

.reports-form
.select2-container--open
.select2-selection--single {
    border-color: #f0ad4e;
    box-shadow: 0 0 0 3px rgba(240, 173, 78, 0.12);
}

/* =========================================
   SELECT2 DROPDOWN
   ========================================= */

.select2-container .select2-dropdown {
    border: 1px solid #d7dce2;
    border-radius: 6px;
    overflow: hidden;

    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

/* Search box inside Select2 */
.select2-container .select2-search--dropdown {
    padding: 10px;
}

.select2-container .select2-search--dropdown input {
    width: 100%;
    height: 40px;

    padding: 0 12px;

    border: 1px solid #d7dce2;
    border-radius: 5px;

    outline: none;
    font-size: 14px;
}

.select2-container .select2-search--dropdown input:focus {
    border-color: #f0ad4e;
}

/* Dropdown options */
.select2-container .select2-results__option {
    padding: 11px 14px;

    font-size: 14px;
    line-height: 1.4;

    white-space: normal;
    word-break: normal;
}

/* Hover / highlighted option */
.select2-container
.select2-results__option--highlighted {
    background-color: #f0ad4e !important;
    color: #fff !important;
}

/* Selected option */
.select2-container
.select2-results__option[aria-selected="true"] {
    background-color: #f7f7f7;
    color: #333;
}

/* =========================================
   SUB-OFFENCES
   ========================================= */

.sub-offences-div {
    width: 100%;
    grid-column: span 2;
}

/* =========================================
   GENERATE REPORT BUTTON
   ========================================= */

.reports-form .form-actions {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.reports-form .generate-report-btn {
    min-width: 220px;
    height: 46px;

    padding: 0 25px;

    border: none;
    border-radius: 6px;

    background: #f0ad4e;
    color: #fff;

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

    cursor: pointer;

    transition: all 0.2s ease;
}

.reports-form .generate-report-btn:hover {
    background: #ec971f;
    transform: translateY(-1px);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.12);
}

.reports-form .generate-report-btn:active {
    transform: translateY(0);
}

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

/* Tablets */
@media (max-width: 900px) {

    .reports-form .form-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .sub-offences-div {
        grid-column: span 1;
    }
}

/* Mobile */
@media (max-width: 600px) {

    .reports-form .form-grid {
        gap: 18px;
    }

    .reports-form .form-control,
    .reports-form
    .select2-container
    .select2-selection--single {
        height: 48px;
    }

    .reports-form
    .select2-container
    .select2-selection--single
    .select2-selection__rendered {
        line-height: 46px;
    }

    .reports-form
    .select2-container
    .select2-selection--single
    .select2-selection__arrow {
        height: 46px;
    }

    .reports-form .generate-report-btn {
        width: 100%;
    }
}

.search-card-body
{
    padding: 20px;
}

.dashboard-copy-btn
{
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: 0 !important;
    border-radius: 10px !important;

    background: #245bde !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    text-decoration: none !important;

    cursor: pointer !important;

    transition: all 0.2s ease !important;
}

.dashboard-csv-btn
{
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: 0 !important;
    border-radius: 10px !important;

    background: #e7b922 !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    text-decoration: none !important;

    cursor: pointer !important;

    transition: all 0.2s ease !important;
}

/* =========================================
   CASE NUMBER DROPDOWN
   ========================================= */

.case-dropdown {
    display: inline-block;
    position: relative;
}

.case-number {
    display: inline-flex;
    align-items: center;
    gap: 5px;

    color: #007bff;
    font-weight: 600;

    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
}

.case-number:hover {
    color: #0056b3;
    text-decoration: none;
}


/* =========================================
   ORANGE DROPDOWN MENU
   ========================================= */

.case-dropdown-menu {
    min-width: 260px;
    width: max-content;
    max-width: 350px;

    padding: 5px 0;

    background-color: #ffffff; /* ORANGE */

    border: #d7dce2;
    border-radius: 5px;

    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);

    z-index: 99999;

    max-height: none !important;
    overflow: visible !important;
}


/* =========================================
   MENU ITEMS
   ========================================= */

.case-dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;

    min-height: 38px;

    padding: 9px 14px;

    font-size: 13px;

    color: #212529;

    white-space: nowrap;
}


/* Icons */
.case-dropdown-menu .dropdown-item i {
    width: 24px;
    min-width: 24px;

    margin-right: 8px;

    text-align: center;
}


/* Hover */
.case-dropdown-menu .dropdown-item:hover {
    background-color: #e0a800;
    color: #ffffff;
}


/* Divider */
.case-dropdown-menu .dropdown-divider {
    border-top: 1px solid rgba(0, 0, 0, 0.15);
    margin: 3px 0;
}

/* =========================================
   OPEN DROPDOWN UPWARDS
   ========================================= */

.case-dropdown.dropup .case-dropdown-menu {
    top: auto !important;
    bottom: 100% !important;

    margin-top: 0 !important;
    margin-bottom: 6px !important;
}

.col-5     { flex: 0 0 41.666%; max-width: 41.666%; }
.col-7     { flex: 0 0 58.333%; max-width: 58.333%; }
.col-sm-3  { flex: 0 0 25%;     max-width: 25%; }
.col-sm-9  { flex: 0 0 75%;     max-width: 75%; }

@media (min-width: 576px) {
    .col-sm-3 { flex: 0 0 25%; max-width: 25%; }
    .col-sm-9 { flex: 0 0 75%; max-width: 75%; }
}

/* =========================================================
   FLOATING LABEL INPUTS (.form-label-group.outline)
   ========================================================= */

.form-label-group {
    position: relative !important;

    margin-bottom: 18px !important;
}

.form-label-group input,
.form-label-group textarea,
.form-label-group select {
    display: block !important;

    width: 100% !important;

    height: 52px !important;

    padding: 20px 16px 6px !important;

    border: 1px solid #dee2e6 !important;
    border-radius: 10px;

    background: #ffffff !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 14px !important;

    outline: none !important;

    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.form-label-group textarea {
    height: auto !important;
    min-height: 90px !important;

    padding-top: 22px !important;

    resize: vertical !important;
}

.form-label-group input:focus,
.form-label-group textarea:focus,
.form-label-group select:focus {
    border-color: #ffc107 !important;

    box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.12) !important;
}

.form-label-group span label {
    position: absolute !important;

    top: 16px !important;
    left: 17px !important;

    margin: 0 !important;

    color: #adb5bd !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 14px !important;
    font-weight: 400 !important;

    pointer-events: none !important;

    transition: all 0.15s ease !important;

    background: transparent !important;
}

.form-label-group input:focus ~ span label,
.form-label-group input:not(:placeholder-shown) ~ span label,
.form-label-group input:valid ~ span label,
.form-label-group textarea:focus ~ span label,
.form-label-group textarea:not(:placeholder-shown) ~ span label,
.form-label-group select:focus ~ span label,
.form-label-group select:valid ~ span label {
    top: 6px !important;

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

    color: #b98900 !important;
}

/* Selects always show a value, so always float their label */
.form-label-group select ~ span label {
    top: 6px !important;

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

    color: #6c757d !important;
}


/* =========================================================
   REQUIRED FIELD INDICATOR
   ========================================================= */

label.required::after {
    content: " *";

    color: #dc3545 !important;
}


/* =========================================================
   DETAIL VIEW TABLES (bordered variant + text helpers)
   ========================================================= */

.table-bordered {
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

.table-bordered td,
.table-bordered th {
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

.font-weight-bold {
    font-weight: 700 !important;
}

.text-uppercase {
    text-transform: uppercase !important;
}

.modal-body h6 {
    margin: 22px 0 10px !important;

    color: #212529 !important;

    font-family: Georgia, "Times New Roman", Times, serif !important;

    font-size: 15px !important;
    font-weight: 700 !important;
}

.modal-body .row:first-child h6 {
    margin-top: 0 !important;
} 


/* Subtle hover highlight for detail-view row groups */
.hvr.hvr-glow {
    transition: box-shadow 0.2s ease !important;
}

.hvr.hvr-glow:hover {
    box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.08) !important;

    border-radius: 12px !important;
}


/* =========================================================
   BRANDED BUTTON / HEADER CLASSES — mapped to theme
   ========================================================= */

.modal-header.bg-odpp {
    background: linear-gradient(180deg, #fcfcfd 0%, #ffffff 100%) !important;
}

.btn-odpp {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important; 

    gap: 8px !important;

    height: 46px !important;

    border: none !important;
    outline: none !important;

    background: #ffc107 !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 14px !important;
    font-weight: 700 !important;

    letter-spacing: 0.5px !important;

    cursor: pointer !important;

    transition: background 0.2s ease, transform 0.2s ease !important;
}

.btn-odpp:hover {
    background: #e0a800 !important;

    transform: translateY(-2px) !important;
}


/* =========================================================
   BUTTON UTILITIES
   ========================================================= */

.rounded-pill {
    border-radius: 50px !important;
}

.btn-block {
    display: flex !important;
    width: 100%;
}

.select2-container--open .select2-dropdown {
    z-index: 1075;
}

#appHeader.main-header .dropdown-menu,
.main-header .nav-item.dropdown .dropdown-menu {
    left: auto !important;
    right: 0 !important;
}

.main-header .dropdown-menu.dropdown-menu-lg {
    max-width: calc(100vw - 20px);
    max-height: 75vh;
    overflow-y: auto;
}

.main-header .dropdown-menu .dropdown-item {
    white-space: normal;
    word-break: break-word;
}

/* =========================================================
   MODAL SECTION DIVIDER (between an "add new" form and a
   list below it — e.g. Manage Accused Persons, Case Offences)
   ========================================================= */

.modal-section-divider {
    margin: 28px 0 18px;

    border: none;
    border-top: 1px solid rgba(0, 0, 0, 0.07);
}

/* Sub-heading right under the divider ("Current Accused Persons") */

.modal-section-title {
    display: flex;
    align-items: center;
    gap: 8px;

    margin: 0 0 14px !important;

    color: #212529;

    font-family: Georgia, "Times New Roman", Times, serif;

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

.modal-section-title i {
    color: #ffc107;

    font-size: 13px;
}


/* =========================================================
   TIGHTER, MORE BREATHABLE FORM ROWS INSIDE MODALS
   ========================================================= */

.modal-body form .row + .row {
    margin-top: 4px;
}

.modal-body .form-group {
    margin-bottom: 16px;
}


/* =========================================================
   EMPTY STATE ROW (list has no records yet)
   ========================================================= */

.table-empty-state {
    padding: 28px 0 !important;

    color: #adb5bd;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-style: italic;

    text-align: center;
}


/* =========================================================
   SMALL ICON-ONLY DELETE BUTTON IN LIST ROWS
   (adds a subtle press/hover affordance on top of the
   existing .btn-link.text-danger base style)
   ========================================================= */

.table .btn-link.text-danger.icon-only {
    width: 32px !important;
    height: 32px !important;

    padding: 0 !important;

    border-radius: 50% !important;
}

.table .btn-link.text-danger.icon-only:active {
    transform: scale(0.92);
}

/* =========================================================
   SMALL LABELED DELETE BUTTON (table rows)
   e.g. <button class="btn btn-xs btn-danger">Delete</button>
   ========================================================= */

.btn.btn-danger {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 6px !important;

    border: none !important;
    outline: none !important;

    border-radius: 8px !important;

    background: #dc3545 !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-weight: 700 !important;

    letter-spacing: 0.3px;

    cursor: pointer !important;

    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease !important;
}

.btn.btn-danger i {
    font-size: 0.95em;
}

.btn.btn-danger:hover {
    background: #c82333 !important;

    transform: translateY(-1px);

    box-shadow: 0 4px 10px rgba(220, 53, 69, 0.25);
}

.btn.btn-danger:active {
    transform: translateY(0) scale(0.97);
}

/* .btn-xs sets height/padding/font-size already — this just
   keeps the danger button's own vertical rhythm consistent
   with that sizing so icon + text center correctly */

.btn-xs.btn-danger {
    height: 30px !important;

    padding: 0 12px !important;

    font-size: 12px !important;
}

/* =========================================================
   CUSTOM BADGE COLOR PALETTE (case status badges)
   Replaces the old Bootstrap-named badge-primary/secondary/etc.
   ========================================================= */

.badge-green   { background: #16a34a; color: #ffffff; }
.badge-red     { background: #dc2626; color: #ffffff; }
.badge-amber   { background: #ffc107; color: #212529; }
.badge-purple  { background: #7c3aed; color: #ffffff; }
.badge-slate   { background: #475569; color: #ffffff; }
.badge-teal    { background: #0d9488; color: #ffffff; }
.badge-blue    { background: #2f6fed; color: #ffffff; }
.badge-cyan    { background: #0891b2; color: #ffffff; }
.badge-indigo  { background: #4338ca; color: #ffffff; }
.badge-brown   { background: #78350f; color: #ffffff; }
.badge-orange  { background: #ea580c; color: #ffffff; }
.badge-pink    { background: #db2777; color: #ffffff; }
.badge-gray    { background: #9ca3af; color: #212529; }

/* Fallback if color is ever missing from the DB */
.badge:not([class*="badge-"]),
span.badge.badge- {
    background: #0755ff !important;
    color: #ffffff !important;
}

/* =========================================================
   UTILITY: HIDE ELEMENT
   Bootstrap's .d-none was removed along with Bootstrap CSS —
   this restores it since app JS still toggles this class
   ========================================================= */

.d-none {
    display: none !important;
}

/* =========================================================
   CASE CLOSED BANNER
   ========================================================= */

.case-closed-banner {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 14px 18px;

    margin-bottom: 20px;

    border-radius: 10px;

    background: rgba(220, 53, 69, 0.08);
    border: 1px solid rgba(220, 53, 69, 0.2);

    color: #a71d2a;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 14px;
    font-weight: 600;
}

.case-closed-banner i {
    font-size: 16px;
}

/* =========================================================
   LEAVE CALENDAR
   ========================================================= */

.leave-calendar-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 14px;

    margin-bottom: 20px;
}

.leave-calendar-jump {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.leave-calendar-jump select {
    height: 40px;
    padding: 0 30px 0 14px;

    border: 1px solid #dee2e6;
    border-radius: 10px;

    background: #ffffff;
    color: #212529;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 600;

    outline: none;
    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;

    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2'%3e%3cpath d='M6 9l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;

    transition: border-color 0.2s ease;
}

.leave-calendar-jump select:focus {
    border-color: #ffc107;
}

.leave-view-switch {
    display: flex;
    gap: 6px;
}

.leave-view-switch button {
    height: 40px;
    padding: 0 18px;

    border: 1px solid #dee2e6;
    border-radius: 10px;

    background: #ffffff;
    color: #495057;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: all 0.2s ease;
}

.leave-view-switch button:hover {
    background: rgba(255, 193, 7, 0.1);
    border-color: #ffc107;
}

.leave-view-switch button.active {
    background: #ffc107;
    border-color: #ffc107;
    color: #212529;
}

/* Calendar shell */

#leave-calendar {
    font-family: "Source Sans Pro", sans-serif;
}

#leave-calendar .fc {
    --fc-border-color: rgba(0, 0, 0, 0.06);
    --fc-today-bg-color: rgba(255, 193, 7, 0.08);
    --fc-neutral-bg-color: #f8f9fa;
    --fc-page-bg-color: #ffffff;
}

#leave-calendar .fc-toolbar-title {
    font-family: Georgia, "Times New Roman", Times, serif;
    font-size: 20px;
    font-weight: 700;
    color: #212529;
}

#leave-calendar .fc-button {
    background: #ffffff !important;
    border: 1px solid #dee2e6 !important;
    color: #495057 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-weight: 600 !important;
    text-transform: capitalize !important;

    box-shadow: none !important;

    transition: all 0.2s ease !important;
}

#leave-calendar .fc-button:hover {
    background: rgba(255, 193, 7, 0.1) !important;
    border-color: #ffc107 !important;
    color: #212529 !important;
}

#leave-calendar .fc-button-active,
#leave-calendar .fc-button-primary:not(:disabled).fc-button-active {
    background: #ffc107 !important;
    border-color: #ffc107 !important;
    color: #212529 !important;
}

#leave-calendar .fc-daygrid-day-number {
    color: #495057;
    font-weight: 600;
    font-size: 12px;
}

#leave-calendar .fc-col-header-cell {
    background: #f8f9fa;
}

#leave-calendar .fc-col-header-cell-cushion {
    color: #6c757d;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none !important;
}

#leave-calendar .fc-daygrid-day-frame {
    transition: background 0.15s ease;
}

#leave-calendar .fc-daygrid-day:hover .fc-daygrid-day-frame {
    background: rgba(0, 0, 0, 0.015);
}

/* Event pills */

#leave-calendar .fc-event {
    border: none !important;
    border-radius: 6px !important;

    padding: 2px 6px;

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

    cursor: pointer;
}

#leave-calendar .fc-daygrid-event-dot {
    display: none;
}

/* Multi-month year view */

#leave-calendar .fc-multimonth {
    gap: 20px;
}

#leave-calendar .fc-multimonth-month {
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    overflow: hidden;
}

#leave-calendar .fc-multimonth-title {
    background: #f8f9fa;
    font-family: Georgia, "Times New Roman", Times, serif;
    font-weight: 700;
    padding: 10px;
}

/* Legend */

.leave-calendar-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;

    margin-top: 18px;
    padding-top: 16px;

    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.leave-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;

    font-family: "Source Sans Pro", sans-serif;
    font-size: 13px;
    color: #495057;
}

.leave-legend-swatch {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex: 0 0 auto;
}

@media (max-width: 576px) {
    .leave-calendar-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .leave-calendar-jump,
    .leave-view-switch {
        justify-content: center;
    }
}

.leave-card
{
    padding: 20px;
}

.leave-btn
{
    padding: 10px 30px;
    outline: none;
    background-color: #d2a233;
    border: none;
    color: #ffffff;
    box-shadow: rgba(50, 50, 93, 0.25) 0px 50px 100px -20px, rgba(0, 0, 0, 0.3) 0px 30px 60px -30px, rgba(10, 37, 64, 0.35) 0px -2px 6px 0px inset;
}

.leave-btn:hover
{
    box-shadow: rgba(50, 50, 93, 0.25) 0px 30px 60px -12px inset, rgba(0, 0, 0, 0.3) 0px 18px 36px -18px inset;
}

/* =========================================================
   LEAVE PAGE ACTION BUTTONS
   ========================================================= */

.btn-set-leave {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: none !important;
    outline: none !important;

    border-radius: 10px !important;

    background: #ffc107 !important;

    color: #212529 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    letter-spacing: 0.3px;

    cursor: pointer !important;

    transition: background 0.2s ease, transform 0.2s ease !important;
}

.btn-set-leave:hover {
    background: #e0a800 !important;
    transform: translateY(-1px);
}

.btn-predict-leave {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 8px !important;

    height: 40px !important;

    padding: 0 18px !important;

    border: 1px solid #ffc107 !important;
    outline: none !important;

    border-radius: 10px !important;

    background: transparent !important;

    color: #b98900 !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;

    letter-spacing: 0.3px;

    cursor: pointer !important;

    margin-right: 8px;

    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease !important;
}

.btn-predict-leave:hover {
    background: #ffc107 !important;
    color: #212529 !important;
    transform: translateY(-1px);
}

@media (max-width: 576px) {
    .btn-predict-leave,
    .btn-set-leave {
        width: 100%;
        margin-right: 0;
        margin-bottom: 8px;
    }
}

/* =========================================================
   ATTENDANCE NOTE DOWNLOAD BUTTON
   ========================================================= */

.btn.btn-primary {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    gap: 6px !important;

    border: none !important;
    outline: none !important;

    border-radius: 8px !important;

    background: #ff8400 !important;
    background-image: none !important;

    color: #ffffff !important;

    font-family: "Source Sans Pro", sans-serif !important;
    font-weight: 700 !important;

    letter-spacing: 0.3px;

    text-decoration: none !important;

    cursor: pointer !important;

    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease !important;
}

.btn.btn-primary i {
    font-size: 0.95em;
}

.btn.btn-primary:hover {
    background: #ff8400 !important;

    color: #ffffff !important;

    transform: translateY(-1px);

    box-shadow: 0 4px 10px rgba(255, 102, 0, 0.25);
}

.btn.btn-primary:active {
    transform: translateY(0) scale(0.97);
}

/* .btn-xs sets height/padding/font-size already — this just
   keeps the primary button's vertical rhythm consistent
   with that sizing so icon + text center correctly, same
   pattern as .btn-xs.btn-danger */
.btn-xs.btn-primary {
    height: 30px !important;

    padding: 0 12px !important;

    font-size: 12px !important;
}
/* =========================================================
   COURT CALENDAR — UPCOMING MATTERS FILTERS
   ========================================================= */

.court-matters-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 16px;

    margin-bottom: 20px;
    padding-bottom: 18px;

    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.court-matters-filters .form-group {
    margin-bottom: 0;
    min-width: 160px;
}

.court-matters-filter-actions {
    display: flex;
    align-items: flex-end;
}

@media (max-width: 576px) {
    .court-matters-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .court-matters-filters .form-group {
        min-width: 100%;
    }
}

.calendar-body
{
    padding: 20px;
}