/* Main Layout */
.layout-wrapper {
    display: flex;
    min-height: 100vh;
    background: #f8f9fa;
}

.sidebar {
    width: 280px;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    transition: all 0.3s ease;
    position: fixed;
    height: 100vh;
    z-index: 1000;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
}

.sidebar.collapsed {
    width: 80px;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    margin-left: 280px;
    transition: margin-left 0.3s ease;
}

.sidebar.collapsed + .main-content {
    margin-left: 80px;
}

.content-area {
    flex: 1;
    padding: 20px;
    background: #f8f9fa;
    min-height: calc(100vh - 140px);
}

/* Sidebar Styles */
.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #34495e;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-logo {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
}

.brand-logo:hover {
    color: #ecf0f1;
}

.sidebar-close {
    color: #bdc3c7;
    background: none;
    border: none;
    font-size: 1.2rem;
}

.sidebar-profile {
    padding: 20px;
    border-bottom: 1px solid #34495e;
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    font-size: 2.5rem;
    color: #3498db;
}

.user-info {
    flex: 1;
}

.user-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.user-role {
    font-size: 0.85rem;
}

.sidebar-nav .nav-link {
    color: #bdc3c7;
    padding: 12px 20px;
    border-left: 3px solid transparent;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.sidebar-nav .nav-link:hover {
    color: white;
    background: rgba(52, 152, 219, 0.1);
    border-left-color: #3498db;
}

.sidebar-nav .nav-link.active {
    color: white;
    background: rgba(52, 152, 219, 0.2);
    border-left-color: #3498db;
}

.sidebar-nav .nav-link i {
    width: 20px;
    text-align: center;
}

.has-submenu .dropdown-arrow {
    margin-left: auto;
    transition: transform 0.3s ease;
}

.has-submenu .nav-link[aria-expanded="true"] .dropdown-arrow {
    transform: rotate(180deg);
}

.submenu {
    background: rgba(0, 0, 0, 0.2);
    border-left: 3px solid #3498db;
}

.submenu .nav-link {
    padding: 10px 20px 10px 50px;
    font-size: 0.9rem;
}

.sidebar-footer {
    padding: 15px 20px;
    border-top: 1px solid #34495e;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.system-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-indicator.online {
    background: #2ecc71;
    box-shadow: 0 0 5px #2ecc71;
}

.version-text {
    font-size: 0.8rem;
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
    display: none;
}

/* Header Styles */
.main-header {
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 999;
}

.sidebar-toggle {
    border: none;
    background: none;
    font-size: 1.2rem;
    color: #6c757d;
}

.breadcrumb {
    margin-bottom: 0;
    background: none;
    padding: 0;
}

.breadcrumb-item a {
    color: #6c757d;
    text-decoration: none;
}

.breadcrumb-item.active {
    color: #495057;
    font-weight: 500;
}

.search-bar {
    width: 300px;
}

.user-avatar-sm {
    color: #3498db;
}

.dropdown-notifications {
    width: 350px;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 15px;
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    margin-bottom: 2px;
}

.notification-text {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 4px;
}

.dropdown-profile {
    width: 280px;
}

/* Footer Styles */
.main-footer {
    background: white;
    border-top: 1px solid #dee2e6;
    padding: 15px 0;
    margin-top: auto;
}

.footer-info {
    font-size: 0.9rem;
}

.footer-links a {
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #495057 !important;
}

/* Responsive */
@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0 !important;
    }
    
    .sidebar-overlay.show {
        display: block;
    }
    
    .search-bar {
        width: 250px;
    }
}

@media (max-width: 768px) {
    .content-area {
        padding: 15px;
    }
    
    .user-info {
        display: none !important;
    }
    
    .search-bar {
        width: 200px;
    }
}