/* =========================
HEADER
========================= */

.app-header {
    background:
        linear-gradient(
            135deg,
            #0d5c2f 0%,
            #198754 55%,
            #146c43 100%
        );
    z-index: 1030;
}

.header-top {
    backdrop-filter: blur(12px);
}

.header-nav {
    background: rgba(255,255,255,0.08);
    border-top: 1px solid rgba(255,255,255,0.08);
}

/* =========================
BRAND
========================= */

.brand-logo{
    width: 70px;
    height: 90px;
    object-fit: contain;
}

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

    .brand-logo{
        width: 48px;
        height: 62px;
    }

}

.brand-title {
    letter-spacing: -0.5px;
}

.brand-subtitle {
    font-size: .95rem;
    opacity: .9;
}

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

.user-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 999px;
    padding: 8px 14px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.08);
}

.user-dropdown-btn:hover {
    background: rgba(255,255,255,0.14);
}

.user-avatar {
    width: 42px;
    height: 42px;
    object-fit: cover;
    border-radius: 50%;
}

/* =========================
NAV
========================= */

.nav-modern-link,
.nav-link {
    color: rgba(255,255,255,0.92) !important;
    padding: 12px 18px !important;
    border-radius: 999px;
    font-weight: 500;
    transition: all .25s ease;
}

.nav-modern-link:hover,
.nav-link:hover {
    background: rgba(255,255,255,0.12);
    color: #fff !important;
}

.active-nav {
    background: #ffc107;
    color: #212529 !important;
    font-weight: 700;
}

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

.dropdown-menu {
    min-width: 240px;
    border-radius: 18px;
    border: 1px solid rgba(0,0,0,.06);
    box-shadow: 0 10px 30px rgba(0,0,0,.08);
    padding: 10px;
    background: #fff;
}

/* FIXED LIGHT MODE TEXT */
.dropdown-menu .dropdown-item {
    color: #212529 !important;
    border-radius: 10px;
    transition: .2s ease;
    padding: 10px 14px;
    font-weight: 500;
}

.dropdown-menu .dropdown-item:hover {
    background: #f8f9fa;
    color: #212529 !important;
    transform: translateX(2px);
}

/* Dropdown toggle arrow */
.dropdown-toggle::after {
    margin-left: 6px;
}

/* FORCE TEXT COLOR INSIDE MORE MENU */
#moreMenu .nav-link,
#moreMenu .dropdown-item,
#moreMenu a {
    color: #212529 !important;
    background: transparent !important;
}

/* Hover */
#moreMenu .nav-link:hover,
#moreMenu .dropdown-item:hover,
#moreMenu a:hover {
    color: #212529 !important;
    background: #f8f9fa !important;
}

/* =========================
OFFCANVAS
========================= */

.offcanvas {
    border-top-right-radius: 24px;
    border-bottom-right-radius: 24px;
}

/* 🔥 FULLSCREEN SIDEBAR OVER HEADER */
.offcanvas {
    width: 100vw !important;
    z-index: 2000 !important;
}

/* Dark overlay */
.offcanvas-backdrop.show {
    opacity: 0.7;
}

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

@media (max-width: 768px) {

    .navbar-nav {
        flex-direction: column !important;
    }

    .nav-link {
        text-align: left;
        padding: 12px 10px !important;
        font-size: 1.05rem;
    }

    .brand-title {
        font-size: 1rem;
    }

    .brand-subtitle {
        font-size: .8rem;
    }

    .dropdown-item {
        padding-left: 20px;
    }

    .dropdown-menu {
        border-radius: 14px;
    }
}

/* =========================
CAROUSEL
========================= */

.carousel-slide {
    height: 25rem;
    position: relative;
}

.carousel-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.carousel-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 122, 51, 0.85);

    clip-path: polygon(60% 0, 100% 0, 100% 100%, 40% 100%);
}

.carousel-caption-custom {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-end;
    padding: 2rem;
    z-index: 2;
}

@media (max-width: 768px) {

    .carousel-slide {
        height: 18rem;
    }

    .carousel-caption-custom {
        align-items: flex-start;
        text-align: left;
    }

    .carousel-overlay {
        clip-path: none;
    }
}

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

footer a i {
    transition: 0.2s ease-in-out;
}

footer a:hover i {
    transform: translateY(-2px);
    color: #0d6efd;
}

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

#mobileUsersCards .card {
    transition: all 0.2s ease;
}

#mobileUsersCards .card:active {
    transform: scale(0.98);
}

#mobileUsersCards .badge {
    font-size: 0.68rem;
    font-weight: 500;
}

/* =========================
REPORTS
========================= */

.report-card {
    transition: all .25s ease;
}

.report-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 1rem 2rem rgba(0,0,0,.08) !important;
}

.report-icon {
    width: 75px;
    height: 75px;
    border-radius: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

/* =========================
DARK MODE
========================= */

[data-bs-theme="dark"] {

    --bs-body-bg: #121212;
    --bs-body-color: #f8f9fa;

}

/* Cards */
[data-bs-theme="dark"] .card {
    background: #1e1e1e;
    border-color: rgba(255,255,255,.08);
}

/* Tables */
[data-bs-theme="dark"] .table {
    --bs-table-bg: transparent;
    --bs-table-color: #f8f9fa;
}

/* Dropdown */
[data-bs-theme="dark"] .dropdown-menu {
    background: #1f1f1f;
    border-color: rgba(255,255,255,.08);
}

/* FIXED DARK MODE DROPDOWN TEXT */
[data-bs-theme="dark"] .dropdown-menu .dropdown-item {
    color: #f8f9fa !important;
}

[data-bs-theme="dark"] .dropdown-menu .dropdown-item:hover {
    background: rgba(255,255,255,0.08);
    color: #fff !important;
}

/* Forms */
[data-bs-theme="dark"] .form-control {
    background: #1f1f1f;
    border-color: rgba(255,255,255,.08);
    color: #fff;
}

[data-bs-theme="dark"] .form-control:focus {
    background: #1f1f1f;
    color: #fff;
}

/* Optional navbar dark enhancement */
[data-bs-theme="dark"] .header-nav {
    background: rgba(0,0,0,0.2);
}

/* Dark mode */
[data-bs-theme="dark"] #moreMenu .nav-link,
[data-bs-theme="dark"] #moreMenu .dropdown-item,
[data-bs-theme="dark"] #moreMenu a {
    color: #f8f9fa !important;
}

[data-bs-theme="dark"] #moreMenu .nav-link:hover,
[data-bs-theme="dark"] #moreMenu .dropdown-item:hover,
[data-bs-theme="dark"] #moreMenu a:hover {
    background: rgba(255,255,255,0.08) !important;
    color: #fff !important;
}