/* PWA Standalone & Mobile Safe-Area Insets */
html, body {
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
}

.pb-safe { 
  padding-bottom: max(env(safe-area-inset-bottom, 0px), 1rem); 
}

.pt-safe { 
  padding-top: max(env(safe-area-inset-top, 0px), 0.5rem); 
}

button, input, select { 
  touch-action: manipulation; 
}

::-webkit-scrollbar { 
  width: 5px; 
  height: 5px; 
}

::-webkit-scrollbar-thumb { 
  background: #cbd5e1; 
  border-radius: 9999px; 
}

.dark ::-webkit-scrollbar-thumb { 
  background: #475569; 
}

@media print {
  .no-print { display: none !important; }
  body { background: white !important; color: black !important; }
}

/* Micro-interaction Keyframes */
@keyframes rowEnter {
  0% { 
    opacity: 0; 
    transform: translateY(-12px) scale(0.98); 
    background-color: rgba(16, 185, 129, 0.25); 
  }
  60% { 
    background-color: rgba(16, 185, 129, 0.12); 
  }
  100% { 
    opacity: 1; 
    transform: translateY(0) scale(1); 
    background-color: transparent; 
  }
}

@keyframes rowExit {
  0% { 
    opacity: 1; 
    transform: scale(1); 
    background-color: rgba(239, 68, 68, 0.2); 
  }
  50% { 
    opacity: 0.3; 
    transform: scale(0.96) translateX(25px); 
    background-color: rgba(239, 68, 68, 0.3); 
  }
  100% { 
    opacity: 0; 
    transform: scale(0.9) translateX(50px); 
    max-height: 0; 
    padding-top: 0; 
    padding-bottom: 0; 
    border: none; 
  }
}

.animate-row-enter {
  animation: rowEnter 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-row-exit {
  animation: rowExit 0.35s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  pointer-events: none;
}