/* Keyframes */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.92); } to { opacity: 1; transform: scale(1); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 var(--accent-glow); } 50% { box-shadow: 0 0 0 6px transparent; } }
@keyframes edgeDash { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }

/* Panel entrance */
.panel { animation: fadeIn 0.25s ease; }
#hovercard, #toast { animation: fadeIn 0.2s ease; }
.pal-list li { animation: slideUp 0.15s ease backwards; }
.pal-list li:nth-child(1) { animation-delay: 0.02s; }
.pal-list li:nth-child(2) { animation-delay: 0.04s; }
.pal-list li:nth-child(3) { animation-delay: 0.06s; }

/* Node entrance */
.node[data-new] { animation: scaleIn 0.35s var(--ease-spring); }

/* Selection pulse */
.node.sel { animation: pulse 2.5s ease-in-out infinite; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}