/* Wrapper um die gesamte Tabelle scrollbar machen */
.field--name-field-stundentafel-tabelle {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* smooth scrolling auf iOS */
}


.table-lesson-plan {
  width: 100%;
  min-width: 600px;
  max-width: 100%;
  border-collapse: collapse; /* Remove spacing between cells */
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 14px;
  color: #333;
  border-radius: 12px;
  overflow: hidden;
}



.table-lesson-plan th,
.table-lesson-plan td {
  padding: 10px 10px; /* Modern spacing */
  text-align: left;
  border: none; /* Remove all borders */
}

.table-lesson-plan td:first-child,
.table-lesson-plan th:first-child {
  padding-right: 5px; /* Less spacing on the right for the first column */
}

.table-lesson-plan thead th {
  position: sticky;
  top: 0;
  background-color: #434343;
  z-index: 10;
}

.table-lesson-plan tbody tr {
  transition: background-color 0.2s ease;
}

.table-lesson-plan tbody tr:hover:not(.sum-row){
  background-color: #1176A6; /* Subtle hover effect */
}

.table-lesson-plan-subheading{
  background-color: #a3a1a1;
}

.sum-cell {
  font-weight: bold;
}

.sum-row {
  font-weight: bold;
  position: sticky;
  top: 0;
  background-color: #434343;
  z-index: 10;
  color: white;
}

/* Tablet: slightly more compact */
@media (max-width: 768px) {
  .table-lesson-plan {
    font-size: 12px;
    min-width: 480px;
  }

  .table-lesson-plan th,
  .table-lesson-plan td {
    padding: 8px 6px;
  }
}

/* Mobile: very compact */
@media (max-width: 480px) {
  .table-lesson-plan {
    font-size: 11px;
    min-width: 400px;
  }

  .table-lesson-plan th,
  .table-lesson-plan td {
    padding: 5px 4px;
  }
}

/* Touch-Geräte: kein Hover */
@media (hover: none) {
  .table-lesson-plan tbody tr:hover:not(.sum-row) {
    background-color: transparent;
  }

  /* Kurzes visuelles Feedback beim Antippen (verschwindet von selbst) */
  .table-lesson-plan tbody tr:active:not(.sum-row) {
    background-color: #d0e8f5;
  }
}