/* ===== 字体引入 ===== */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@500;700;900&family=Noto+Sans+SC:wght@400;500;700&family=Space+Grotesk:wght@500;700&display=swap');

/* ===== 设计令牌 ===== */
:root {
  --c-primary: #004098;
  --c-primary-dark: #002855;
  --c-primary-light: #3A6DB5;
  --c-accent: #A63A2A;
  --c-accent-soft: #C25A45;
  --c-bg: #F5F1E8;
  --c-bg-alt: #EDE6D3;
  --c-bg-deep: #E4DCC4;
  --c-ink: #1A1A1A;
  --c-ink-soft: #4A4A4A;
  --c-ink-mute: #7A7468;
  --c-line: #C8BFA8;
  --c-line-soft: #DDD5BE;
  --c-paper: #FBF8F0;
  --radius: 4px;
  --radius-sm: 2px;
  --maxw: 1180px;
  --header-h: 64px;
  --serif: 'Noto Serif SC', 'Songti SC', serif;
  --sans: 'Noto Sans SC', sans-serif;
  --mono: 'Space Grotesk', monospace;
  --shadow-line: 0 1px 0 var(--c-line);
}

/* ===== 重置 ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  color: var(--c-ink);
  background: var(--c-bg);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  /* 噪点纹理 + 方格底纹叠加 */
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(var(--c-line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--c-line-soft) 1px, transparent 1px);
  background-size: 160px 160px, 22px 22px, 22px 22px;
  background-position: 0 0, -1px -1px, -1px -1px;
}
img { max-width: 100%; display: block; }
a { color: var(--c-primary); text-decoration: none; transition: color .2s; }
a:hover { color: var(--c-accent); }
ul, ol { list-style: none; }

/* ===== 通用容器 ===== */
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

