/* Component container - Enhanced for better visibility */
.component-container {
  display: block !important;
  width: 100% !important;
  margin: 10px 0 !important;
  padding: 0 !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
  border: 2px solid #6366f1 !important;
  background-color: var(--color-bg-primary, #ffffff) !important;
  position: relative !important;
  z-index: 100 !important;
  max-height: none !important;
  min-height: 150px !important;
}

.dark-mode .component-container {
  background-color: #1e1e2e !important;
  border-color: #818cf8 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
}

.comparador-container {
  width: 100%;
  margin: 0;
  font-family: var(--font-family, 'Inter', sans-serif);
  background-color: transparent;
  border-radius: 8px;
  padding: 0;
}

.comparador-header {
  padding: 0.5rem 0.5rem 0.5rem 0.5rem;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 0.25rem;
}

.comparador-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.15rem;
  color: var(--text-color, #333333);
  line-height: 1.2;
}

.comparador-subtitle {
  font-size: 0.8rem;
  color: var(--secondary-text-color, #666666);
  margin-bottom: 0.25rem;
  line-height: 1.2;
}

/* Tab navigation */
.nav-tabs {
  display: flex;
  margin-bottom: 0.25rem;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border-color, #e2e8f0);
  padding-left: 0;
  list-style: none;
}

.nav-item {
  margin-right: 0.5rem;
}

.nav-tab {
  display: flex;
  align-items: center;
  padding: 0.5rem 0;
  cursor: pointer;
  color: var(--secondary-text-color, #666666);
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
  margin-right: 1rem;
}

.nav-tab i {
  margin-right: 0.75rem;
  font-size: 0.9rem;
}

.nav-tab.active {
  color: #0052CC;
  font-weight: 600;
}

.comparador-view-container {
  padding: 0.5rem 0;
}

/* Upload view */
.comparador-upload-view h4, 
.comparador-criteria-view h4, 
.comparador-results-view h4 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-color, #333333);
}

.comparador-upload-view p, 
.comparador-criteria-view p, 
.comparador-results-view p {
  font-size: 0.9rem;
  color: var(--secondary-text-color, #666666);
  margin-bottom: 1rem;
}

/* Upload area styling */
.dropzone {
  border: 2px dashed var(--border-color, #cccccc);
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
  transition: all 0.3s;
  background-color: var(--bg-color-light, #f9f9f9);
  position: relative;
  cursor: pointer;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.dropzone i {
  font-size: 2rem;
  color: var(--secondary-text-color, #666666);
  margin-bottom: 1rem;
}

.dropzone p {
  margin-bottom: 0.25rem !important;
  font-weight: 500;
}

.dropzone .hint {
  font-size: 0.8rem;
  color: var(--secondary-text-color, #666666);
  margin-bottom: 0 !important;
  font-weight: normal;
}

.dropzone.dragover {
  border-color: var(--primary-color, #4a6cf7);
  background-color: var(--primary-color-light, rgba(74, 108, 247, 0.05));
}

.file-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

/* Files list */
.file-list {
  margin-top: 1rem;
}

.file-item {
  display: flex;
  align-items: center;
  padding: 10px;
  margin-bottom: 10px;
  border-radius: 8px;
  border: 1px solid var(--border-color, #e1e1e1);
  background-color: #fff;
  position: relative;
}

.file-item.upload-error {
  border-color: var(--danger-color, #e53935);
  background-color: var(--danger-color-light, rgba(229, 57, 53, 0.05));
}

.file-item.status-uploading {
  border-color: var(--primary-color, #4a6cf7);
  background-color: var(--primary-color-light, rgba(74, 108, 247, 0.05));
}

.file-item.status-uploaded {
  border-color: var(--success-color, #43a047);
  background-color: var(--success-color-light, rgba(67, 160, 71, 0.05));
}

.file-details {
  flex: 1;
  margin-left: 0.75rem;
}

/* File preview styling */
.file-preview {
  position: relative;
  width: 60px;
  height: 80px;
  margin-right: 15px;
  background-color: #f0f2f5;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color, #e1e1e1);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.file-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* PDF placeholder styling */
.pdf-placeholder {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: transparent;
}

.file-preview .pdf-icon {
  width: 28px;
  height: 28px;
  color: #e74c3c;
}

.file-name {
  font-weight: 500;
  margin-bottom: 0.25rem;
  word-break: break-word;
  color: var(--text-color, #333333);
  font-size: 0.9rem;
}

.file-meta {
  display: flex;
  align-items: center;
  font-size: 0.75rem;
  color: var(--secondary-text-color, #666666);
}

.file-size {
  margin-right: 0.75rem;
}

.file-status {
  font-weight: 500;
}

.status-uploading .file-status {
  color: var(--primary-color, #4a6cf7);
}

.status-uploaded .file-status {
  color: var(--success-color, #43a047);
}

.status-error .file-status {
  color: var(--danger-color, #e53935);
}

.error-message {
  color: var(--danger-color, #e53935);
  font-size: 0.8rem;
  margin-top: 0.25rem;
  display: none;
}

.upload-error .error-message {
  display: block;
}

.file-delete {
  background: none;
  border: none;
  padding: 0.25rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
  color: var(--secondary-text-color, #666666);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
}

.file-delete:hover {
  background-color: var(--danger-color-light, rgba(229, 57, 53, 0.1));
  color: var(--danger-color, #e53935);
}

.file-delete svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
}

/* Progress indicator styles */
.progress-container {
  height: 4px;
  background-color: #e0e0e0;
  border-radius: 2px;
  margin-top: 0.5rem;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background-color: var(--primary-color, #4a6cf7);
  width: 0%;
  transition: width 0.3s ease;
}

/* Files counter */
.files-counter {
  display: block;
  margin-top: 0.75rem;
  margin-bottom: 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--secondary-text-color, #666666);
}

/* Upload progress */
.upload-progress {
  margin-top: 0.25rem;
  background-color: var(--bg-color, #ffffff);
  border-radius: 4px;
  height: 4px;
  overflow: hidden;
}

.file-actions {
  display: flex;
  margin-top: 5px;
}

.file-retry {
  background: var(--secondary-color, #4a90e2);
  color: white;
  border: none;
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  margin-top: 5px;
  transition: background 0.3s ease;
}

.file-retry:hover {
  background: var(--secondary-color-dark, #3a80d2);
}

.file-retry i {
  margin-right: 4px;
  font-size: 10px;
}

/* Button styling */
.comparador-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 1.5rem;
}

.button-container, .buttons-container {
  margin-top: 1.5rem;
  display: flex;
  justify-content: flex-end;
}

.buttons-container {
  justify-content: space-between;
}

.primary-button, .secondary-button {
  border-radius: 6px;
  padding: 0.6rem 1.2rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: all 0.2s;
  font-size: 0.9rem;
}

.primary-button {
  background-color: var(--primary-color, #4a6cf7);
  color: white;
  border: none;
  padding: 6px 16px;
}

.primary-button i {
  margin-right: 0.5rem;
}

.primary-button:disabled {
  background-color: var(--disabled-color, #cccccc);
  cursor: not-allowed;
  opacity: 0.7;
}

.primary-button:not(:disabled):hover {
  background-color: var(--primary-color-dark, #3a5cd7);
}

/* Ensure compare button is always visible */
[id$="_compare_btn"] {
  opacity: 1;
  visibility: visible;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  background-color: var(--primary-color, #4a6cf7) !important;
  color: white !important;
  min-width: 120px;
}

[id$="_compare_btn"]:disabled {
  opacity: 0.8 !important;
  box-shadow: none;
  background-color: var(--disabled-color, #cccccc) !important;
}

/* Additional rule for Comparar button to ensure full visibility */
.comparador-actions .primary-button {
  opacity: 1 !important;
  background-color: #4a6cf7 !important;
  color: white !important;
  border: none !important;
  padding: 8px 16px !important;
  font-weight: bold;
  min-width: 120px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
}

/* Alternate styling for the continue button to match reference */
#id_2vllhvb_continue_btn, [id$="_continue_btn"] {
  background-color: #eeeeee;
  color: #666666;
  border-radius: 4px;
  font-size: 14px;
  padding: 6px 12px;
}

#id_2vllhvb_continue_btn:not(:disabled), [id$="_continue_btn"]:not(:disabled) {
  background-color: #eeeeee;
  color: #333333;
}

#id_2vllhvb_continue_btn:hover:not(:disabled), [id$="_continue_btn"]:hover:not(:disabled) {
  background-color: #dddddd;
}

.secondary-button {
  background-color: transparent;
  color: var(--text-color, #333333);
  border: 1px solid var(--border-color, #cccccc);
}

.secondary-button i {
  margin-right: 0.5rem;
}

.secondary-button:hover {
  background-color: var(--bg-color-light, #f9f9f9);
}

.button-icon {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  margin-right: 0.5rem;
}

/* Warning message */
.warning {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
  padding: 0.75rem;
  border-radius: 0.375rem;
  margin-top: 1rem;
  font-size: 0.875rem;
}

.warning-icon {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2;
}

/* Upload counter */
.upload-limit {
  display: inline-block;
  background: #f3f4f6;
  color: var(--secondary-text-color, #666666);
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

.upload-counter {
  text-align: center;
  color: var(--secondary-text-color, #666666);
  font-size: 0.875rem;
  margin-top: 1rem;
}

.upload-count {
  color: var(--primary-color, #4a6cf7);
  font-weight: 600;
}

/* Criteria view styling */
.criteria-section {
  width: 100%;
}

.criteria-subtitle {
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 1rem;
  color: var(--text-color, #333333);
}

.insurance-types {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.insurance-type-option {
  position: relative;
  border: 1px solid var(--border-color, #cccccc);
  border-radius: 8px;
  padding: 1rem;
  cursor: pointer;
  flex: 1 0 calc(33.333% - 1rem);
  min-width: 120px;
  transition: all 0.2s;
  text-align: center;
}

.insurance-type-option:hover {
  border-color: var(--primary-color, #4a6cf7);
}

.insurance-type-option.selected {
  border-color: var(--primary-color, #4a6cf7);
  background-color: var(--primary-color-light, rgba(74, 108, 247, 0.05));
}

.insurance-type-option input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.insurance-type-option label {
  display: block;
  text-align: center;
  font-weight: 500;
  cursor: pointer;
  font-size: 0.9rem;
}

/* Questions list */
.questions-list {
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-color, #e6e6e6);
  border-radius: 4px;
  overflow: hidden;
}

.question-item {
  display: flex;
  align-items: center;
  padding: 10px 15px;
  margin: 5px 0;
  background: #f5f5f5;
  border-radius: 4px;
  transition: background-color 0.2s;
  justify-content: space-between;
}

.question-item:hover {
  background: #e9e9e9;
}

.question-content {
  flex: 1;
  display: flex;
  align-items: center;
}

.question-text {
  flex: 1;
  margin-right: 10px;
  font-size: 0.9rem;
  color: #333;
}

.delete-question-btn {
  background: none;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #999;
  transition: all 0.2s ease;
  margin-left: 8px;
}

.delete-question-btn:hover {
  background-color: rgba(255, 0, 0, 0.1);
  color: #d32f2f;
}

.delete-question-btn i {
  font-size: 14px;
}

/* Custom question input */
.custom-question-input {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
  align-items: center;
}

.question-input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color, #cccccc);
  border-radius: 4px;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.question-input:focus {
  outline: none;
  border-color: var(--primary-color, #4a6cf7);
  box-shadow: 0 0 0 2px rgba(74, 108, 247, 0.1);
}

.add-question-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--primary-color, #4a6cf7);
  background: none;
  border: none;
  padding: 0.5rem;
  font-size: 0.875rem;
  cursor: pointer;
  margin-top: 1rem;
}

.add-question-btn:hover {
  color: var(--primary-color-dark, #3a5cd7);
}

/* Results view styling */
.processing-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background-color: var(--bg-color-light, #f9f9f9);
  border-radius: 8px;
  margin: 20px 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid var(--border-color-light, #e0e0e0);
  border-top: 4px solid var(--primary-color, #4a6cf7);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

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

.loading-text {
  margin-top: 10px;
  color: var(--secondary-text-color, #666666);
  font-weight: 500;
}

.results-view {
  padding-bottom: 0.5rem;
}

.empty-results {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  background-color: var(--bg-color-light, #f9f9f9);
  border-radius: 8px;
  margin: 1rem 0;
}

.empty-results i {
  font-size: 2rem;
  color: var(--secondary-text-color, #666666);
  margin-bottom: 1rem;
}

.empty-results p {
  color: var(--secondary-text-color, #666666);
  margin-bottom: 0 !important;
}

.proposals-comparison {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.proposal-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  width: 100%;
  margin-bottom: 2rem;
}

.proposal-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.25rem;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}

.proposal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.proposal-header {
  display: flex;
  align-items: center;
  margin-bottom: 0.75rem;
}

.proposal-logo {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background-color: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
}

.proposal-logo img {
  max-width: 16px;
  max-height: 16px;
}

.proposal-name {
  font-weight: 600;
  color: #2d3748;
  font-size: 1rem;
  margin: 0;
}

.company-url {
  color: #718096;
  font-size: 0.85rem;
  margin-top: 0.25rem;
  word-break: break-all;
}

/* Comparison table styles */
.comparison-results {
  width: 100%;
  overflow-x: auto;
  margin-top: 0.5rem;
  position: relative;
}

.comparison-results-structure {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0;
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid #e0e0e0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  table-layout: fixed;
}

.comparison-table th, 
.comparison-table td {
  padding: 0.6rem;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  vertical-align: top;
  word-wrap: break-word;
  word-break: normal;
  overflow-wrap: break-word;
  hyphens: auto;
  max-width: none;
}

.comparison-table thead {
  background-color: #f8fafc;
  border-bottom: 2px solid #e2e8f0;
}

.comparison-table th {
  font-weight: 600;
  color: #2d3748;
  font-size: 0.9rem;
}

.comparison-table th.question-header {
  width: 28%;
  min-width: 220px;
  background-color: #f8fafc;
  border-right: 1px solid #e2e8f0;
}

.comparison-table th.company-header {
  text-align: center;
  background-color: #f8fafc;
  font-size: 0.9rem;
  padding: 0.5rem;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
  width: 36%;
}

.comparison-table th.company-header > div {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.comparison-table th.company-header img.company-favicon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  flex-shrink: 0;
}

.comparison-table td {
  background-color: #fff;
  min-height: 2.5rem;
  white-space: normal;
  line-height: 1.5;
  overflow: visible;
}

.comparison-table td.question-cell {
  font-weight: 500;
  color: #2d3748;
  background-color: #f8fafc;
}

/* Stripe the table rows for better readability */
.comparison-table tbody tr:nth-child(even) td:not(.question-cell) {
  background-color: #f9fafc;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table th:last-child,
.comparison-table td:last-child {
  border-right: none;
}

.comparison-table .answer-text {
  margin-bottom: 0.35rem;
  display: block;
  width: 100%;
  white-space: pre-wrap;
}

.comparison-table .page-info {
  font-size: 0.75rem;
  color: #718096;
  display: block;
  width: 100%;
  margin-top: 0.25rem;
}

.comparison-table .page-label {
  font-weight: 500;
  color: #4a5568;
}

/* Styling for page links */
.comparison-table .page-link {
  color: #4a6cf7;
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0 2px;
}

.comparison-table .page-link:hover {
  text-decoration: underline;
  color: #3355cc;
}

.comparison-table .page-link:focus {
  outline: 1px dotted #4a6cf7;
  outline-offset: 2px;
}

/* Style for empty answers */
.comparison-table .answer-text.empty-answer {
  color: #a0aec0;
  font-style: italic;
}

/* Make sure N/A and not found info is clearly visible */
.comparison-table .answer-text:empty::after {
  content: 'Informação não encontrada';
  color: #a0aec0;
  font-style: italic;
}

/* Add max-height for very long content with scrolling */
.comparison-table td {
  max-height: none;
}

/* Ensure quoted answers are properly displayed */
.comparison-table .answer-text:has(q) {
  quotes: """ """ "'" "'";
}

/* Media query for mobile */
@media (max-width: 768px) {
  .comparison-table {
    display: block;
    overflow-x: auto;
  }

  .comparison-table th.question-header {
    min-width: 150px;
  }
}

/* Component message specific styling */
.component-message .comparison-table {
  font-size: 0.9rem;
}

.component-message .comparison-table th,
.component-message .comparison-table td {
  padding: 0.6rem 0.8rem;
}

/* Download options */
.download-options {
  margin-top: 1.5rem;
  text-align: center;
  padding: 0.75rem;
  background-color: var(--bg-color-light, #f9f9f9);
  border-radius: 8px;
}

.download-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-color, #333333);
  font-size: 0.9rem;
}

.download-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.download-button {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 0.9rem;
  border: 1px solid var(--border-color, #cccccc);
  border-radius: 4px;
  background-color: var(--bg-color, #ffffff);
  color: var(--text-color, #333333);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.85rem;
}

.download-button:hover {
  background-color: var(--bg-color-light, #f9f9f9);
  border-color: var(--primary-color, #4a6cf7);
}

.download-button.loading {
  position: relative;
  color: transparent;
}

.download-button.loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid var(--border-color-light, #e0e0e0);
  border-top: 2px solid var(--primary-color, #4a6cf7);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* Error container */
.error-container, .comparador-error-container {
  padding: 1.5rem;
  background-color: var(--danger-color-light, rgba(229, 57, 53, 0.1));
  border-radius: 8px;
  margin-top: 1rem;
  text-align: center;
  color: var(--danger-color, #e53935);
}

/* Integration with chat message */
.message .comparador-container {
  margin-top: 0.5rem;
  margin-left: -0.5rem;
  width: calc(100% + 1rem);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .proposal-cards {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
}

@media (max-width: 600px) {
  .proposal-cards {
    grid-template-columns: 1fr;
  }
}

/* Hover effect for file preview to show zoom indicator */
.file-preview:hover::after {
  content: '🔍';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  font-size: 18px;
  cursor: pointer;
}

/* PDF Preview Modal */
.pdf-preview-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.pdf-preview-modal .modal-content {
  background-color: white;
  border-radius: 8px;
  max-width: 90%;
  max-height: 90%;
  width: auto;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.pdf-preview-modal .modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background-color: #f7f7f7;
  border-bottom: 1px solid #e1e1e1;
}

.pdf-preview-modal .modal-title {
  font-weight: 600;
  font-size: 18px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 80%;
}

.pdf-preview-modal .close-modal {
  font-size: 28px;
  font-weight: 700;
  color: #888;
  cursor: pointer;
  line-height: 1;
}

.pdf-preview-modal .close-modal:hover {
  color: #333;
}

.pdf-preview-modal .modal-body {
  padding: 20px;
  text-align: center;
  overflow: auto;
  max-height: calc(90vh - 70px);
  display: flex;
  justify-content: center;
  align-items: center;
}

.pdf-preview-modal .full-preview-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.1);
}

@media (max-width: 600px) {
  .pdf-preview-modal .modal-content {
    width: 95%;
    max-height: 95%;
  }
  
  .pdf-preview-modal .modal-body {
    padding: 10px;
  }
  
  .pdf-preview-modal .modal-title {
    font-size: 16px;
  }
}

/* Comparison Results Styles */
.comparison-results-structure {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 0;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Summary Section */
.proposals-summary {
  margin-bottom: 2rem;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #2d3748;
  margin-bottom: 1.5rem;
}

.proposal-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  width: 100%;
}

.proposal-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.5rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.proposal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

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

.proposal-logo {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.proposal-logo img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.proposal-logo i {
  font-size: 1.5rem;
  color: #4a5568;
}

.proposal-name {
  font-size: 1.1rem;
  font-weight: 600;
  color: #2d3748;
  margin: 0;
}

.company-url {
  font-size: 0.9rem;
  color: #4a5568;
  margin-top: 0.5rem;
}

/* Comparison Table */
.criteria-comparison {
  margin-top: 0.25rem;
  width: 100%;
}

.criteria-comparison-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #2d3748;
}

.criteria-grid {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
}

.criterion-row {
  display: flex;
  border-bottom: 1px solid #e2e8f0;
}

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

.criterion-name {
  flex: 0 0 250px;
  padding: 1rem;
  background: #f8fafc;
  font-weight: 600;
  color: #2d3748;
  border-right: 1px solid #e2e8f0;
}

.criterion-values {
  flex: 1;
  display: flex;
  overflow-x: auto;
}

.comparison-value {
  flex: 1;
  min-width: 200px;
  padding: 1rem;
  border-right: 1px solid #e2e8f0;
}

.comparison-value:last-child {
  border-right: none;
}

.value-text {
  color: #4a5568;
  line-height: 1.5;
}

.page-info {
  font-size: 0.8rem;
  color: #718096;
  margin-top: 0.5rem;
}

/* Download Options */
.download-options {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: #f8fafc;
  border-radius: 8px;
  margin-top: 2rem;
}

.download-label {
  font-weight: 500;
  color: #4a5568;
}

.download-buttons {
  display: flex;
  gap: 0.5rem;
}

.download-button {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  color: #4a5568;
  cursor: pointer;
  transition: all 0.2s;
}

.download-button:hover {
  background: #f1f5f9;
  border-color: #cbd5e0;
  color: #2d3748;
}

.download-button i {
  font-size: 1.2rem;
}

/* Header Row Styles */
.header-row {
  background: #f8fafc;
}

.header-row .criterion-name {
  background: #edf2f7;
}

/* Loading State */
.comparador-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: #4a5568;
  font-size: 1.1rem;
}

.comparador-loading i {
  margin-right: 0.5rem;
  animation: spin 1s linear infinite;
}

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

/* Error State */
.comparador-error {
  padding: 1rem;
  background: #fff5f5;
  border: 1px solid #feb2b2;
  border-radius: 8px;
  color: #c53030;
  margin-bottom: 1rem;
}

/* Empty State */
.no-results {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  text-align: center;
  color: #4a5568;
}

.no-results i {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: #a0aec0;
}

.no-results p {
  font-size: 1.1rem;
  margin: 0;
}

/* Component inside message bubble */
.component-in-message {
  width: 100%;
  padding: 0;
  margin: 0;
}

.component-in-message .comparador-container {
  width: 100%;
  margin: 0;
  padding: 0.5rem 0;
  border-radius: 8px;
  box-shadow: none;
  border: none;
}

/* Make sure the message bubble can accommodate the component */
.component-in-message .message-bubble {
  max-width: 100%;
  width: 100%;
}

/* Make tabs work well in the message bubble */
.component-in-message .nav-tabs {
  margin-bottom: 0.5rem;
}

.component-in-message .comparador-title {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.component-in-message .comparador-subtitle {
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

/* Adjust sizing for smaller space */
.component-in-message .dropzone {
  min-height: 120px;
  padding: 1rem;
}

.dark-mode .component-in-message .comparador-container {
  background-color: transparent;
}

/* Only apply wide widths to messages that actually contain components */
.message-container.component-message .message-bubble,
.message-container .message-bubble:has(.component-in-message):not(:empty) {
  max-width: 85%;
  width: auto;
}

/* More specific selector for agent messages with actual components */
.message-container.agent-message.component-message .message-bubble,
.message-container.agent-message .message-bubble:has(.component-in-message .comparador-container) {
  max-width: 90% !important;
  width: 90% !important;
}

@media (max-width: 800px) {
  .message-container.agent-message.component-message .message-bubble,
  .message-container.agent-message .message-bubble:has(.component-in-message .comparador-container) {
    max-width: 95% !important;
    width: 95% !important;
  }
}

/* Additional styling for component messages */
.component-message .message-bubble {
    padding: 12px 15px;
    max-width: 90% !important;
    width: 90% !important;
}

.component-message .component-in-message {
    margin-top: 10px;
}

/* Improve dropzone appearance in message */
.component-message .dropzone {
    border: 2px dashed #ccc;
    border-radius: 8px;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.02);
    margin-bottom: 15px;
}

.component-message .dropzone:hover {
    border-color: #E3175E;
    background-color: rgba(227, 23, 94, 0.05);
}

/* Improve button styling */
.component-message .btn-primary {
    background-color: #E3175E;
    border-color: #E3175E;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.component-message .btn-primary:hover:not(:disabled) {
    background-color: #B01340;
    border-color: #B01340;
}

.component-message .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Dark mode adjustments */
.dark-mode .component-message .dropzone {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: #555;
}

.dark-mode .component-message .dropzone:hover {
    border-color: #E3175E;
    background-color: rgba(227, 23, 94, 0.1);
}

@media (max-width: 800px) {
    .component-message .message-bubble {
        max-width: 95% !important;
    }
}

/* Ensure message container can grow to fit component content */
.component-message {
    width: 100%;
    max-width: 100%;
}

.component-message .message-bubble {
    width: auto;
    max-width: 800px !important;
}

/* Ensure tabs display properly */
.component-message .nav-tabs {
    border-bottom: 1px solid #dee2e6;
    display: flex;
    flex-wrap: wrap;
    padding-left: 0;
    margin-bottom: 0;
    list-style: none;
    width: 100%;
}

.component-message .tab-content {
    width: 100%;
}

/* Media queries for responsive grid */
@media (max-width: 768px) {
  .criteria-grid {
    display: block;
    overflow-x: auto;
  }
  
  .criterion-row, 
  .criterion-name, 
  .criterion-values, 
  .comparison-values-container,
  .comparison-values-row,
  .comparison-value {
    display: block;
    width: 100%;
  }
  
  .criterion-name {
    border-right: none;
  }
  
  .comparison-value {
    border-right: none;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1rem;
  }
  
  .comparison-value:last-child {
    border-bottom: none;
  }
}

/* Ensure the component inside a message takes full available width */
.component-message .comparison-results,
.component-message .comparison-results-structure,
.component-message .proposals-summary,
.component-message .criteria-comparison {
  width: 100%;
}

/* Fix for the component container in message view */
.component-message .component-container {
  width: 100% !important;
  margin: 5px 0 !important;
  max-width: 100% !important;
}

/* Specific layout for the component in message view */
.component-message .proposal-cards {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* For small screens, stack the cards */
@media (max-width: 600px) {
  .proposal-cards {
    grid-template-columns: 1fr;
  }
}

/* Message bubble styling for actual components only */
.message-container.component-message .message-bubble:has(.component-in-message),
.message-container .message-bubble:has(.component-in-message .comparador-container) {
  max-width: 95% !important;
  width: 95% !important;
  padding: 15px !important;
}

/* Make sure component messages expand to full width */
.message-container.component-message {
  width: 100%;
  max-width: 100%;
}

.message-container.component-message .message-bubble {
  max-width: 95% !important;
  width: 95% !important;
  padding: 12px !important;
  background-color: #fff !important;
}

.component-message .criteria-grid {
  width: 100%;
  margin-bottom: 1.5rem;
  border: 1px solid #e2e8f0;
}

.component-message .criterion-name {
  width: 30%;
  font-size: 0.9rem;
}

.component-message .criterion-values {
  width: 70%;
}

.component-message .comparison-value {
  font-size: 0.9rem;
}

.component-message .page-info {
  font-size: 0.75rem;
  color: #718096;
  margin-top: 0.25rem;
}

/* Fix scrolling in chat bubbles */
.component-message .criteria-comparison {
  max-width: 100%;
  overflow-x: auto;
}

@media (max-width: 600px) {
  .component-message .criterion-name {
    width: 100%;
  }
  
  .component-message .criterion-values {
    width: 100%;
  }
}

.criterion-name.question-text {
  font-weight: 600;
  color: #2d3748;
  line-height: 1.4;
}

/* Ensure header styling is consistent */
.header-row .criterion-name {
  font-weight: 700;
  color: #1a202c;
  background-color: #edf2f7;
}

/* Tab content */
.tab-content {
  padding: 0.5rem 0;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* File upload view */
.upload-view {
  padding: 0.5rem 0;
}

/* Criteria selection view */
.criteria-view {
  padding: 0.5rem 0;
}

/* Results view */
.results-view {
  padding-bottom: 0.5rem;
}

/* Comparison results container */
.comparison-results {
  width: 100%;
  overflow-x: auto;
  margin-top: 0.5rem;
  position: relative;
}

.comparison-results-structure {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0;
}

/* Criteria comparison */
.criteria-comparison {
  margin-top: 0.25rem;
  width: 100%;
}

/* Comparison table */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid #e0e0e0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.comparison-table th, 
.comparison-table td {
  padding: 0.6rem;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  vertical-align: top;
  word-wrap: break-word;
  word-break: normal;
  overflow-wrap: break-word;
  hyphens: auto;
  max-width: none;
}

.comparison-table thead {
  background-color: #f8fafc;
  border-bottom: 2px solid #e2e8f0;
}

.comparison-table th {
  font-weight: 600;
  color: #2d3748;
  font-size: 0.9rem;
}

.comparison-table th.question-header {
  width: 28%;
  min-width: 220px;
  background-color: #f8fafc;
  border-right: 1px solid #e2e8f0;
}

.comparison-table th.company-header {
  text-align: center;
  background-color: #f8fafc;
  font-size: 0.9rem;
  padding: 0.5rem;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
  width: 36%;
}

.comparison-table th.company-header > div {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.comparison-table th.company-header img.company-favicon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  flex-shrink: 0;
}

.comparison-table td {
  background-color: #fff;
  min-height: 2.5rem;
  white-space: normal;
  line-height: 1.5;
  overflow: visible;
}

.comparison-table td.question-cell {
  font-weight: 500;
  color: #2d3748;
  background-color: #f8fafc;
}

/* Stripe the table rows for better readability */
.comparison-table tbody tr:nth-child(even) td:not(.question-cell) {
  background-color: #f9fafc;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table th:last-child,
.comparison-table td:last-child {
  border-right: none;
}

.comparison-table .answer-text {
  margin-bottom: 0.35rem;
  display: block;
  width: 100%;
  white-space: pre-wrap;
}

.comparison-table .page-info {
  font-size: 0.75rem;
  color: #718096;
  display: block;
  width: 100%;
  margin-top: 0.25rem;
}

/* Media query for mobile */
@media (max-width: 768px) {
  .criteria-grid {
    display: block;
    overflow-x: auto;
  }
  
  .criterion-row, 
  .criterion-name, 
  .criterion-values, 
  .comparison-values-container,
  .comparison-values-row,
  .comparison-value {
    display: block;
    width: 100%;
  }
  
  .criterion-name {
    border-right: none;
  }
  
  .comparison-value {
    border-right: none;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1rem;
  }
  
  .comparison-value:last-child {
    border-bottom: none;
  }
}

/* Ensure the component inside a message takes full available width */
.component-message .comparison-results,
.component-message .comparison-results-structure,
.component-message .proposals-summary,
.component-message .criteria-comparison {
  width: 100%;
}

/* Fix for the component container in message view */
.component-message .component-container {
  width: 100% !important;
  margin: 5px 0 !important;
  max-width: 100% !important;
}

/* Specific layout for the component in message view */
.component-message .proposal-cards {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* For small screens, stack the cards */
@media (max-width: 600px) {
  .proposal-cards {
    grid-template-columns: 1fr;
  }
}

/* Message bubble styling for components */
/* COMMENTED OUT - This duplicate rule was causing wide bubbles for all messages */
/*
.message-container .message-bubble:has(.component-in-message) {
  max-width: 95% !important;
  width: 95% !important;
  padding: 15px !important;
}
*/

/* Make sure component messages expand to full width */
.message-container.component-message {
  width: 100%;
  max-width: 100%;
}

.message-container.component-message .message-bubble {
  max-width: 95% !important;
  width: 95% !important;
  padding: 12px !important;
  background-color: #fff !important;
}

.component-message .criteria-grid {
  width: 100%;
  margin-bottom: 1.5rem;
  border: 1px solid #e2e8f0;
}

.component-message .criterion-name {
  width: 30%;
  font-size: 0.9rem;
}

.component-message .criterion-values {
  width: 70%;
}

.component-message .comparison-value {
  font-size: 0.9rem;
}

.component-message .page-info {
  font-size: 0.75rem;
  color: #718096;
  margin-top: 0.25rem;
}

/* Fix scrolling in chat bubbles */
.component-message .criteria-comparison {
  max-width: 100%;
  overflow-x: auto;
}

@media (max-width: 600px) {
  .component-message .criterion-name {
    width: 100%;
  }
  
  .component-message .criterion-values {
    width: 100%;
  }
}

.criterion-name.question-text {
  font-weight: 600;
  color: #2d3748;
  line-height: 1.4;
}

/* Ensure header styling is consistent */
.header-row .criterion-name {
  font-weight: 700;
  color: #1a202c;
  background-color: #edf2f7;
}

/* Tab content */
.tab-content {
  padding: 0.5rem 0;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* File upload view */
.upload-view {
  padding: 0.5rem 0;
}

/* Criteria selection view */
.criteria-view {
  padding: 0.5rem 0;
}

/* Results view */
.results-view {
  padding-bottom: 0.5rem;
}

/* ============================================
   COMPREHENSIVE DARK MODE STYLES FOR COMPARADOR
   ============================================ */

/* Dark mode text color fixes */
.dark-mode .comparador-container {
  background-color: #1e1e2e;
  color: #e4e4e7;
}

.dark-mode .comparador-header {
  background-color: #2a2a3e;
  border-bottom-color: #3f3f56;
}

.dark-mode .comparador-title {
  color: #ffffff !important;
  font-size: 1.25rem;
  font-weight: 700;
}

.dark-mode .comparador-subtitle {
  color: #a1a1aa !important;
  font-size: 1rem;
}

/* Dark mode navigation tabs */
.dark-mode .nav-tabs {
  background-color: #2a2a3e;
  border-bottom-color: #3f3f56;
}

/* FIX: Dark mode for component message bubbles - prevent white background */
.dark-mode .message-container.component-message .message-bubble {
  background-color: #2a2a3e !important; /* Match dark mode container color */
  border: 1px solid #3f3f56;
}

/* FIX: Ensure all component elements respect dark mode */
.dark-mode .component-in-message {
  background-color: transparent !important;
}

.dark-mode .component-message .component-container {
  background-color: #1e1e2e !important;
}

/* Fix any remaining white backgrounds in dark mode */
.dark-mode .file-item {
  background-color: #2a2a3e !important;
}

.dark-mode .comparison-table td {
  background-color: #2a2a3e !important;
}

.dark-mode .nav-tab {
  color: #a1a1aa !important;
  font-size: 1rem;
}

.dark-mode .nav-tab:hover {
  color: #e4e4e7 !important;
  background-color: #35354a;
}

.dark-mode .nav-tab.active {
  color: #818cf8 !important;
  border-bottom-color: #818cf8;
  font-weight: 600;
}

/* Dark mode dropzone */
.dark-mode .dropzone {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
  color: #e4e4e7;
}

.dark-mode .dropzone:hover,
.dark-mode .dropzone.dragover {
  border-color: #818cf8 !important;
  background-color: #35354a !important;
}

.dark-mode .dropzone i {
  color: #71717a !important;
}

.dark-mode .dropzone p {
  color: #e4e4e7 !important;
  font-size: 1.1rem;
}

.dark-mode .dropzone .hint {
  color: #a1a1aa !important;
}

/* Dark mode file items */
.dark-mode .file-item {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
  color: #e4e4e7;
}

.dark-mode .file-item:hover {
  background-color: #35354a !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.dark-mode .file-name {
  color: #ffffff !important;
  font-size: 1rem;
}

.dark-mode .file-meta,
.dark-mode .file-size,
.dark-mode .file-status {
  color: #a1a1aa !important;
}

.dark-mode .file-delete {
  color: #71717a !important;
}

.dark-mode .file-delete:hover {
  background-color: #ef4444 !important;
  color: #ffffff !important;
}

/* Dark mode buttons */
.dark-mode .primary-button {
  background-color: #818cf8 !important;
  color: #ffffff !important;
  font-size: 1rem;
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(129, 140, 248, 0.3);
}

.dark-mode .primary-button:hover:not(:disabled) {
  background-color: #6366f1 !important;
  box-shadow: 0 4px 8px rgba(129, 140, 248, 0.4);
}

.dark-mode .primary-button:disabled {
  background-color: #52525b !important;
  color: #71717a !important;
}

.dark-mode .secondary-button {
  color: #e4e4e7 !important;
  border-color: #3f3f56 !important;
  font-size: 1rem;
}

.dark-mode .secondary-button:hover {
  background-color: #35354a !important;
  border-color: #818cf8 !important;
  color: #818cf8 !important;
}

/* Dark mode questions */
.dark-mode .question-item {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
}

.dark-mode .question-item:hover {
  background-color: #35354a !important;
}

.dark-mode .question-text {
  color: #e4e4e7 !important;
  font-size: 1rem;
}

.dark-mode .custom-question-input {
  background-color: #1e1e2e !important;
  border-color: #3f3f56 !important;
  color: #e4e4e7 !important;
  font-size: 1rem;
}

.dark-mode .custom-question-input:focus {
  border-color: #818cf8 !important;
  box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.3);
}

/* Dark mode insurance types */
.dark-mode .insurance-type-option {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
}

.dark-mode .insurance-type-option:hover {
  border-color: #818cf8 !important;
  background-color: #35354a !important;
}

.dark-mode .insurance-type-option.selected {
  border-color: #818cf8 !important;
  background-color: #35354a !important;
  box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.3);
}

.dark-mode .insurance-type-option label {
  color: #e4e4e7 !important;
  font-size: 1.1rem;
}

/* Dark mode comparison table */
.dark-mode .comparison-table {
  background-color: #1e1e2e !important;
  border-color: #3f3f56 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.dark-mode .comparison-table th {
  background-color: #35354a !important;
  color: #ffffff !important;
  border-color: #3f3f56 !important;
  font-size: 1rem;
}

.dark-mode .comparison-table td {
  background-color: #2a2a3e !important;
  color: #e4e4e7 !important;
  border-color: #3f3f56 !important;
  font-size: 1rem;
}

.dark-mode .comparison-table tbody tr:nth-child(even) td {
  background-color: #35354a !important;
}

.dark-mode .comparison-table tbody tr:hover td {
  background-color: #414157 !important;
}

.dark-mode .comparison-table .answer-text {
  color: #e4e4e7 !important;
  font-size: 1rem;
}

.dark-mode .comparison-table .page-info {
  color: #71717a !important;
}

/* Dark mode proposal cards */
.dark-mode .proposal-card {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dark-mode .proposal-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
  border-color: #818cf8 !important;
}

.dark-mode .proposal-name {
  color: #ffffff !important;
  font-size: 1.25rem;
}

.dark-mode .company-url {
  color: #818cf8 !important;
}

/* Dark mode errors and warnings */
.dark-mode .comparador-error {
  background-color: #450a0a !important;
  border-color: #7f1d1d !important;
  color: #fca5a5 !important;
}

.dark-mode .warning {
  background-color: #451a03 !important;
  border-color: #92400e !important;
  color: #fbbf24 !important;
}

/* Dark mode empty states */
.dark-mode .empty-results,
.dark-mode .no-results {
  color: #a1a1aa !important;
}

.dark-mode .empty-results i,
.dark-mode .no-results i {
  color: #52525b !important;
}

.dark-mode .empty-results p,
.dark-mode .no-results p {
  color: #a1a1aa !important;
  font-size: 1.1rem;
}

/* Dark mode download buttons */
.dark-mode .download-button {
  background-color: #2a2a3e !important;
  border-color: #3f3f56 !important;
  color: #e4e4e7 !important;
}

.dark-mode .download-button:hover {
  background-color: #818cf8 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 8px rgba(129, 140, 248, 0.4);
}

/* Dark mode headers and sections */
.dark-mode .comparador-upload-view h4,
.dark-mode .comparador-criteria-view h4,
.dark-mode .comparador-results-view h4 {
  color: #ffffff !important;
  font-size: 1.25rem;
}

.dark-mode .comparador-upload-view p,
.dark-mode .comparador-criteria-view p,
.dark-mode .comparador-results-view p {
  color: #a1a1aa !important;
  font-size: 1rem;
}

/* Dark mode loading states */
.dark-mode .comparador-loading {
  color: #a1a1aa !important;
}

.dark-mode .processing-indicator {
  background-color: #2a2a3e !important;
  color: #a1a1aa !important;
}

/* Dark mode file preview */
.dark-mode .file-preview {
  background-color: #35354a !important;
  border-color: #3f3f56 !important;
}

/* Dark mode custom styles for comparador_custom.css overrides */
.dark-mode .question-checkbox-label {
  color: #e4e4e7 !important;
}

.dark-mode .remove-question-btn {
  color: #71717a !important;
}

.dark-mode .remove-question-btn:hover {
  background-color: #ef4444 !important;
  color: #ffffff !important;
}

.dark-mode .add-question-button {
  background-color: #818cf8 !important;
  color: #ffffff !important;
}

.dark-mode .add-question-button:hover {
  background-color: #6366f1 !important;
}

.dark-mode .custom-question {
  background-color: #35354a !important;
}

.dark-mode .no-questions {
  color: #71717a !important;
}

.dark-mode .company-header {
  background-color: #414157 !important;
  color: #ffffff !important;
}

/* Enhanced font sizes for better readability */
@media (min-width: 769px) {
  .comparador-title { font-size: 1.5rem !important; }
  .comparador-subtitle { font-size: 1.1rem !important; }
  .nav-tab { font-size: 1.1rem !important; }
  .dropzone p { font-size: 1.25rem !important; }
  .dropzone .hint { font-size: 1.05rem !important; }
  .file-name { font-size: 1.1rem !important; }
  .question-text { font-size: 1.1rem !important; }
  .primary-button, .secondary-button { font-size: 1.1rem !important; }
  .comparison-table th, .comparison-table td { font-size: 1.05rem !important; }
  .proposal-name { font-size: 1.4rem !important; }
} 