/* LuigiPOS Backoffice Custom Styles */

/* Enhanced animations and transitions */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--luigipos-orange);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--luigipos-orange-dark);
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 107, 53, 0.3);
    border-radius: 50%;
    border-top-color: var(--luigipos-orange);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Enhanced form controls */
.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid #E9ECEF;
    transition: all 0.3s ease;
}

.form-control:hover, .form-select:hover {
    border-color: var(--luigipos-orange-light);
}

/* Custom badges */
.badge-luigipos-success {
    background: linear-gradient(135deg, #28A745 0%, #20C997 100%);
}

.badge-luigipos-warning {
    background: linear-gradient(135deg, #FFC107 0%, #FF8C5A 100%);
}

.badge-luigipos-danger {
    background: linear-gradient(135deg, #DC3545 0%, #E83E8C 100%);
}

/* Enhanced cards */
.card-hover {
    transition: all 0.3s ease;
    cursor: pointer;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.15);
}

/* Table enhancements */
.table-hover tbody tr:hover {
    background-color: rgba(255, 107, 53, 0.05);
}

.table-luigipos {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Navigation enhancements */
.sidebar .nav-link {
    position: relative;
    overflow: hidden;
}

.sidebar .nav-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0;
    background: var(--luigipos-orange);
    transition: width 0.3s ease;
    z-index: -1;
}

.sidebar .nav-link:hover::before,
.sidebar .nav-link.active::before {
    width: 100%;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        top: 56px;
        left: -250px;
        width: 250px;
        height: calc(100vh - 56px);
        z-index: 1000;
        transition: left 0.3s ease;
    }
    
    .sidebar.show {
        left: 0;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .stat-card {
        margin-bottom: 1rem;
    }
}

/* Print styles */
@media print {
    .sidebar,
    .navbar,
    .btn,
    .page-header {
        display: none !important;
    }
    
    .main-content {
        margin-left: 0 !important;
        padding: 1rem !important;
    }
    
    .card {
        border: 1px solid #000 !important;
        box-shadow: none !important;
    }
}

/* Dark mode support (future enhancement) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here */
}

/* Accessibility improvements */
.visually-hidden-focusable:focus {
    position: static !important;
    width: auto !important;
    height: auto !important;
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .btn-luigipos {
        border: 2px solid #000;
    }
    
    .card-luigipos {
        border: 2px solid #000;
    }
}
