/* ORIGINAL WORKING TOPNAV CSS - MINIMAL & WORKING */
:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --sidebar-bg: #2c3e50;
    --topbar-bg: #34495e;
    --footer-bg: #1a252f;
    --card-shadow: 0 4px 20px rgba(0,0,0,0.08);
    --hover-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%) !important;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
}

.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Topbar Styles */
.admin-topbar {
    background: var(--topbar-bg);
    color: var(--topbar-text);
    padding: 0;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1030;
}

.topbar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    flex-wrap: nowrap;
    gap: 1rem;
}

.topbar-left {
    display: flex;
    align-items: center;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-left: auto;
}

/* Topbar Content */
.topbar-left h4 {
    margin: 0;
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--topbar-text);
    transition: all 0.3s ease;
}

.topbar-left a:hover h4 {
    opacity: 0.8;
    transform: translateX(2px);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Topbar Buttons */
.topbar-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    color: var(--topbar-text);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.topbar-btn:hover {
    background: rgba(255,255,255,0.2);
    color: var(--topbar-text);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.3);
}

/* Notification badge */
.notification-badge {
    background: #e74c3c;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

/* Topbar Dropdown Styling - WHITE BACKGROUND LIKE REFERENCE */
.admin-topbar .dropdown-menu {
    background-color: var(--admin-dropdown-bg) !important;
    border: none !important;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15) !important;
    border-radius: 12px !important;
    padding: 0.5rem 0 !important;
    margin-top: 0.5rem !important;
    z-index: 9999 !important;
}

/* Dropdown Items Styling */
.admin-topbar .dropdown-menu .dropdown-item {
    color: var(--admin-dropdown-text) !important;
    padding: 0.75rem 1.25rem !important;
    transition: all 0.3s ease !important;
}

/* Dropdown Items Hover */
.admin-topbar .dropdown-menu .dropdown-item:hover {
    background-color: var(--admin-dropdown-hover-bg) !important;
    color: var(--admin-dropdown-hover-text) !important;
}

/* Horizontal Navigation Z-Index Fix */
.horizontal-nav {
    z-index: 1000 !important;
}

/* Dropdown Container Positioning */
.admin-topbar .dropdown {
    position: relative !important;
}

.admin-topbar .dropdown-item {
    padding: 0.75rem 1.25rem !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
    transition: all 0.3s ease !important;
    text-decoration: none !important;
    color: #495057 !important; /* Dark text for white background */
}

.admin-topbar .dropdown-item:hover,
.admin-topbar .dropdown-item:focus {
    background: rgba(102, 126, 234, 0.1) !important;
    color: #667eea !important;
    transform: translateX(5px) !important;
    text-decoration: none !important;
}

.admin-topbar .dropdown-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.75rem 1.25rem !important;
    margin: -0.5rem 0 0.5rem 0 !important;
    border-radius: 12px 12px 0 0 !important;
}

.admin-topbar .dropdown-item i {
    width: 16px !important;
    text-align: center !important;
}

/* Language Flag Styling in Topbar Dropdown */
.admin-topbar .dropdown-item .language-flag {
    width: 20px !important;
    height: 15px !important;
    object-fit: cover !important;
    border-radius: 2px !important;
    margin-right: 0.5rem !important;
    vertical-align: middle !important;
    display: inline-block !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
}

/* Currency Icons Styling - Match Reference Colors */
.admin-topbar .dropdown-item .fa-dollar-sign {
    color: #28a745 !important; /* text-success */
}

.admin-topbar .dropdown-item .fa-euro-sign {
    color: #007bff !important; /* text-primary */
}

.admin-topbar .dropdown-item .fa-pound-sign {
    color: #ffc107 !important; /* text-warning */
}

.admin-topbar .dropdown-item .fa-yen-sign {
    color: #dc3545 !important; /* text-danger */
}

/* Notification Icons Colors */
.admin-topbar .dropdown-item .fa-user-plus {
    color: #28a745 !important; /* text-success */
}

.admin-topbar .dropdown-item .fa-shield-alt {
    color: #ffc107 !important; /* text-warning */
}

.admin-topbar .dropdown-item .fa-cog {
    color: #17a2b8 !important; /* text-info */
}

/* Notification dropdown special styling */
.admin-topbar .dropdown-menu[style*="width: 350px"] {
    width: 350px !important;
}

.admin-topbar .dropdown-menu[style*="width: 350px"] .dropdown-item {
    display: flex !important;
    align-items: flex-start !important;
    gap: 1rem !important;
    padding: 1rem 1.25rem !important;
}

