/* Global Styles */
body {
    background-color: #eef6fc;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Register & Dashboard Prefix */
.db-card, .login-card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}

.db-btn-primary {
    border-radius: 8px;
    padding: 10px 24px;
    transition: all 0.3s ease;
}

/* Footer Styling */
footer a {
    text-decoration: none !important;
    transition: color 0.2s;
}

/* Dashboard Wrapper & Sidebar Layout */
#wrapper {
    overflow-x: hidden;
    display: flex;
    width: 100%;
}

#sidebar-wrapper {
    min-height: 100vh;
    width: 250px;
    margin-left: 0;
    transition: margin 0.25s ease-out;
    background-color: #1e293b; /* Dark Navy Slate */
    border-right: 1px solid #334155;
    z-index: 1000;
}

#sidebar-wrapper .sidebar-heading {
    padding: 1.5rem 1.25rem;
    font-size: 1.25rem;
    font-weight: 700;
    border-bottom: 1px solid #334155;
    color: #f8fafc;
}

#sidebar-wrapper .list-group {
    width: 250px;
}

#sidebar-wrapper .list-group-item {
    padding: 0.85rem 1.5rem;
    color: #94a3b8;
    background-color: transparent;
    border: none;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
    border-left: 4px solid transparent;
}

#sidebar-wrapper .list-group-item:hover {
    color: #f1f5f9;
    background-color: #334155;
    padding-left: 1.85rem;
}

#sidebar-wrapper .list-group-item.active {
    color: #38bdf8; /* Vibrant Sky Blue */
    background-color: #1e293b;
    border-left-color: #38bdf8;
    font-weight: 600;
}

#page-content-wrapper {
    min-width: 100vw;
    width: 100%;
    background-color: #eef6fc;
}

/* Sidebar Toggle functionality */
#wrapper.toggled #sidebar-wrapper {
    margin-left: -250px;
}

@media (min-width: 768px) {
    #page-content-wrapper {
        min-width: 0;
        width: 100%;
    }
}

@media (max-width: 767.98px) {
    #sidebar-wrapper {
        margin-left: -250px;
        position: fixed;
        height: 100%;
        top: 0;
        left: 0;
        overflow-y: auto;
    }
    #wrapper.toggled #sidebar-wrapper {
        margin-left: 0;
    }
}

/* Dashboard Premium Components */
.gradient-banner {
    background: linear-gradient(135deg, #0284c7 0%, #4f46e5 100%);
    color: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(79, 70, 229, 0.15);
}

.stat-card {
    border: none;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

/* ==========================================================
   Global Responsive Data View (Desktop Table vs Mobile Card)
   ========================================================== */

/* Default hide mobile view */
.mobile-card-view {
    display: none;
}

/* Base styles for the mobile cards to ensure premium look */
.mobile-card-view .card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    margin-bottom: 1rem;
    transition: transform 0.2s;
}

.mobile-card-view .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
}

.mobile-card-view .card-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

/* When on small screens (mobile/tablet up to 768px) */
@media (max-width: 768px) {
    .desktop-table-view {
        display: none !important;
    }
    .mobile-card-view {
        display: block !important;
    }
}

/* When on large screens (desktop > 768px) */
@media (min-width: 769px) {
    .desktop-table-view {
        display: block !important;
    }
    .mobile-card-view {
        display: none !important;
    }
}

/* ==========================================================
   Scroll to Top Button
   ========================================================== */
#scrollToTopBtn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1050;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: #0284c7;
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(2, 132, 199, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease-in-out;
    cursor: pointer;
}

#scrollToTopBtn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#scrollToTopBtn:hover {
    background-color: #0369a1;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(2, 132, 199, 0.6);
}