/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --success-gradient: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    --warning-gradient: linear-gradient(135deg, #f7971e 0%, #ffd200 100%);
    --danger-gradient: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    --bs-modal-bg: #0d6efd;
    --success-color: #10b981;
    --bs-heading-color: #000;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #3b82f6;
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --shadow-light: 0 8px 32px rgba(31, 38, 135, 0.37);
    --shadow-heavy: 0 15px 35px rgba(31, 38, 135, 0.5);
    --border-radius: 16px;
    --border-radius-sm: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; 
  min-height: 100vh;
  color: #1f2937;
  line-height: 1.6;
}

/* Dashboard Layout */
.status-dashboard {
    min-height: 100vh;
    padding: 0;
    background: #384a64;
}

/* Header Section */
.dashboard-header {
  background: var(--primary-gradient);
  padding: 2rem 0;
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
}

.dashboard-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.3;
}

.status-hero {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  position: relative;
  z-index: 2;
}

.status-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: white;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-light);
}

.status-hero.operational .status-icon {
  background: var(--success-gradient);
}

.status-hero.degraded .status-icon {
  background: var(--warning-gradient);
}

.status-hero.partial-outage .status-icon,
.status-hero.major-outage .status-icon {
  background: var(--danger-gradient);
}

.status-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.status-subtitle {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
}

/* Dashboard Controls */
.dashboard-controls {
  position: relative;
  z-index: 2;
}

.subscription-selector {
  margin-bottom: 1rem;
}

.subscription-selector label {
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: block;
}

.subscription-selector select {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  color: white;
  padding: 0.5rem 1rem;
}

.subscription-selector select option {
  background: #1f2937;
  color: white;
}

.control-buttons {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.btn-glass {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  color: white;
  border-radius: var(--border-radius-sm);
  padding: 0.5rem 1rem;
  font-weight: 500;
  transition: var(--transition);
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: var(--shadow-light);
  color: white;
}

.connection-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: white;
  font-size: 0.9rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.status-dot.connected {
  background: var(--success-color);
  animation: pulse-success 2s infinite;
}

.status-dot.connecting {
  background: var(--warning-color);
  animation: pulse-warning 1s infinite;
}

.status-dot.disconnected,
.status-dot.error {
  background: var(--danger-color);
  animation: pulse-danger 1s infinite;
}

/* Status Overview Cards */
.status-overview {
  margin-bottom: 2rem;
}

.status-card {
  background: white;
  border-radius: var(--border-radius);
  padding: 2rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
}

.status-card.clickable:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.status-card.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.status-card.disabled:hover {
  transform: none;
}

.status-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: #e5e7eb;
  transition: var(--transition);
}

.status-card.operational::before {
  background: var(--success-gradient);
}

.status-card.degraded::before {
  background: var(--warning-gradient);
}

.status-card.partial-outage::before,
.status-card.major-outage::before {
  background: var(--danger-gradient);
}

.status-card .card-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #6b7280;
}

.status-card.operational .card-icon {
  color: var(--success-color);
}

.status-card.degraded .card-icon {
  color: var(--warning-color);
}

.status-card.partial-outage .card-icon,
.status-card.major-outage .card-icon {
  color: var(--danger-color);
}

.card-number {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.card-label {
  font-size: 1rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.card-hover-effect {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  transition: left 0.5s;
}

.status-card:hover .card-hover-effect {
  left: 100%;
}

/* Filter Section */
.filter-section {
  margin-bottom: 2rem;
}

.filter-tabs {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.filter-tab {
  background: white;
  border: 2px solid #e5e7eb;
  border-radius: var(--border-radius);
  padding: 1rem 1.5rem;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-tab:hover {
  border-color: #d1d5db;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.filter-tab.active {
  background: var(--primary-gradient);
  border-color: transparent;
  color: white;
  box-shadow: var(--shadow-light);
}

.tab-count {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 700;
}

.filter-tab.active .tab-count {
  background: rgba(255, 255, 255, 0.3);
}

/* Services Grid */
.services-section {
  margin-bottom: 2rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: 1.5rem;
}

.service-card {
  background: white;
  border-radius: var(--border-radius);
  padding: 1.5rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  border-left: 4px solid #e5e7eb;
  position: relative;
  overflow: hidden;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.service-card.operational {
  border-left-color: var(--success-color);
}

.service-card.degraded {
  border-left-color: var(--warning-color);
}

.service-card.partial-outage,
.service-card.major-outage {
  border-left-color: var(--danger-color);
}

.service-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.service-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--border-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: #f3f4f6;
  color: #6b7280;
  flex-shrink: 0;
}

.service-card.operational .service-icon {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success-color);
}

.service-card.degraded .service-icon {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning-color);
}

.service-card.partial-outage .service-icon,
.service-card.major-outage .service-icon {
  background: rgba(239, 68, 68, 0.1);
  color: var(--danger-color);
}

.service-info {
  flex: 1;
  min-width: 0;
}

.service-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.25rem;
  word-break: break-word;
}

.service-type {
  font-size: 0.9rem;
  color: #6b7280;
  margin: 0;
}

.service-status {
  flex-shrink: 0;
}

.status-indicator {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: white;
  font-weight: 600;
}

.status-indicator.operational {
  background: var(--success-color);
}

.status-indicator.degraded {
  background: var(--warning-color);
}

.status-indicator.partial-outage,
.status-indicator.major-outage {
  background: var(--danger-color);
}

.service-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid #f3f4f6;
}

