/* Custom styles */

/* HTMX loading indicator */
.htmx-indicator {
    opacity: 0;
    transition: opacity 50ms ease-in;
}

.htmx-request .htmx-indicator {
    opacity: 1;
}

.htmx-request.htmx-indicator {
    opacity: 1;
}

/* Smooth transitions for HTMX swaps */
.htmx-settling {
    opacity: 0.5;
}

/* Toast notifications */
.toast {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Table hover effects */
tbody tr {
    transition: background-color 0.15s ease;
}

/* Loading skeleton */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* Sortable column headers */
thead th button {
    transition: color 0.15s ease;
}

thead th button:hover {
    color: #4B5563; /* gray-600 */
}

thead th button:focus {
    outline: none;
    text-decoration: underline;
}