/* ============================================
   CUSTOM WORDPRESS ADMIN SIDEBAR STYLING
   Colorful design with provincial branding
   ============================================ */

/* Admin Sidebar - Colorful Gradient Background */
#adminmenuback,
#adminmenuwrap,
#adminmenu,
#adminmenu .wp-submenu {
    background: linear-gradient(180deg, #1F4E79 0%, #6B46C1 100%) !important;
}

#adminmenuback {
    background: linear-gradient(180deg, #1F4E79 0%, #6B46C1 100%) !important;
}

/* WordPress Logo Replacement */
#wpadminbar #wp-admin-bar-wp-logo > .ab-item {
    padding: 0 12px !important;
    width: 36px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#wpadminbar #wp-admin-bar-wp-logo > .ab-item .ab-icon {
    width: 32px !important;
    height: 32px !important;
    margin: 0 !important;
    background: transparent !important;
    background-image: url('../images/logo.png') !important;
    background-size: contain !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

#wpadminbar #wp-admin-bar-wp-logo > .ab-item .ab-icon:before {
    content: '' !important;
    display: none !important;
}

/* Hide WordPress "W" logo icon */
#wpadminbar #wp-admin-bar-wp-logo > .ab-item .ab-icon svg {
    display: none !important;
}

/* Admin Menu Items - Enhanced Colors */
#adminmenu a {
    color: rgba(255, 255, 255, 0.9) !important;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

#adminmenu li.wp-menu-separator {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin: 8px 0;
}

/* Menu Item Hover - Colorful Gradient */
#adminmenu a:hover,
#adminmenu a:focus {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.3) 0%, rgba(139, 92, 246, 0.3) 100%) !important;
    color: #ffffff !important;
    border-left-color: #3B82F6;
    transform: translateX(2px);
}

/* Active/Current Menu Item - Bright Highlight */
#adminmenu li.current a,
#adminmenu li.wp-has-current-submenu a,
#adminmenu li.wp-has-current-submenu .wp-submenu li.current a,
#adminmenu li.wp-has-current-submenu .wp-submenu li a:hover,
#adminmenu li.wp-has-current-submenu .wp-submenu li a:focus {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.5) 0%, rgba(139, 92, 246, 0.5) 100%) !important;
    color: #ffffff !important;
    border-left-color: #D4AF37;
    font-weight: 600;
    box-shadow: inset 0 0 20px rgba(212, 175, 55, 0.2);
}

/* Submenu Styling */
#adminmenu .wp-submenu {
    background: linear-gradient(180deg, rgba(31, 78, 121, 0.95) 0%, rgba(107, 70, 193, 0.95) 100%) !important;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.2);
}

#adminmenu .wp-submenu a {
    color: rgba(255, 255, 255, 0.8) !important;
    padding-left: 36px !important;
}

#adminmenu .wp-submenu a:hover,
#adminmenu .wp-submenu a:focus {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.4) 0%, rgba(139, 92, 246, 0.4) 100%) !important;
    color: #ffffff !important;
    padding-left: 40px;
}

/* Menu Icons - Enhanced with Color */
#adminmenu .wp-menu-image:before {
    color: rgba(255, 255, 255, 0.9) !important;
    transition: all 0.3s ease;
}

#adminmenu li:hover .wp-menu-image:before,
#adminmenu li.current .wp-menu-image:before {
    color: #D4AF37 !important;
    transform: scale(1.1);
}

/* Notification Bubbles - Colorful */
#adminmenu .awaiting-mod,
#adminmenu .update-plugins {
    background: linear-gradient(135deg, #EF4444 0%, #F59E0B 100%) !important;
    color: #ffffff !important;
    border-radius: 10px;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
}

/* Collapse Menu Button */
#adminmenu .folded #collapse-button {
    color: rgba(255, 255, 255, 0.9) !important;
}

#collapse-button {
    color: rgba(255, 255, 255, 0.9) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px 0;
    transition: all 0.3s ease;
}

#collapse-button:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #D4AF37 !important;
}

/* Admin Bar - Top Bar Styling */
#wpadminbar {
    background: linear-gradient(90deg, #1F4E79 0%, #3B82F6 50%, #8B5CF6 100%) !important;
    border-bottom: 2px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

#wpadminbar .ab-item,
#wpadminbar a.ab-item,
#wpadminbar > #wp-toolbar > li > .ab-item {
    color: rgba(255, 255, 255, 0.9) !important;
}

#wpadminbar .ab-item:hover,
#wpadminbar a.ab-item:hover {
    color: #D4AF37 !important;
}

/* Site Title in Admin Bar */
#wpadminbar .ab-top-menu > li#wp-admin-bar-site-name > .ab-item {
    font-weight: 600;
    color: #ffffff !important;
}

/* Admin Bar Icons */
#wpadminbar .ab-icon,
#wpadminbar .ab-item:before,
#wpadminbar .ab-icon:before {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Responsive - Folded Menu */
.folded #adminmenu .wp-submenu {
    background: linear-gradient(180deg, rgba(31, 78, 121, 0.98) 0%, rgba(107, 70, 193, 0.98) 100%) !important;
    border-left: 3px solid #D4AF37;
    box-shadow: 4px 0 15px rgba(0, 0, 0, 0.3);
}

/* Custom Menu Items - Province Items with Gold Accent */
#adminmenu li.menu-top.province-item a {
    border-left: 3px solid rgba(212, 175, 55, 0.5);
}

#adminmenu li.menu-top.province-item:hover a,
#adminmenu li.menu-top.province-item.current a {
    border-left-color: #D4AF37;
}

/* Scrollbar Styling for Menu */
#adminmenu {
    scrollbar-width: thin;
    scrollbar-color: rgba(212, 175, 55, 0.5) transparent;
}

#adminmenu::-webkit-scrollbar {
    width: 8px;
}

#adminmenu::-webkit-scrollbar-track {
    background: transparent;
}

#adminmenu::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.6) 0%, rgba(212, 175, 55, 0.3) 100%);
    border-radius: 4px;
}

#adminmenu::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.8) 0%, rgba(212, 175, 55, 0.5) 100%);
}

/* Dashboard Widgets - Subtle Color Accents */
.postbox .hndle {
    border-left: 4px solid #3B82F6;
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.05) 0%, transparent 100%);
}

.postbox .inside {
    border-left: 4px solid transparent;
}

/* Welcome Panel Enhancement */
.welcome-panel {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-left: 4px solid #D4AF37;
}

/* Button Hover Effects */
.button-primary,
.button.button-primary {
    background: linear-gradient(135deg, #3B82F6 0%, #8B5CF6 100%) !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
}

.button-primary:hover,
.button.button-primary:hover {
    background: linear-gradient(135deg, #2563EB 0%, #7C3AED 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

/* Mobile Responsive */
@media screen and (max-width: 782px) {
    #adminmenuback,
    #adminmenuwrap,
    #adminmenu {
        background: linear-gradient(180deg, #1F4E79 0%, #6B46C1 100%) !important;
    }
    
    #wpadminbar {
        background: linear-gradient(90deg, #1F4E79 0%, #3B82F6 100%) !important;
    }
}
