/* Fix horizontal scrolling completely */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden !important;
  width: 100vw;
  max-width: 100vw;
}

body, html {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #f8fafc;
  min-height: 100vh;
  color: #1e293b;
}

.dashboard-futuristic {
  background: #f8fafc;
  min-height: 100vh;
  padding: 0;
  margin: 0;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
}

.main-dashboard-container {
  margin: 0;
  padding: 32px;
  width: calc(100vw - 260px);
  max-width: calc(100vw - 260px);
  overflow-x: hidden !important;
  transition: all 0.3s ease;
}

/* Dashboard Header */
.dashboard-header {
  margin-bottom: 32px;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dashboard-title {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.header-user {
  display: flex;
  align-items: center;
  gap: 16px;
}

.user-welcome {
  color: #64748b;
  font-size: 14px;
}

/* Metrics Grid */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
  margin-bottom: 48px;
  max-width: 100%;
  overflow: hidden;
}

.metric-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: all 0.2s ease;
}

.metric-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.metric-card.active {
  border-color: #3b82f6;
  background: #f0f9ff;
}

.metric-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.metric-label {
  color: #64748b;
  font-size: 14px;
  font-weight: 500;
}

.metric-icon {
  color: #94a3b8;
}

.metric-value {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}

.metric-change {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 500;
}

.metric-change.up {
  color: #10b981;
}

.metric-change.neutral {
  color: #64748b;
}

.change-icon {
  display: flex;
  align-items: center;
}

/* Charts Grid */
.charts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 32px;
  max-width: 100%;
  overflow: hidden;
}

.chart-card {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
}

.chart-header {
  padding: 20px 24px;
  border-bottom: 1px solid #e2e8f0;
}

.chart-title {
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
}

.chart-content {
  padding: 24px;
}

/* Status Chart */
.status-chart {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.status-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.status-item:hover {
  background: #f1f5f9;
}

.status-indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-right: 12px;
}

.status-label {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: #475569;
}

.status-count {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

/* Account Info */
.account-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.info-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid #f1f5f9;
}

.info-item:last-child {
  border-bottom: none;
}

.info-label {
  color: #64748b;
  font-size: 14px;
  font-weight: 500;
  min-width: 100px;
}

.info-value {
  color: #0f172a;
  font-size: 14px;
  font-weight: 500;
  text-align: right;
}

.api-token-display {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.token-code {
  background: #f1f5f9;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12px;
  color: #475569;
  border: 1px solid #e2e8f0;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  word-break: break-all;
  flex: 1;
  min-width: 0;
}

.copy-token-btn {
  background: #3b82f6;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.copy-token-btn:hover {
  background: #2563eb;
}

.copy-token-btn.copied {
  background: #10b981;
}

/* Modern Filters - Complete Redesign */
.filters-container {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 32px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  max-width: 100%;
  overflow: hidden;
}

.filters-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f1f5f9;
}

.filters-title {
  font-size: 18px;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

.filters-count {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
}

.filters-grid {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: flex-end;
  max-width: 100%;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  flex-shrink: 0;
}

.filter-group:first-child {
  width: 120px;
  min-width: 120px;
}

.filter-group:nth-child(2) {
  width: 160px;
  min-width: 160px;
}

.filter-group.filter-search {
  flex: 1;
  min-width: 180px;
  max-width: calc(100% - 300px);
}

.filter-tag {
  font-size: 12px;
  font-weight: 600;
  color: #4b5563;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modern-select,
.modern-input {
  height: 42px;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: #1f2937;
  background: #fafbfc;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  width: 100%;
}

.modern-select {
  padding: 0 16px;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%234b5563' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 14px center;
  background-repeat: no-repeat;
  background-size: 16px 16px;
  padding-right: 44px;
  appearance: none;
  cursor: pointer;
}

.modern-input {
  padding: 0 16px;
}

.modern-select:focus,
.modern-input:focus {
  outline: none;
  border-color: #3b82f6;
  background: white;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.06);
}

.modern-select:hover,
.modern-input:hover {
  border-color: #d1d5db;
}

.search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 14px;
  color: #9ca3af;
  z-index: 1;
  pointer-events: none;
}

.search-input {
  padding-left: 44px !important;
}

.modern-input::placeholder {
  color: #9ca3af;
  font-weight: 400;
}

/* Responsive Filters */
@media (max-width: 1024px) {
  .filters-grid {
    gap: 16px;
  }
  
  .filter-group:first-child,
  .filter-group:nth-child(2) {
    width: 160px;
  }
  
  .filter-group.filter-search {
    min-width: 200px;
  }
}

@media (max-width: 768px) {
  .filters-container {
    padding: 20px;
    margin-bottom: 24px;
  }
  
  .filters-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 16px;
  }
  
  .filters-grid {
    flex-direction: column;
    gap: 16px;
  }
  
  .filter-group,
  .filter-group:first-child,
  .filter-group:nth-child(2),
  .filter-group.filter-search {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }
}

/* Fix main container for horizontal scrolling */
.main-dashboard-container {
  max-width: none;
  margin: 0;
  padding: 24px;
  width: 100%;
  overflow-x: hidden;
}

.dashboard-futuristic {
  overflow-x: hidden;
  width: 100%;
}

/* Ensure tables don't cause horizontal scroll */
.responsive-leads-table {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.leads-table table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 500;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-secondary {
  background: white;
  color: #374151;
  border-color: #d1d5db;
}

.btn-secondary:hover {
  background: #f9fafb;
  border-color: #9ca3af;
}

/* Tables */
.leads-table {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  max-width: 100%;
}

.leads-table table {
  width: 100%;
  border-collapse: collapse;
}

.leads-table th,
.leads-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #f1f5f9;
  font-size: 14px;
}

.leads-table th {
  background: #f8fafc;
  font-weight: 600;
  color: #374151;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.leads-table tr:hover {
  background: #f8fafc;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 6px;
  text-transform: capitalize;
}