/* ===== 顶部导航 ===== */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--header-h);
  background: var(--c-primary-dark);
  box-shadow: 0 2px 0 var(--c-accent);
  transition: box-shadow .35s ease;
}
.site-header.scrolled {
  box-shadow: 0 4px 12px rgba(0,0,0,.18);
}
.header-inner {
  width: 100%; max-width: 100%; margin: 0 auto; padding: 0 24px;
  height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand {
  display: flex; align-items: baseline; gap: 8px; color: #FBF8F0;
  font-family: var(--serif); font-weight: 700; font-size: 18px; letter-spacing: 1px; white-space: nowrap; flex-shrink: 0;
}
.brand .brand-en { font-family: var(--mono); font-size: 10px; opacity: .65; letter-spacing: 2px; text-transform: uppercase; }
.nav-list {
  display: flex; align-items: center; gap: 0; flex-wrap: nowrap; flex: 1; justify-content: flex-end; min-width: 0;
}
.nav-list a {
  color: rgba(251,248,240,.78); font-size: 13px; padding: 6px 8px; white-space: nowrap;
  border-bottom: 2px solid transparent; transition: all .2s;
}
.nav-list a:hover { color: #FBF8F0; }
.nav-list a.active { color: #FBF8F0; border-bottom-color: var(--c-accent-soft); }

/* 汉堡按钮 */
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; width: 38px; height: 38px; position: relative; }
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ''; position: absolute; left: 8px; right: 8px; height: 2px; background: #FBF8F0; transition: transform .3s, opacity .2s;
}
.nav-toggle span { top: 18px; }
.nav-toggle span::before { top: -7px; }
.nav-toggle span::after { top: 7px; }
.nav-toggle.open span { background: transparent; }
.nav-toggle.open span::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span::after { transform: translateY(-7px) rotate(-45deg); }

/* ===== 主体偏移（避开固定头） ===== */
main { padding-top: var(--header-h); }

/* ===== 板块通用 ===== */
.section { padding: 72px 0; position: relative; }
.section.alt { background: var(--c-bg-alt); }
.section-head { margin-bottom: 44px; position: relative; }
.section-num {
  font-family: var(--mono); font-weight: 700; font-size: 13px; color: var(--c-accent);
  letter-spacing: 3px; display: block; margin-bottom: 8px;
}
.section-title {
  font-family: var(--serif); font-weight: 900; font-size: clamp(1.7rem, 3.5vw, 2.6rem);
  color: var(--c-primary-dark); line-height: 1.25; letter-spacing: 1px;
}
.section-title::after {
  content: ''; display: block; width: 56px; height: 3px; background: var(--c-accent); margin-top: 16px;
}
.section-lead { color: var(--c-ink-soft); margin-top: 14px; max-width: 640px; font-size: 15px; }

/* 子板块 */
.block { margin-bottom: 48px; }
.block:last-child { margin-bottom: 0; }
.block-title {
  font-family: var(--serif); font-weight: 700; font-size: 1.3rem; color: var(--c-primary-dark);
  margin-bottom: 18px; padding-left: 14px; border-left: 4px solid var(--c-accent); line-height: 1.3;
}
.block p { margin-bottom: 12px; color: var(--c-ink-soft); }
.block ul.checklist { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px 24px; }
.block ul.checklist li {
  position: relative; padding-left: 24px; color: var(--c-ink-soft); font-size: 15px;
}
.block ul.checklist li::before {
  content: ''; position: absolute; left: 0; top: 10px; width: 8px; height: 8px;
  background: var(--c-primary); border-radius: 1px;
}
.block ul.checklist li.warn::before { background: var(--c-accent); }

/* 不对称两栏（主+辅） */
.split { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; align-items: start; }
.split-even { grid-template-columns: 1fr 1fr; }
.sub-title { font-family: var(--serif); font-weight: 700; font-size: 1.05rem; color: var(--c-primary); margin-bottom: 8px; }

/* 信息表 */
.info-table { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--c-paper); border: 1px solid var(--c-line); }
.info-table th, .info-table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--c-line-soft); }
.info-table th { background: var(--c-primary-dark); color: #FBF8F0; font-weight: 500; font-family: var(--sans); letter-spacing: 1px; }
.info-table tr:last-child td { border-bottom: 0; }
.info-table td:first-child { font-weight: 700; color: var(--c-primary-dark); width: 28%; }
.info-table tr:hover td { background: var(--c-bg-deep); }

/* 标签 */
.tag {
  display: inline-block; font-size: 12px; padding: 2px 9px; border: 1px solid var(--c-line);
  background: var(--c-paper); color: var(--c-ink-soft); border-radius: var(--radius-sm); margin-right: 6px;
  font-family: var(--mono);
}
.tag.accent { border-color: var(--c-accent); color: var(--c-accent); }
.tag.primary { border-color: var(--c-primary); color: var(--c-primary); }

/* 待补充/待核实标注 */
.tbd {
  color: var(--c-accent); font-weight: 600; font-size: 13px;
  border-bottom: 1px dashed var(--c-accent); padding-bottom: 1px;
}

/* 提示框 */
.callout {
  border-left: 3px solid var(--c-accent); background: var(--c-paper);
  padding: 16px 20px; margin: 20px 0; border-radius: 0 var(--radius) var(--radius) 0;
}
.callout.warn { border-left-color: var(--c-accent); background: #F7E9E5; }
.callout.tip { border-left-color: var(--c-primary); background: #E8EEF8; }
.callout strong { color: var(--c-accent); font-family: var(--serif); }
.callout.tip strong { color: var(--c-primary); }

/* 链接卡（官网链接页用） */
.link-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px; background: var(--c-paper); border: 1px solid var(--c-line);
  border-radius: var(--radius); margin-bottom: 12px; transition: border-color .2s, transform .2s;
}
.link-row:hover { border-color: var(--c-accent); }
.link-row .link-info h4 { font-family: var(--serif); color: var(--c-primary-dark); font-size: 1.05rem; margin-bottom: 2px; }
.link-row .link-info span { color: var(--c-ink-mute); font-size: 13px; font-family: var(--mono); }
.link-row .link-go { color: var(--c-accent); font-family: var(--mono); font-weight: 700; font-size: 14px; letter-spacing: 1px; }

/* 翻页 */
.pager { display: flex; justify-content: space-between; gap: 16px; margin-top: 64px; padding-top: 32px; border-top: 2px solid var(--c-line); }
.pager a {
  flex: 1; max-width: 48%; padding: 16px 20px; background: var(--c-paper);
  border: 1px solid var(--c-line); border-radius: var(--radius); transition: border-color .2s;
}
.pager a:hover { border-color: var(--c-accent); }
.pager a .pl { font-family: var(--mono); font-size: 12px; color: var(--c-ink-mute); letter-spacing: 2px; }
.pager a .pt { font-family: var(--serif); font-weight: 700; color: var(--c-primary-dark); font-size: 1.05rem; margin-top: 4px; }
.pager a.next { text-align: right; }

/* ===== 首页专用 ===== */
.hero { position: relative; height: calc(100vh - var(--header-h)); min-height: 560px; overflow: hidden; }
.carousel { position: absolute; inset: 0; }
.carousel-track { position: absolute; inset: 0; }
.carousel-slide {
  position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease;
  background-size: cover; background-position: center;
}
.carousel-slide.active { opacity: 1; }
.carousel-slide::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,40,85,.35) 0%, rgba(0,40,85,.75) 100%);
}
.hero-content {
  position: relative; z-index: 3; height: 100%; display: flex; flex-direction: column;
  justify-content: flex-end; padding: 0 28px 80px; max-width: var(--maxw); margin: 0 auto; color: #FBF8F0;
}
.hero-eyebrow { font-family: var(--mono); font-size: 13px; letter-spacing: 4px; opacity: .8; margin-bottom: 16px; }
.hero-title {
  font-family: var(--serif); font-weight: 900; font-size: clamp(2.2rem, 6vw, 4.2rem);
  line-height: 1.1; letter-spacing: 2px; max-width: 720px;
}
.hero-title .hl { color: var(--c-accent-soft); }
.hero-sub { font-size: 17px; opacity: .88; margin-top: 20px; max-width: 520px; line-height: 1.7; }
/* 轮播控制：箭头叠加在图片左右两侧居中，指示点留在左下角 */
.hero .hero-prev, .hero .hero-next {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 4;
  width: 44px; height: 44px; border: 1px solid rgba(251,248,240,.4); background: rgba(0,40,85,.35);
  color: #FBF8F0; cursor: pointer; border-radius: 50%; font-size: 22px; line-height: 1;
  display: flex; align-items: center; justify-content: center; transition: background .2s;
}
.hero .hero-prev { left: 24px; }
.hero .hero-next { right: 24px; }
.hero .hero-prev:hover, .hero .hero-next:hover { background: var(--c-accent); }
.hero-dots { position: absolute; bottom: 26px; left: 28px; z-index: 4; display: flex; align-items: center; gap: 14px; }
.hero-dots .dot { width: 28px; height: 3px; border: 0; background: rgba(251,248,240,.35); cursor: pointer; transition: background .2s; }
.hero-dots .dot.active { background: var(--c-accent-soft); }

