@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.animate-shimmer {
    animation: shimmer 2s infinite linear;
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-12px); max-height: 0; }
    to { opacity: 1; transform: translateY(0); max-height: 600px; }
}
.animate-slide-down {
    animation: slideDown 0.35s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    overflow: hidden;
}

/* Inline Resolve Panel */
#inline-resolve-panel {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    border: 1px solid #e2e8f0;
    border-radius: 1.25rem;
    padding: 1.25rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
#inline-resolve-panel:hover {
    border-color: #94a3b8;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Estilos específicos para el Kanban */
.kanban-col {
    max-height: calc(100vh - 120px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Mejora minimalista para columnas vacías */
@media (min-width: 768px) {
    /* Eliminado el comprimido de columnas vacías según petición del usuario */
}

.drop-zone {
    transition: background-color 0.2s ease;
}

.drop-zone.drag-over {
    background-color: rgba(59, 130, 246, 0.05);
    border-radius: 0.75rem;
}

.kanban-card {
    cursor: grab;
    user-select: none;
    transition: transform 0.1s, box-shadow 0.1s;
}

.kanban-card:active {
    cursor: grabbing;
    transform: scale(0.98);
}

.kanban-card.is-dragging {
    opacity: 0.5;
    background: #f8fafc;
}

/* Menú contextual móvil */
.context-menu-trigger {
    padding: 8px;
    margin: -8px;
    border-radius: 50%;
}
.context-menu-trigger:active {
    background-color: #f1f5f9;
}

/* Scroll-Spy smooth transition */
#wo-detail-scroll-container button {
    transition: all 0.2s ease-in-out;
}

/* Custom Scrollbar for the detail modal to be more discrete */
#wo-detail-scroll-container::-webkit-scrollbar {
    width: 6px;
}
#wo-detail-scroll-container::-webkit-scrollbar-track {
    background: transparent;
}
#wo-detail-scroll-container::-webkit-scrollbar-thumb {
    background: #e2e8f0;
    border-radius: 10px;
}
#wo-detail-scroll-container::-webkit-scrollbar-thumb:hover {
    background: #cbd5e1;
}

/* Drag & Drop Operaciones */
.operation-card.dragging {
    opacity: 0.5;
    border: 2px dashed #3b82f6 !important; /* blue-500 */
    cursor: grabbing;
}

.operation-card.drag-over {
    border-top: 3px solid #3b82f6 !important;
}

.drag-handle {
    cursor: grab;
}

.drag-handle:active {
    cursor: grabbing;
}

/* Transiciones de Deslizamiento (Swipe/Slide) */
.slide-out-left {
    animation: slideOutLeft 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
.slide-out-right {
    animation: slideOutRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
.slide-in-right {
    animation: slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
.slide-in-left {
    animation: slideInLeft 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes slideOutLeft {
    from { opacity: 1; transform: translateX(0); }
    to { opacity: 0; transform: translateX(-30px); }
}
@keyframes slideOutRight {
    from { opacity: 1; transform: translateX(0); }
    to { opacity: 0; transform: translateX(30px); }
}
@keyframes slideInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Ajustes responsive para el modal de operaciones */
#wo-add-op-modal .form-content-wrapper {
    transition: all 0.3s ease;
    will-change: transform, opacity;
}

/* Regla Touch-First: Detectar si el dispositivo soporta hover o no */
@media (hover: none) {
  .touch\:opacity-100 {
    opacity: 1 !important;
  }
}
