/* 仅让首页正文两端对齐 */
.home .page__content p {
  text-align: justify;
}


.highlight-box {
  border-left: 5px solid #003366;   /* 深蓝边框 */
  background-color: #f8f9fa;        /* 浅灰底色 */
  padding: 15px 20px;
  border-radius: 8px;
  margin: 20px 0;
  text-align: justify;
}

.highlight-box p {
  margin-bottom: 8px;
}



/* ----------- 基础字体（更现代、更优雅）----------- */
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-weight: 400;      /* 默认字重柔和但清晰 */
  color: #222;           /* 比纯黑柔和更高档 */
  line-height: 1.65;     /* 文本呼吸更顺畅 */
}

/* ----------- 正文排版 ----------- */
.page__content p {
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 1.0rem;  /* 段落之间更松，学术感更强 */
}

/* ===== Teaching Experience 年份卡片风格 ===== */

.teach-year-card {
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  border-top: 4px solid #0077c8;   /* 顶部蓝线 */
  padding: 14px 20px 18px;
  margin-bottom: 20px;
}

.teach-year-header {
  font-weight: 700;
  font-size: 1.05rem;
  color: #0077c8;
  margin-bottom: 8px;
}

/* 每一条 teaching entry */
.teach-entry {
  padding-top: 10px;
  padding-bottom: 10px;
  border-top: 1px solid #eeeeee;
}

.teach-entry:first-of-type {
  border-top: none;
}

.teach-role {
  font-size: 0.98rem;
  margin-bottom: 4px;
}

.teach-meta,
.teach-note {
  font-size: 0.9rem;
  color: #555;
  display: flex;
  align-items: flex-start;
  margin-bottom: 2px;
}

.teach-icon {
  margin-right: 6px;
  margin-top: 1px;
}

/* 让页面标题和卡片之间留一点空间 */
.page__content > p:first-of-type {
  margin-bottom: 1.0rem;
}


/* ----------- 链接样式（更高级的蓝色）----------- */
.page__content a {
  color: #0056b3;         /* 深一点的蓝，更专业 */
  text-decoration: none;
}
.page__content a:hover {
  text-decoration: underline;
}

/* ----------- 标题层级优化（更优雅）----------- */
.page__content h1 {
  font-size: 2.0rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.page__content h2 {
  font-size: 1.55rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
}

.page__content h3 {
  font-size: 1.25rem;
  font-weight: 500;
  margin-top: 1.6rem;
}

/* ----------- 列表优化 ----------- */
.page__content ul li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

/* ========= 尽量吃满横向空间，压缩右侧留白 ========= */
@media (min-width: 1200px) {

  /* 让 main 容器可以占满整个视口宽度 */
  body.layout--single.wide #main {
    max-width: 100vw !important;
  }

  /* 让中间这块 .page 更宽，右边几乎贴边 */
  body.layout--single.wide #main .page {
    max-width: none !important;
    width: calc(100vw - 340px);  /* 340 ≈ 左侧 sidebar + 中间空隙 */
  }
}
/* =========================================================
   扩展 Homepage 字体排版到全站（Publications 等页）
   ========================================================= */

/* 所有页面的正文基本字体 */
.page__content,
.archive__item-body,
.archive__item-excerpt,
.page__meta,
.page__footer {
  font-size: 16px !important;
  line-height: 1.65 !important;
  color: #222 !important;
}

/* 所有段落间距统一 */
.page__content p,
.archive__item-excerpt p {
  margin-bottom: 1rem !important;
}

/* 所有列表字体与间距统一 */
.page__content ul li,
.page__content ol li,
.archive__item-excerpt ul li,
.archive__item-excerpt ol li {
  font-size: 16px !important;
  line-height: 1.6 !important;
  margin-bottom: 0.5rem;
}

/* 所有标题大小统一（避免 Publications 页标题太大） */
.page__content h1,
.archive__item-body h1 {
  font-size: 2.0rem !important;
  font-weight: 600 !important;
}

.page__content h2,
.archive__item-body h2 {
  font-size: 1.55rem !important;
  font-weight: 600 !important;
}

