@font-face {
  font-family: "Academy Song";
  src: url("fonts/academy-zh.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: Cinzel;
  src: url("fonts/cinzel.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --night: #0c1418;
  --panel: #101d21;
  --rule: #304044;
  --ink: #ecede5;
  --soft: #b5c1c1;
  --gold: #ddc38c;
  --teal: #98c9c5;
  --serif: "Academy Song", "Songti SC", "Noto Serif CJK SC", SimSun, serif;
  --latin: Cinzel, Georgia, serif;
  --mono: "IBM Plex Mono", Consolas, monospace;
  --page: min(1280px, calc(100% - 2 * clamp(22px, 6.3vw, 100px)));
  --nav-height: 80px;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--night); color: var(--ink); }
body:has(dialog[open]) { overflow: hidden; }
button, input { font: inherit; }
button { color: inherit; cursor: pointer; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--teal); outline-offset: 4px; }
h1, h2, p, figure, dl, dd { margin: 0; }
h1, h2, .brand b, .faculty-info strong { font-family: var(--serif); font-weight: 600; }
h2 { font-size: clamp(30px, 3.1vw, 48px); line-height: 1.3; letter-spacing: .07em; }
.container, .nav-wrap { width: var(--page); margin-inline: auto; }
section[id] { scroll-margin-top: calc(var(--nav-height) + 12px); }
.icon { width: 18px; height: 18px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linejoin: round; stroke-linecap: round; }
.icon-bank { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip { position: fixed; z-index: 10; top: 0; left: 1rem; padding: .8rem 1rem; background: var(--gold); color: var(--night); transform: translateY(-130%); }
.skip:focus { transform: translateY(0); }
.topbar {
  position: sticky; z-index: 5; top: 0;
  border-bottom: 1px solid #334246;
  background: #0b1418f7;
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--nav-height); }
.brand { display: inline-flex; align-items: center; gap: 11px; flex: 0 0 auto; }
.brand img { display: block; object-fit: contain; }
.brand span { display: grid; gap: 2px; }
.brand b { font-size: 21px; letter-spacing: .12em; line-height: 1.4; }
.brand small { font: 500 10px/1.4 var(--latin); letter-spacing: .19em; color: var(--gold); }
.primary-nav { display: flex; align-self: stretch; gap: clamp(18px, 2.6vw, 42px); }
.primary-nav a { position: relative; display: grid; align-items: center; color: #b5c2c3; font-size: 14px; letter-spacing: .04em; white-space: nowrap; }
.primary-nav a.current, .primary-nav a:hover { color: var(--gold); }
.primary-nav a.current::after { content: ""; position: absolute; height: 2px; bottom: 0; left: 0; right: 0; background: var(--gold); }
.nav-tools, .search-button, .menu-button { display: flex; align-items: center; justify-content: center; }
.nav-tools { gap: 7px; }
.search-button, .menu-button { background: transparent; border: 1px solid #3a494d; height: 38px; padding: 0 12px; gap: 9px; color: #d7dcd8; }
.search-button { font-size: 13px; }
.search-button .icon { width: 16px; height: 16px; }
.search-button kbd { font: 13px var(--mono); color: #a4b1b0; border: 1px solid #465254; border-radius: 2px; width: 15px; }
.menu-button { display: none; }
.search-button:hover, .menu-button:hover { color: var(--gold); border-color: var(--gold); }
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  background: radial-gradient(ellipse at 73% 52%, #1a393a 0, #11252a 32%, #0a1419 74%);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: linear-gradient(#5875771a 1px, transparent 1px), linear-gradient(90deg, #5875771a 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(90deg, transparent 8%, #000 66%, #0008);
}
.hero-inner { min-height: clamp(460px, 40vw, 590px); display: grid; grid-template-columns: 1.15fr 1fr; align-items: center; gap: clamp(20px, 4vw, 80px); padding-block: 50px; }
.hero-copy { position: relative; z-index: 1; }
.hero-emblem {
  position: relative; isolation: isolate; display: grid; place-items: center; aspect-ratio: 1;
  width: min(100%, 435px); justify-self: center; border-radius: 50%; border: 1px solid #8bb9b34d;
  background: radial-gradient(circle, #6f927628, transparent 72%);
}
.hero-emblem::before, .hero-emblem::after { content: ""; position: absolute; border-radius: 50%; }
.hero-emblem::before { inset: 8%; border: 1px dashed #96b4a25e; }
.hero-emblem::after { inset: -5%; border: 1px solid #7da39f28; }
.hero-emblem img { width: 76%; height: auto; filter: drop-shadow(0 0 26px #cea97042); }
.hero-kicker { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; color: #f1d69b; }
.hero-kicker span { width: 42px; height: 1px; background: currentColor; }
.hero-kicker b { font: 500 clamp(13px, 1.1vw, 17px)/1.5 var(--latin); letter-spacing: .27em; }
.hero h1 { font-size: clamp(64px, 6.7vw, 104px); line-height: 1.22; letter-spacing: .075em; color: #fff6e6; text-shadow: 0 4px 22px #050b1470; }
.hero-subtitle { margin-top: 17px; font: 600 clamp(18px, 1.5vw, 23px)/1.6 var(--serif); letter-spacing: .08em; color: #c8d9d4; text-shadow: 0 2px 7px #061419; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 15px; margin-top: clamp(28px, 3vw, 42px); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; gap: 15px; padding: 0 24px; border: 1px solid transparent; letter-spacing: .06em; font-size: 15px; font-weight: 600; }
.btn.gold { color: #202522; background: #ddc490; border-color: #e7cea0; }
.btn.gold:hover { background: #f2dcb0; }
.btn.ghost { border-color: #9eaaa689; background: #0c1b2196; color: #ecede4; }
.btn.ghost:hover { background: #243338; border-color: #d9cfb8; }
.hero-scale { position: absolute; bottom: 0; width: 100%; height: 5px; border-bottom: 1px solid #afa48685; background: repeating-linear-gradient(90deg, #bdc2b36b 0 1px, transparent 1px 19px); }
.block { padding-block: clamp(47px, 5vw, 79px); border-bottom: 1px solid var(--rule); }
.section-en { display: flex; gap: 10px; align-items: center; font: 500 11px/1.5 var(--mono); color: var(--gold); letter-spacing: .18em; margin-bottom: 9px; }
.section-en::before { content: ""; width: 22px; height: 1px; background: #b59c65; }
.about { display: grid; align-items: center; grid-template-columns: 1.3fr .8fr; gap: clamp(40px, 8vw, 135px); }
.intro-text { font-size: 16px; line-height: 1.95; color: var(--soft); max-width: 620px; margin-top: 20px; }
.source-note { margin-top: 16px; color: var(--teal); font-size: 13px; line-height: 1.7; }
.seal-panel { position: relative; display: grid; place-items: center; align-content: center; gap: 12px; min-height: 245px; margin: 0; border: 1px solid #394a49; background: radial-gradient(ellipse at center, #1b3031, #101c21 75%); isolation: isolate; overflow: hidden; }
.seal-grid { z-index: -1; position: absolute; inset: 0; opacity: .44; background-image: linear-gradient(#34474680 1px, transparent 1px), linear-gradient(90deg,#34474680 1px,transparent 1px); background-size: 24px 24px; }
.seal-panel img { height: 105px; width: auto; }
.seal-panel figcaption { display: grid; gap: 4px; text-align: center; position: relative; }
.seal-panel figcaption span { font: 600 18px var(--serif); letter-spacing: .14em; color: #e2c68f; }
.seal-panel small { font: 10px var(--mono); letter-spacing: .14em; color: #b6b6a4; }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 18px; margin-bottom: 26px; }
.section-note { color: var(--soft); font-size: 14px; }
.faculty-grid, .facility-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 2vw, 28px); }
.faculty-card { display: block; text-align: left; padding: 0; border: 1px solid var(--rule); background: #112025; position: relative; overflow: hidden; }
.facility-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.faculty-card { min-height: 115px; background: linear-gradient(130deg, #1b2f32, #112025 65%); }
.faculty-card::before { content: ""; position: absolute; left: 0; top: 0; width: 32px; border-top: 1px solid #91b5aa; }
.faculty-info { display: flex; flex-direction: column; padding: 22px 23px 24px; }
.faculty-info strong { font-size: clamp(20px, 1.65vw, 26px); font-weight: 600; margin-block: 6px 10px; }
.faculty-info > span { font-size: 14px; line-height: 1.75; color: var(--soft); }
.faculty-card > .icon { position: absolute; top: 12px; right: 12px; width: 15px; color: var(--gold); transform: rotate(-45deg); }
.faculty-card:hover { border-color: #ac956c; background: #172a2e; }
.news-list { border-top: 1px solid var(--rule); }
.news-list button { width: 100%; display: flex; align-items: center; gap: clamp(16px, 3vw, 47px); padding: 20px 4px; background: transparent; border: 0; border-bottom: 1px solid var(--rule); text-align: left; }
.news-list .category { color: var(--teal); font-size: 13px; margin-left: auto; }
.news-list strong { font-weight: 500; font-size: 16px; }
.news-list .icon { color: var(--gold); width: 16px; }
.news-list button:hover strong { color: var(--gold); }
.news { border: 0; }
footer { background: #091115; border-top: 1px solid var(--rule); }
.footer-inner { padding-block: 30px; display: flex; align-items: center; gap: 26px; }
.footer-inner .brand b { font-size: 17px; }
.footer-inner .brand small { font-size: 9px; }
footer p { font-size: 12px; line-height: 1.6; color: #93a3a5; margin-left: auto; }
.backtop, .dialog-close { display: grid; place-items: center; width: 38px; height: 38px; padding: 0; border: 1px solid #3a4e50; background: transparent; color: var(--gold); }
dialog { padding: 0; border: 1px solid #536668; color: var(--ink); background: #111f23; max-width: min(590px, calc(100vw - 32px)); width: 100%; max-height: min(78svh, 730px); box-shadow: 0 18px 100px #03090ccc; }
dialog::backdrop { background: #02090dda; }
.dialog-body { padding: clamp(23px, 4vw, 42px); position: relative; }
.dialog-close { position: absolute; top: 12px; right: 12px; width: 31px; height: 31px; }
.dialog-close .icon { width: 16px; }
dialog h2 { font-size: clamp(24px, 3vw, 35px); padding-right: 22px; }
.record-meta, .result-count { color: var(--teal); font-size: 13px; line-height: 1.7; margin-block: 12px 18px; }
#record-text { border-top: 1px solid var(--rule); padding-top: 18px; }
#record-text p { color: #c8d3ce; line-height: 1.95; margin-bottom: 12px; }
#record-text p:last-child { margin: 0; }
.search-field { margin-top: 20px; display: flex; align-items: center; gap: 10px; background: #0d181c; border: 1px solid #586a68; color: var(--teal); padding: 0 13px; }
.search-field input { border: 0; outline: 0; background: transparent; color: var(--ink); min-width: 0; width: 100%; padding: 13px 0; }
.search-field:focus-within { border-color: var(--teal); }
.search-field input:focus-visible { outline: none; }
.search-result { display: flex; gap: 14px; align-items: center; text-align: left; width: 100%; padding: 13px 1px; border: 0; border-top: 1px solid var(--rule); background: transparent; }
.search-result small { color: #9dbcb2; font-size: 12px; flex: 0 0 auto; }
.search-result strong { font-size: 15px; font-weight: 500; }
.search-result:hover { color: var(--gold); }
@media (max-width: 1050px) {
  .nav-wrap { gap: 15px; }
  .search-button span, .search-button kbd { display: none; }
  .search-button { width: 38px; padding: 0; }
}
@media (max-width: 900px) {
  :root { --nav-height: 65px; }
  .menu-button { display: flex; width: 38px; padding: 0; }
  .primary-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #101b20; border-bottom: 1px solid #52605b; padding: 8px max(22px, 6.3vw) 16px; }
  .primary-nav.open { display: grid; gap: 0; }
  .primary-nav a { min-height: 44px; border-top: 1px solid var(--rule); }
  .primary-nav a.current::after { content: none; }
  .hero-inner { min-height: 405px; }
  .faculty-info { padding: 16px 14px; }
  .facility-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about { grid-template-columns: 1.2fr .8fr; gap: 26px; }
}
@media (max-width: 650px) {
  :root { --page: calc(100% - 40px); --nav-height: 62px; }
  .brand img { width: 31px; height: 39px; }
  .brand b { font-size: 17px; }
  .brand small { font-size: 8px; }
  .brand { gap: 8px; }
  .primary-nav { padding-inline: 20px; }
  .hero-inner { min-height: 0; grid-template-columns: 1fr; justify-items: start; row-gap: 31px; padding-block: 46px 42px; }
  .hero-emblem { grid-row: 1; width: min(60%, 235px); }
  .hero-kicker { gap: 11px; margin-bottom: 12px; }
  .hero-kicker span { width: 26px; }
  .hero-kicker b { font-size: 12px; letter-spacing: .22em; }
  .hero h1 { font-size: clamp(44px, 11.4vw, 70px); letter-spacing: .055em; }
  .hero-subtitle { font-size: 17px; margin-top: 9px; letter-spacing: .075em; }
  .hero-actions { gap: 10px; margin-top: 23px; }
  .btn { padding-inline: 15px; gap: 9px; min-height: 43px; font-size: 14px; }
  .about { grid-template-columns: 1fr; gap: 24px; }
  .seal-panel { min-height: 190px; }
  .seal-panel img { height: 88px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 9px; margin-bottom: 20px; }
  .faculty-grid { grid-template-columns: 1fr; }
  .facility-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faculty-card { min-height: 88px; padding-right: 19px; }
  .faculty-info { justify-content: center; padding: 14px 12px; }
  .faculty-info strong { font-size: 20px; margin: 3px 0 5px; }
  .faculty-info > span { font-size: 13px; }
  .faculty-card > .icon { width: 12px; top: 10px; right: 9px; }
  .news-list button { display: grid; grid-template-columns: 1fr 18px; gap: 7px 14px; }
  .news-list strong { grid-row: 1; grid-column: 1; font-size: 15px; }
  .news-list .category { margin-left: 0; grid-row: 2; grid-column: 1; }
  .news-list .icon { grid-row: 1/3; grid-column: 2; }
  .footer-inner { flex-wrap: wrap; gap: 16px; }
  .footer-inner p { flex-basis: 100%; order: 2; }
  .backtop { margin-left: auto; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

.source-note a, .seal-panel a, .record-meta a, footer p a {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: .18em;
}
