* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #f5f7fa;
}

.layout-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    left: 0;
    top: 0;
    width: 260px;
    background: white;
    box-shadow: 2px 0 10px rgba(0,0,0,0.08);
    position: fixed;
    height: 100vh;
    z-index: 100;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 30px 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.sidebar-header h2 {
    font-size: 22px;
    font-weight: 700;
}

.sidebar-menu {
    flex: 1;
    padding: 20px 0;
    overflow-y: auto;
}

.menu-group {
    margin-bottom: 15px;
    padding: 0 12px;
}

.menu-group-title {
    padding: 12px 16px 10px;
    font-size: 12px;
    font-weight: 700;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s;
    border-radius: 8px;
}

.menu-group-title:hover {
    background: rgba(0, 0, 0, 0.04);
}

.menu-group-title .toggle-arrow {
    margin-left: auto;
    font-size: 12px;
    transition: transform 0.25s ease;
    display: inline-block;
}

.menu-group.collapsed .toggle-arrow {
    transform: rotate(-90deg);
}

.menu-group-children {
    overflow: hidden;
    max-height: 500px;
    transition: max-height 0.3s ease;
}

.menu-group.collapsed .menu-group-children {
    max-height: 0;
}

.group-icon {
    font-size: 16px;
}

.menu-group-style-0 {
    border-left: 3px solid #667eea;
    background: linear-gradient(to right, rgba(102, 126, 234, 0.05) 0%, transparent 100%);
    border-radius: 8px;
}

.menu-group-style-0 .menu-group-title {
    color: #667eea;
}

.menu-group-style-1 {
    border-left: 3px solid #11998e;
    background: linear-gradient(to right, rgba(17, 153, 142, 0.05) 0%, transparent 100%);
    border-radius: 8px;
}

.menu-group-style-1 .menu-group-title {
    color: #11998e;
}

.menu-group-style-2 {
    border-left: 3px solid #f59e0b;
    background: linear-gradient(to right, rgba(245, 158, 11, 0.05) 0%, transparent 100%);
    border-radius: 8px;
}

.menu-group-style-2 .menu-group-title {
    color: #f59e0b;
}

.menu-group-style-3 {
    border-left: 3px solid #8b5cf6;
    background: linear-gradient(to right, rgba(139, 92, 246, 0.05) 0%, transparent 100%);
    border-radius: 8px;
}

.menu-group-style-3 .menu-group-title {
    color: #8b5cf6;
}

.menu-item {
    padding: 13px 20px;
    color: #555;
    cursor: pointer;
    transition: all 0.25s;
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    border-radius: 10px;
    margin: 3px 8px;
    font-weight: 500;
}

.menu-item:hover {
    background: rgba(102, 126, 234, 0.08);
    color: #667eea;
    transform: translateX(3px);
}

.menu-item.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    font-weight: 600;
}

.main-content {
    margin-left: 260px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.header {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 20px;
    color: #333;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-name {
    color: #666;
}

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-logout {
    background: #fee;
    color: #e74c3c;
}

.btn-logout:hover {
    background: #fdd;
}

.btn-small {
    padding: 5px 12px;
    font-size: 13px;
    margin-right: 5px;
}

.btn-edit {
    background: #e3f2fd;
    color: #1976d2;
}

.btn-delete {
    background: #ffebee;
    color: #d32f2f;
}

.btn-perm {
    background: #fff3e0;
    color: #ef6c00;
}

.content-area {
    padding: 30px;
}

.card {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.card + .card {
    margin-top: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}



.filters {
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
}

.filters select,
.filters input {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.search-box {
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
}