.page__content h3,
.archive__item-body h3 {
  font-size: 1.25rem !important;
  font-weight: 500 !important;
}

/* Publications 清单中特殊标题（paper titles）处理 */
.archive__item-title a {
  font-size: 1.1rem !important;
  font-weight: 600 !important;
  line-height: 1.4 !important;
  color: #0056b3 !important; /* 与 homepage 链接颜色一致 */
}
/* ========== 统一 Publications 等 archive 页面的字体和行距 ========== */

/* 列表正文（论文简要介绍） */
.archive__item-excerpt,
.archive__item-excerpt p {
  font-size: 16px !important;
  line-height: 1.65 !important;
  color: #222 !important;
}

/* 列表中的 bullet 列表（如果有） */
.archive__item-excerpt ul li,
.archive__item-excerpt ol li {
  font-size: 16px !important;
  line-height: 1.6 !important;
  margin-bottom: 0.5rem;
}

/* 论文标题 */
.archive__item-title a {
  font-size: 1.1rem !important;
  font-weight: 600 !important;
  line-height: 1.4 !important;
  color: #0056b3 !important;  /* 和主页链接颜色统一 */
}

/* Publications 页正文区域（如果有额外文字） */
.archive__item-body {
  font-size: 16px !important;
  line-height: 1.65 !important;
}

/* =========================================================
   强制覆盖 Minimal Mistakes 的 archive 页面（Publications）样式
   ========================================================= */

/* 正文及摘要的字体统一 */
.archive .archive__item-excerpt,
.archive .archive__item-excerpt p,
.archive .archive__item-body,
.archive .archive__item-body p {
  font-size: 16px !important;
  line-height: 1.65 !important;
  color: #222 !important;
}

/* Publications 中的列表统一 */
.archive .archive__item-excerpt ul li,
.archive .archive__item-excerpt ol li,
.archive .archive__item-body ul li,
.archive .archive__item-body ol li {
  font-size: 16px !important;
  line-height: 1.6 !important;
  margin-bottom: 0.5rem !important;
}

/* 论文标题大小统一 */
.archive .archive__item-title a {
  font-size: 1.1rem !important;
  font-weight: 600 !important;
  line-height: 1.4 !important;
  color: #0056b3 !important; /* 与 homepage 链接一致 */
}

/* 论文条目之间间距更优雅 */
.archive .archive__item {
  margin-bottom: 1.5rem !important;
}

/* Selective block 高亮 */
.pub-highlight {
  border-left: 4px solid #003366;
  background: #f5f7fb;
  padding: 16px 22px;
  border-radius: 10px;
  margin: 16px 0 28px;
}


/* ===============================
   Teaching Experience Layout — Spacing Upgrade
   =============================== */

/* 整个年份卡片 */
.teach-year-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 22px 26px;
  margin: 28px 0;
  border-top: 4px solid #0077c8;
  box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

/* 年份标题 */
.teach-year-header {
  font-weight: 700;
  font-size: 1.15rem;
  color: #0077c8;
  margin-bottom: 16px;    /* 加大空间 */
}

/* 每条 teaching entry */
.teach-entry {
  padding: 18px 0;         /* 条目之间更宽松 */
  border-top: 1px solid #e7e7e7;
}

/* 第一条不需要上边框 */
.teach-entry:first-of-type {
  border-top: none;
}

/* 课程名字 */
.teach-role {
  font-size: 1.02rem;
  font-weight: 600;
  margin-bottom: 6px;
}

/* Meta 信息（School 信息） */
.teach-meta {
  font-size: 0.95rem;
  color: #444;
  margin-bottom: 4px;
  line-height: 1.55;
  display: flex;
}

/* Note 信息（Semester + Level） */
.teach-note {
  font-size: 0.93rem;
  color: #555;
  line-height: 1.55;
  display: flex;
}

/* 图标间距 */
.teach-icon {
  margin-right: 8px;
  margin-top: 2px;
}

