/* 相册模块样式 */

/* 自定义样式 */
.pic-card {
  transition: all 0.3s ease;
}
.pic-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}
.image-grid {
  display: block;
  width: 100%;
}

.image-grid > div {
  width: 100%;
  margin-bottom: 20px;
}
.image-item {
  transition: all 0.3s ease;
  cursor: pointer;
}
.image-item:hover {
  transform: scale(1.05);
}
.thumbnail-container {
  position: relative;
  width: 100%;
  padding-bottom: 100%; /* 1:1 宽高比 */
  overflow: hidden;
  background-color: var(--color-light-cyan-background);
}
.thumbnail {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: rgba(0, 0, 0, 0.9);
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.modal-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.modal-close-btn {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1002;
}
.modal-image-container {
  width: 100%;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}
.image-zoom-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.image-zoom-container:active {
  cursor: grabbing;
}
.image-zoom-container img {
  width: 100vw;
  height: 100vh;
  object-fit: contain;
  object-position: center;
  transition: transform 0.05s linear;
  touch-action: none;
  will-change: transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform-style: preserve-3d;
  -webkit-transform-style: preserve-3d;
}
.close {
  position: absolute;
  top: 20px;
  right: 20px;
  color: var(--color-gray-light);
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
  z-index: 1001;
}
.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
  cursor: pointer;
}
.modal-buttons {
  position: fixed;
  bottom: 30px;
  display: flex;
  gap: 12px;
  z-index: 1002;
}
.modal-btn {
  background-color: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  backdrop-filter: blur(4px);
  transition: background-color 0.2s ease;
}
.modal-btn:hover {
  background-color: rgba(0, 0, 0, 0.8);
}

/* 模态框加载指示器 - 使用全局样式 */
.loading-indicator {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1002;
}
#modal-image {
  display: none;
}
#modal-image.loaded {
  display: block;
}

.no-animation {
  transition: none !important;
}

.prev-btn:hover,
.prev-btn:active,
.next-btn:hover,
.next-btn:active {
  transform: translateY(-50%) !important;
  box-shadow: none !important;
}