/* 公告条 */
.ticker {
  background: var(--c-accent); color: #FBF8F0; overflow: hidden; white-space: nowrap;
  font-size: 14px; letter-spacing: 1px;
}
.ticker-track { display: inline-block; padding: 11px 0; animation: ticker 30s linear infinite; }
.ticker-track span { margin: 0 60px; }
.ticker-track span::before { content: '◆'; margin-right: 12px; opacity: .6; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* 索引导航（首页核心功能） */
.index-list { display: flex; flex-direction: column; }
.index-item {
  display: grid; grid-template-columns: 70px 1fr auto; gap: 24px; align-items: center;
  padding: 22px 0; border-bottom: 1px solid var(--c-line); transition: padding-left .25s;
}
.index-item:hover { padding-left: 14px; }
.index-item:hover .index-go { color: var(--c-accent); }
.index-num { font-family: var(--mono); font-weight: 700; font-size: 1.6rem; color: var(--c-accent); }
.index-text h3 { font-family: var(--serif); font-weight: 700; font-size: 1.25rem; color: var(--c-primary-dark); }
.index-text p { color: var(--c-ink-soft); font-size: 14px; margin-top: 2px; }
.index-go { font-family: var(--mono); font-size: 13px; color: var(--c-ink-mute); letter-spacing: 2px; }

/* 欢迎语不对称布局 */
.welcome { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center; }
.welcome-text h2 { font-family: var(--serif); font-weight: 900; font-size: clamp(1.8rem, 4vw, 2.8rem); color: var(--c-primary-dark); line-height: 1.25; }
.welcome-text h2 em { font-style: normal; color: var(--c-accent); }
.welcome-text p { color: var(--c-ink-soft); margin-top: 18px; font-size: 16px; }
.welcome-img { position: relative; }
.welcome-img img { width: 100%; height: 360px; object-fit: cover; border-radius: var(--radius); }
.welcome-img::before {
  content: ''; position: absolute; top: -14px; left: -14px; right: 24px; bottom: 24px;
  border: 2px solid var(--c-accent); border-radius: var(--radius); z-index: -1;
}

/* 校训带 */
.motto-band {
  background: var(--c-primary-dark); color: #FBF8F0; text-align: center; padding: 56px 28px;
}
.motto-band .motto {
  font-family: var(--serif); font-weight: 900; font-size: clamp(1.8rem, 4vw, 3rem);
  letter-spacing: 12px; line-height: 1.4;
}
.motto-band .motto-en { font-family: var(--mono); font-size: 13px; letter-spacing: 3px; opacity: .6; margin-top: 14px; }

/* ===== 返回顶部 ===== */
.back-top {
  position: fixed; right: 28px; bottom: 28px; z-index: 90;
  width: 46px; height: 46px; background: var(--c-primary-dark); color: #FBF8F0;
  border: 0; border-radius: var(--radius); cursor: pointer; font-size: 20px;
  opacity: 0; pointer-events: none; transition: opacity .3s, background .2s;
}
.back-top.show { opacity: 1; pointer-events: auto; }
.back-top:hover { background: var(--c-accent); }

/* ===== 页脚 ===== */
.site-footer { background: var(--c-primary-dark); color: rgba(251,248,240,.7); padding: 48px 0 28px; }
.footer-inner { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.footer-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; padding-bottom: 28px; border-bottom: 1px solid rgba(251,248,240,.15); }
.footer-brand { font-family: var(--serif); font-weight: 700; font-size: 1.2rem; color: #FBF8F0; }
.footer-brand span { display: block; font-family: var(--mono); font-size: 11px; opacity: .6; letter-spacing: 2px; margin-top: 4px; }
.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer-links a { color: rgba(251,248,240,.7); font-size: 14px; }
.footer-links a:hover { color: #FBF8F0; }
.footer-bottom { text-align: center; font-size: 12px; opacity: .5; padding-top: 20px; font-family: var(--mono); letter-spacing: 1px; }
.footer-thanks { text-align: center; font-size: 12px; opacity: .6; padding-top: 8px; }
.footer-motto { text-align: center; font-family: var(--serif); font-size: 15px; letter-spacing: 6px; opacity: .85; padding-top: 18px; }
.footer-site { text-align: center; font-size: 13px; opacity: .75; padding-top: 8px; }

/* ===== 页面底部免责声明 ===== */
.page-disclaimer {
  margin-top: 48px; padding: 16px 20px; text-align: center;
  border-top: 1px solid var(--c-line); border-bottom: 1px solid var(--c-line);
  font-size: 13px; color: var(--c-ink-soft); line-height: 1.8;
}

/* ===== 滚动进入动效 ===== */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ===== 移动端菜单遮罩 ===== */
.menu-mask {
  position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 95; opacity: 0; pointer-events: none; transition: opacity .3s;
}
.menu-mask.show { opacity: 1; pointer-events: auto; }

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
  .welcome, .split { grid-template-columns: 1fr; }
  .welcome-img::before { display: none; }
}
@media (max-width: 768px) {
  /* 手机端表格横向滚动，防止溢出错位 */
  .info-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .info-table td:first-child { width: auto; min-width: 88px; }
  .info-table th, .info-table td { padding: 10px 12px; font-size: 14px; }
  /* 手机端页脚：隐藏桌面专属链接，4 项单行均分，禁止句中换行 */
  .footer-links a.hide-mobile { display: none; }
  .footer-top { flex-direction: column; gap: 16px; }
  .footer-links { width: 100%; display: flex; justify-content: space-between; gap: 8px; flex-wrap: nowrap; }
  .footer-links a { white-space: nowrap; font-size: 14px; }
}
@media (max-width: 768px) {
  .container, .header-inner, .footer-inner { padding: 0 20px; }
  .section { padding: 52px 0; }
  .nav-toggle { display: block; }
  .nav-list {
    position: fixed; top: var(--header-h); right: -100%; width: 78%; max-width: 320px; height: calc(100vh - var(--header-h));
    background: var(--c-primary-dark); flex-direction: column; align-items: stretch; gap: 0; padding: 16px 0;
    transition: right .3s ease; overflow-y: auto;
  }
  .nav-list.open { right: 0; }
  .nav-list a { padding: 14px 24px; font-size: 15px; border-bottom: 1px solid rgba(251,248,240,.1); }
  .nav-list a.active { border-bottom-color: var(--c-accent); background: rgba(255,255,255,.04); }
  .block ul.checklist { grid-template-columns: 1fr; }
  .hero-dots { left: 20px; bottom: 20px; gap: 10px; }
  .hero .hero-prev, .hero .hero-next { width: 34px; height: 34px; font-size: 18px; }
  .hero .hero-prev { left: 12px; }
  .hero .hero-next { right: 12px; }
  .hero-content { padding: 0 20px 70px; }
  .pager { flex-direction: column; }
  .pager a.next { text-align: left; }
  .ticker-track span { margin: 0 30px; }
}

/* 学院卡片 hover */
.college-card:hover {
  border-color: var(--c-accent) !important;
  background: #E8DFC8 !important;
}
@media (max-width: 768px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr) !important; }
  .college-grid { grid-template-columns: 1fr !important; }
}
@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr 1fr !important; gap: 10px !important; }
}