/* 让 Teaching 页面整体更舒适 */
.page__content > p:first-of-type {
  margin-bottom: 1.5rem;
}

/* =========================================================
   FORCE Publication page to use unified font size + line height
   ========================================================= */

/* 覆盖 publication 列表标题、作者、摘要等所有内容 */
.archive,
.archive .archive__item-title,
.archive .archive__item-title a,
.archive .archive__item-excerpt,
.archive .archive__item-body,
.archive p,
.archive li,
.archive span {
    font-size: 16px !important;
    line-height: 1.65 !important;
    color: #222 !important;
}

/* 论文标题比正文稍微大一点，但统一风格 */
.archive .archive__item-title a {
    font-size: 18px !important;
    font-weight: 600 !important;
}

/* 论文列表之间的间距 */
.archive .archive__item {
    margin-bottom: 1.2rem !important;
}

/* year / category header */
.archive__subtitle {
    font-size: 1.3rem !important;
    font-weight: 600 !important;
    margin-top: 2rem !important;
    color: #001b44 !important;
}

/* ===== Make venue lines (ICSE, TOSEM, TSE etc.) blue and unified ===== */

/* venue line: the 3rd <p> inside each publication item */
.archive .archive__item p:nth-of-type(3),
.archive .archive__item-excerpt p:nth-of-type(3) {
    color: #0056b3 !important;   /* 专业蓝 */
    font-weight: 500 !important;
}

/* ===== Unified Venue Color Styling for Publication Page ===== */

/* 自动匹配每篇论文的第 3 行（venue 行） */
.archive .archive__item p:nth-of-type(3),
.archive .archive__item-excerpt p:nth-of-type(3) {
    color: #0056b3 !important;     /* 专业蓝 */
    font-weight: 500 !important;
}

/* 如果 venue 行以图标开头，也仍然保持蓝色 */
.archive .archive__item p:nth-of-type(3) span,
.archive .archive__item-excerpt p:nth-of-type(3) span {
    color: #0056b3 !important;
}

/* ===== Make Teaching page font smaller and unified ===== */

/* Teaching 页面正文整体缩小 */
.page-teaching .page__content,
.page-teaching .page__content p,
.page-teaching .page__content li,
.page-teaching .page__content span {
    font-size: 16px !important;
    line-height: 1.6 !important;
    color: #222;
}

/* 卡片内部字体统一 */
.page-teaching .teach-year-card,
.page-teaching .teach-entry,
.page-teaching .teach-meta,
.page-teaching .teach-note {
    font-size: 16px !important;
}

/* 卡片标题（校名）稍微大一点但不夸张 */
.page-teaching .teach-year-header {
    font-size: 20px !important;
    font-weight: 600 !important;
}

/* ===== Publications: venue & Core 统一蓝色样式 ===== */

.page__content .pub-venue {
  color: #0056b3 !important;      /* 专业深蓝 */
  font-weight: 500;
}

/* 如果想把 Core A / Core A* 再强调一下 */
.page__content .pub-venue {
  white-space: normal;
}

.page__content .pub-venue:has(> .pub-core),
.page__content .pub-core {
  font-weight: 600;
}

/* 可选：让整行 venue 稍微小一点间距 */
.page__content .pub-venue {
  display: inline-block;
  margin-top: 2px;
}

/* ===== Force venue line to turn BLUE ===== */

.page__content span.pub-venue,
.page .archive__item span.pub-venue,
span.pub-venue {
    color: #0056b3 !important;
    font-weight: 600 !important;
}

/* venue line is sometimes inside <p> */
.page__content p span.pub-venue {
    color: #0056b3 !important;
}

/* make emojis inside venue also turn blue */
span.pub-venue * {
    color: #0056b3 !important;
}

/* specialty: if Core A/A* is inside the same span */
span.pub-venue strong,
span.pub-venue em {
    color: #0056b3 !important;
}

/* ===== Publications: venue 统一为蓝色 ===== */

.page__content .pub-venue {
  color: #0056b3 !important;    /* 深一点的蓝，更专业 */
  font-weight: 500;
}