.badge.fixed {
  background: #dcfce7;
  color: #166534;
}

.badge.partial {
  background: #fef3c7;
  color: #92400e;
}

.badge.not_fixed {
  background: #f1f5f9;
  color: #475569;
}

.badge.error {
  background: #fee2e2;
  color: #991b1b;
}

/* Responsive */
@media (max-width: 768px) {
  .charts-grid {
    grid-template-columns: 1fr;
  }
  
  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .main-dashboard-container {
    padding: 16px;
  }
}

@media (max-width: 480px) {
  .metrics-grid {
    grid-template-columns: 1fr;
  }
}

/* Modern Sidebar Design */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 260px;
  max-width: 260px;
  background: linear-gradient(180deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  z-index: 100;
  box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  overflow-x: hidden;
}

.sidebar-header {
  padding: 16px 18px 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-logo.large-logo {
  justify-content: center;
  align-items: center;
  display: flex;
  padding: 12px 0;
  margin: 0;
}

.large-logo-image {
  width: 120px !important;
  height: 120px !important;
  filter: brightness(0) invert(1);
  display: block;
  margin: 0 auto;
  object-fit: contain;
}

.nav-section {
  padding: 0 18px;
  margin-top: 8px;
}

.sidebar-nav {
  flex: 1;
  padding: 20px 0;
  overflow-y: auto;
}

.nav-title {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
  padding-left: 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  border-radius: 12px;
  margin-bottom: 4px;
  transition: all 0.2s ease;
}

.nav-link span {
  transition: opacity 0.3s ease;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  transform: translateX(4px);
}

.nav-link.active {
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.nav-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.sidebar-footer {
  padding: 16px 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.2);
}

.api-section {
  margin-bottom: 20px;
  transition: all 0.3s ease;
}

.api-title {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.api-container {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.api-key-display {
  flex: 1;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.8);
  word-break: break-all;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  line-height: 1.4;
}

.api-copy-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.api-copy-btn:hover {
  background: rgba(59, 130, 246, 0.3);
  border-color: rgba(59, 130, 246, 0.5);
  transform: translateY(-1px);
}

.api-copy-btn.copied {
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
  border-color: rgba(34, 197, 94, 0.3);
}

.copy-icon {
  width: 14px;
  height: 14px;
}

.user-section {
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  background: rgba(59, 130, 246, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(59, 130, 246, 0.3);
}

.user-avatar svg {
  width: 20px;
  height: 20px;
  color: #3b82f6;
}

.user-details {
  flex: 1;
  transition: all 0.3s ease;
}

.user-name {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 2px;
}

.user-company {
  font-size: 13px;
  color: #60a5fa;
  font-weight: 500;
  margin-bottom: 2px;
}

.user-email {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 2px;
}

.user-role {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Missing Table and Detail Styles */
.responsive-leads-table {
  width: 100%;
  overflow-x: auto;
}

.proof-btn {
  background: #3b82f6;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.proof-btn:hover {
  background: #2563eb;
  transform: scale(1.02);
}

.lead-details-row {
  background: #f8fafc;
}

.lead-details-row td {
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
  padding: 16px;
}

.lead-details-card {
  background: white;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.lead-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 24px;
  margin-top: 12px;
}

.details-section {
  background: white;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e2e8f0;
}

.details-label {
  font-size: 16px;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 12px;
}

.details-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.details-list li {
  padding: 8px 12px;
  background: #f8fafc;
  border-radius: 6px;
  border-left: 3px solid #3b82f6;
  font-size: 14px;
  line-height: 1.4;
}

.details-list li b {
  color: #1f2937;
  font-weight: 600;
}

/* Before/After Styling */
.before {
  color: #6b7280;
  text-decoration: line-through;
  font-style: italic;
}

.after {
  color: #059669;
  font-weight: 600;
}

/* Input and Filter Elements */
.input_container {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.input_label {
  font-size: 14px;
  font-weight: 500;
  color: #374151;
}

.input_field {
  width: 100%;
  padding: 8px 12px;
  font-size: 14px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background: white;
  color: #1f2937;
  transition: border-color 0.2s ease;
}

.input_field:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

select.input_field {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 8px center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 32px;
  appearance: none;
}

/* Copy Button Styles */
.copy-btn {
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  color: #374151;
  font-size: 12px;
  font-weight: 500;
  padding: 6px 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.copy-btn:hover {
  background: #e5e7eb;
  border-color: #9ca3af;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .lead-details-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .lead-details-card {
    padding: 12px;
  }
  
  .leads-table table {
    min-width: 600px;
  }
} 

/* Main content with sidebar */
.with-sidebar {
  margin-left: 260px;
  width: calc(100vw - 260px);
  max-width: calc(100vw - 260px);
  overflow-x: hidden !important;
}

/* Responsive design */
@media (max-width: 900px) {
  .sidebar {
    width: 80px;
    max-width: 80px;
  }
  
  .sidebar-header {
    padding: 20px 0;
    text-align: center;
  }
  
  .large-logo-image {
    width: 50px !important;
    height: 50px !important;
  }
  
  .nav-section {
    padding: 0 12px;
  }
  
  .nav-link {
    justify-content: center;
    padding: 12px 8px;
    margin-bottom: 8px;
  }
  
  .nav-link span {
    display: none;
  }
  
  .sidebar-footer {
    padding: 16px 8px;
  }
  
  .api-section {
    display: none;
  }
  
  .user-details {
    display: none;
  }
  
  .with-sidebar {
    margin-left: 80px;
    width: calc(100vw - 80px);
    max-width: calc(100vw - 80px);
  }
  
  .main-dashboard-container {
    width: calc(100vw - 80px);
    max-width: calc(100vw - 80px);
    padding: 20px;
  }
}

@media (max-width: 768px) {
  .charts-grid {
    grid-template-columns: 1fr;
  }
  
  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .main-dashboard-container {
    padding: 16px;
  }
} 

/* Modern Metrics Cards */
.metric-card-clean {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 32px 28px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: flex-start;
  gap: 24px;
  transition: all 0.3s ease;
  cursor: pointer;
  box-shadow: 
    0 8px 24px rgba(30, 58, 138, 0.1),
    0 4px 12px rgba(99, 102, 241, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.metric-card-clean:hover {
  transform: translateY(-3px);
  border-color: #3b82f6;
  box-shadow: 
    0 16px 40px rgba(59, 130, 246, 0.15),
    0 8px 20px rgba(30, 58, 138, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.metric-card-clean.active {
  border-color: #3b82f6;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(30, 58, 138, 0.04) 100%);
  box-shadow: 
    0 12px 32px rgba(59, 130, 246, 0.25),
    0 6px 16px rgba(30, 58, 138, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transform: translateY(-1px);
}

.metric-icon-clean {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, #3b82f6 0%, #1e3a8a 100%);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(59, 130, 246, 0.25);
}

.metric-content-clean {
  flex: 1;
}

.metric-value-clean {
  font-size: 36px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
  margin-bottom: 12px;
  letter-spacing: -0.025em;
}

.metric-label-clean {
  font-size: 18px;
  color: #374151;
  font-weight: 600;
  margin-bottom: 16px;
  letter-spacing: -0.025em;
}

.metric-description {
  font-size: 15px;
  color: #6b7280;
  font-weight: 400;
  line-height: 1.6;
  margin-top: 12px;
}

/* Error Detection Details */
.error-details-section {
  margin: 32px 0;
  padding: 24px;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

.section-title {
  font-size: 20px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 20px;
}

.error-stats-grid, .fix-types-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.error-stat-card, .fix-type-card {
  padding: 20px;
  background: #f8fafc;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.error-stat-header, .fix-type-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.error-stat-header h4, .fix-type-header h4 {
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  margin: 0;
}

.error-stat-value, .fix-type-count {
  font-size: 24px;
  font-weight: 700;
  color: #1f2937;
}

.error-stat-description, .fix-type-description {
  font-size: 13px;
  color: #6b7280;
  margin: 0;
  line-height: 1.4;
}

.error-types-list {
  margin-top: 12px;
}

.error-type-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e5e7eb;
}

.error-type-item:last-child {
  border-bottom: none;
}

.error-type-name {
  font-size: 13px;
  color: #374151;
  font-weight: 500;
}

.error-type-count {
  font-size: 13px;
  color: #6b7280;
  font-weight: 600;
}

/* Removed mini trend graphs - using clean descriptions instead */

/* Beautiful Footer */
.footer {
  margin-top: 60px;
  padding: 40px 32px;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  border-top: 1px solid #e5e7eb;
  border-radius: 12px 12px 0 0;
  text-align: center;
  color: #64748b;
  font-size: 14px;
  font-weight: 500;
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6, #06b6d4, #10b981);
  background-size: 200% 100%;
  animation: footerGlow 3s ease-in-out infinite;
}

@keyframes footerGlow {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.footer-content {
  position: relative;
  z-index: 1;
}

.footer-logo {
  margin-bottom: 12px;
  opacity: 0.8;
}

.footer-text {
  margin: 0;
  line-height: 1.6;
  letter-spacing: 0.025em;
}

.footer-links {
  margin-top: 16px;
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-link {
  color: #64748b;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: #3b82f6;
}

@media (max-width: 768px) {
  .footer {
    padding: 32px 20px;
    margin-top: 40px;
  }
  
  .footer-links {
    flex-direction: column;
    gap: 12px;
  }
}

/* Clean Dropdown Styles */
.clean-dropdown-container {
  padding: 24px;
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.dropdown-header {
  display: flex;
  gap: 24px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f3f4f6;
}

.header-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-label {
  font-weight: 600;
  color: #374151;
  font-size: 14px;
}

.status-badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.status-fixed { background: #dcfce7; color: #166534; }
.status-partial { background: #fef3c7; color: #92400e; }
.status-not_fixed { background: #fee2e2; color: #991b1b; }
.status-error { background: #fee2e2; color: #991b1b; }

.form-name {
  background: #f3f4f6;
  padding: 4px 8px;
  border-radius: 6px;
  font-family: monospace;
  font-size: 13px;
  color: #4b5563;
}

.comparison-section {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  margin-bottom: 24px;
  align-items: start;
}

.comparison-side {
  background: #f9fafb;
  border-radius: 8px;
  padding: 16px;
}

.comparison-side h4 {
  margin: 0 0 12px 0;
  color: #1f2937;
  font-size: 14px;
  font-weight: 600;
}

.data-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.data-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 8px;
  align-items: center;
}

.field-name {
  font-size: 12px;
  color: #6b7280;
  font-weight: 500;
}

.field-value {
  font-family: monospace;
  font-size: 13px;
  color: #1f2937;
  background: #ffffff;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #e5e7eb;
  word-break: break-all;
}

.comparison-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #6b7280;
  font-weight: bold;
  padding-top: 30px;
}

.issues-summary {
  border-top: 1px solid #f3f4f6;
  padding-top: 20px;
}

.issues-summary h4 {
  margin: 0 0 16px 0;
  color: #1f2937;
  font-size: 14px;
  font-weight: 600;
}

.issues-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.issue-item {
  padding: 12px 16px;
  border-radius: 8px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 14px;
  line-height: 1.5;
}

.issue-item.issue-success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
}

.issue-item.issue-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
}

.issue-item b {
  font-weight: 600;
}

/* Address Analysis styles */
.analysis-section {
  border-top: 1px solid #f3f4f6;
  padding-top: 20px;
  margin-top: 20px;
}

.analysis-section h4 {
  margin: 0 0 16px 0;
  color: #0369a1;
  font-size: 14px;
  font-weight: 600;
}

.analysis-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.analysis-item {
  padding: 8px 12px;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: 6px;
  font-size: 13px;
  color: #0c4a6e;
}

.analysis-item strong {
  color: #0369a1;
  font-weight: 600;
}

/* Eniro Lookup styles */
.eniro-section {
  border-top: 1px solid #f3f4f6;
  padding-top: 20px;
  margin-top: 20px;
}

.eniro-section h4 {
  margin: 0 0 16px 0;
  color: #a16207;
  font-size: 14px;
  font-weight: 600;
}

.eniro-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.eniro-item {
  padding: 8px 12px;
  background: #fefce8;
  border: 1px solid #fde047;
  border-radius: 6px;
  font-size: 13px;
  color: #92400e;
}

.eniro-item strong {
  color: #a16207;
  font-weight: 600;
}

.eniro-item.success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.eniro-item.success strong {
  color: #15803d;
}

.eniro-item.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
}

.eniro-item.error strong {
  color: #b91c1c;
}

/* Modern Analytics Dashboard - Sleeker, Lighter, Smoother */
.analytics-dashboard {
  margin: 32px 0;
  padding: 32px;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  border-radius: 14px;
  border: 1px solid #f1f5f9;
  box-shadow: 0 2px 8px rgba(30,58,138,0.04);
}

.analytics-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.analytics-card {
  background: #f8fafc;
  border-radius: 12px;
  padding: 24px 20px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 1px 4px rgba(30,58,138,0.03);
  transition: box-shadow 0.2s, transform 0.2s;
  position: relative;
  overflow: hidden;
}
.analytics-card:hover {
  transform: translateY(-1px) scale(1.01);
  box-shadow: 0 4px 16px rgba(30,58,138,0.07);
}
.analytics-card.primary {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0e7ff 100%);
  border-color: #dbeafe;
}
.analytics-card.secondary {
  background: linear-gradient(135deg, #fef2f2 0%, #f3e8ff 100%);
  border-color: #fca5a5;
}
.analytics-card.success {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdf4 100%);
  border-color: #bbf7d0;
}
.metric-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.metric-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #3b82f6 0%, #1e3a8a 100%);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 18px;
  box-shadow: 0 2px 8px rgba(59,130,246,0.15);
}
.analytics-card.secondary .metric-icon {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.analytics-card.success .metric-icon {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.trend-indicator {
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 11px;
  font-weight: 500;
  padding: 2px 6px;
  border-radius: 4px;
  color: white;
  opacity: 0.85;
}
.trend-indicator.positive {
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
}
.trend-indicator.negative {
  background: linear-gradient(135deg, #f87171 0%, #dc2626 100%);
}
.metric-value {
  font-size: 28px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.metric-label {
  font-size: 15px;
  color: #334155;
  font-weight: 500;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
.metric-chart {
  height: 6px;
  background: #e0e7ef;
  border-radius: 4px;
  margin-bottom: 12px;
  overflow: hidden;
}
.chart-bar {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6 0%, #1e3a8a 100%);
  border-radius: 3px;
  transition: width 0.5s;
}
.analytics-card.secondary .chart-bar {
  background: linear-gradient(90deg, #ef4444 0%, #dc2626 100%);
}
.analytics-card.success .chart-bar {
  background: linear-gradient(90deg, #10b981 0%, #059669 100%);
}
.metric-description {
  font-size: 13px;
  color: #64748b;
  font-weight: 400;
  line-height: 1.4;
}
.analytics-charts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}
.chart-card {
  background: #f8fafc;
  border-radius: 10px;
  padding: 14px 10px 10px 10px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 1px 4px rgba(30,58,138,0.03);
}
.chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.chart-header h4 {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
}
.chart-legend {
  display: flex;
  gap: 8px;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  color: #6b7280;
  font-weight: 500;
}
.legend-color {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}
.legend-color.fixed { background: #10b981; }
.legend-color.partial { background: #f59e0b; }
.legend-color.unfixed { background: #ef4444; }
.chart-period {
  font-size: 10px;
  color: #6b7280;
  font-weight: 500;
}
.pie-chart {
  position: relative;
  width: 90px;
  height: 90px;
  margin: 0 auto;
}
.pie-segment {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  clip-path: polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%, 0% 100%, 0% 0%);
  transform: rotate(calc(var(--percentage) * 3.6deg));
}
.pie-segment.fixed {
  background: conic-gradient(from 0deg, #10b981 0deg, #10b981 calc(var(--percentage) * 3.6deg), transparent calc(var(--percentage) * 3.6deg));
}
.pie-segment.partial {
  background: conic-gradient(from calc(var(--percentage) * 3.6deg), #f59e0b calc(var(--percentage) * 3.6deg), #f59e0b calc(var(--percentage) * 7.2deg), transparent calc(var(--percentage) * 7.2deg));
}
.pie-segment.unfixed {
  background: conic-gradient(from calc(var(--percentage) * 7.2deg), #ef4444 calc(var(--percentage) * 7.2deg), #ef4444 calc(var(--percentage) * 10.8deg), transparent calc(var(--percentage) * 10.8deg));
}
.pie-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  background: white;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.pie-value {
  font-size: 11px;
  font-weight: 600;
  color: #0f172a;
}
.pie-label {
  font-size: 8px;
  color: #6b7280;
  font-weight: 500;
}
.bar-chart {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bar-item {
  display: flex;
  align-items: center;
  gap: 6px;
}
.bar-label {
  width: 70px;
  font-size: 10px;
  color: #374151;
  font-weight: 500;
}
.bar-container {
  flex: 1;
  height: 12px;
  background: #e0e7ef;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  border-radius: 6px;
  transition: width 0.5s;
  position: relative;
}
.bar-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.12) 50%, transparent 100%);
}
.bar-value {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 9px;
  font-weight: 600;
  color: #334155;
  text-shadow: none;
}
.mini-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}
.mini-stat-card {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  border-radius: 16px;
  padding: 20px 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all 0.3s ease;
  cursor: pointer;
  box-shadow: 
    0 4px 12px rgba(30, 58, 138, 0.1),
    0 2px 6px rgba(99, 102, 241, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
}
.mini-stat-card:hover {
  transform: translateY(-2px);
  border-color: #3b82f6;
  box-shadow: 
    0 8px 20px rgba(59, 130, 246, 0.15),
    0 4px 10px rgba(30, 58, 138, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
.mini-stat-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #3b82f6 0%, #1e3a8a 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.25);
}
.mini-stat-content {
  flex: 1;
  min-width: 0;
}
.mini-stat-value {
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
  margin-bottom: 4px;
  letter-spacing: -0.025em;
}
.mini-stat-label {
  font-size: 13px;
  color: #6b7280;
  font-weight: 600;
  letter-spacing: -0.025em;
  text-transform: uppercase;
}
@media (max-width: 768px) {
  .analytics-metrics-grid {
    grid-template-columns: 1fr;
  }
  .analytics-charts-grid {
    grid-template-columns: 1fr;
  }
  .mini-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .metric-value {
    font-size: 16px;
  }
  .pie-chart {
    width: 60px;
    height: 60px;
  }
  .pie-center {
    width: 22px;
    height: 22px;
  }
  .pie-value {
    font-size: 8px;
  }
  .chart-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .chart-legend {
    flex-wrap: wrap;
    gap: 4px;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .comparison-section {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .comparison-arrow {
    display: none;
  }
  
  .dropdown-header {
    flex-direction: column;
    gap: 12px;
  }
  
  .data-item {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* Process Explanation Styles */
.process-explanation-section,
.specific-process-section {
  background: #ffffff;
  border-radius: 12px;
  padding: 24px;
  margin: 16px 0;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.process-explanation-section h4,
.specific-process-section h4 {
  color: #0f172a;
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 20px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.process-explanation-section h5,
.specific-process-section h5 {
  color: #374151;
  font-size: 16px;
  font-weight: 600;
  margin: 20px 0 12px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Data Sources */
.data-sources {
  margin-bottom: 24px;
}

.source-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.source-card {
  background: #f8fafc;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.source-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.source-card.dawa {
  border-left: 4px solid #10b981;
}

.source-card.eniro {
  border-left: 4px solid #3b82f6;
}

.source-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.source-icon {
  font-size: 24px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.source-info h6 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.source-reliability {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
}

.source-description {
  font-size: 13px;
  color: #475569;
  line-height: 1.5;
  margin: 8px 0;
}

.source-coverage {
  font-size: 12px;
  color: #64748b;
  margin-top: 8px;
}

/* Process Steps */
.process-steps {
  margin-bottom: 24px;
}

.steps-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 12px;
}

.process-step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: #f8fafc;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e2e8f0;
}

.step-number {
  width: 32px;
  height: 32px;
  background: #3b82f6;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  flex-shrink: 0;
}

.step-content {
  flex: 1;
}

.step-content h6 {
  margin: 0 0 8px 0;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.step-content p {
  margin: 0 0 12px 0;
  font-size: 13px;
  color: #475569;
  line-height: 1.5;
}

.step-fixes,
.step-methods,
.step-conditions {
  margin-top: 8px;
}

.step-fixes strong,
.step-methods strong,
.step-conditions strong {
  font-size: 12px;
  color: #374151;
  font-weight: 600;
}

.step-fixes ul,
.step-methods ul,
.step-conditions ul {
  margin: 4px 0 0 0;
  padding-left: 16px;
}

.step-fixes li,
.step-methods li,
.step-conditions li {
  font-size: 12px;
  color: #64748b;
  margin: 2px 0;
}

/* Quality Assurance */
.quality-assurance {
  margin-bottom: 24px;
}

.qa-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.qa-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #475569;
  padding: 8px 12px;
  background: #f0f9ff;
  border-radius: 6px;
  border: 1px solid #bae6fd;
}

.qa-icon {
  font-size: 16px;
  color: #10b981;
}

/* Specific Process Details */
.validation-method,
.data-source-details,
.quality-checks {
  margin-bottom: 20px;
}

.method-info,
.source-details,
.checks-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.method-item,
.source-detail-item,
.check-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: #f8fafc;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.method-item strong,
.source-detail-item .source-label,
.check-item .check-label {
  font-size: 13px;
  color: #374151;
  font-weight: 500;
}

.source-badge,
.status-badge,
.certainty-badge,
.source-status,
.check-status {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 4px;
}

.source-badge.dawa {
  background: #dcfce7;
  color: #166534;
}

.source-badge.eniro {
  background: #dbeafe;
  color: #1e40af;
}

.source-badge.unknown {
  background: #f3f4f6;
  color: #374151;
}

.status-badge.success {
  background: #dcfce7;
  color: #166534;
}

.status-badge.error {
  background: #fee2e2;
  color: #991b1b;
}

.certainty-badge.high {
  background: #dcfce7;
  color: #166534;
}

.certainty-badge.medium {
  background: #fef3c7;
  color: #92400e;
}

.certainty-badge.low {
  background: #fee2e2;
  color: #991b1b;
}

.certainty-badge.none {
  background: #f3f4f6;
  color: #374151;
}

.source-status.yes {
  color: #166534;
}

.source-status.no {
  color: #991b1b;
}

.check-status.pass {
  color: #166534;
}

.check-status.fail {
  color: #991b1b;
}

.suggestions-count,
.similarity-score {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
}

/* Campaign Analytics Styles */
.campaign-analytics-section {
  margin: 48px 0;
  padding: 32px;
  background: white;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.campaign-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 24px;
  margin-bottom: 48px;
}

.campaign-card {
  background: #f8fafc;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.campaign-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.campaign-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.campaign-name {
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
}

.campaign-status-badge {
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.campaign-status-badge.excellent {
  background: #dcfce7;
  color: #166534;
}

.campaign-status-badge.good {
  background: #fef3c7;
  color: #92400e;
}

.campaign-status-badge.needs-improvement {
  background: #fee2e2;
  color: #991b1b;
}

.campaign-metrics {
  margin-bottom: 20px;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.metric-label {
  font-size: 14px;
  color: #64748b;
}

.metric-value {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.metric-value.success {
  color: #059669;
}

.metric-percentage {
  font-size: 12px;
  color: #64748b;
  margin-left: 8px;
}

.campaign-chart {
  margin-bottom: 20px;
}

.chart-bar-container {
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 8px;
}

.chart-bar.success {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #059669);
  transition: width 0.3s ease;
}

.chart-labels {
  text-align: center;
  font-size: 12px;
  color: #64748b;
}

.campaign-details {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.detail-item {
  flex: 1;
  text-align: center;
  padding: 12px;
  background: white;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.detail-label {
  display: block;
  font-size: 11px;
  color: #64748b;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.detail-value {
  display: block;
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

/* Error Types Section */
.error-types-section {
  margin-bottom: 48px;
}

.subsection-title {
  font-size: 20px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 24px;
  text-align: center;
}

.error-types-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.error-type-card {
  background: white;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.error-type-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.error-type-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.error-type-name {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.error-type-stats {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.error-type-count {
  font-size: 16px;
  font-weight: 700;
  color: #3b82f6;
}

.error-type-percentage {
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
}

.error-type-fix-info {
  margin: 12px 0;
  padding: 12px;
  background: #f8fafc;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.fix-stats-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.fix-stats-row:last-child {
  margin-bottom: 0;
}

.fix-label {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
}

.fix-count.success {
  font-size: 14px;
  font-weight: 600;
  color: #059669;
}

.fix-count.error {
  font-size: 14px;
  font-weight: 600;
  color: #dc2626;
}

.fix-rate {
  font-size: 11px;
  color: #64748b;
  font-weight: 500;
}

.error-type-bar {
  height: 6px;
  background: #f1f5f9;
  border-radius: 3px;
  overflow: hidden;
}

.error-type-progress {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #1d4ed8);
  transition: width 0.3s ease;
}

/* Daily Trends Section */
.daily-trends-section {
  margin-bottom: 32px;
}

.daily-trends-chart {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
}

.daily-bar {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
  padding: 12px;
  background: #f8fafc;
  border-radius: 8px;
}

.daily-bar:last-child {
  margin-bottom: 0;
}

.daily-date {
  min-width: 60px;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.daily-metrics {
  flex: 1;
  display: flex;
  gap: 24px;
  margin: 0 24px;
}

.daily-total {
  font-size: 14px;
  color: #64748b;
}

.daily-fixed {
  font-size: 14px;
  color: #059669;
  font-weight: 600;
}

.daily-chart {
  width: 120px;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

.daily-chart-bar {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #059669);
  transition: width 0.3s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
  .source-cards {
    grid-template-columns: 1fr;
  }
  
  .method-info,
  .source-details,
  .checks-list {
    grid-template-columns: 1fr;
  }
  
  .process-step {
    flex-direction: column;
    gap: 12px;
  }
  
  .step-number {
    align-self: flex-start;
  }
  
  .campaign-summary-grid {
    grid-template-columns: 1fr;
  }
  
  .error-types-grid {
    grid-template-columns: 1fr;
  }
  
  .campaign-details {
    flex-direction: column;
  }
  
  .daily-metrics {
    flex-direction: column;
    gap: 8px;
    margin: 0 16px;
  }
  
  .daily-chart {
    width: 80px;
  }
}

/* Campaign Analysis Page Styles */
.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.back-button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  color: #64748b;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.2s ease;
}

.back-button:hover {
  background: #e2e8f0;
  color: #475569;
}

.campaign-overview-section {
  margin-bottom: 48px;
}

.campaign-overview-card {
  background: white;
  border-radius: 16px;
  padding: 32px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.overview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
}

.overview-header h2 {
  font-size: 28px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.overview-stats {
  display: flex;
  gap: 32px;
}

.stat-item {
  text-align: center;
}

.stat-value {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
}

.stat-label {
  display: block;
  font-size: 14px;
  color: #64748b;
  margin-top: 4px;
}

.status-distribution h3 {
  font-size: 20px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 20px;
}

.status-bars {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.status-bar {
  display: flex;
  align-items: center;
  gap: 16px;
}

.status-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-width: 200px;
}

.status-name {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
}

.status-count {
  font-size: 14px;
  color: #64748b;
}

.status-progress {
  flex: 1;
  height: 8px;
  background: #f1f5f9;
  border-radius: 4px;
  overflow: hidden;
}

.status-fill {
  height: 100%;
  transition: width 0.3s ease;
}

.status-fill.status-fixed {
  background: linear-gradient(90deg, #10b981, #059669);
}

.status-fill.status-partial {
  background: linear-gradient(90deg, #f59e0b, #d97706);
}

.status-fill.status-not_fixed {
  background: linear-gradient(90deg, #ef4444, #dc2626);
}

.status-fill.status-error {
  background: linear-gradient(90deg, #ef4444, #dc2626);
}

.error-analysis-section {
  margin-bottom: 48px;
}

.error-analysis-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 24px;
}

.analysis-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.analysis-card h4 {
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 20px;
}

.error-list,
.fix-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.error-item,
.fix-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.error-info,
.fix-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-width: 200px;
}

.error-name,
.fix-name {
  font-size: 14px;
  font-weight: 500;
  color: #0f172a;
}

.error-stats,
.fix-stats {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.error-count,
.fix-count {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
}

.error-percentage,
.fix-percentage {
  font-size: 12px;
  font-weight: 600;
  color: #3b82f6;
}

.error-fix-breakdown {
  margin: 8px 0;
  padding: 8px;
  background: #f8fafc;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

.fix-breakdown-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2px;
}

.fix-breakdown-row:last-child {
  margin-bottom: 0;
}

.fix-breakdown-label {
  font-size: 11px;
  color: #64748b;
  font-weight: 500;
}

.fix-breakdown-count.success {
  font-size: 12px;
  font-weight: 600;
  color: #059669;
}

.fix-breakdown-count.error {
  font-size: 12px;
  font-weight: 600;
  color: #dc2626;
}

.fix-breakdown-rate {
  font-size: 10px;
  color: #64748b;
  font-weight: 500;
}

.error-bar,
.fix-bar {
  flex: 1;
  height: 6px;
  background: #f1f5f9;
  border-radius: 3px;
  overflow: hidden;
}

.error-fill {
  height: 100%;
  background: linear-gradient(90deg, #ef4444, #dc2626);
  transition: width 0.3s ease;
}

.fix-fill {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #059669);
  transition: width 0.3s ease;
}

.recent-leads-section {
  margin-bottom: 48px;
}

.error-count {
  color: #ef4444;
  font-weight: 600;
}

.fix-count {
  color: #10b981;
  font-weight: 600;
}

.no-errors {
  color: #10b981;
  font-weight: 600;
}

.no-fixes {
  color: #64748b;
}

/* Responsive Design for Campaign Analysis */
@media (max-width: 768px) {
  .header-left {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .overview-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  
  .overview-stats {
    flex-direction: row;
    gap: 24px;
  }
  
  .error-analysis-grid {
    grid-template-columns: 1fr;
  }
  
  .status-label,
  .error-info,
  .fix-info {
    min-width: 150px;
  }
}

/* Simple Statistics Styles */
.simple-stats-section {
  margin: 48px 0;
  padding: 32px;
  background: white;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.main-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
  margin-bottom: 48px;
}

.main-stat-card {
  background: #f8fafc;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.main-stat-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.main-stat-card.sellable {
  border-left: 4px solid #10b981;
}

.main-stat-card.fixed {
  border-left: 4px solid #3b82f6;
}

.main-stat-card.already-good {
  border-left: 4px solid #22c55e;
}

.main-stat-card.unsellable {
  border-left: 4px solid #ef4444;
}

.main-stat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.main-stat-icon {
  font-size: 24px;
}

.main-stat-title {
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
}

.main-stat-numbers {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.main-stat-count {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
}

.main-stat-percent {
  font-size: 20px;
  font-weight: 600;
  color: #64748b;
}

.main-stat-description {
  font-size: 14px;
  color: #64748b;
  line-height: 1.4;
}

.campaign-breakdown-section {
  margin-bottom: 32px;
}

.campaign-breakdown-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.campaign-breakdown-card {
  background: white;
  border-radius: 8px;
  padding: 20px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.campaign-breakdown-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.campaign-breakdown-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e2e8f0;
}

.campaign-breakdown-name {
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
}

.campaign-breakdown-total {
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
}

.campaign-breakdown-stats {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.campaign-breakdown-stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.campaign-breakdown-label {
  font-size: 14px;
  font-weight: 500;
  color: #0f172a;
}

.campaign-breakdown-value {
  font-size: 14px;
  font-weight: 600;
  color: #3b82f6;
}

/* Detailed Campaign Analysis Styles */
.detailed-campaign-section {
  margin-bottom: 32px;
}

.subsection-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.full-analysis-btn {
  background: #3b82f6;
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  transition: background-color 0.2s ease;
}

.full-analysis-btn:hover {
  background: #2563eb;
}

/* Campaign Analysis Styles */
.campaign-overview-section {
  margin: 32px 0;
}

.campaign-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.campaign-overview-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.campaign-overview-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.campaign-overview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}

.campaign-overview-name {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.campaign-overview-total {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
  background: #f1f5f9;
  padding: 6px 12px;
  border-radius: 6px;
}

.campaign-overview-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
}

.overview-stat {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 8px;
}

.overview-stat.sellable {
  background: #dcfce7;
  border: 1px solid #22c55e;
}

.overview-stat.unsellable {
  background: #fef2f2;
  border: 1px solid #ef4444;
}

.overview-stat-icon {
  font-size: 20px;
}

.overview-stat-info {
  flex: 1;
}

.overview-stat-label {
  font-size: 12px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 2px;
}

.overview-stat-numbers {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.overview-stat-count {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.overview-stat-percent {
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
}

.campaign-overview-actions {
  text-align: center;
}

.analyze-btn {
  background: #3b82f6;
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  transition: background-color 0.2s ease;
}

.analyze-btn:hover {
  background: #2563eb;
}

/* Campaign Analysis Styles */
.campaign-analysis-section {
  margin: 32px 0;
}

.campaign-analysis-header {
  margin-bottom: 32px;
}

.campaign-analysis-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.summary-card {
  background: white;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 16px;
}

.summary-card-icon {
  font-size: 24px;
}

.summary-card-info {
  flex: 1;
}

.summary-card-label {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 4px;
}

.summary-card-count {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
}

.summary-card-percent {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
}

/* Results */
.results-section {
  margin-top: 32px;
}

.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.results-header h3 {
  font-size: 20px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.results-count {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
  background: #f1f5f9;
  padding: 6px 12px;
  border-radius: 6px;
}

.no-results {
  text-align: center;
  padding: 64px 32px;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
}

.no-results-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.no-results h4 {
  font-size: 20px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 8px;
}

.no-results p {
  font-size: 16px;
  color: #64748b;
}

.leads-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 24px;
}

.lead-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.lead-card.sellable {
  border-left: 4px solid #22c55e;
}

.lead-card.unsellable {
  border-left: 4px solid #ef4444;
}

.lead-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.lead-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}

.lead-name {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}

.status-badge {
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}

.status-badge.sellable {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #22c55e;
}

.status-badge.unsellable {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #ef4444;
}

.lead-data {
  margin-bottom: 20px;
}

.data-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #f1f5f9;
}

.data-row:last-child {
  border-bottom: none;
}

.data-label {
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  min-width: 100px;
}

.data-value {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  text-align: right;
  flex: 1;
}

.fixes-applied {
  background: #f8fafc;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}

.fixes-title {
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 12px;
}

.fixes-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.fix-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: white;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.fix-icon {
  font-size: 16px;
}

.fix-description {
  font-size: 13px;
  color: #0f172a;
  flex: 1;
}

.lead-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid #e2e8f0;
}

.lead-date {
  font-size: 12px;
  color: #64748b;
}

/* Responsive for Campaign Analysis */
@media (max-width: 768px) {
  .campaign-overview-grid {
    grid-template-columns: 1fr;
  }
  
  .campaign-analysis-summary {
    grid-template-columns: 1fr;
  }
  
  .leads-grid {
    grid-template-columns: 1fr;
  }
  
  .lead-card-header {
    flex-direction: column;
    gap: 12px;
  }
  
  .data-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  
  .data-value {
    text-align: left;
  }
}

/* Real-Time Analysis Panel Styles */
.toggle-analysis-btn {
  background: #3b82f6;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.toggle-analysis-btn:hover {
  background: #2563eb;
}

.analysis-panel {
  background: #f8fafc;
  border-radius: 12px;
  padding: 24px;
  margin-top: 24px;
  border: 1px solid #e2e8f0;
}

.analysis-header {
  text-align: center;
  margin-bottom: 24px;
}

.analysis-header h3 {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}

.analysis-header p {
  font-size: 16px;
  color: #64748b;
  margin: 0;
}

.analysis-filters {
  background: white;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 24px;
  border: 1px solid #e2e8f0;
}

.analysis-results {
  background: white;
  border-radius: 8px;
  padding: 20px;
  border: 1px solid #e2e8f0;
}

.analysis-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.analysis-lead-card {
  background: white;
  border-radius: 8px;
  padding: 20px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.analysis-lead-card.sellable {
  border-left: 4px solid #22c55e;
}

.analysis-lead-card.unsellable {
  border-left: 4px solid #ef4444;
}

.analysis-lead-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.analysis-lead-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.analysis-lead-info {
  flex: 1;
}

.analysis-lead-name {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}

.analysis-lead-campaign {
  font-size: 14px;
  color: #64748b;
  font-weight: 500;
}

.analysis-lead-status {
  flex-shrink: 0;
}

.analysis-status-badge {
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}

.analysis-status-badge.sellable {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #22c55e;
}

.analysis-status-badge.unsellable {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #ef4444;
}

.analysis-lead-data {
  margin-bottom: 16px;
}

.analysis-data-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid #f8fafc;
  gap: 12px;
}

.analysis-data-row:last-child {
  border-bottom: none;
}

.analysis-data-label {
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  min-width: 100px;
  flex-shrink: 0;
}

.analysis-data-value {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  flex: 1;
  text-align: left;
}

.analysis-status {
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  flex-shrink: 0;
  white-space: nowrap;
}

.analysis-status.good {
  background: #dcfce7;
  color: #166534;
}

.analysis-status.fixed {
  background: #dbeafe;
  color: #1e40af;
}

.analysis-status.bad {
  background: #fef2f2;
  color: #dc2626;
}

.analysis-lead-meta {
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
}

.analysis-lead-date {
  font-size: 12px;
  color: #64748b;
}

/* Responsive for Analysis Panel */
@media (max-width: 768px) {
  .analysis-results-grid {
    grid-template-columns: 1fr;
  }
  
  .analysis-lead-header {
    flex-direction: column;
    gap: 12px;
  }
  
  .analysis-data-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  
  .analysis-data-value {
    text-align: left;
  }
}

.detailed-campaign-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 24px;
}

.detailed-campaign-card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.detailed-campaign-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.detailed-campaign-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid #e2e8f0;
}

.detailed-campaign-name {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
}

.detailed-campaign-total {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
  background: #f1f5f9;
  padding: 6px 12px;
  border-radius: 6px;
}

.detailed-campaign-summary {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.summary-stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: #f8fafc;
  border-radius: 6px;
}

.summary-label {
  font-size: 14px;
  font-weight: 500;
  color: #0f172a;
}

.summary-value {
  font-size: 14px;
  font-weight: 600;
  color: #3b82f6;
}

.summary-value.clickable {
  text-decoration: none;
  transition: all 0.2s ease;
}

.summary-value.clickable:hover {
  color: #1e40af;
  text-decoration: underline;
}

.fixes-breakdown {
  background: #f8fafc;
  border-radius: 8px;
  padding: 16px;
}

.fixes-title {
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 12px;
}

.fixes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.fix-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: white;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.fix-icon {
  font-size: 16px;
}

.fix-label {
  font-size: 13px;
  font-weight: 500;
  color: #0f172a;
  flex: 1;
}

.fix-count {
  font-size: 13px;
  font-weight: 700;
  color: #3b82f6;
  background: #dbeafe;
  padding: 2px 6px;
  border-radius: 4px;
  min-width: 20px;
  text-align: center;
}

/* Responsive Design for Simple Statistics */
@media (max-width: 768px) {
  .main-stats-grid {
    grid-template-columns: 1fr;
  }
  
  .detailed-campaign-grid {
    grid-template-columns: 1fr;
  }
  
  .detailed-campaign-summary {
    grid-template-columns: 1fr;
  }
  
  .fixes-grid {
    grid-template-columns: 1fr;
  }
}