/* 引入字体：Jost (类Futura几何无衬线) 用于标题，Noto Sans SC 用于正文 */
@import url('https://fonts.googleapis.com/css2?family=Jost:wght@300;400;500&family=Noto+Sans+SC:wght@300;400;500&display=swap');

/* 全局基础设置 */
:root {
  --color-text-primary: #1a1a1a;
  --color-text-secondary: #4a4a4a;
  --color-bg: #f9f9f9;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Noto Sans SC', sans-serif;
  color: var(--color-text-primary);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* 标题字体覆盖 */
h1, h2, h3, h4, h5, h6, .font-heading {
  font-family: 'Jost', sans-serif;
  letter-spacing: 0.05em;
}

/* 导航链接下划线动画 */
.nav-link {
  position: relative;
  text-decoration: none;
  color: var(--color-text-secondary);
  transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
  color: #000;
}

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

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

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

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

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* 动画实用类 */
.animate-fade-in-up {
  animation: fadeInUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
  opacity: 0; /* 初始隐藏 */
}

.animate-fade-in {
  animation: fadeIn 1.5s ease-out forwards;
  opacity: 0;
}

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

/* 图片悬停效果 */
.img-hover-zoom {
  overflow: hidden;
  position: relative;
}

.img-hover-zoom img {
  transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

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

/* 遮罩层动画 */
.hover-overlay {
  opacity: 0;
  transition: opacity 0.4s ease;
  background: rgba(0, 0, 0, 0.3);
}

.group:hover .hover-overlay {
  opacity: 1;
}

/* 灯箱样式 */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 10, 10, 0.95);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  backdrop-filter: blur(5px);
}

.lightbox.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox-content {
  max-width: 90%;
  max-height: 90vh;
  position: relative;
  transform: scale(0.95);
  transition: transform 0.4s ease;
}

.lightbox.active .lightbox-content {
  transform: scale(1);
}

.lightbox img {
  max-height: 85vh;
  max-width: 100%;
  object-fit: contain;
  box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}

.lightbox-caption {
  color: #fff;
  text-align: center;
  margin-top: 1rem;
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  letter-spacing: 0.1em;
  font-size: 0.9rem;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  z-index: 1001;
  opacity: 0.7;
  transition: opacity 0.2s;
  background: transparent;
  border: none;
}

.lightbox-close:hover {
  opacity: 1;
}

/* 极简按钮交互 */
.btn-minimal {
  position: relative;
  padding-right: 1.5em;
  transition: color 0.3s ease;
}

.btn-minimal::after {
  content: '→';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.3s ease;
}

.btn-minimal:hover::after {
  transform: translate(5px, -50%);
}

/* 隐藏特定元素的滚动条但保留功能 */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none; 
  scrollbar-width: none; 
}

/* 移动端菜单过渡 */
#mobile-menu {
    transition: max-height 0.4s ease-in-out, opacity 0.4s ease-in-out;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

#mobile-menu.open {
    max-height: 400px;
    opacity: 1;
}