/* venue 里的 emoji / 加粗 等也跟着变蓝 */
.page__content .pub-venue * {
  color: #0056b3 !important;
}

/* ===============================
   Publications — C 套装卡片风格
   =============================== */

/* 整个 publications 页面正文统一 */
.page__content .pub-card {
  background: #fafafa;
  border-radius: 10px;
  padding: 12px 16px;
  margin: 10px 0 14px;
  border: 1px solid #e4e4e4;
  box-shadow: 0 2px 6px rgba(0,0,0,0.03);
  transition: box-shadow 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

/* hover 轻微浮起 */
.page__content .pub-card:hover {
  box-shadow: 0 5px 14px rgba(0,0,0,0.08);
  transform: translateY(-1px);
  border-color: #d0d7ff;
}

/* 自动高亮最新一篇（第一张卡片） */
.page__content .pub-card:first-of-type {
  border-color: #ff9800;
  box-shadow: 0 6px 18px rgba(255,152,0,0.25);
  background: linear-gradient(180deg,#fffaf3,#fafafa);
}

/* 标题稍微大一点 */
.page__content .pub-card strong {
  font-size: 1rem;
}

/* 作者行 */
.page__content .pub-card br + span,
.page__content .pub-card br + text {
  line-height: 1.6;
}

/* venue 行统一蓝色 */
.page__content .pub-venue {
  display: inline-block;
  margin-top: 2px;
  color: #0056b3 !important;
  font-weight: 500;
}

/* venue 里的所有文字都跟随变蓝 */
.page__content .pub-venue * {
  color: #0056b3 !important;
}

/* Core A/A* 小 badge 风格 */
.page__content .pub-core {
  display: inline-block;
  padding: 1px 8px;
  margin-right: 4px;
  border-radius: 999px;
  background: #e8f0ff;
  color: #003366 !important;
  font-size: 0.75rem;
  font-weight: 600;
}

/* ===== Publications: Year card style ===== */

.page__content .pub-year-card {
  background: #fafafa;
  border-radius: 10px;
  padding: 14px 18px;
  margin: 14px 0 20px;
  border: 1px solid #e4e4e4;
  box-shadow: 0 2px 6px rgba(0,0,0,0.03);
  transition: box-shadow 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

/* hover 效果 */
.page__content .pub-year-card:hover {
  box-shadow: 0 5px 14px rgba(0,0,0,0.08);
  transform: translateY(-1px);
  border-color: #d0d7ff;
}

/* 最新年份（第一个 year card）自动高亮 */
.page__content .pub-year-card:first-of-type {
  border-color: #ff9800;
  box-shadow: 0 6px 18px rgba(255,152,0,0.25);
  background: linear-gradient(180deg,#fffaf3,#fafafa);
}

/* 年份标题样式 */
.pub-year-header {
  font-weight: 700;
  font-size: 1.05rem;
  color: #003366;
  margin-bottom: 8px;
}

.page__content {
  max-width: 1100px !important;   /* 原本 760 */
  font-size: 0.92rem;              /* 顺便让正文字体缩小一点 */
}

.page {
  padding-right: 20px; /* 防止太贴右侧 */
}

/* 正文整体字体比例缩小 */
html {
  font-size: 15px;   /* 默认 16px，我们缩到 15 或 14 */
}

/* 一级标题（如 Teaching、Publications）缩小一点 */
.page__title {
  font-size: 1.9rem !important;
}

/* 年份标题（如 2025） */
.pub-year-title {
  font-size: 1.25rem !important;
}

/* 每条论文的条目（原字体偏大） */
.pub-entry {
  font-size: 0.95rem !important;
}

/* ============ Project cards: 2-column grid + hover extra ============ */

/* 网格：大屏两列，小屏自动变一列 */
.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 18px;
  margin-top: 10px;
}

/* 每个项目卡片 */
.proj-card {
  background: #f9fafc;
  border-radius: 12px;
  border: 1px solid #dde3ee;
  padding: 14px 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: box-shadow 0.16s ease, transform 0.16s ease, border-color 0.16s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* hover 效果 */
.proj-card:hover {
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transform: translateY(-1px);
  border-color: #c5d0f5;
}

/* 卡片头：左标题 + 右标签 */
.proj-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 4px;
}

.proj-title {
  font-size: 1rem;
  font-weight: 600;
  color: #102a43;
  margin-bottom: 2px;
}

.proj-meta {
  font-size: 0.82rem;
  color: #6b778d;
}

/* 标签区域 */
.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: flex-end;
}

.proj-tag {
  font-size: 0.72rem;
  padding: 2px 7px;
  border-radius: 999px;
  background: #eef1ff;
  color: #344675;
  border: 1px solid #d7ddff;
}

.proj-tag-core {
  background: #ffe9c7;
  border-color: #f5c58a;
  color: #8a5200;
}

/* 概要描述：始终可见 */
.proj-desc {
  margin-top: 6px;
  margin-bottom: 2px;
  font-size: 0.9rem;
  line-height: 1.55;
}

/* 额外内容：默认折叠，hover 时展开 */
.proj-extra {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  margin-top: 0;
  transition: max-height 0.24s ease, opacity 0.24s ease, margin-top 0.24s ease;
  font-size: 0.86rem;
  color: #4f5d75;
}

.proj-card:hover .proj-extra {
  max-height: 600px;   /* 足够放下 bullet + 图片 */
  opacity: 1;
  margin-top: 8px;
}

/* 额外内容里的列表 */
.proj-extra ul {
  padding-left: 1.1rem;
  margin-bottom: 6px;
}

.proj-extra li {
  margin-bottom: 3px;
  line-height: 1.5;
}

/* 项目图片：小而精致（风格 A） */
.proj-img {
  display: block;
  max-width: 55%;
  margin: 10px auto 4px;
  border-radius: 6px;
}

/* 小屏上 header 垂直排列，更易读 */
@media (max-width: 768px) {
  .proj-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .proj-tags {
    justify-content: flex-start;
  }
}

/* ------------ Project Grid Layout ------------ */

.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 20px;
  margin-top: 12px;
}

/* ------------ Project Card ------------ */

.proj-card {
  background: #f9fafc;
  border-radius: 12px;
  border: 1px solid #dde3ee;
  padding: 16px 18px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  transition: 0.2s ease;
  display: flex;
  flex-direction: column;
}

/* hover 效果 */
.proj-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  border-color: #cad5f5;
}

