/* Import Batch Details Page Styles */

/* Main Container */

.batch-details-container {
  padding: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Header Section */

.batch-details-header {
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border, #e5e7eb);
  padding-bottom: 24px;
}

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

.batch-header-content h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  color: var(--text, #1f2937);
}

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

/* Metadata Display */

.batch-metadata {
  display: flex;
  gap: 24px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.metadata-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.metadata-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted, #6b7280);
  text-transform: uppercase;
}

.metadata-value {
  font-size: 14px;
  color: var(--text, #1f2937);
}

/* Typography Utilities */

.font-mono {
  font-family: "Monaco", "Courier New", monospace;
}

.text-sm {
  font-size: 13px;
}

/* Summary Cards */

.batch-summary {
  display: flex;
  gap: 16px;
  margin-top: 16px;
}

.summary-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 20px;
  background-color: var(--bg-secondary, #f9fafb);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 6px;
  flex: 1;
  max-width: 150px;
}

.summary-count {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary, #2563eb);
  margin-bottom: 4px;
}

.summary-label {
  font-size: 12px;
  color: var(--muted, #6b7280);
  text-align: center;
}

/* Content Sections */

.batch-details-content {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.batch-section {
  padding: 20px;
  background-color: var(--bg-secondary, #f9fafb);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px;
}

.batch-section h2 {
  margin: 0 0 16px 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--text, #1f2937);
}

/* Empty State */

.empty-state {
  padding: 40px;
  text-align: center;
  background-color: var(--bg-secondary, #f9fafb);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px;
  color: var(--muted, #6b7280);
}

/* Tables - Shared Styles */

.contacts-table-wrapper,
.companies-table-wrapper {
  overflow-x: auto;
}

.contacts-table,
.companies-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.contacts-table thead,
.companies-table thead {
  background-color: var(--bg-tertiary, #f3f4f6);
}

.contacts-table th,
.companies-table th {
  padding: 12px;
  text-align: left;
  font-weight: 600;
  color: var(--text, #111827);
  border-bottom: 2px solid var(--border, #e5e7eb);
  font-size: 12px;
  text-transform: uppercase;
}

.contacts-table td,
.companies-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border, #e5e7eb);
  color: var(--text, #1f2937);
}

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

.contact-row:hover,
.company-row:hover {
  background-color: var(--bg-hover, #f9fafb);
}

/* Contact/Company Names */

.contact-name,
.company-name {
  font-weight: 500;
  color: var(--text, #111827);
}

.name-text {
  display: block;
  word-break: break-word;
}

/* Email Links */

.email-link {
  color: var(--primary, #2563eb);
  text-decoration: none;
  word-break: break-word;
}

.email-link:hover {
  text-decoration: underline;
}

/* Contact Count Badge */

.contact-count {
  display: inline-block;
  padding: 4px 8px;
  background-color: var(--primary-100, #dbeafe);
  color: var(--primary, #2563eb);
  border-radius: 4px;
  font-weight: 500;
  font-size: 13px;
}

/* Text Utilities */

.text-muted {
  color: var(--muted, #6b7280);
}

/* Empty States */

.empty-state-contacts,
.empty-state-companies {
  padding: 20px;
  text-align: center;
  color: var(--muted, #6b7280);
  background-color: var(--bg-secondary, #f9fafb);
  border-radius: 6px;
}

/* Batch Not Found Page */

.batch-not-found-container {
  padding: 40px 24px;
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
}

.not-found-card {
  padding: 32px;
  background-color: var(--bg-secondary, #f9fafb);
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px;
  text-align: center;
}

.not-found-card h1 {
  margin: 0 0 16px 0;
  font-size: 24px;
  font-weight: 700;
  color: var(--text-dark, #111827);
}

.not-found-card p {
  margin: 12px 0;
  color: var(--text, #1f2937);
  line-height: 1.6;
}

.not-found-card code {
  background-color: var(--bg-tertiary, #f3f4f6);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: "Monaco", "Courier New", monospace;
  font-size: 13px;
  color: var(--danger, #dc2626);
}

.help-text {
  margin-top: 20px !important;
  font-weight: 500;
  color: var(--muted, #6b7280);
}

.not-found-card ul {
  text-align: left;
  display: inline-block;
  margin: 12px 0 20px 0;
  padding-left: 20px;
  color: var(--muted, #6b7280);
}

.not-found-card li {
  margin: 8px 0;
  line-height: 1.5;
}

.action-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
  flex-wrap: wrap;
}

/* Responsive Design */

@media (max-width: 768px) {
  .batch-details-container {
    padding: 16px;
  }

  .batch-header-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .header-buttons {
    width: 100%;
    flex-direction: column;
  }

  .header-buttons .btn {
    width: 100%;
  }

  .batch-metadata {
    flex-direction: column;
    gap: 12px;
  }

  .batch-summary {
    flex-direction: column;
  }

  .summary-card {
    max-width: 100%;
  }

  /* Tables Mobile Styling */

  .contacts-table,
  .companies-table {
    font-size: 12px;
  }

  .contacts-table th,
  .companies-table th,
  .contacts-table td,
  .companies-table td {
    padding: 8px;
  }

  .contacts-table th,
  .companies-table th {
    font-size: 11px;
  }

  /* Hide less important columns on mobile */

  .contacts-table th:nth-child(4),
  .contacts-table td:nth-child(4),
  .contacts-table th:nth-child(5),
  .contacts-table td:nth-child(5) {
    display: none;
  }

  .batch-not-found-container {
    padding: 24px 16px;
    min-height: 300px;
  }

  .not-found-card {
    padding: 24px;
  }

  .not-found-card h1 {
    font-size: 20px;
  }

  .action-buttons {
    flex-direction: column;
  }
}
