/* Medical Theme CSS */
:root {
  --primary-blue: #0ea5e9;
  --primary-teal: #14b8a6;
  --medical-green: #10b981;
  --medical-purple: #8b5cf6;
  --medical-red: #ef4444;
  --medical-gray: #6b7280;
  --medical-light: #f8fafc;
  --medical-dark: #1e293b;
}

/* Smooth animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

@keyframes scan-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

/* Custom styles */
.animate-fade-in {
  animation: fadeIn 0.5s ease-out;
}

.animate-pulse-glow {
  animation: pulse-glow 2s infinite;
}

.medical-gradient {
  background: linear-gradient(135deg, #0ea5e9 0%, #14b8a6 100%);
}

.medical-card {
  background: white;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  overflow: hidden;
}

.medical-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(14, 165, 233, 0.12);
}

.medical-card-header {
  background: linear-gradient(90deg, #f0f9ff 0%, #f8fafc 100%);
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem;
}

.medical-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.025em;
}

.medical-badge-success {
  background-color: #d1fae5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.medical-badge-warning {
  background-color: #fef3c7;
  color: #92400e;
  border: 1px solid #fde68a;
}

.medical-badge-error {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.medical-badge-info {
  background-color: #dbeafe;
  color: #1e40af;
  border: 1px solid #bfdbfe;
}

/* Timeline */
.medical-timeline {
  position: relative;
  padding-left: 2rem;
}

.medical-timeline::before {
  content: '';
  position: absolute;
  left: 0.75rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, #0ea5e9, #14b8a6);
  opacity: 0.3;
}

.medical-timeline-item {
  position: relative;
  margin-bottom: 1.5rem;
}

.medical-timeline-item::before {
  content: '';
  position: absolute;
  left: -1.6rem;
  top: 0.25rem;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: #0ea5e9;
  border: 3px solid white;
  box-shadow: 0 0 0 2px #0ea5e9;
}

/* QR Scanner Effect */
.qr-scanner {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
}

.qr-scanner::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #0ea5e9, transparent);
  animation: scan-line 2s linear infinite;
}

/* Form Controls */
.medical-input {
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  transition: all 0.2s;
  background: white;
}

.medical-input:focus {
  outline: none;
  border-color: #0ea5e9;
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
  background: white;
}

.medical-btn-primary {
  background: linear-gradient(135deg, #0ea5e9 0%, #14b8a6 100%);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: all 0.2s;
}

.medical-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.medical-btn-secondary {
  background: white;
  color: #0ea5e9;
  border: 1px solid #0ea5e9;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: all 0.2s;
}

.medical-btn-secondary:hover {
  background: #f0f9ff;
  transform: translateY(-1px);
}

/* Status Indicators */
.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 0.5rem;
}

.status-dot.active {
  background-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.status-dot.warning {
  background-color: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.status-dot.error {
  background-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

/* Dashboard Cards */
.dashboard-stat-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border-radius: 12px;
  padding: 1.5rem;
  border: 1px solid #e5e7eb;
  transition: all 0.3s;
}

.dashboard-stat-card:hover {
  border-color: #0ea5e9;
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.1);
}

/* Navigation */
.medical-nav {
  background: linear-gradient(90deg, #ffffff 0%, #f8fafc 100%);
  border-bottom: 1px solid #e5e7eb;
  backdrop-filter: blur(10px);
}

.nav-link-medical {
  color: #6b7280;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.2s;
  position: relative;
}

.nav-link-medical:hover {
  color: #0ea5e9;
  background: #f0f9ff;
}

.nav-link-medical.active {
  color: #0ea5e9;
  background: #f0f9ff;
  font-weight: 600;
}

.nav-link-medical.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 1rem;
  right: 1rem;
  height: 2px;
  background: linear-gradient(90deg, #0ea5e9, #14b8a6);
  border-radius: 1px;
}

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

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

/* Alert Styles */
.medical-alert {
  border-radius: 12px;
  padding: 1rem 1.5rem;
  border-left: 4px solid;
}

.medical-alert-success {
  background-color: #f0fdf4;
  border-left-color: #10b981;
  color: #065f46;
}

.medical-alert-warning {
  background-color: #fffbeb;
  border-left-color: #f59e0b;
  color: #92400e;
}

.medical-alert-error {
  background-color: #fef2f2;
  border-left-color: #ef4444;
  color: #991b1b;
}

.medical-alert-info {
  background-color: #eff6ff;
  border-left-color: #0ea5e9;
  color: #1e40af;
}