.comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin: 15px auto;
  border: 1px solid #ddddddad;
  position: relative;
  z-index: 20 !important;
  background-color: #ddddddad;
  font-size: 14px;
  max-width: 1000px;
  width: 100%;
  border-radius: 12px;
}

.comparison-item {
  text-align: center;
}

.comparison-grid::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background-color: #ddd;
  transform: translateX(-50%);
}

.comparison-item:last-child {
  border-right: none;
}

.comparison-header {
  padding: 10px;
  background-color: #dddddd00;
  border-bottom: 1px solid #ddddddad;
  font-weight: bold;
  color: #5f4abd;
}

.comparison-image {
  padding: 10px;
}

.comparison-image img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

/* Table Styles */
.table-container {
  overflow-x: auto;
  margin: 20px 0;
  z-index: 20 !important;
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #ddd;
}

th, td {
  padding: 12px;
  text-align: left;
  border: 1px solid #dddddd6b;
  vertical-align: top;
}

th {
  background-color: #dddddde6;
  font-weight: bold;
  color: #5f4abd; /* Colore testo header */
  text-align: center;
}

/* Righe pari - background bianco con testo viola */
tbody tr:nth-child(even) {
  background-color: rgba(47, 39, 94, 0.8);
  color: #ffffff;
}

/* Righe dispari - background nero semi-trasparente con testo bianco */
tbody tr:nth-child(odd) {
  background-color: rgba(0, 0, 0, 0.7); /* Nero con opacità 40% */
  color: #ffffff; /* Testo bianco per righe trasparenti */
}

/* Hover per righe pari (background bianco) */
tbody tr:nth-child(even):hover {
  background-color: rgba(47, 39, 94, 0.7); /* Background leggermente più scuro */
  color: #ffffff; /* Testo viola più scuro */
}

/* Hover per righe dispari (background trasparente) */
tbody tr:nth-child(odd):hover {
  background-color: rgba(0, 0, 0, 0.9); /* Nero più opaco */
  color: #f0f0f0; /* Testo bianco leggermente più chiaro */
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .comparison-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .comparison-grid::after {
    display: none;
  }
  
  .comparison-item {
    border-right: none;
    border-bottom: 1px solid #ddd;
  }
  
  .comparison-item:last-child {
    border-bottom: none;
  }
  
  table {
    font-size: 14px;
  }
  
  th, td {
    padding: 8px;
  }
  
  /* Stack table on very small screens */
  @media (max-width: 480px) {
    table, thead, tbody, th, td, tr {
      display: block;
    }

    table {
      border: none;
    }
    
    thead tr {
      position: absolute;
      top: -9999px;
      left: -9999px;
    }
    
    tr {
      border: 1px solid #ddd;
      margin-bottom: 10px;
      padding: 10px;
      border-radius: 4px;
    }
    
    td {
      border: none;
      padding: 10px 5px;
      position: relative;
      padding-left: 35%;
    }
    
    td:before {
      content: attr(data-label) ": ";
      position: absolute;
      left: 6px;
      width: 30%;
      padding-right: 10px;
      white-space: nowrap;
      font-weight: bold;
    }
  }
}