/* ── Animations ── */
@keyframes spin { to { transform: rotate(360deg); } }

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.08); opacity: 0.8; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(60px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes shimmer {
  0% { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}

@keyframes ripple {
  0% { transform: scale(0); opacity: 0.5; }
  100% { transform: scale(4); opacity: 0; }
}

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

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes floatY {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 20px rgba(124,58,237,0.3); }
  50% { box-shadow: 0 0 40px rgba(124,58,237,0.7), 0 0 80px rgba(124,58,237,0.2); }
}

/* ── Skeleton loading ── */
.skeleton {
  background: linear-gradient(90deg, var(--c-surface) 25%, var(--c-surface2) 50%, var(--c-surface) 75%);
  background-size: 400px 100%;
  animation: shimmer 1.4s infinite;
  border-radius: 6px;
}

/* ── Applied animations ── */
.animate-fadeIn { animation: fadeIn 0.4s ease forwards; }
.animate-slideUp { animation: slideUp 0.5s ease forwards; }
.animate-float { animation: floatY 4s ease-in-out infinite; }
.animate-glow { animation: glow 2.5s ease-in-out infinite; }
.animate-pulse { animation: pulse 2s ease-in-out infinite; }

/* Stagger children */
.stagger > * { opacity: 0; animation: slideUp 0.5s ease forwards; }
.stagger > *:nth-child(1) { animation-delay: 0.05s; }
.stagger > *:nth-child(2) { animation-delay: 0.1s; }
.stagger > *:nth-child(3) { animation-delay: 0.15s; }
.stagger > *:nth-child(4) { animation-delay: 0.2s; }
.stagger > *:nth-child(5) { animation-delay: 0.25s; }
.stagger > *:nth-child(6) { animation-delay: 0.3s; }

/* ── Ripple effect on buttons ── */
.btn { position: relative; overflow: hidden; }
.btn::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 5px; height: 5px;
  background: rgba(255,255,255,0.5);
  border-radius: 50%;
  transform: scale(0);
  opacity: 0;
  transition: none;
}
.btn:active::after { animation: ripple 0.5s ease; }

/* ── Hero gradient BG ── */
.hero-bg {
  background: linear-gradient(-45deg, #0f0a1e, #1a1130, #2d1b69, #0f0a1e);
  background-size: 400% 400%;
  animation: gradientShift 10s ease infinite;
}

/* ── Glassmorphism card hover ── */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(124,58,237,0.2);
  border-color: rgba(124,58,237,0.3);
}

/* ── Transaction item animation ── */
.tx-item {
  animation: slideUp 0.4s ease forwards;
  opacity: 0;
}

/* ── Chart container ── */
.chart-container { position: relative; height: 240px; }

/* ── Upload area ── */
.upload-zone {
  border: 2px dashed var(--c-border);
  border-radius: var(--radius);
  padding: 40px 24px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  background: var(--c-surface);
}
.upload-zone:hover, .upload-zone.drag-over {
  border-color: var(--c-primary);
  background: rgba(124,58,237,0.06);
}
.upload-zone svg { width: 40px; height: 40px; color: var(--c-text3); margin: 0 auto 12px; }
.upload-zone p { color: var(--c-text2); font-size: 0.9rem; }
.upload-zone span { color: var(--c-primary-light); font-weight: 600; }

/* ── Number ticker ── */
.ticker { display: inline-block; animation: countUp 0.6s ease; }

/* ── Page transitions ── */
.page-enter { animation: fadeIn 0.3s ease; }