/* ===== 联系弹窗 ===== */
.modal-mask {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0, 28, 60, 0.55);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  opacity: 0; pointer-events: none; transition: opacity .3s ease;
}
.modal-mask.show { opacity: 1; pointer-events: auto; }
.modal-card {
  width: 100%; max-width: 420px; background: #FBF8F0;
  border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--c-line);
  transform: translateY(16px); transition: transform .3s ease;
  box-shadow: 0 12px 40px rgba(0,28,60,.25);
}
.modal-mask.show .modal-card { transform: translateY(0); }
.modal-head {
  position: relative; background: var(--c-primary-dark); color: #FBF8F0;
  padding: 20px 24px; border-bottom: 2px solid var(--c-accent);
}
.modal-head h3 {
  font-family: var(--serif); font-weight: 700; font-size: 1.05rem;
  letter-spacing: 1px; line-height: 1.5;
}
.modal-body { padding: 22px 24px; }
.modal-label {
  font-size: 12px; color: var(--c-ink-mute); letter-spacing: 1px;
  font-family: var(--mono); margin-bottom: 6px; display: block;
}
.modal-input {
  width: 100%; background: var(--c-bg-alt); border: 1px solid var(--c-line);
  border-radius: var(--radius); padding: 12px 14px;
  font-family: var(--mono); font-size: 15px; color: var(--c-ink);
  letter-spacing: 1px; outline: none; user-select: all;
}
.modal-desc {
  font-size: 13px; color: var(--c-ink-soft); line-height: 1.7;
  margin-top: 14px;
}
.modal-hint {
  font-size: 12px; color: var(--c-ink-mute); margin-top: 10px;
  padding-top: 10px; border-top: 1px dashed var(--c-line);
}
.modal-btns { display: flex; gap: 10px; padding: 0 24px 22px; }
.modal-btn {
  flex: 1; padding: 11px 0; border-radius: var(--radius);
  font-family: var(--sans); font-size: 14px; font-weight: 500;
  cursor: pointer; transition: background .2s, border-color .2s; border: 1px solid transparent;
}
.modal-btn.secondary {
  background: transparent; color: var(--c-ink-soft); border-color: var(--c-line);
}
.modal-btn.secondary:hover { background: var(--c-bg-alt); }
.modal-btn.primary {
  background: var(--c-primary-dark); color: #FBF8F0;
}
.modal-btn.primary:hover { background: var(--c-primary); }
.modal-btn.primary.copied { background: var(--c-accent); }
.modal-close {
  position: absolute; top: 12px; right: 14px; background: none; border: 0;
  color: rgba(251,248,240,.7); font-size: 22px; cursor: pointer; line-height: 1;
}
.modal-close:hover { color: #FBF8F0; }
@media (max-width: 480px) {
  .modal-card { max-width: 100%; }
  .modal-body, .modal-btns { padding-left: 18px; padding-right: 18px; }
  .modal-btns { padding-bottom: 18px; }
}

/* 浮动咨询入口（页面右下角） */
.contact-fab {
  position: fixed; right: 28px; bottom: 84px; z-index: 90;
  background: var(--c-accent); color: #FBF8F0; border: 0; cursor: pointer;
  padding: 10px 16px; border-radius: var(--radius);
  font-family: var(--sans); font-size: 13px; font-weight: 500;
  box-shadow: 0 4px 12px rgba(166,58,42,.3);
  transition: background .2s, transform .2s;
  display: none;
}
.contact-fab.show { display: inline-block; }
.contact-fab:hover { background: var(--c-accent-soft); transform: translateY(-2px); }
@media (max-width: 768px) {
  .contact-fab { right: 20px; bottom: 80px; }
}
