/**
 * Benchmark Section Styles
 * For product detail page benchmark display
 */

.pd-benchmark-section {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  margin: 32px 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e7eb;
}

.benchmark-header {
  margin-bottom: 20px;
}

.benchmark-title {
  font-size: 22px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 12px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.benchmark-hint {
  font-size: 14px;
  color: #6b7280;
  margin: 0;
}

/* Preview Badges */
.benchmark-preview-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.benchmark-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 2px 6px rgba(102, 126, 234, 0.25);
  transition: all 0.2s ease;
}

.benchmark-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.35);
}

.benchmark-badge strong {
  font-weight: 600;
  opacity: 0.9;
}

/* Load Button */
.btn-load-benchmark {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 420px;
  padding: 14px 24px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  margin: 0 auto;
}

.btn-load-benchmark:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.btn-load-benchmark:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-load-benchmark .btn-icon {
  font-size: 20px;
}

.btn-load-benchmark.loading .btn-icon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Benchmark Content */
.benchmark-content {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 2px solid #f3f4f6;
}

.benchmark-loading {
  text-align: center;
  padding: 40px 20px;
  color: #6b7280;
}

.benchmark-loading-spinner {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  border: 4px solid #f3f4f6;
  border-top-color: #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.benchmark-error {
  text-align: center;
  padding: 32px 20px;
  color: #ef4444;
  background: #fee2e2;
  border-radius: 8px;
}

/* Benchmark Data Display */
.benchmark-data-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.benchmark-card {
  background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 18px;
  text-align: center;
  transition: all 0.2s ease;
}

.benchmark-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.15);
}

.benchmark-card-label {
  font-size: 13px;
  color: #6b7280;
  font-weight: 500;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.benchmark-card-value {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.2;
}

.benchmark-card-value.large {
  font-size: 28px;
}

.benchmark-card-subtitle {
  font-size: 12px;
  color: #9ca3af;
  margin-top: 4px;
}

/* Spec Details */
.benchmark-specs {
  background: #f9fafb;
  border-radius: 10px;
  padding: 20px;
  margin-top: 20px;
}

.benchmark-specs-title {
  font-size: 16px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 16px 0;
}

.benchmark-spec-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #e5e7eb;
}

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

.benchmark-spec-label {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
}

.benchmark-spec-value {
  font-size: 14px;
  color: #1a1a1a;
  font-weight: 600;
  text-align: right;
}

/* Score Badges */
.benchmark-score-badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  margin-top: 8px;
}

.benchmark-score-badge.excellent {
  background: #10b981;
  color: #fff;
}

.benchmark-score-badge.good {
  background: #3b82f6;
  color: #fff;
}

.benchmark-score-badge.average {
  background: #f59e0b;
  color: #fff;
}

.benchmark-score-badge.poor {
  background: #ef4444;
  color: #fff;
}

/* Attribution */
.benchmark-attribution {
  text-align: center;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
  font-size: 13px;
  color: #9ca3af;
}

.benchmark-attribution a {
  color: #667eea;
  text-decoration: none;
  font-weight: 500;
}

.benchmark-attribution a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
  .pd-benchmark-section {
    padding: 16px;
    margin: 20px 0;
  }

  .benchmark-title {
    font-size: 18px;
  }

  .benchmark-preview-badges {
    flex-direction: column;
    gap: 8px;
  }

  .benchmark-badge {
    justify-content: center;
  }

  .btn-load-benchmark {
    font-size: 14px;
    padding: 12px 20px;
  }

  .benchmark-data-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .benchmark-card {
    padding: 14px;
  }

  .benchmark-card-value {
    font-size: 20px;
  }

  .benchmark-spec-row {
    flex-direction: column;
    gap: 4px;
  }

  .benchmark-spec-value {
    text-align: left;
  }
}

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