/* ------------ Top area: Title + tags ------------ */

.proj-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.proj-title {
  font-size: 1rem;
  font-weight: 600;
  color: #102a43;
}

.proj-meta {
  font-size: 0.82rem;
  color: #6b778d;
}

/* tags */
.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.proj-tag {
  font-size: 0.7rem;
  border-radius: 999px;
  padding: 2px 7px;
  background: #eef1ff;
  border: 1px solid #d8defd;
  color: #344675;
}

.proj-tag-core {
  background: #ffe8c7;
  border-color: #f3c28a;
  color: #8a5200;
}

/* ------------ Body layout: text left + image right ------------ */

.proj-body {
  margin-top: 6px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

/* 左侧文字（summary + extra） */
.proj-text {
  flex: 1;
}

/* 右侧图片（自动小） */
.proj-img {
  width: 120px;         /* 控制图片大小（想更小可改成 90px 或 100px） */
  height: auto;
  border-radius: 6px;
  flex-shrink: 0;
  margin-top: 4px;
}

/* summary */
.proj-desc {
  font-size: 0.9rem;
  color: #2f3f53;
  line-height: 1.55;
}

/* extra (hover 展开) */
.proj-extra {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: 0.28s ease;
  font-size: 0.85rem;
  color: #4f5d75;
  margin-top: 0;
}

/* hover 展开 extra */
.proj-card:hover .proj-extra {
  max-height: 500px;
  opacity: 1;
  margin-top: 8px;
}

/* bullets */
.proj-extra ul {
  padding-left: 1.2rem;
  margin-bottom: 8px;
}

.proj-extra li {
  margin-bottom: 4px;
  line-height: 1.5;
}

/* 手机端：图片自动下移，保持可读性 */
@media (max-width: 600px) {
  .proj-body {
    flex-direction: column;
  }
  .proj-img {
    width: 65%;
    margin: 10px auto 0;
  }
}

/* ----------------- Project Grid Layout ----------------- */

.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 20px;
  margin-top: 12px;
}

