/* Progress bar transitions */
.progress-bar-transition {
  transition: width 0.4s ease-out;
}

/* HTMX swap transitions */
.htmx-swapping {
  opacity: 0.5;
  transition: opacity 0.2s ease-in;
}

.htmx-settling {
  opacity: 1;
  transition: opacity 0.2s ease-out;
}

/* HTMX indicator */
.htmx-indicator {
  display: none;
}

.htmx-request .htmx-indicator {
  display: inline-block;
}

.htmx-request.htmx-indicator {
  display: inline-block;
}

/* Scrollbar styling for dark theme */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgb(17, 24, 39);
}

::-webkit-scrollbar-thumb {
  background: rgb(55, 65, 81);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgb(75, 85, 99);
}

/* Pulse animation for downloading status */
@keyframes pulse-blue {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.animate-pulse-blue {
  animation: pulse-blue 2s ease-in-out infinite;
}

/* Row highlight on update */
@keyframes row-flash {
  0% { background-color: rgba(99, 102, 241, 0.1); }
  100% { background-color: transparent; }
}

tr.htmx-settling {
  animation: row-flash 0.5s ease-out;
}

/* Table layout fixes */
table {
  table-layout: fixed;
}

td {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Resizable columns */
.resizable-th {
  position: relative;
}

.resize-handle {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  cursor: col-resize;
  background: transparent;
  transition: background 0.15s;
}

.resize-handle:hover,
.resize-handle:active {
  background: rgba(99, 102, 241, 0.5);
}
