@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: #0D0D0D;
  color: #ffffff;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom scrollbar - Dark theme */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #111111;
}

::-webkit-scrollbar-thumb {
  background: #2A2A2A;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #3A3A3A;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.8;
  }
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

.animate-pulse-custom {
  animation: pulse 2s infinite;
}

/* Glassmorphism Components - Removed, using solid backgrounds */
.glass {
  background: #1A1A1A;
  border: 1px solid #1E1E1E;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.glass-dark {
  background: #111111;
  border: 1px solid #1E1E1E;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.glass-navbar {
  background: #0D0D0D;
  border-bottom: 1px solid #1E1E1E;
}

/* First Rule Alert Colors */
.alert-critical {
  @apply bg-red-500/20 border-red-500/50 text-red-400;
}

.alert-warning {
  @apply bg-yellow-500/20 border-yellow-500/50 text-yellow-400;
}

.alert-info {
  @apply bg-blue-500/20 border-blue-500/50 text-blue-400;
}

.alert-success {
  @apply bg-green-500/20 border-green-500/50 text-green-400;
}

/* Button System - First Rule Style */
.btn-primary {
  background: #ffffff;
  color: #0D0D0D;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  font-weight: 500;
  font-size: 1.125rem;
  border: none;
  transition: background 0.3s, box-shadow 0.3s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  cursor: pointer;
}
.btn-primary:hover {
  background: #F5F5F5;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.bg-gray-700 {
  background-color: rgb(41 43 46) !important;
}

.btn-secondary {
  background: #1A1A1A;
  color: #A1A1A1;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  font-weight: 500;
  font-size: 1.125rem;
  border: 1px solid #2A2A2A;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
  cursor: pointer;
}
.btn-secondary:hover {
  background: #1A1A1A;
  color: #ffffff;
  border-color: #ffffff;
}

.btn-critical {
  @apply bg-red-500 text-white px-6 py-3 rounded-lg font-medium transition-all duration-300 hover:bg-red-600 hover:shadow-lg;
}

.btn-warning {
  @apply bg-yellow-500 text-black px-6 py-3 rounded-lg font-medium transition-all duration-300 hover:bg-yellow-600 hover:shadow-lg;
}

.btn-success {
  @apply bg-green-500 text-white px-6 py-3 rounded-lg font-medium transition-all duration-300 hover:bg-green-600 hover:shadow-lg;
}

.btn-info {
  @apply bg-blue-500 text-white px-6 py-3 rounded-lg font-medium transition-all duration-300 hover:bg-blue-600 hover:shadow-lg;
}

/* Dashboard preview animations */
.dashboard-card {
  transition: all 0.3s ease;
  background: rgba(0, 0, 0, 0.4) !important;
}

.dashboard-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  background: rgba(0, 0, 0, 0.6) !important;
}

/* Icon containers */
.icon-container {
  transition: all 0.3s ease;
}

.icon-container:hover {
  transform: translateY(-2px);
  filter: brightness(1.1);
}

/* Section reveal animation */
.section-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.section-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Stats counter animation */
.stat-number {
  display: inline-block;
}

/* Form focus states */
input:focus, textarea:focus {
  outline: none;
  border-color: #FFFFFF !important;
}

input::placeholder, textarea::placeholder {
  color: #6C6C6C;
}

/* First Rule Gradient texts */
.gradient-text {
  background: linear-gradient(135deg, #d1d5db, #9ca3af);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-brand {
  background: linear-gradient(135deg, #60a5fa, #34d399, #fbbf24);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Card Components */
.card-dark {
  @apply bg-gray-900/50 border border-white/10 rounded-xl p-6 backdrop-blur-sm;
}

.card-glass {
  background: #1A1A1A;
  border: 1px solid #1E1E1E;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* Dashboard Preview Styles */
.dashboard-mock {
  background: #1A1A1A;
  border: 1px solid #1E1E1E;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

/* Stats and Metrics */
.stat-card {
  background: #1A1A1A;
  border: 1px solid #1E1E1E;
  transition: all 0.3s ease;
}

.stat-card:hover {
  background: #1A1A1A;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  border-color: #1E1E1E;
}

/* Loading state */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.2), transparent);
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Text Hierarchy */
h1, h2, h3, h4, h5, h6 {
  color: #EDEDED !important;
}

h1 {
  color: #FFFFFF;
}


/* Ensure dark theme consistency */
.bg-gray-50, .bg-blue-600 {
  background-color: rgba(17, 17, 17, 0.8) !important;
}

/* Override any problematic hover states */
/* *:hover {
  background-color: inherit;
} */

button:hover:not(.btn-primary):not(.btn-secondary) {
  background-color: rgba(31, 31, 31, 0.5) !important;
}

/* Mobile optimizations */
@media (max-width: 768px) {
  .navbar {
    padding: 1rem 0;
  }
  
  h1 {
    font-size: 2rem !important;
    line-height: 1.2 !important;
    color: #d1d5db !important;
  }
  
  .stat-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Dashboard alert action buttons */
.dashboard-alert {
  transition: all 0.3s ease;
  transform: scale(1);
}
.dashboard-alert:hover {
  transform: scale(1.02);
  background: #1A1A1A !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  border-color: #2A2A2A !important;
}
.dashboard-alert:hover .alert-name {
  color: #FFFFFF !important;
}
.dashboard-alert:hover .alert-type {
  color: #C0C0C0 !important;
}
.dashboard-alert:hover .alert-change {
  color: inherit !important;
}
.dashboard-alert:hover .action-btn {
  background: #2A2A2A !important;
  color: #ffffff !important;
}
.dashboard-alert:hover .action-btn:hover {
  background: #3A3A3A !important;
}
.dashboard-alert .action-btn {
  font-size: 0.875rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  width: 180px;
  height: 40px;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
}
.dashboard-alert .action-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
/* Flash gradiente vermelho para novo alerta */
.dashboard-alert.flash-red {
  background: linear-gradient(90deg, #ef4444 0%, #fff0 100%) !important;
  transition: background 1s;
}

.flash-stripe {
  position: absolute;
  top: 0;
  left: -80px;
  width: 80px;
  height: 100%;
  background: linear-gradient(90deg, 
    rgba(255,255,255,0) 0%, 
    rgba(255,255,255,0.6) 20%, 
    rgba(255,255,255,0.9) 50%, 
    rgba(255,255,255,0.6) 80%, 
    rgba(255,255,255,0) 100%);
  filter: blur(0.5px);
  opacity: 1;
  z-index: 20;
  pointer-events: none;
  border-radius: 8px;
  box-shadow: 0 0 40px rgba(255,255,255,0.7);
  transform: skewX(-15deg);
}

/* Online status indicator */
.online-indicator {
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0%, 100% {
    opacity: 1;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
  }
  50% {
    opacity: 0.8;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.8);
  }
}

/* Notification badge styles */
#notification-badge {
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

#notification-badge.alert-active {
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
  animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
  0%, 100% {
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
  }
  50% {
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.8);
  }
}

.bg-gray-900\/80 {
  background-color: #1A1A1A !important;
}

.bg-gray-800 {
  background-color: #111111 !important;
}

.pt-30 {
  padding-top: 7.5rem;
}