/* 全局自定义样式和动画效果 */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

:root {
  --color-primary: #1a1a1a;
  --color-secondary: #666666;
  --color-light: #f8f8f8;
  --color-white: #ffffff;
  --transition-slow: 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --transition-base: 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 300;
  color: var(--color-primary);
  background: var(--color-white);
  line-height: 1.6;
  overflow-x: hidden;
}

/* 导航栏样式 */
.nav-link {
  position: relative;
  transition: var(--transition-base);
}

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

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

/* 图片悬停效果 */
.image-hover {
  overflow: hidden;
  cursor: pointer;
}

.image-hover img {
  transition: transform 0.6s ease, filter 0.6s ease;
}

.image-hover:hover img {
  transform: scale(1.05);
  filter: brightness(0.95);
}

/* 淡入动画 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 1s ease forwards;
}

/* 文字装饰样式 */
.text-decoration {
  background: linear-gradient(180deg, transparent 65%, #f0f0f0 35%);
  padding: 0 4px;
}

/* 自定义滚动条 */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-light);
}

::-webkit-scrollbar-thumb {
  background: var(--color-secondary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}

/* 响应式辅助类 */
.container-fluid {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 20px;
}

/* 加载动画 */
.loading {
  opacity: 0;
  animation: fadeIn 1s ease forwards;
}

/* 延迟加载动画 */
.delay-100 {
  animation-delay: 100ms;
}

.delay-200 {
  animation-delay: 200ms;
}

.delay-300 {
  animation-delay: 300ms;
}

.delay-400 {
  animation-delay: 400ms;
}

/* 页面切换过渡 */
.page-transition {
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.page-transition-out {
  opacity: 0;
  transform: translateY(10px);
}

/* 英雄区域样式 */
.hero-section {
  height: 100vh;
  position: relative;
  overflow: hidden;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.2) 0%, rgba(0,0,0,0.4) 100%);
}

/* 网格布局优化 */
.grid-item {
  position: relative;
  overflow: hidden;
}

.grid-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background var(--transition-base);
  display: flex;
  align-items: center;
  justify-content: center;
}

.grid-item:hover .grid-item-overlay {
  background: rgba(255,255,255,0.1);
}

/* 按钮样式 */
.button-ghost {
  border: 1px solid var(--color-primary);
  background: transparent;
  color: var(--color-primary);
  padding: 12px 32px;
  cursor: pointer;
  transition: all var(--transition-base);
}

.button-ghost:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

/* 文字高亮 */
.text-highlight {
  position: relative;
  display: inline-block;
}

.text-highlight::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 30%;
  background: rgba(255,215,0,0.2);
  z-index: -1;
}

/* 移动端优化 */
@media (max-width: 768px) {
  .container-fluid {
    padding: 0 16px;
  }
  
  .hero-section {
    height: 70vh;
  }
  
  .grid-item-overlay {
    background: rgba(255,255,255,0.05);
  }
}

/* 触摸设备优化 */
@media (hover: none) {
  .image-hover img {
    transform: none !important;
  }
  
  .image-hover:hover img {
    filter: none;
  }
}