/* 
 * 全局样式文件 - Fashion Gallery
 * 极简主义、视觉优先、响应式优化
 */

/* 引入思源宋体用于诗意文案 */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@300;400;500&display=swap');

:root {
  --transition-slow: 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --color-text-primary: #1a1a1a;
  --color-text-light: #666666;
  --spacing-unit: 8px;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  /* 现代无衬线字体栈，优先系统默认 */
  font-family: 'Helvetica Neue', Helvetica, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', Arial, sans-serif;
  color: var(--color-text-primary);
  background-color: #ffffff;
  overflow-x: hidden; /* 防止横向溢出 */
  line-height: 1.6;
}

/* 特殊字体类：用于标题、引言等 */
.font-serif-sc {
  font-family: 'Noto Serif SC', serif;
}

/* 极简滚动条 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #e5e5e5;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #d4d4d4;
}

/* -------------------------------------------
   自定义动画效果 
   ------------------------------------------- */

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

.fade-in {
  animation: fadeIn 1.2s ease-out forwards;
  opacity: 0; /* 初始隐藏 */
}

/* 延迟类 */
.delay-100 { animation-delay: 0.1s; }
.delay-300 { animation-delay: 0.3s; }
.delay-500 { animation-delay: 0.5s; }
.delay-700 { animation-delay: 0.7s; }

/* -------------------------------------------
   图片交互效果 
   ------------------------------------------- */

/* 图片容器：隐藏溢出 */
.img-container {
  overflow: hidden;
  position: relative;
  display: block;
}

/* 图片缩放效果 */
.img-zoom {
  transition: transform var(--transition-slow);
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.img-container:hover .img-zoom {
  transform: scale(1.05); /* 轻微放大，保持优雅 */
}

/* 图片加载占位色块 */
.bg-placeholder {
  background-color: #f5f5f5;
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

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

/* -------------------------------------------
   导航与排版辅助 
   ------------------------------------------- */

/* 导航链接下划线动效 */
.nav-link {
  position: relative;
  text-decoration: none;
  padding-bottom: 4px;
  color: inherit;
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 1px;
  bottom: 0;
  left: 50%;
  background-color: currentColor;
  transition: all 0.4s ease;
  transform: translateX(-50%);
  opacity: 0.6;
}

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

/* 字间距增强 */
.tracking-widest-xl {
  letter-spacing: 0.25em;
}

/* 纵横比工具类 (Tailwind默认可能不全) */
.aspect-3-4 {
  aspect-ratio: 3 / 4;
}

.aspect-16-9 {
  aspect-ratio: 16 / 9;
}

/* 选中态样式 - 保持极简黑白 */
::selection {
  background: #f0f0f0;
  color: #000;
}

/* -------------------------------------------
   响应式辅助 
   ------------------------------------------- */
@media (max-width: 640px) {
  .mobile-full-height {
    min-height: 80vh;
  }
}