.status-text {
  font-weight: 600;
  font-size: 0.9rem;
}

.service-card.operational .status-text {
  color: var(--success-color);
}

.service-card.degraded .status-text {
  color: var(--warning-color);
}

.service-card.partial-outage .status-text,
.service-card.major-outage .status-text {
  color: var(--danger-color);
}

.update-time {
  font-size: 0.8rem;
  color: #9ca3af;
}

.service-pulse {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--success-color);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.service-card:hover .service-pulse {
  transform: scaleX(1);
}

/* Empty States */
.empty-state,
.filter-empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: #6b7280;
}

.empty-icon {
  font-size: 4rem;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.empty-state h3,
.filter-empty-state h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #374151;
}

.empty-state p,
.filter-empty-state p {
  font-size: 1rem;
  margin: 0;
}

/* Toast Notifications */
.toast-notification {
  position: fixed;
  top: 2rem;
  right: 2rem;
  background: white;
  border-radius: var(--border-radius-sm);
  padding: 1rem 1.5rem;
  box-shadow: var(--shadow-heavy);
  border-left: 4px solid;
  z-index: 1000;
  transform: translateX(100%);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 400px;
}

.toast-notification.show {
  transform: translateX(0);
}

.toast-notification.success {
  border-left-color: var(--success-color);
  color: var(--success-color);
}

.toast-notification.error {
  border-left-color: var(--danger-color);
  color: var(--danger-color);
}

/* Animations */
@keyframes pulse-success {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

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

@keyframes pulse-danger {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

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

.fade-in {
  animation: fade-in 0.3s ease-out;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .services-grid {
      grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  }
}

@media (max-width: 768px) {
  .status-title {
      font-size: 2rem;
  }
    
  .status-hero {
      flex-direction: column;
      text-align: center;
      gap: 1rem;
  }
    
  .dashboard-header {
      padding: 1.5rem 0;
  }
    
  .services-grid {
      grid-template-columns: 1fr;
      gap: 1rem;
  }
    
  .service-card {
      padding: 1rem;
  }
    
  .filter-tabs {
      flex-direction: column;
  }
    
  .filter-tab {
      justify-content: center;
  }
    
  .status-overview .row {
      gap: 1rem;
  }
    
  .toast-notification {
      top: 1rem;
      right: 1rem;
      left: 1rem;
      max-width: none;
  }
}

@media (max-width: 576px) {
  .status-icon {
      width: 60px;
      height: 60px;
      font-size: 2rem;
  }
    
  .status-title {
      font-size: 1.5rem;
  }
    
  .card-number {
      font-size: 2rem;
  }
    
  .service-header {
      flex-direction: column;
      align-items: center;
      text-align: center;
  }
    
  .service-footer {
      flex-direction: column;
      gap: 0.5rem;
      align-items: center;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  :root {
      --primary-gradient: linear-gradient(135deg, #1e293b 0%, #334155 100%);
  }
    
  body {
      background: var(--dark-gradient);
      color: #f1f5f9;
  }
    
  .service-card,
  .status-card,
  .filter-tab {
      background: #1e293b;
      color: #f1f5f9;
      border-color: #334155;
  }
    
  .service-icon {
      background: #334155;
  }
    
  .service-footer {
      border-top-color: #334155;
  }
    
  .toast-notification {
      background: #1e293b;
      color: #f1f5f9;
  }
}

/* Loading states */
.loading {
  opacity: 0.7;
  pointer-events: none;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid #f3f4f6;
  border-top: 2px solid var(--info-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Utility classes */
.text-gradient {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.glass-effect {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
}

/* Add these styles to your existing CSS */

.service-location {
    font-size: 0.8rem;
    color: #9ca3af;
    margin-left: 0.5rem;
}

.service-rg {
    font-size: 0.8rem;
    color: #6b7280;
    margin: 0.25rem 0 0 0;
}

.service-type {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Cloud service specific styling */
.service-card[data-service*="cloud"] .service-icon {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.service-card[data-service*="cloud"].operational .service-icon {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}
.badge.badge-primary{
    color:black;
}
.badge.badge-secondary {
    color: black;
}

.badge.badge-success {
    color: var(--success-color);
}
.badge.badge-danger {
    color: var(--danger-color);
}
.badge.badge-warning {
    color: var(--warnings-color);  
}
.modal-content {
    background: #3d8bf3 !important;
    border:1px solid #3d8bf3 !important;
}
.incident-form label{
    color:black;
}
.badge.badge-info{
    color:black;
}
.affected-services-link {
    color: #4b4bd6;
    text-decoration: none;
    border-bottom: 1px dashed;
}

    .affected-services-link:hover {
        color: #0d6efd;
        border-bottom: 1px solid;
    }
.affected-services-link {
    color: #4b4bd6;
    text-decoration: none;
    border-bottom: 1px dashed;
    cursor: pointer;
}

    .affected-services-link:hover {
        color: #0d6efd;
        border-bottom: 1px solid;
    }

.service-type-name {
    font-weight: 600;
    margin-bottom: 15px;
    padding-bottom: 5px;
    border-bottom: 1px solid #eee;
}