/* ----------------- Project Card ----------------- */

.proj-card {
  background: #f9fafc;
  border-radius: 15px;   /* 更圆角 */
  border: 1px solid #dde3ee;
  padding: 18px 22px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06); /* 更明显阴影 */
  transition: 0.25s ease;
}

/* Hover 效果 */
.proj-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  border-color: #c8d3f2;
}

/* Project header */
.proj-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.proj-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #102a43;
}

.proj-meta {
  font-size: 0.82rem;
  color: #6b778d;
}

/* Tags */
.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.proj-tag {
  font-size: 0.72rem;
  padding: 2px 7px;
  border-radius: 999px;
  background: #eef1ff;
  border: 1px solid #d8defd;
  color: #344675;
}

.proj-tag-core {
  background: #ffe8c7;
  border-color: #f3c28a;
  color: #8a5200;
}

/* ----------------- Body: Text left + Image right ----------------- */

.proj-body {
  margin-top: 10px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.proj-text {
  flex: 1;
}

/* Small right-side image */
.proj-img {
  width: 110px;       /* 控制图片大小（新版更小） */
  border-radius: 8px;
  flex-shrink: 0;
  margin-top: 6px;
}

/* Summary */
.proj-desc {
  font-size: 0.9rem;
  line-height: 1.55;
  color: #2f3f53;
}

/* Hover extra */
.proj-extra {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: 0.3s ease;
}

.proj-card:hover .proj-extra {
  max-height: 600px;
  opacity: 1;
  margin-top: 6px;
}

/* List in extra */
.proj-extra ul {
  padding-left: 1.2rem;
}
.proj-extra li {
  margin-bottom: 4px;
  line-height: 1.5;
}

/* Mobile: image moves below */
@media (max-width: 600px) {
  .proj-body {
    flex-direction: column;
  }
  .proj-img {
    width: 60%;
    margin: 10px auto 0;
  }
}

/* -------- Grid layout -------- */

.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 20px;
  margin-top: 12px;
}

/* -------- Card -------- */

.proj-card {
  background: #f9fafc;
  border-radius: 16px;
  border: 1px solid #dde3ee;
  padding: 18px 22px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
  transition: 0.25s ease;
}

.proj-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  border-color: #c8d3f2;
}

/* -------- Header area -------- */

.proj-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.proj-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #102a43;
}

.proj-meta {
  font-size: 0.82rem;
  color: #6b778d;
}

/* -------- Tags -------- */

.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.proj-tag {
  font-size: 0.72rem;
  padding: 2px 7px;
  background: #eef1ff;
  border: 1px solid #d8defd;
  border-radius: 999px;
  color: #344675;
}

.proj-tag-core {
  background: #ffe8c7;
  border-color: #f3c28a;
  color: #8a5200;
}

/* -------- Description & Hover Extra -------- */

.proj-desc {
  margin-top: 8px;
  font-size: 0.92rem;
  line-height: 1.55;
  color: #2f3f53;
}

.proj-extra {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: 0.3s ease;
  margin-top: 0;
}

.proj-card:hover .proj-extra {
  max-height: 500px;
  opacity: 1;
  margin-top: 10px;
}

.proj-extra ul {
  padding-left: 1.2rem;
}

.proj-extra li {
  margin-bottom: 4px;
  line-height: 1.5;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 18px;
  margin-top: 10px;
}

.service-card {
  background: #f9fafc;
  border-radius: 14px;
  border: 1px solid #dde3ee;
  padding: 16px 18px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  transition: 0.22s ease;
}

.service-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 14px rgba(0,0,0,0.10);
  border-color: #c8d3f2;
}

.service-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 6px;
}

