/* ✨ SAFARSMART ENHANCED UI/UX STYLES */

/* ==================== FLIGHT CARD IMPROVEMENTS ==================== */

.flight-card-enhanced {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.flight-card-enhanced:hover {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
  border-color: #1a365d;
}

.flight-card-enhanced.comparison-selected {
  border: 2px solid #3b82f6;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(59, 130, 246, 0.02));
}

/* ==================== BADGE SYSTEM ==================== */

.badge {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: none;
}

.badge--trusted {
  background: linear-gradient(135deg, #059669, #047857);
  color: white;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.3);
}

.badge--external {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
}

.badge--compliant {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
}

.badge--non-compliant {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.badge--recommendation {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
  animation: pulse 2s infinite;
}

.badge--price-drop {
  background: linear-gradient(135deg, #06b6d4, #0891b2);
  color: white;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

/* ==================== RESULTS CONTAINER ==================== */

.results-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 20px;
  margin-top: 20px;
}

@media (max-width: 1024px) {
  .results-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-sidebar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 20px;
  }
}

@media (max-width: 640px) {
  .results-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-sidebar {
    grid-template-columns: 1fr;
  }
}

/* ==================== FILTER SIDEBAR ==================== */

.filter-sidebar {
  background: white;
  border-radius: 12px;
  padding: 16px;
  border: 1.5px solid #e2e8f0;
  height: fit-content;
  position: sticky;
  top: 20px;
}

.filter-group {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f1f5f9;
}

.filter-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.filter-title {
  font-weight: 700;
  color: #1a365d;
  font-size: 0.95rem;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.filter-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  cursor: pointer;
  font-size: 0.9rem;
  color: #64748b;
  transition: all 0.2s;
}

.filter-item:hover {
  color: #1a365d;
}

.filter-item input {
  cursor: pointer;
  width: 18px;
  height: 18px;
  accent-color: #1a365d;
}

/* ==================== FLIGHT RESULTS LIST ==================== */

#duffelResultsList {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.flight-card-enhanced {
  display: flex;
  flex-direction: column;
}

/* ==================== WISHLIST BUTTON ==================== */

.wish-btn {
  transition: all 0.3s ease;
  font-size: 1.4rem;
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wish-btn:hover {
  transform: scale(1.1);
}

.wish-btn:active {
  transform: scale(0.95);
}

/* ==================== COMPARISON VIEW ==================== */

.comparison-modal {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.comparison-content {
  background: white;
  border-radius: 16px;
  max-width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  padding: 0;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.comparison-header {
  background: linear-gradient(135deg, #1a365d, #2d4a7a);
  color: white;
  padding: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e2e8f0;
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  padding: 20px;
}

.comparison-table th,
.comparison-table td {
  padding: 16px;
  text-align: right;
  border-bottom: 1px solid #e2e8f0;
}

.comparison-table th {
  background: #f8fafc;
  font-weight: 700;
  color: #1a365d;
}

.comparison-table td {
  color: #64748b;
}

/* ==================== INFO PILL STYLES ==================== */

.info-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #f1f5f9;
  border-radius: 8px;
  font-size: 0.85rem;
  color: #64748b;
  font-weight: 600;
}

.info-pill.important {
  background: linear-gradient(135deg, rgba(26, 54, 93, 0.1), rgba(45, 74, 122, 0.1));
  color: #1a365d;
  font-weight: 700;
}

/* ==================== QUICK ACTIONS ==================== */

.quick-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.action-btn {
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.action-btn--primary {
  background: linear-gradient(135deg, #1a365d, #2d4a7a);
  color: white;
}

.action-btn--primary:hover {
  box-shadow: 0 4px 12px rgba(26, 54, 93, 0.3);
  transform: translateY(-2px);
}

.action-btn--secondary {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #e2e8f0;
}

.action-btn--secondary:hover {
  background: #e2e8f0;
  border-color: #cbd5e1;
}

/* ==================== NOTIFICATIONS ==================== */

.notification {
  position: fixed;
  padding: 16px 24px;
  border-radius: 8px;
  color: white;
  font-weight: 600;
  z-index: 10000;
  animation: slideInRight 0.3s ease-in-out;
}

@keyframes slideInRight {
  from {
    transform: translateX(400px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.notification.success {
  background: linear-gradient(135deg, #10b981, #059669);
}

.notification.error {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

.notification.info {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

/* ==================== LOADING STATE ==================== */

.flight-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f1f5f9;
  border-top-color: #1a365d;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 16px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-text {
  color: #64748b;
  font-weight: 600;
}

/* ==================== EMPTY STATE ==================== */

.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-state__icon {
  font-size: 4rem;
  margin-bottom: 16px;
}

.empty-state__title {
  font-size: 1.3rem;
  font-weight: 700;
  color: #1a365d;
  margin-bottom: 8px;
}

.empty-state__description {
  color: #94a3b8;
  margin-bottom: 24px;
}

/* ==================== RESPONSIVE ADJUSTMENTS ==================== */

@media (max-width: 768px) {
  .flight-card-enhanced {
    margin-bottom: 12px;
  }
  
  .filter-sidebar {
    position: static;
    top: auto;
  }
  
  .quick-actions {
    flex-direction: column;
  }
  
  .action-btn {
    width: 100%;
  }
  
  .info-pill {
    font-size: 0.8rem;
    padding: 6px 10px;
  }
}

/* ==================== DARK MODE SUPPORT ==================== */

@media (prefers-color-scheme: dark) {
  .flight-card-enhanced {
    background: #1e293b;
    border-color: #334155;
  }
  
  .filter-sidebar {
    background: #1e293b;
    border-color: #334155;
  }
  
  .filter-title {
    color: #f1f5f9;
  }
  
  .filter-item {
    color: #cbd5e1;
  }
  
  .filter-item:hover {
    color: #f1f5f9;
  }
  
  .comparison-table th {
    background: #0f172a;
    color: #f1f5f9;
  }
  
  .comparison-table td {
    color: #cbd5e1;
  }
  
  .info-pill {
    background: rgba(148, 163, 184, 0.1);
    color: #cbd5e1;
  }
  
  .action-btn--secondary {
    background: #334155;
    color: #f1f5f9;
    border-color: #475569;
  }
  
  .action-btn--secondary:hover {
    background: #475569;
  }
}
