/* Custom styles */
body {
    font-family: 'K2D','Sarabun', sans-serif;
}

.sidebar {
    height: 100vh;
    position: fixed;
}

.content {
    margin-left: 16rem;
}

/* Mobile menu button styles */
.mobile-menu-btn {
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 50;
    background: linear-gradient(to right, #3b82f6, #1d4ed8, #3b82f6);
    color: white;
    border: none;
    border-radius: 0.5rem;
    padding: 0.75rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.mobile-menu-btn:hover {
    background: linear-gradient(to right, #2563eb, #1e40af, #2563eb);
    transform: scale(1.05);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.mobile-menu-btn:focus {
    outline: none;
    ring: 4px;
    ring-color: rgba(59, 130, 246, 0.5);
}

.mobile-close-btn {
    background: linear-gradient(to right, #ef4444, #dc2626, #ef4444);
    color: white;
    border: none;
    border-radius: 0.5rem;
    padding: 0.5rem;
    transition: all 0.3s ease;
}

.mobile-close-btn:hover {
    background: linear-gradient(to right, #dc2626, #b91c1c, #dc2626);
    transform: scale(1.05);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    
    .content {
        margin-left: 0;
    }
    
    .card {
        margin-bottom: 1rem;
    }
    
    /* ปรับ padding สำหรับเนื้อหาหลักเมื่อมีปุ่มเมนูอยู่ด้านบน */
    .main-content {
        padding-top: 4rem;
    }
}

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Card hover effect */
.card-hover:hover {
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

/* Smooth transitions for sidebar */
#sidebar-multi-level-sidebar {
    transition: transform 0.3s ease-in-out;
}