/* ADAShield Pro - Custom Styles */

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Screen reader only - for skip links and hidden labels */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Show skip link on focus */
.sr-only:focus,
.focus\:not-sr-only:focus {
  position: absolute;
  width: auto;
  height: auto;
  padding: 0.5rem 1rem;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* Custom animations */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes pulse-glow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(37, 99, 235, 0.3);
  }
  50% {
    box-shadow: 0 0 40px rgba(37, 99, 235, 0.6);
  }
}

/* Chat widget animation */
#chatWidget {
  animation: slideUp 0.3s ease-out;
}

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

/* Chat toggle button pulse */
#chatToggle {
  animation: pulse-glow 2s infinite;
}

#chatToggle:hover {
  animation: none;
}

/* Custom scrollbar for chat */
#chatMessages::-webkit-scrollbar {
  width: 6px;
}

#chatMessages::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 3px;
}

#chatMessages::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

#chatMessages::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Code blocks in patches */
pre {
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

/* Loading animation */
.animate-bounce {
  animation: bounce 1s infinite;
}

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

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Feature card hover effect */
.feature-card {
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
}

/* Button press effect */
button:active {
  transform: scale(0.98);
}

/* Focus styles for accessibility */
a:focus,
button:focus,
input:focus {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  #chatWidget {
    width: calc(100vw - 24px);
    right: 12px;
    bottom: 12px;
  }

  #chatToggle {
    width: 56px;
    height: 56px;
    right: 12px;
    bottom: 12px;
  }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
  /* Add dark mode styles if needed */
}

/* Print styles */
@media print {
  #chatWidget,
  #chatToggle,
  nav {
    display: none !important;
  }
}

/* Transition utilities */
.transition-all {
  transition-property: all;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

/* Skeleton loading animation */
.skeleton {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Tooltip styles */
.tooltip {
  position: relative;
}

.tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 8px;
  background: #1e293b;
  color: white;
  font-size: 12px;
  border-radius: 4px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.tooltip:hover::after {
  opacity: 1;
}

/* Status indicator */
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.status-dot.online {
  background-color: #22c55e;
}

.status-dot.offline {
  background-color: #ef4444;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}
