/* 全局样式定义 - 摩登衣序 */

/* 引入 Google Fonts 替代方案 (思源黑体风格) */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500&family=Playfair+Display:ital,wght@0,400;0,600;1,400&display=swap');

/* 基础设置 */
:root {
  --font-main: 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
  --font-serif: 'Playfair Display', serif; /* 用于极少数装饰性文字 */
  --bg-color: #ffffff;
  --text-color: #1f1f1f;
  --transition-smooth: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-color);
  color: var(--text-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  line-height: 1.6;
}

/* 自定义动画关键帧 */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes revealText {
  from {
    clip-path: inset(0 100% 0 0);
  }
  to {
    clip-path: inset(0 0 0 0);
  }
}

@keyframes subtleZoom {
  0% { transform: scale(1.0); }
  100% { transform: scale(1.05); }
}

/* 动画工具类 */
.animate-fade-up {
  animation: fadeInUp 1s ease-out forwards;
  opacity: 0; /* 初始隐藏 */
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }

/* 交互效果 */
.hover-reveal-line {
  position: relative;
  display: inline-block;
}

.hover-reveal-line::after {
  content: '';
  position: absolute;
  width: 0;
  height: 1px;
  bottom: -2px;
  left: 0;
  background-color: currentColor;
  transition: width 0.3s ease;
}

.hover-reveal-line:hover::after,
.hover-reveal-line.active::after {
  width: 100%;
}

/* 图片容器效果 */
.img-container {
  overflow: hidden;
  position: relative;
}

.img-container img {
  transition: transform 0.8s ease;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

/* 沉浸式全屏背景 */
.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  animation: subtleZoom 20s infinite alternate linear;
}

/* 隐藏滚动条但保留功能 */
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* 瀑布流布局辅助 */
.masonry-grid {
  column-count: 1;
  column-gap: 1.5rem;
}

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

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

.masonry-item {
  break-inside: avoid;
  margin-bottom: 1.5rem;
}

/* 文字排版辅助 */
.text-justify-custom {
  text-align: justify;
  text-justify: inter-ideograph;
}

/* 遮罩层渐变 */
.overlay-gradient {
  background: linear-gradient(to top, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0) 40%);
}