/* Suggested Actions List Smooth Animations */

/* Container for animated list items */
.column-items {
    position: relative;
    overflow: hidden;
}

/* Base animation for all action items */
.accordion-item.action-item {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: top center;
    opacity: 1;
    max-height: 200px; /* Adjust based on your item height */
    overflow: hidden;
}

/* Animation classes for adding items */
.accordion-item.action-item.item-entering {
    animation: slideInAction 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes slideInAction {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
        max-height: 0;
        margin-bottom: 0;
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        max-height: 200px;
        margin-bottom: 0.5rem;
    }
}

/* Animation classes for removing items */
.accordion-item.action-item.item-removing {
    animation: slideOutAction 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    pointer-events: none;
}

@keyframes slideOutAction {
    from {
        opacity: 1;
        transform: translateX(0) scale(1);
        max-height: 200px;
        margin-bottom: 0.5rem;
    }
    to {
        opacity: 0;
        transform: translateX(-20px) scale(0.95);
        max-height: 0;
        margin-bottom: 0;
        padding-top: 0;
        padding-bottom: 0;
    }
}

/* Status change animations */
.item-status {
    transition: all 0.2s ease-in-out;
    position: relative;
}

.item-status.status-changing {
    animation: statusPulse 0.3s ease-in-out;
}

@keyframes statusPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Complete task animation */
.accordion-item.action-item.item-completing {
    animation: completeAction 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes completeAction {
    0% {
        transform: translateX(0);
        background-color: transparent;
    }
    50% {
        transform: translateX(5px);
        background-color: rgba(16, 185, 129, 0.1);
    }
    100% {
        transform: translateX(0);
        background-color: transparent;
    }
}

/* Item reordering animation */
.accordion-item.action-item.item-moving {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
}

/* Hover states with smooth transitions */
.accordion-item.action-item:hover {
    background-color: rgba(75, 85, 99, 0.1);
    transform: translateX(2px);
}

/* Action buttons animation */
.item-actions {
    transition: opacity 0.2s ease-in-out;
}

.item-actions .action-btn {
    transition: all 0.2s ease-in-out;
    transform: scale(1);
}

.item-actions .action-btn:hover {
    transform: scale(1.1);
}

.item-actions .action-btn:active {
    transform: scale(0.95);
}

/* Priority badge animation */
.item-priority {
    transition: all 0.2s ease-in-out;
}

.accordion-item.action-item:hover .item-priority {
    transform: scale(1.05);
}

/* Smooth height transitions for container */
.column-content {
    transition: height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Loading state for new items */
.accordion-item.action-item.item-loading {
    opacity: 0.5;
    pointer-events: none;
}

.accordion-item.action-item.item-loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.1) 50%, transparent 100%);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Fade effect for long lists */
.column-content::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to bottom, transparent, rgba(17, 24, 39, 0.9));
    pointer-events: none;
    transition: opacity 0.3s ease;
}

/* Item count animation */
.item-count {
    transition: all 0.3s ease-in-out;
}

.item-count.count-changing {
    animation: countBounce 0.4s ease-in-out;
}

@keyframes countBounce {
    0%, 100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.2);
    }
    75% {
        transform: scale(0.9);
    }
}