/* 
 * 全局样式文件
 * 遵循极简主义设计原则
 * 适配 Pico.css 变量系统与自定义时尚风格
 */

/* 引入字体：思源宋体(Noto Serif SC) 与 思源黑体(Noto Sans SC) */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500&family=Noto+Serif+SC:wght@300;400;600&display=swap');

:root {
  /* --- 覆盖 Pico.css 默认变量以符合品牌色调 --- */
  
  /* 基础排版 */
  --pico-font-family: 'Noto Sans SC', system-ui, -apple-system, sans-serif;
  --pico-font-size: 16px;
  --pico-line-height: 1.6;
  
  /* 色彩系统 - 极简黑白灰 */
  --pico-background-color: #ffffff;
  --pico-color: #1a1a1a; /* 深炭灰 */
  --pico-muted-color: #666666; /* 次要文字 */
  --pico-primary: #1a1a1a; /* 主色调改为深色 */
  --pico-primary-background: #1a1a1a;
  --pico-primary-hover: #333333;
  --pico-primary-underline: rgba(26, 26, 26, 0.5);
  --pico-primary-inverse: #ffffff;
  
  /* 边框与阴影 - 去除厚重感 */
  --pico-border-radius: 0; /* 锐利直角，符合现代时尚感 */
  --pico-box-shadow: none;
  --pico-form-element-spacing-vertical: 0.75rem;
  --pico-form-element-spacing-horizontal: 1rem;

  /* 自定义变量 */
  --font-serif: 'Noto Serif SC', serif;
  --font-sans: 'Noto Sans SC', sans-serif;
  --nav-height: 80px;
  --transition-smooth: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* --- 全局重置与基础样式 --- */

html {
  scroll-behavior: smooth;
}

body {
  font-weight: 300; /* 整体字体偏细 */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 标题样式 - 思源宋体 */
h1, h2, h3, h4, h5, h6, .serif-font {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}

/* 链接样式 - 去除默认下划线，自定义悬停 */
a {
  text-decoration: none;
  transition: var(--transition-smooth);
}

a:hover {
  opacity: 0.7;
  text-decoration: none;
}

/* --- 布局组件 --- */

/* 导航栏 */
header.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5%;
  border-bottom: 1px solid rgba(0,0,0,0.03);
  transition: transform 0.3s ease;
}

header.navbar nav ul {
  display: flex;
  gap: 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

header.navbar nav a {
  color: var(--pico-color);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

header.navbar nav a.active {
  border-bottom: 1px solid var(--pico-color);
}

/* 页面容器 */
main.container {
  padding-top: var(--nav-height);
  max-width: 1200px; /* 桌面端版心 */
  margin: 0 auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

main.container-fluid {
  padding-top: var(--nav-height);
  padding-left: 0;
  padding-right: 0;
  max-width: 100%;
}

/* 沉浸式全屏部分 */
.hero-section {
  height: 100vh;
  width: 100%;
  position: relative;
  overflow: hidden;
  margin-top: calc(var(--nav-height) * -1); /* 抵消padding使其全屏 */
}

/* 页脚 */
footer {
  text-align: center;
  padding: 3rem 0;
  font-size: 0.8rem;
  color: #888;
  border-top: 1px solid #f0f0f0;
  margin-top: 4rem;
}

/* --- 视觉元素与工具类 --- */

/* 图片处理 */
img {
  display: block;
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

.img-hover-zoom {
  overflow: hidden;
  position: relative;
}

.img-hover-zoom img {
  transition: transform 0.8s ease;
}

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

/* 文字排版工具 */
.text-center { text-align: center; }
.text-justify { text-align: justify; }
.uppercase { text-transform: uppercase; }
.tracking-wide { letter-spacing: 0.15em; }
.font-light { font-weight: 300; }

.section-spacing {
  padding: 6rem 0;
}

/* 按钮风格重置 */
button, .btn {
  background-color: transparent;
  border: 1px solid var(--pico-color);
  color: var(--pico-color);
  border-radius: 0;
  padding: 0.75rem 2rem;
  font-family: var(--font-sans);
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.3s ease;
}

button:hover, .btn:hover {
  background-color: var(--pico-color);
  color: #fff;
  border-color: var(--pico-color);
}

/* --- 动画 --- */

/* 淡入动画 */
.fade-in {
  opacity: 0;
  animation: fadeIn 1s ease-out forwards;
}

.fade-in-up {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1s ease-out forwards;
}

.delay-200 { animation-delay: 0.2s; }
.delay-400 { animation-delay: 0.4s; }
.delay-600 { animation-delay: 0.6s; }

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

/* 占位符加载 */
.placeholder-loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #f8f8f8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* --- 响应式调整 --- */

@media (max-width: 768px) {
  :root {
    --nav-height: 60px;
  }

  header.navbar {
    padding: 0 1rem;
  }
  
  header.navbar nav ul {
    gap: 1rem;
  }
  
  header.navbar nav a {
    font-size: 0.8rem;
  }

  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.5rem; }
  
  .section-spacing {
    padding: 3rem 0;
  }
}