.admin-topbar .dropdown-menu[style*="width: 350px"] .dropdown-item div {
    flex: 1 !important;
}

.admin-topbar .dropdown-menu[style*="width: 350px"] .fw-bold {
    font-weight: 600 !important;
    color: #495057 !important;
    margin-bottom: 0.25rem !important;
}

.admin-topbar .dropdown-menu[style*="width: 350px"] .text-muted {
    color: #6c757d !important;
    font-size: 0.8rem !important;
}

/* Settings Panel Styling */
.settings-panel {
    position: fixed !important;
    top: 0 !important;
    right: -400px !important;
    width: 400px !important;
    height: 100vh !important;
    background: white !important;
    box-shadow: -5px 0 20px rgba(0,0,0,0.15) !important;
    z-index: 10001 !important;
    transition: right 0.3s ease !important;
    display: flex !important;
    flex-direction: column !important;
}

.settings-panel.open {
    right: 0 !important;
}

.settings-panel-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    padding: 1.5rem !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    border-bottom: 1px solid rgba(255,255,255,0.1) !important;
}

.settings-panel-body {
    flex: 1 !important;
    padding: 1.5rem !important;
    overflow-y: auto !important;
}

.settings-section {
    margin-bottom: 2rem !important;
}

.settings-section-title {
    color: #495057 !important;
    font-weight: 600 !important;
    margin-bottom: 1rem !important;
    padding-bottom: 0.5rem !important;
    border-bottom: 2px solid #e9ecef !important;
    font-size: 0.9rem !important;
}

.settings-item {
    padding: 1rem !important;
    background: #f8f9fa !important;
    border-radius: 8px !important;
    margin-bottom: 0.75rem !important;
    transition: all 0.3s ease !important;
}

.settings-item:hover {
    background: #e9ecef !important;
    transform: translateX(5px) !important;
}

.settings-item .fw-bold {
    color: #495057 !important;
    font-weight: 600 !important;
    margin-bottom: 0.25rem !important;
    font-size: 0.9rem !important;
}

.settings-item .text-muted {
    color: #6c757d !important;
    font-size: 0.8rem !important;
    margin-bottom: 0 !important;
}

.settings-item .badge {
    padding: 0.5rem !important;
    border-radius: 6px !important;
}

.settings-item .badge i {
    font-size: 0.9rem !important;
}

/* Badge color variants */
.settings-item .badge.bg-primary {
    background-color: #667eea !important;
}

.settings-item .badge.bg-success {
    background-color: #28a745 !important;
}

.settings-item .badge.bg-info {
    background-color: #17a2b8 !important;
}

.settings-item .badge.bg-warning {
    background-color: #ffc107 !important;
    color: #212529 !important;
}

/* Form switches in settings */
.settings-item .form-check-input {
    width: 2rem !important;
    height: 1rem !important;
    margin-top: 0 !important;
}

.settings-item .form-check-input:checked {
    background-color: #667eea !important;
    border-color: #667eea !important;
}

.settings-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: rgba(0,0,0,0.5) !important;
    z-index: 10000 !important;
    display: none !important;
}

.settings-overlay.show {
    display: block !important;
}

/* Topbar Responsive Styles */
@media (max-width: 991px) {
    .topbar-content {
        padding: 0.75rem 1rem;
        gap: 0.5rem;
    }
    
    .topbar-left h4 {
        font-size: 1.1rem;
    }
    
    .topbar-right {
        gap: 0.5rem;
    }
    
    .topbar-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 767px) {
    .topbar-content {
        padding: 0.5rem 0.75rem;
        gap: 0.25rem;
    }
    
    .topbar-left h4 {
        font-size: 1rem;
    }
    
    .topbar-btn {
        padding: 0.35rem 0.6rem;
        font-size: 0.8rem;
    }
    
    /* Only hide text labels on very small screens */
    .topbar-btn span {
        display: none !important;
    }
    
    .settings-panel {
        width: 100% !important;
        right: -100% !important;
    }
    
    .settings-panel.open {
        right: 0 !important;
    }
}

@media (max-width: 575px) {
    .topbar-content {
        padding: 0.5rem;
        gap: 0.25rem;
    }
    
    .topbar-left h4 {
        font-size: 0.9rem;
    }
    
    .topbar-btn {
        padding: 0.3rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .mobile-menu-toggle {
        padding: 0.3rem 0.5rem !important;
        font-size: 0.8rem !important;
    }
}