/* 自定义样式文件 - 时尚女装展示网站 */

/* 悬停放大效果 */
.hover-scale {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-scale:hover {
  transform: scale(1.03);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
}

/* 图片悬停效果 */
.image-hover {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.image-hover img {
  transition: transform 0.5s ease;
}

.image-hover:hover img {
  transform: scale(1.05);
}

/* 平滑滚动 */
html {
  scroll-behavior: smooth;
}

/* 导航链接活跃状态 */
.nav-link {
  position: relative;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: #333333;
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* 淡入动画 */
.fade-in {
  animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 轮播图过渡效果 */
.carousel-item {
  transition: opacity 0.5s ease-in-out;
}

/* 按钮悬停效果 */
.btn-hover {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn-hover::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(212, 200, 184, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-hover:hover::before {
  width: 300px;
  height: 300px;
}

/* 网格项悬停效果 */
.grid-item {
  transition: all 0.3s ease;
}

.grid-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

/* 文字叠加效果 */
.text-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
  color: white;
  padding: 20px;
  transform: translateY(100%);
  transition: transform 0.4s ease;
}

.text-overlay-parent:hover .text-overlay {
  transform: translateY(0);
}

/* 加载动画 */
.loading {
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* 响应式图片容器 */
.image-container {
  position: relative;
  overflow: hidden;
  background-color: #F5F3EF;
}

.image-container img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 卡片阴影效果 */
.card-shadow {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
}

.card-shadow:hover {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* 分隔线样式 */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, #E8E8E8, transparent);
  margin: 40px 0;
}

/* 滚动进入视图动画 */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.scroll-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 图片网格布局 */
.masonry-grid {
  column-count: 3;
  column-gap: 20px;
}

.masonry-item {
  break-inside: avoid;
  margin-bottom: 20px;
}

@media (max-width: 1024px) {
  .masonry-grid {
    column-count: 2;
  }
}

@media (max-width: 640px) {
  .masonry-grid {
    column-count: 1;
  }
}

/* 轮播指示器 */
.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #E8E8E8;
  transition: background-color 0.3s ease, transform 0.3s ease;
  cursor: pointer;
}

.carousel-indicator.active {
  background-color: #333333;
  transform: scale(1.2);
}

/* 平滑过渡 */
.smooth-transition {
  transition: all 0.3s ease;
}