/* 全局样式文件 - 女装展示网站 */
/* 使用现代CSS实现响应式布局和优雅设计 */

/* 导入Google Fonts - 思源宋体（标题）和思源黑体（正文） */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@300;400;600&family=Noto+Sans+SC:wght@300;400;500&display=swap');

/* CSS变量定义 - 设计令牌 */
:root {
  /* 色彩系统 */
  --primary-bg: #fefefe;
  --text-color: #333333;
  --accent-color: #e8e8e8;
  --neutral-light: #f8f8f8;
  --neutral-medium: #e0e0e0;
  --neutral-dark: #666666;
  
  /* 字体系统 */
  --font-heading: 'Noto Serif SC', serif;
  --font-body: 'Noto Sans SC', sans-serif;
  
  /* 间距系统 */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 3rem;
  --space-xl: 4rem;
  
  /* 圆角系统 */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  
  /* 阴影系统 */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.2);
  
  /* 过渡动画 */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* 基础重置和全局样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--text-color);
  background-color: var(--primary-bg);
  line-height: 1.6;
  overflow-x: hidden;
}

/* 排版系统 */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: var(--space-sm);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin-bottom: var(--space-sm);
  font-weight: 300;
}

/* 导航栏样式 */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: transparent;
  backdrop-filter: blur(10px);
  z-index: 1000;
  transition: all var(--transition-normal);
  padding: var(--space-sm) 0;
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 400;
  text-decoration: none;
  color: var(--text-color);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: var(--space-md);
}

.nav-link {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 400;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link:hover {
  color: var(--neutral-dark);
}

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

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

/* 页面容器通用样式 */
.page-container {
  min-height: 100vh;
  padding-top: 80px; /* 为固定导航栏留出空间 */
}

.section {
  padding: var(--space-xl) 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

/* 首页特定样式 */
.hero-slider {
  height: 100vh;
  position: relative;
  overflow: hidden;
}

.slider-container {
  height: 100%;
  position: relative;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity var(--transition-slow);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.slide.active {
  opacity: 1;
}

.series-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.series-card {
  text-align: center;
  text-decoration: none;
  color: var(--text-color);
  transition: transform var(--transition-normal);
}

.series-card:hover {
  transform: translateY(-5px);
}

.series-icon {
  width: 120px;
  height: 120px;
  margin: 0 auto var(--space-sm);
  background: var(--accent-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  transition: background var(--transition-normal);
}

.series-card:hover .series-icon {
  background: var(--neutral-medium);
}

/* 系列页面样式 - 瀑布流布局 */
.masonry-grid {
  columns: 3;
  column-gap: var(--space-md);
}

.masonry-item {
  break-inside: avoid;
  margin-bottom: var(--space-md);
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-md);
}

.masonry-item img {
  width: 100%;
  height: auto;
  transition: transform var(--transition-normal);
}

.masonry-item:hover img {
  transform: scale(1.03);
}

.series-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

/* 风格页面样式 */
.style-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: var(--space-lg);
}

.style-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.style-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.style-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.style-content {
  padding: var(--space-md);
  background: var(--primary-bg);
}

/* 工艺页面样式 */
.craftsmanship-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: var(--space-xl);
  align-items: start;
}

.craftsmanship-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
  align-items: center;
}

.craftsmanship-image {
  width: 100%;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.craftsmanship-text {
  padding: var(--space-sm);
}

/* 页脚样式 */
.footer {
  background: var(--neutral-light);
  padding: var(--space-lg) 0;
  text-align: center;
  margin-top: var(--space-xl);
}

.footer-content {
  font-size: 0.9rem;
  color: var(--neutral-dark);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .masonry-grid {
    columns: 2;
  }
  
  .craftsmanship-item {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .style-grid {
    grid-template-columns: 1fr;
  }
  
  .series-grid {
    grid-template-columns: 1fr;
  }
  
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  
  .nav-menu {
    flex-direction: column;
    gap: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .masonry-grid {
    columns: 1;
  }
  
  .container {
    padding: 0 var(--space-sm);
  }
  
  .section {
    padding: var(--space-lg) 0;
  }
}

/* 工具类 */
.text-center { text-align: center; }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }

/* 无障碍支持 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 焦点可见性 */
button:focus,
a:focus {
  outline: 2px solid var(--text-color);
  outline-offset: 2px;
}

/* 图片懒加载支持 */
img[data-src] {
  opacity: 0;
  transition: opacity var(--transition-normal);
}

img[data-src].loaded {
  opacity: 1;
}