/* styles.css */

.collage-section {
  height: 120vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: whitesmoke;
}

.collage-header {
  display: flex;

  width: 100%;
  overflow: hidden;
}

.collage-title {
  display: flex;
  width: 100%;
  height: 16%;
  justify-content: center;
  padding-top: 20px;
}

.collage-section h1 {
  display: flex;
  align-items: center;
  justify-content: center;

  color: var(--hero-overlay-color);
  font-family: var(--regular-text);
  font-weight: 600;
  font-size: 2.8rem;
}

.collage-container {
  height: 100vh;
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 10px;
  padding: 20px;
}

.collage-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
}

.collage-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 15px;
}

.collage-item .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  background-color: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  opacity: 0;
  scale: 1;
  transition: all 0.2s;
  display: flex;
  justify-content: center;
  align-items: center;
}

.collage-item .overlay img {
  width: 270px; /* Set a fixed width */
  height: 270px; /* Set a fixed height */
  object-fit: contain;
}

.collage-item:hover .overlay {
  opacity: 1;

  cursor: pointer;
  transition: all 0.2s;
}

.item1 {
  grid-column: 1 / 3;
  grid-row: 1;
}

.item2 {
  grid-column: 3;
  grid-row: 1 / 3;
}

.item3 {
  grid-column: 1;
  grid-row: 2;
}

.item4 {
  /*max-height: 300px;*/
  grid-column: 2;
  grid-row: 2;
}

.item5 {
  max-height: 290px;
}

.item6 {
  max-height: 290px;
  grid-column: 2 / 4;
  grid-row: 3;
}

/* Reszponzív beállítások kisebb képernyőkhöz */
@media screen and (max-width: 1024px) {
  .collage-container {
    height: auto;
    min-height: 80vh;
  }

  .item2 {
    height: calc(
      100% - 0px
    ); /* Pontosan az item3 és item4 együttes magassága */
    grid-row: 1 / 3; /* Biztosítja, hogy az item2 kitöltse az első két sort */
  }

  .item3 {
    max-height: 300px;
  }

  .item4 {
    max-height: 300px;
  }
}

@media screen and (max-width: 768px) {
  .collage-section {
    height: auto;
  }

  .collage-container {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }

  .item1 {
    grid-column: 1 / 3;
    grid-row: 1;
  }

  .item2 {
    grid-column: 1;
    grid-row: 2;
    max-height: 250px;
    height: auto; /* Felülírja az előző media query beállítást */
  }

  .item3 {
    grid-column: 2;
    grid-row: 2;
    max-height: 250px;
  }

  .item4 {
    grid-column: 1;
    grid-row: 3;
    max-height: 250px;
  }

  .item5 {
    grid-column: 2;
    grid-row: 3;
  }

  .item6 {
    grid-column: 1 / 3;
    grid-row: 4;
  }
}

@media screen and (max-width: 480px) {
  .item2,
  .item3,
  .item4 {
    max-height: 200px;
  }

  .collage-item .overlay img {
    width: 150px;
    height: 150px;
  }
}
