/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.14);
}
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
}

/* Sidebar link transitions */
.sidebar-link {
  transition: background-color 0.15s ease, color 0.15s ease;
}

/* Table tweaks */
table {
  border-collapse: separate;
  border-spacing: 0;
}
th {
  user-select: none;
}
tr {
  transition: background-color 0.1s ease;
}

/* Focus ring */
input:focus,
select:focus,
button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.5);
}

/* Loading spinner */
@keyframes spin {
  to { transform: rotate(360deg); }
}
.spinner {
  animation: spin 0.7s linear infinite;
}

/* Skeleton pulse */
@keyframes pulse-bg {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.15; }
}
.skeleton {
  animation: pulse-bg 1.5s ease-in-out infinite;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 6px;
}

/* Toast slide-in */
@keyframes slide-in-right {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
@keyframes slide-out-right {
  from { transform: translateX(0); opacity: 1; }
  to { transform: translateX(100%); opacity: 0; }
}
.toast-enter {
  animation: slide-in-right 0.25s ease-out forwards;
}
.toast-exit {
  animation: slide-out-right 0.2s ease-in forwards;
}

/* Tooltip */
.tooltip-container {
  position: relative;
}
.tooltip-container .tooltip-text {
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.15s ease;
  position: absolute;
  z-index: 50;
}
.tooltip-container:hover .tooltip-text {
  visibility: visible;
  opacity: 1;
}

/* Monospace */
.font-mono {
  font-family: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
}

/* Transition for cards */
.card-hover {
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.card-hover:hover {
  background-color: #1a1a2e;
  border-color: rgba(255, 255, 255, 0.082);
}
