.folder-btn {
  width: auto;
  cursor: pointer;
}

.folder-btn.active {
  color: bisque;
}

/* 資料夾名稱 */
.current-folder {
  text-align: center;
  margin-bottom: 20px;
  font-size: 1.1rem;
}

.current-folder #folderName {
  font-weight: bold;
  color: #007ACC;
}

/* 主圖區 */
.gallery {
  position: relative;
}

.gallery .main {
  position: relative;
  display: flex;
  justify-content: center;
}

.gallery .main img {
  display: block;
  width: 60vh;
  height: 60vh;
  object-fit: cover;
}

.gallery .btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.4);
  color: white;
  border: none;
  font-size: 2rem;
  width: 50px;
  height: 50px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
}

.gallery .btn.prev {
  left: 10px;
}

.gallery .btn.next {
  right: 10px;
}

/* 縮圖區（三張） */
.gallery .thumbs {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 20px;
}

.gallery .thumbs img {
  width: calc((80vw - 40px) / 3);
  height: calc((80vw - 40px) / 3);
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.3s;
}

.gallery .thumbs img.active,
.gallery .thumbs img:hover {
  opacity: 1;
}

/* 總覽區（三張一列） */

.overview-center {
  display: flex;
  justify-content: center;
  align-items: center;
}

.overview {
  width: 80vw;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.overview img {
  width: calc((80vw - 40px) / 3);
  height: calc((80vw - 40px) / 3);
  cursor: pointer;
  border: 2px solid transparent;
  transition: border 0.3s;
  object-fit: cover;
}

.overview img:hover {
  border: 2px solid #007ACC;
}

@media (max-width: 768px) {
  .gallery .main img {
    width: 40vh;
    height: 40vh;
  }

  .gallery .thumbs {
    gap: 12px;
  }
  
  .gallery .thumbs img {
    width: calc(40vh / 3);
    height: calc(40vh / 3);
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s;
  }

  .overview {
    width: 100%;
    gap: 12px;
  }
  
  .overview img {
    width: calc(40vh / 3);
    height: calc(40vh / 3);
  }
}