@font-face {
  font-family: "Centaur";
  src: local("Centaur");
}

/* ====== 基础 ====== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  font-family: system-ui, -apple-system;
  color: #f5f5f5;
}

body {
  overflow-x: hidden;
}

/* ====== 背景 ====== */
.background {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: url("background.jpg") center / cover no-repeat;
}

/* ====== 毛玻璃 ====== */
.glass {
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(10px);
}

/* ====== Header ====== */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 16px 40px;
  display: flex;
  justify-content: space-between;
  z-index: 10;
}

.site-header a {
  margin-left: 20px;
  text-decoration: none;
  color: #ddd;
  font-size: 0.9rem;
}

/* ====== Section 通用 ====== */
.section {
  min-height: 88vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ====== 第一版 ====== */
.section-home {
  height: 100vh;
  position: relative;
  padding-top: 120px;
}

.center-block {
  text-align: center;
}

.avatar {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  margin-bottom: 24px;
}

.motto {
  font-size: 0.9rem;
  opacity: 0.75;
}

/* 向下提示 */
.scroll-indicator {
  position: absolute;
  bottom: 40px;
  font-size: 1.2rem;
  opacity: 0.6;
  animation: float 2.5s ease-in-out infinite;
}

@keyframes float {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(8px); }
  100% { transform: translateY(0); }
}

/* ====== 第二版 ====== */
.section-projects {
  background: #000;
  padding: 140px 0;   /* 上下间距加宽 */
}

.projects-wrapper {
  width: 80%;
  max-width: 1000px;
  text-align: center;
}

.tags {
  margin-bottom: 60px;
}

.tags span {
  font-size: 0.75rem;
  padding: 6px 14px;
  background: rgba(255,255,255,0.1);
  border-radius: 14px;
  margin: 0 6px;
}

.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
 
  margin-bottom: 40px;
}

.project-card {
  text-decoration: none;
  color: inherit;
  padding: 30px;
  background: rgba(255,255,255,0.05);
  border-radius: 16px;
  transition: transform 0.25s ease, background 0.25s ease;
}

.project-card:hover {
  transform: translateY(-6px);
  background: rgba(255,255,255,0.12);
}

.icon {
  font-size: 1.6rem;
  margin-bottom: 12px;
}

/* 次级项目 */
.project-card.secondary {
  display: block;
  padding: 18px 30px;
  margin-bottom: 40px;
  background: rgba(255,255,255,0.03);
}

.project-note {
  font-size: 0.85rem;
  opacity: 0.7;
}

/* ====== 第三版 ====== */

.con {
  font-family: "Centaur", "Times New Roman", serif;
  font-size: 2.1rem;
  line-height: 1.7;
  max-width: 720px;
}

.links {
  margin-bottom: 30px;
}

.btn {
  display: inline-block;
  margin: 0 10px;
  padding: 10px 22px;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 22px;
  text-decoration: none;
  color: inherit;
  font-size: 0.85rem;
  transition: background 0.2s ease;
}

.btn:hover {
  background: rgba(255,255,255,0.15);
}

.quote {
  font-family: "Centaur", "Times New Roman", serif;
  font-size: 1.6rem;
  line-height: 1.7;
  max-width: 720px;
}

/* ====== Footer ====== */
.site-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  padding: 80px 60px;
  font-size: 0.8rem;
}

/* 确保页脚列内部元素垂直排列，并保持间距 */
.footer-column {
  display: flex;
  flex-direction: column;
  gap: 12px; /* 统一行间距 */
}

/* 针对备案链接的专用对齐 */
.footer-column a {
  display: inline-flex;    /* 关键：允许内容在一行内弹性布局 */
  align-items: center;     /* 关键：垂直方向居中对齐图标和文字 */
  text-decoration: none;
  color: #ccc;
  line-height: 1.2;
}

.site-footer a {
  text-decoration: none;
  color: #ccc;
}

/* Align icons and text in footer links */


.footer-column ac img {
  height: 8px;           /* 固定高度防止撑破行高 */
  width: auto;
  margin-right: 8px;      /* 图标与文字的间距 */
  flex-shrink: 0;         /* 防止图标在空间不足时被挤压 */
}

/* 页脚后留白（透明） */
.footer-space {
  height: 60px;
}

/* ====== 动效 ====== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1.8s ease, transform 1.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}


/* ====== 响应式适配 (移动端优先逻辑) ====== */

@media (max-width: 768px) {
  /* 调整 Header 间距和导航 */
  .site-header {
    padding: 16px 20px;
  }
  
  .site-header a {
    margin-left: 10px;
    font-size: 0.8rem;
  }

  /* 调整首屏标题与间距 */
  .section-home {
    padding-top: 80px;
  }

  .avatar {
    width: 110px;
    height: 110px;
  }

  /* 第三版文字内容在手机端需缩小 */
  .con, .quote {
    font-size: 1.5rem; /* 从 2.1rem 降级 */
    padding: 0 20px;
    line-height: 1.5;
  }

  /* 项目展示区 */
  .projects-wrapper {
    width: 90%;
  }

  .projects {
    grid-template-columns: 1fr; /* 强制单列显示 */
    gap: 20px;
  }

  /* 页脚布局由双列变为单列 */
  .site-footer {
    grid-template-columns: 1fr;
    padding: 60px 30px;
    gap: 40px;
    text-align: center;
  }

  .footer-column {
    align-items: center; /* 居中页脚内容 */
  }

  .btn {
    margin: 5px; /* 按钮防止挤压 */
    width: 80%;  /* 移动端按钮建议拉长，易于点击 */
  }
}

/* 针对超小屏幕 (iPhone SE等) */
@media (max-width: 480px) {
  .con, .quote {
    font-size: 1.25rem;
  }
  
  .tags span {
    display: inline-block;
    margin-bottom: 8px;
  }
}