/**
 * E10_U01_1 Ferien – D&D: Nummeriere die Bilder (1–6)
 * Tabela 6 vrstic x 7 stolpcev: stolpci 1–3 (drop|napis|slika) za elemente 1–3, stolpec 4 prazen, stolpci 5–7 za elemente 4–6.
 * Številke horizontalno pod tabelo. Audio v content-container > audio-container.
 */

.exercise-container {
  width: 100%;
  max-width: 75rem;
  height: 100%;
  max-height: 42rem;
  margin: 0 auto;
  padding: 0.25rem 0.75rem;
  font-family: 'League Spartan', sans-serif;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

.content-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 68rem;
  gap: 1rem;
}

.audio-and-table-row {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 0.5rem;
  width: 100%;
  min-height: 0;
}

.audio-container {
  flex: 0 0 5rem;
  margin-right: 0.5rem;
  margin-top: 0.5rem;
}

.number-images-table {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border-collapse: collapse;
  border: 0.1rem solid rgba(0, 105, 159, 0.6);
  background-color: #fff;
  font-family: 'League Spartan', sans-serif;
  table-layout: fixed;
}

.number-images-table td {
  border: 0.1rem solid rgba(0, 105, 159, 0.6);
  padding: 0.5rem;
  vertical-align: middle;
  text-align: center;
}

.number-images-table tr td {
  min-height: 3.5rem;
  height: 3.5rem;
}

.drop-cell {
  width: 5rem;
  min-width: 5rem;
  text-align: center;
}

.caption-cell {
  font-size: 0.95rem;
  line-height: 1.3;
  color: #333;
  text-align: center;
}

.img-cell {
  width: 12rem;
  min-width: 12rem;
  text-align: center;
}

.img-cell img {
  max-width: 100%;
  max-height: 10rem;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

.empty-cell {
  width: 2rem;
  min-width: 2rem;
  border: 0.1rem solid rgba(0, 105, 159, 0.6);
  background: transparent;
}

.drop-cell .drop_element {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  min-width: 3rem;
  height: 2rem;
  min-height: 2rem;
  flex-shrink: 0;
}

.drop_element {
  border: 0.15rem solid #F9B002;
  border-radius: 0.9rem;
  background-color: #fff;
  padding: 0 0.4rem;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.drop_element.dragover {
  background-color: rgba(249, 176, 2, 0.15);
}

.drop_element.correct {
  border-color: #258174;
  background-color: rgba(37, 129, 116, 0.1);
}

.drop_element.incorrect {
  border-color: #e00;
  background-color: rgba(255, 0, 0, 0.08);
}

.drop_element .drag_element {
  border: 0;
  background-color: transparent;
}

.answers-container {
  flex-shrink: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-start;
  align-items: center;
  margin-left: 5.5rem;
}

.drag_element {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  font-size: 1rem;
  user-select: none;
  width: 3rem;
  min-width: 3rem;
  height: 2rem;
  min-height: 2rem;
  padding: 0 0.5rem;
  box-sizing: border-box;
  background-color: #fff;
  border: 0.15rem solid #00699F;
  border-radius: 0.9rem;
}

.drag_element.dragging {
  opacity: 0.5;
  cursor: grabbing;
}

.drag_element.correct {
  border-color: #258174;
}

.drag_element.incorrect {
  border-color: #e00;
}

@media (hover: none) {
  .drag_element {
    touch-action: none;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
  }
}

.touch-drag-ghost {
  position: fixed;
  pointer-events: none;
  opacity: 0.8;
  z-index: 1000;
  box-sizing: border-box;
  background-color: #fff;
  border: 0.15rem solid #00699F;
  border-radius: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
