/* =========================================================
   1. SIDEBAR STYLES (Glassmorphism & Navigation)
   ========================================================= */
.glass-sidebar {
    background: rgba(10, 61, 98, 0.92) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    min-height: 100vh;
    width: 280px;
    transition: margin 0.3s ease-in-out;
}

.list-group-item-sidebar {
    color: rgba(255, 255, 255, 0.7);
    padding: 0.8rem 1.5rem;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    position: relative;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.list-group-item-sidebar:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #FFBB5C;
    transform: translateX(5px);
}

.list-group-item-sidebar.active {
    background: rgba(255, 187, 92, 0.15) !important;
    color: #FFBB5C !important;
    border-left: 4px solid #FFBB5C !important;
}

#page-content-wrapper {
    padding-top: 72px; /* same as header height */
}

/* =========================================================
   2. HEADER & NAVIGATION (Floating Fixes)
   ========================================================= */
.floating-header {
    position: fixed;
    top: 20px;
    right: 0;
    left: 0;
    height: 72px; 
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Header adjust when sidebar is visible */
#wrapper:not(.toggled) .floating-header {
    left: 280px;
}

.glass-nav-container {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-wrap: nowrap !important;
    align-items: center;
}

/* SEARCH BAR FIX: Allow shrinking to prevent covering the name */
.search-bar-container {
    position: relative;
    background: rgba(0, 0, 0, 0.03);
    border-radius: 50px;
    padding: 0 15px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    max-width: 400px;
    min-width: 150px; /* Ensures it doesn't disappear completely */
    flex-grow: 1;    /* Takes available space */
    flex-shrink: 1;  /* Shrinks first when space is tight */
    margin-right: 1.5rem;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.search-input {
    background: transparent;
    border: none;
    padding: 8px 10px 8px 30px;
    width: 100%;
    outline: none;
    font-size: 14px;
}

.search-icon {
    position: absolute;
    left: 15px;
    color: #64748b;
}

/* PROFILE FIX: Stay fixed on the right */
.user-profile-glass {
    min-width: fit-content;
    flex-shrink: 0; /* Prevents name/email from squishing */
    flex-grow: 0 !important;
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.avatar-glass {
    width: 40px;
    height: 40px;
    background: linear-gradient(45deg, #0A3D62, #1e3c72);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: bold;
    border: 2px solid white;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* =========================================================
   3. COMPONENTS (Cards & Gold Hover Effects)
   ========================================================= */
.dashboard-main-grid {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* GOLD BOUNDARY EFFECT */
.glass-card-light, 
.glass-card-dark, 
.lead-item, 
.stat-card,
.lead-item-glass {
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    position: relative;
    overflow: hidden;
}
.border-bottom-faint { border-bottom: 1px solid rgba(0,0,0,0.05); }

.glass-card-light, .glass-card-dark, .lead-item {
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.stat-card:hover,
.lead-item-glass:hover {
    transform: translateY(-5px);
    border: 1.5px solid #FFBB5C !important; /* Gold Boundary */
    box-shadow: 0 12px 24px rgba(255, 187, 92, 0.15) !important;
}

.glass-card-dark {
    background: linear-gradient(135deg, rgba(10, 61, 98, 0.95), rgba(0, 0, 0, 0.9));
    backdrop-filter: blur(10px);
    border-radius: 20px;
}

.glass-progress {
    height: 10px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.05);
}

/* Icons & Notification dots */
.glass-icon-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 12px;
    cursor: pointer;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: #FF6B35;
    border-radius: 50%;
    border: 2px solid white;
}

/* =========================================================
   4. UTILITIES & RESPONSIVE
   ========================================================= */
.bg-light-soft {
    background-color: #f1f5f9;
}

.animate-pulse {
    animation: pulse-gold 2s infinite;
}

@keyframes pulse-gold {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); opacity: 0.8; }
    100% { transform: scale(1); }
}

@media (max-width: 992px) {
    .search-bar-container { max-width: 200px !important; }
    #wrapper:not(.toggled) .floating-header { left: 0; padding: 0 10px; }
}

#current-dashboard-time {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    color: var(--zenzele-blue);
    letter-spacing: 0.5px;
}

.badge.bg-white.border {
    transition: all 0.3s ease;
}

/* Make the clock badge glow slightly like the other glass cards */
.badge.bg-white.border:hover {
    border-color: #FFBB5C !important;
    box-shadow: 0 4px 12px rgba(255, 187, 92, 0.2) !important;
}