.service-title {
  font-size: 1rem;
  font-weight: 600;
  color: #102a43;
}

.service-meta {
  font-size: 0.82rem;
  color: #6b778d;
}

.service-tag {
  font-size: 0.7rem;
  padding: 2px 7px;
  border-radius: 999px;
  background: #eef1ff;
  border: 1px solid #d8defd;
  color: #344675;
}

.service-list {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.9rem;
  line-height: 1.55;
  color: #2f3f53;
}

.service-list li {
  margin-bottom: 4px;
}

/* ========== Typing tagline under About ========== */

.tagline-typing {
  margin-top: 0.8rem;
  margin-bottom: 1.5rem;
  font-size: 0.98rem;
  font-weight: 400;
  color: #233149;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.tagline-prefix {
  font-weight: 500;
  color: #555;
}

#tt-typewriter {
  font-weight: 500;
  color: #0056b3;  /* 和你链接蓝色呼应 */
}

/* 小闪烁光标 */
.tagline-cursor {
  display: inline-block;
  width: 8px;
  margin-left: 2px;
  animation: tt-blink 0.9s steps(1) infinite;
  color: #0056b3;
}

@keyframes tt-blink {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

/* ====== Elegant Auto-Scrolling News Ticker ====== */
.news-ticker {
  position: relative;
  overflow: hidden;
  height: 70px;               /* 可根据内容行数自动调整：2 行约 70px */
  border-left: 4px solid #003366;
  background: #f8f9fc;
  padding: 10px 15px;
  border-radius: 10px;
}

.news-ticker ul {
  list-style: none;
  padding: 0;
  margin: 0;
  animation: scrollNews 8s linear infinite;
}

.news-ticker li {
  font-size: 15px;
  line-height: 1.6;
  padding: 3px 0;
}

/* Hover 暂停滚动 */
.news-ticker:hover ul {
  animation-play-state: paused;
}

/* 关键帧：自然循环，不跳动，无空白 */
@keyframes scrollNews {
  0%   { transform: translateY(0); }
  25%  { transform: translateY(-25%); }
  50%  { transform: translateY(-50%); }
  75%  { transform: translateY(-75%); }
  100% { transform: translateY(-100%); }
}

/* --- Custom navbar background color --- */
.masthead {
  background-color: #f2f2f2 !important;   /* 你可以改成更深或更浅的灰 */
  border-bottom: 1px solid #e0e0e0;
}

.masthead__inner-wrap {
  background-color: transparent !important;
}

.masthead__menu-item a {
  color: #4a4a4a !important;      /* 导航文字灰色 */
}

.masthead__menu-item a:hover {
  color: #000 !important;         /* 鼠标悬停变黑 */
}

/* ===== Navigation Bar (方案 A：学术浅灰蓝版) ===== */

.masthead {
  background-color: #f5f7fa !important;   /* 更现代的浅灰蓝 */
  border-bottom: 1px solid #d8dde5 !important;  /* 更柔和的分割线 */
  box-shadow: 0 1px 3px rgba(0,0,0,0.04); /* 轻微阴影让顶栏更清晰 */
}

/* 顶部导航的 logo/title */
.masthead__title a {
  color: #2e3a44 !important;
  font-weight: 600 !important;
}

/* 菜单文字 */
.masthead__menu-item a {
  color: #333 !important;
  font-size: 0.96rem !important; /* 稍微小一点，减少视觉压力 */
  padding: 10px 14px !important;
}

/* hover 效果 */
.masthead__menu-item a:hover {
  color: #0056b3 !important;   /* 与你网站所有链接统一 */
  background: rgba(0, 86, 179, 0.08); /* 漂亮的浅蓝 hover 背景 */
  border-radius: 6px;
}

/* 当前页面高亮 */
.masthead__menu-item--active a {
  color: #0056b3 !important;
  font-weight: 600 !important;
  border-bottom: 2px solid #0056b3;
}

/* Remove left border + indent from blockquotes inside the gray box */
.highlight-box blockquote {
  border-left: none !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
}


