/* fashion-women-website-010051/frontend/public/css/style.css */

/* 全局重置与基础设置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-white: #FFFFFF;
  --color-light-gray: #F8F9FA;
  --color-dark-gray: #2C3E50;
  --color-gold: #D4AF37;
  --transition: all 0.3s ease;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  background-color: var(--color-white);
  color: var(--color-dark-gray);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: "Playfair Display", "思源宋体", serif;
  font-weight: 600;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* 布局容器 */
.container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* 导航栏 */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  padding: 1.25rem 0;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

.nav-list {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
}

.nav-link {
  font-size: 1.125rem;
  font-weight: 500;
  position: relative;
  padding: 0.5rem 0;
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-gold);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-gold);
  transition: var(--transition);
}

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

/* 返回顶部按钮 */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background-color: var(--color-dark-gray);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

/* 轮播图 */
.hero-slider {
  height: 100vh;
  position: relative;
  overflow: hidden;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  background-size: cover;
  background-position: center;
}

.slide.active {
  opacity: 1;
}

.slide-content {
  position: absolute;
  bottom: 15%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: var(--color-white);
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.slide-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  letter-spacing: 1px;
}

.slider-indicators {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.75rem;
}

.indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: var(--transition);
}

.indicator.active {
  background-color: var(--color-gold);
}

/* 精选系列 */
.section-title {
  text-align: center;
  font-size: 2.25rem;
  margin: 4rem 0 2.5rem;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--color-gold);
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 5rem;
}

.featured-card {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
}

.featured-card:hover {
  transform: scale(1.02);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.featured-img {
  width: 100%;
  height: 350px;
  object-fit: cover;
}

/* 编辑推荐 */
.editorial-section {
  margin-bottom: 5rem;
}

.editorial-item {
  display: flex;
  align-items: center;
  gap: 3rem;
  margin-bottom: 4rem;
}

.editorial-content {
  flex: 1;
}

.editorial-title {
  font-size: 1.875rem;
  margin-bottom: 1rem;
}

.editorial-text {
  color: #555;
  font-size: 1.125rem;
}

.editorial-image {
  flex: 1;
  border-radius: 8px;
  overflow: hidden;
  height: 400px;
}

.editorial-item:nth-child(even) {
  flex-direction: row-reverse;
}

/* 风格画廊 */
.gallery-filters {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 3rem 0 2rem;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 0.5rem 1.5rem;
  background: transparent;
  border: 1px solid var(--color-dark-gray);
  color: var(--color-dark-gray);
  border-radius: 30px;
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn.active,
.filter-btn:hover {
  background-color: var(--color-dark-gray);
  color: var(--color-white);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.gallery-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition);
}

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

.gallery-img {
  width: 100%;
  height: 350px;
  object-fit: cover;
}

.gallery-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.7);
  color: white;
  padding: 0.75rem;
  font-size: 1rem;
}

.banner-section {
  background: var(--color-light-gray);
  padding: 4rem 0;
  margin: 4rem 0;
  text-align: center;
}

.banner-text {
  font-size: 2rem;
  font-style: italic;
  max-width: 800px;
  margin: 0 auto;
}

/* 细节之艺 */
.craft-section {
  margin-bottom: 5rem;
}

.craft-item {
  display: flex;
  gap: 3rem;
  margin-bottom: 4rem;
  align-items: center;
}

.craft-image {
  flex: 1;
  border-radius: 8px;
  overflow: hidden;
  height: 400px;
}

.craft-content {
  flex: 1;
}

.craft-title {
  font-size: 1.875rem;
  margin-bottom: 1rem;
}

.craft-text {
  color: #555;
  font-size: 1.125rem;
}

.detail-section {
  margin: 5rem 0;
}

.detail-container {
  display: flex;
  gap: 3rem;
  margin-top: 2rem;
}

.detail-main {
  flex: 2;
  border-radius: 8px;
  overflow: hidden;
  height: 500px;
}

.detail-hotspots {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.hotspot {
  border-radius: 8px;
  overflow: hidden;
  height: 240px;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
}

.hotspot:hover,
.hotspot.active {
  border-color: var(--color-gold);
  transform: scale(1.02);
}

.hotspot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fabric-section {
  margin: 5rem 0;
}

.fabric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.fabric-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  height: 300px;
  cursor: pointer;
  transition: var(--transition);
}

.fabric-item:hover {
  transform: scale(1.02);
}

.fabric-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.7);
  color: white;
  padding: 1.5rem;
  transform: translateY(100%);
  transition: var(--transition);
}

.fabric-item:hover .fabric-overlay {
  transform: translateY(0);
}

/* 页脚 */
.footer {
  text-align: center;
  padding: 2rem 0;
  border-top: 1px solid rgba(0,0,0,0.1);
  color: #999;
  font-size: 0.875rem;
  margin-top: 3rem;
}

/* 模态框 */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  max-width: 90%;
  max-height: 90%;
}

.modal-img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
}

/* 响应式设计 */
@media (max-width: 1024px) {
  .container {
    padding: 0 1.5rem;
  }
  
  .hero-slider .slide-title {
    font-size: 2rem;
  }
  
  .editorial-item,
  .craft-item {
    flex-direction: column;
    text-align: center;
  }
  
  .editorial-image,
  .craft-image {
    height: 300px;
  }
  
  .detail-container {
    flex-direction: column;
  }
  
  .detail-main {
    height: 400px;
  }
  
  .detail-hotspots {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  
  .hotspot {
    height: 180px;
  }
}

@media (max-width: 768px) {
  .nav-list {
    gap: 1.5rem;
  }
  
  .nav-link {
    font-size: 1rem;
  }
  
  .hero-slider .slide-title {
    font-size: 1.75rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .editorial-title,
  .craft-title {
    font-size: 1.5rem;
  }
  
  .editorial-text,
  .craft-text {
    font-size: 1rem;
  }
  
  .banner-text {
    font-size: 1.5rem;
  }
  
  .gallery-grid,
  .featured-grid {
    grid-template-columns: 1fr;
  }
  
  .back-to-top {
    width: 40px;
    height: 40px;
    bottom: 1.5rem;
    right: 1.5rem;
  }
}

/* 加载动画 */
.loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3000;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s ease;
}

.loading.hidden {
  opacity: 0;
  visibility: hidden;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 5px solid rgba(0,0,0,0.1);
  border-top: 5px solid var(--color-gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}