/* ==========================================================================
   IMBA 形象網站 — 前台樣式
   色彩：深海軍藍（主色）＋黃銅金（強調）＋米白紙色（背景）
   ========================================================================== */

:root {
    --navy-950: #051327;
    --navy-900: #071a33;
    --navy: #0b2545;
    --navy-700: #13315c;
    --blue: #1f4e79;
    --gold: #b8893b;
    --gold-600: #9c7230;
    --gold-light: #e2c27f;
    --paper: #f7f4ee;
    --paper-2: #efe9dd;
    --white: #ffffff;
    --ink: #1a2433;
    --muted: #5a6575;
    --line: #e4ddcf;
    --line-cool: #e3e8ef;

    --font-serif: "Noto Serif TC", "Songti TC", "PMingLiU", Georgia, serif;
    --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", sans-serif;

    --container: 1280px;
    --gutter: clamp(16px, 4vw, 40px);
    --radius: 6px;
    --radius-lg: 12px;
    --shadow-sm: 0 1px 2px rgba(7, 26, 51, .06), 0 2px 8px rgba(7, 26, 51, .05);
    --shadow: 0 10px 30px -10px rgba(7, 26, 51, .22);
    --ease: cubic-bezier(.2, .7, .2, 1);
    --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
    margin: 0;
    background: var(--white);
    color: var(--ink);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.75;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img, svg, video, iframe { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--gold-600); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 2px; }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .6em; color: var(--navy); }
p { margin: 0 0 1em; }
button { font: inherit; }

.icon { width: 1.1em; height: 1.1em; flex: none; vertical-align: -.15em; }
.icon--inline { width: .9em; height: .9em; opacity: .6; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: 880px; }

.visually-hidden {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 1000; padding: 10px 16px;
    background: var(--gold); color: var(--navy-900); font-weight: 600; border-radius: var(--radius);
    transition: top .2s;
}
.skip-link:focus { top: 12px; }
main:focus { outline: none; }

/* ---------- Buttons & links ---------- */
.btn {
    display: inline-flex; align-items: center; gap: .55em; justify-content: center;
    padding: .8em 1.5em; border-radius: 999px; border: 1.5px solid transparent;
    font-weight: 600; font-size: .95rem; letter-spacing: .02em; line-height: 1.2;
    text-decoration: none; cursor: pointer;
    transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn .icon { transition: transform .25s var(--ease); }
.btn:hover .icon { transform: translateX(3px); }
.btn--gold { background: var(--gold); color: var(--white); }
.btn--gold:hover { background: var(--gold-600); color: var(--white); }
.btn--ghost { border-color: rgba(255, 255, 255, .55); color: var(--white); }
.btn--ghost:hover { background: var(--white); color: var(--navy); border-color: var(--white); }
.btn--navy { background: var(--navy); color: var(--white); }
.btn--navy:hover { background: var(--navy-700); color: var(--white); }
.btn--outline { border-color: var(--navy); color: var(--navy); }
.btn--outline:hover { background: var(--navy); color: var(--white); }

.link-arrow {
    display: inline-flex; align-items: center; gap: .45em; font-weight: 600; color: var(--navy);
    text-decoration: none; border-bottom: 1.5px solid var(--gold); padding-bottom: 2px;
}
.link-arrow .icon { transition: transform .25s var(--ease); color: var(--gold); }
.link-arrow:hover { color: var(--gold-600); }
.link-arrow:hover .icon { transform: translateX(4px); }
.link-arrow--back:hover .icon { transform: translateX(-4px); }

.eyebrow {
    display: inline-flex; align-items: center; gap: 12px; margin: 0 0 14px;
    font-size: .78rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-600);
}
.eyebrow::before { content: ""; width: 28px; height: 1.5px; background: currentColor; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: var(--white); transition: box-shadow .3s; }
.site-header.is-scrolled { box-shadow: 0 6px 24px -12px rgba(7, 26, 51, .35); }

.topbar { background: var(--navy-900); color: rgba(255, 255, 255, .8); font-size: .82rem; }
.topbar__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 38px; }
.topbar__school { color: inherit; text-decoration: none; letter-spacing: .04em; }
.topbar__school:hover { color: var(--gold-light); }
.topbar__tools { display: flex; align-items: center; gap: 18px; margin-left: auto; }
.topbar__search { display: flex; align-items: center; background: rgba(255, 255, 255, .08); border-radius: 999px; padding: 0 4px 0 12px; }
.topbar__search input {
    width: 160px; border: 0; background: transparent; color: var(--white); font: inherit; padding: 5px 0; transition: width .3s var(--ease);
}
.topbar__search input::placeholder { color: rgba(255, 255, 255, .5); }
.topbar__search input:focus { outline: none; width: 220px; }
.topbar__search:focus-within { box-shadow: 0 0 0 2px var(--gold); }
.topbar__search button { border: 0; background: none; color: inherit; padding: 6px 8px; cursor: pointer; display: flex; }
.topbar__lang { display: inline-flex; align-items: center; gap: 6px; color: inherit; text-decoration: none; font-weight: 500; }
.topbar__lang:hover { color: var(--gold-light); }

.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--navy); min-width: 0; }
.brand__logo { max-height: 52px; width: auto; }
.brand__mark {
    display: grid; place-items: center; flex: none; height: 46px; padding: 0 12px;
    background: var(--navy); color: var(--white); border-radius: 4px;
    font-family: var(--font-serif); font-weight: 700; font-size: 1.15rem; letter-spacing: .08em;
    box-shadow: inset 0 -3px 0 var(--gold);
}
.brand__mark--light { background: transparent; border: 1.5px solid rgba(255, 255, 255, .35); box-shadow: inset 0 -3px 0 var(--gold); }
.brand__text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.brand__name { font-family: var(--font-serif); font-weight: 700; font-size: 1.05rem; letter-spacing: .04em; }
.brand__uni { font-size: .76rem; font-weight: 600; color: var(--gold-600); letter-spacing: .2em; margin-bottom: 1px; }
.brand__sub { font-size: .74rem; color: var(--muted); letter-spacing: .02em; font-family: var(--font-sans); }
.brand__name--en { white-space: nowrap; font-family: var(--font-sans); font-weight: 600; font-size: .9rem; letter-spacing: 0; }
@media (min-width: 1241px) {
    .lang-en .brand { flex: none; }
    .lang-en .nav-link { font-size: .9rem; letter-spacing: 0; padding-inline: 9px; }
    .lang-en .nav-link::after { left: 9px; right: 9px; }
}

.nav-list { display: flex; align-items: stretch; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-item { position: relative; display: flex; align-items: center; }
.nav-link {
    position: relative; display: block; padding: 26px 12px; color: var(--navy); text-decoration: none;
    font-weight: 500; font-size: .98rem; letter-spacing: .03em; white-space: nowrap;
}
.nav-link::after {
    content: ""; position: absolute; left: 12px; right: 12px; bottom: 18px; height: 2px; background: var(--gold);
    transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav-item:hover > .nav-link::after, .nav-item.is-active > .nav-link::after, .nav-link:focus-visible::after { transform: scaleX(1); }
.nav-item.is-active > .nav-link { color: var(--navy); font-weight: 600; }
.nav-sub-toggle { display: none; }
.nav-sub {
    position: absolute; top: 100%; left: 0; min-width: 220px; list-style: none; margin: 0; padding: 10px 0;
    background: var(--white); border-top: 2px solid var(--gold); box-shadow: var(--shadow);
    opacity: 0; visibility: hidden; transform: translateY(8px); transition: all .25s var(--ease);
}
.nav-item:hover > .nav-sub, .nav-item:focus-within > .nav-sub { opacity: 1; visibility: visible; transform: none; }
.nav-sub a { display: block; padding: 9px 20px; color: var(--ink); text-decoration: none; font-size: .93rem; }
.nav-sub a:hover, .nav-sub a[aria-current] { background: var(--paper); color: var(--navy); }
.nav-mobile-tools { display: none; }

.nav-toggle {
    display: none; position: relative; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; color: var(--navy);
}
.nav-toggle__bar, .nav-toggle__bar::before, .nav-toggle__bar::after {
    position: absolute; left: 10px; width: 24px; height: 2px; background: currentColor; border-radius: 2px;
    transition: transform .3s var(--ease), opacity .2s;
}
.nav-toggle__bar { top: 21px; }
.nav-toggle__bar::before, .nav-toggle__bar::after { content: ""; left: 0; }
.nav-toggle__bar::before { top: -7px; }
.nav-toggle__bar::after { top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::after { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1240px) {
    :root { --header-h: 64px; }
    .topbar__search { display: none; }
    .nav-toggle { display: block; }
    .site-nav {
        position: fixed; inset: calc(var(--header-h) + 38px) 0 0 0; z-index: 99; overflow-y: auto;
        background: var(--white); padding: 8px var(--gutter) 40px;
        transform: translateX(100%); visibility: hidden; transition: transform .35s var(--ease), visibility .35s;
    }
    .site-nav.is-open { transform: none; visibility: visible; }
    .nav-list { flex-direction: column; gap: 0; }
    .nav-item { flex-wrap: wrap; border-bottom: 1px solid var(--line); }
    .nav-link { flex: 1; padding: 16px 0; font-size: 1.05rem; }
    .nav-link::after { display: none; }
    .nav-item.is-active > .nav-link { color: var(--gold-600); }
    .nav-sub-toggle {
        display: grid; place-items: center; width: 44px; height: 44px; border: 0; background: none; color: var(--navy); cursor: pointer;
    }
    .nav-sub-toggle .icon { transition: transform .25s; }
    .nav-sub-toggle[aria-expanded="true"] .icon { transform: rotate(180deg); }
    .nav-sub {
        position: static; flex-basis: 100%; min-width: 0; padding: 0 0 12px; border: 0; box-shadow: none;
        opacity: 1; visibility: visible; transform: none; display: none;
    }
    .nav-item.is-open > .nav-sub { display: block; }
    .nav-item:hover > .nav-sub { transform: none; }
    .nav-sub a { padding: 10px 16px; border-left: 2px solid var(--line); }
    .nav-mobile-tools { display: flex; flex-direction: column; gap: 16px; margin-top: 24px; }
    .nav-mobile-tools input { width: 100%; padding: 12px 16px; border: 1px solid var(--line); border-radius: 999px; font: inherit; }
    .nav-mobile-tools a { display: inline-flex; align-items: center; gap: 8px; color: var(--navy); font-weight: 600; text-decoration: none; }
    body.nav-open { overflow: hidden; }
}
@media (max-width: 520px) {
    .brand__mark { height: 40px; padding: 0 9px; font-size: 1rem; }
    .brand__name { font-size: .92rem; }
    .brand__uni { font-size: .66rem; letter-spacing: .12em; }
    .brand__sub { font-size: .6rem; letter-spacing: 0; line-height: 1.25; }
    .lang-en .brand { gap: 8px; }
    .lang-en .brand__mark { height: 34px; padding: 0 6px; font-size: .72rem; }
    .brand__name--en { font-size: clamp(7px, calc((100vw - 132px) / 25), .9rem); }
    .topbar__school { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60vw; }
}

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--navy); color: var(--white); overflow: hidden; }
.hero__slides { position: relative; min-height: clamp(460px, 74vh, 720px); }
.hero__slide {
    position: absolute; inset: 0; display: flex; align-items: center;
    opacity: 0; visibility: hidden; transition: opacity .9s var(--ease), visibility .9s;
}
.hero__slide.is-active { opacity: 1; visibility: visible; }
.hero--static .hero__slide { position: relative; min-height: clamp(460px, 74vh, 700px); }
.hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 7s linear; }
.hero__slide.is-active .hero__img { transform: scale(1); }
.hero__slide::before {
    content: ""; position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(100deg, rgba(5, 19, 39, .88) 0%, rgba(7, 26, 51, .62) 45%, rgba(7, 26, 51, .12) 100%);
}
.hero--static .hero__slide::before { background: radial-gradient(ellipse at 80% 20%, rgba(184, 137, 59, .25), transparent 55%); }
.hero__pattern {
    position: absolute; inset: 0;
    background:
        radial-gradient(circle at 85% 110%, rgba(31, 78, 121, .9), transparent 50%),
        linear-gradient(135deg, var(--navy-950) 0%, var(--navy) 55%, var(--navy-700) 100%);
}
.hero__pattern::after {
    content: ""; position: absolute; right: -10%; top: 50%; width: min(820px, 90vw); aspect-ratio: 1; transform: translateY(-50%);
    background: url("../img/globe-lines.svg") center / contain no-repeat; opacity: .5;
}
.hero__content { position: relative; z-index: 2; padding-block: 80px 120px; }
.hero__eyebrow {
    display: inline-flex; align-items: center; gap: 12px; margin-bottom: 18px;
    color: var(--gold-light); font-size: .82rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase;
}
.hero__eyebrow::before { content: ""; width: 36px; height: 1.5px; background: currentColor; }
.hero__title {
    max-width: 16em; margin: 0 0 22px; color: var(--white);
    font-family: var(--font-serif); font-weight: 700; font-size: clamp(2rem, 4.6vw, 3.6rem); line-height: 1.22; letter-spacing: .02em;
    text-wrap: balance;
}
.lang-en .hero__title { letter-spacing: 0; }
.hero__subtitle { max-width: 36em; margin-bottom: 34px; color: rgba(255, 255, 255, .85); font-size: clamp(1rem, 1.6vw, 1.18rem); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__slide.is-active .hero__content > * { animation: rise .9s var(--ease) both; }
.hero__slide.is-active .hero__content > *:nth-child(2) { animation-delay: .08s; }
.hero__slide.is-active .hero__content > *:nth-child(3) { animation-delay: .16s; }
.hero__slide.is-active .hero__content > *:nth-child(4) { animation-delay: .24s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

.hero__controls { position: absolute; z-index: 3; left: 0; right: 0; bottom: 92px; display: flex; align-items: center; gap: 14px; }
.hero__arrow {
    display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .4); background: transparent; color: var(--white); cursor: pointer; transition: background .2s;
}
.hero__arrow:hover { background: rgba(255, 255, 255, .15); }
.hero__dots { display: flex; gap: 8px; }
.hero__dot { width: 28px; height: 3px; padding: 0; border: 0; background: rgba(255, 255, 255, .35); cursor: pointer; transition: background .3s, width .3s; }
.hero__dot.is-active { width: 48px; background: var(--gold-light); }

/* ---------- Stats ---------- */
.stats { position: relative; z-index: 5; margin-top: -64px; }
.stats__list {
    display: grid; grid-template-columns: repeat(var(--cols, 4), 1fr); list-style: none; margin: 0; padding: 0;
    background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.stat { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 30px 16px; text-align: center; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat__value { font-family: var(--font-serif); font-size: clamp(1.8rem, 3.4vw, 2.6rem); font-weight: 700; line-height: 1.1; color: var(--navy); }
.stat__value::after { content: ""; display: block; width: 24px; height: 2px; margin: 12px auto 4px; background: var(--gold); }
.stat__label { font-size: .9rem; color: var(--muted); }
@media (max-width: 720px) {
    .stats__list { grid-template-columns: repeat(2, 1fr); }
    .stat:nth-child(odd) { border-left: 0; }
    .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section--tint { background: var(--paper); }
.section__head { max-width: 720px; margin-bottom: clamp(32px, 5vw, 56px); }
.section__head--row { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; max-width: none; flex-wrap: wrap; }
.section__title { font-family: var(--font-serif); font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 700; letter-spacing: .02em; text-wrap: balance; }
.section__title--sm { font-size: clamp(1.3rem, 2.2vw, 1.6rem); }
.empty { padding: 40px; text-align: center; color: var(--muted); background: var(--paper); border-radius: var(--radius); }

/* Intro */
.intro__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.intro__grid--single { grid-template-columns: minmax(0, 820px); }
.intro__text .prose { color: var(--muted); }
.intro__media { position: relative; margin: 0; }
.intro__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-lg); }
.intro__media::before {
    content: ""; position: absolute; inset: 24px -24px -24px 24px; z-index: -1; border: 1.5px solid var(--gold); border-radius: var(--radius-lg);
}
@media (max-width: 860px) {
    .intro__grid { grid-template-columns: 1fr; }
    .intro__media::before { inset: 14px -10px -14px 10px; }
}

/* Features */
.features { background: var(--paper); }
.features__grid { display: grid; grid-template-columns: repeat(var(--cols, 4), 1fr); gap: 2px; list-style: none; margin: 0; padding: 0; }
.feature {
    position: relative; padding: 36px 30px 40px; background: var(--white);
    transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.feature::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease); }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); z-index: 1; }
.feature:hover::before { transform: scaleX(1); }
.feature__num { position: absolute; top: 24px; right: 26px; font-family: var(--font-serif); font-size: .9rem; color: var(--gold); letter-spacing: .1em; }
.feature__icon { width: 46px; height: 46px; color: var(--navy); margin-bottom: 22px; }
.feature__title { font-family: var(--font-serif); font-size: 1.2rem; margin-bottom: 10px; }
.feature__text { margin: 0; color: var(--muted); font-size: .95rem; }
@media (max-width: 980px) { .features__grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .features__grid { grid-template-columns: 1fr; } }

/* News on home */
.news-home__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(28px, 4vw, 56px); }
.news-lead__media, .news-card__media {
    display: block; overflow: hidden; border-radius: var(--radius-lg); background: var(--navy); aspect-ratio: 16 / 10;
}
.news-lead__media img, .news-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.news-lead:hover img, .news-card:hover img { transform: scale(1.04); }
.news-placeholder {
    display: grid; place-items: center; width: 100%; height: 100%;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-700) 100%);
    color: rgba(255, 255, 255, .18); font-family: var(--font-serif); font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 700; letter-spacing: .15em;
}
.news-lead__body { padding-top: 22px; }
.news-lead__title { font-family: var(--font-serif); font-size: clamp(1.25rem, 2vw, 1.55rem); margin: 8px 0 10px; }
.news-lead__title a, .news-row__title, .news-card__title a { color: var(--navy); text-decoration: none; background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 1.5px no-repeat; transition: background-size .35s var(--ease); }
.news-lead__title a:hover, .news-row__title:hover, .news-card__title a:hover { background-size: 100% 1.5px; color: var(--navy); }
.news-lead__summary { color: var(--muted); }
.news-list { list-style: none; margin: 0; padding: 0; }
.news-row { padding: 18px 0; border-bottom: 1px solid var(--line); }
.news-list--compact .news-row:first-child { padding-top: 0; }
.news-row__title { display: inline; font-weight: 600; font-size: 1.02rem; line-height: 1.6; }
.news-list--grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 32px; }
@media (max-width: 860px) {
    .news-home__grid { grid-template-columns: 1fr; }
    .news-list--grid { grid-template-columns: 1fr; }
}

.news-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 6px; font-size: .84rem; color: var(--muted); }
.news-meta time { font-variant-numeric: tabular-nums; letter-spacing: .03em; }
.tag {
    --tag: var(--blue);
    display: inline-flex; align-items: center; gap: 4px; padding: 1px 10px; border-radius: 999px;
    font-size: .76rem; font-weight: 600; color: var(--tag); background: color-mix(in srgb, var(--tag) 12%, white);
}
.tag--pin { --tag: var(--gold-600); }
.tag--pin .icon { width: .85em; height: .85em; }

/* Faculty cards on home */
.faculty-home { padding-top: 0; }
.faculty-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; list-style: none; margin: 0; padding: 0; }
.person__photo {
    display: grid; place-items: center; aspect-ratio: 4 / 5; margin-bottom: 16px; overflow: hidden;
    border-radius: var(--radius-lg); background: var(--paper-2); color: var(--line);
}
.person__photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.35); transition: filter .4s, transform .6s var(--ease); }
.person:hover .person__photo img { filter: none; transform: scale(1.03); }
.person__photo .icon, .profile__photo .icon { width: 40%; height: 40%; color: #cfc6b4; }
.person__name { font-family: var(--font-serif); font-size: 1.1rem; margin: 0 0 2px; }
.person__title { margin: 0 0 6px; color: var(--gold-600); font-size: .88rem; font-weight: 600; }
.person__expertise { margin: 0; color: var(--muted); font-size: .88rem; line-height: 1.6; }
@media (max-width: 900px) { .faculty-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; } }

/* CTA */
.cta { background: var(--navy); color: var(--white); position: relative; overflow: hidden; }
.cta::before {
    content: ""; position: absolute; right: -120px; top: -160px; width: 480px; height: 480px; border-radius: 50%;
    border: 1px solid rgba(226, 194, 127, .25); box-shadow: 0 0 0 60px rgba(226, 194, 127, .04), 0 0 0 120px rgba(226, 194, 127, .03);
}
.cta__inner { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 32px; padding-block: clamp(56px, 7vw, 88px); flex-wrap: wrap; }
.cta__title { color: var(--white); font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.2rem); margin-bottom: 8px; }
.cta__text { margin: 0; color: rgba(255, 255, 255, .78); max-width: 40em; }
.cta__actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Inner page hero ---------- */
.page-hero { position: relative; overflow: hidden; background: var(--navy); color: var(--white); }
.page-hero .hero__pattern::after { right: -5%; width: min(560px, 70vw); opacity: .35; }
.page-hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.page-hero--image::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(100deg, rgba(5, 19, 39, .9), rgba(7, 26, 51, .55)); }
.page-hero__inner { position: relative; z-index: 2; padding-block: clamp(48px, 7vw, 88px); }
.page-hero__title { margin: 10px 0 0; color: var(--white); font-family: var(--font-serif); font-size: clamp(1.8rem, 4vw, 2.8rem); letter-spacing: .03em; }
.page-hero__summary { max-width: 42em; margin: 14px 0 0; color: rgba(255, 255, 255, .82); font-size: 1.05rem; }

.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0; padding: 0; font-size: .85rem; }
.breadcrumb li + li::before { content: "/"; margin-right: 6px; opacity: .5; }
.breadcrumb a { color: rgba(255, 255, 255, .75); text-decoration: none; }
.breadcrumb a:hover { color: var(--gold-light); }
.breadcrumb span { color: var(--gold-light); }
.breadcrumb--dark a { color: var(--muted); }
.breadcrumb--dark a:hover { color: var(--gold-600); }

/* ---------- Page body ---------- */
.page-body { padding-block: clamp(48px, 7vw, 88px); }
.page-body--sidebar { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.subnav { position: sticky; top: calc(var(--header-h) + 54px); }
.subnav__title { margin: 0 0 12px; padding-bottom: 12px; border-bottom: 2px solid var(--navy); font-family: var(--font-serif); font-size: 1.15rem; }
.subnav ul { list-style: none; margin: 0; padding: 0; }
.subnav a { display: block; padding: 10px 14px; border-left: 2px solid var(--line); color: var(--ink); text-decoration: none; font-size: .95rem; transition: all .2s; }
.subnav a:hover { border-color: var(--gold-light); background: var(--paper); color: var(--navy); }
.subnav a[aria-current] { border-color: var(--gold); background: var(--paper); color: var(--navy); font-weight: 600; }
@media (max-width: 860px) {
    .page-body--sidebar { grid-template-columns: 1fr; }
    .subnav { position: static; }
    .subnav ul { display: flex; flex-wrap: wrap; gap: 8px; }
    .subnav a { border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; }
    .subnav a[aria-current] { background: var(--navy); color: var(--white); border-color: var(--navy); }
}

.card-links { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.card-links li { margin: 0 !important; }
.card-links li::before { display: none; }
.card-links a {
    position: relative; display: flex; flex-direction: column; gap: 6px; height: 100%; padding: 24px 48px 24px 24px;
    border: 1px solid var(--line); border-radius: var(--radius-lg); text-decoration: none; color: var(--ink); transition: all .25s var(--ease);
}
.card-links a:hover { border-color: var(--gold); box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.card-links strong { color: var(--navy); font-family: var(--font-serif); font-size: 1.1rem; }
.card-links span { color: var(--muted); font-size: .9rem; }
.card-links .icon { position: absolute; right: 20px; top: 28px; color: var(--gold); }

/* ---------- Prose（編輯器內容） ---------- */
.prose { font-size: 1.02rem; line-height: 1.9; overflow-wrap: anywhere; }
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { margin: 2em 0 .7em; padding-left: 14px; border-left: 3px solid var(--gold); font-family: var(--font-serif); font-size: 1.55rem; }
.prose h3 { margin: 1.8em 0 .6em; font-family: var(--font-serif); font-size: 1.25rem; }
.prose h4 { margin: 1.6em 0 .5em; font-size: 1.08rem; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 1.2em; }
.prose li { margin: .35em 0; }
.prose ul li::marker { color: var(--gold); }
.prose a { color: var(--blue); }
.prose img { border-radius: var(--radius); margin: 1.5em 0; }
.prose figure { margin: 1.8em 0; }
.prose figcaption { margin-top: 8px; color: var(--muted); font-size: .88rem; text-align: center; }
.prose blockquote { margin: 1.6em 0; padding: 18px 24px; border-left: 3px solid var(--gold); background: var(--paper); color: var(--navy); font-family: var(--font-serif); }
.prose blockquote p:last-child { margin: 0; }
.prose hr { margin: 2.5em 0; border: 0; border-top: 1px solid var(--line); }
.prose table { width: 100%; margin: 1.6em 0; border-collapse: collapse; font-size: .95rem; display: block; overflow-x: auto; }
.prose table > tbody, .prose table > thead { display: table; width: 100%; border-collapse: collapse; }
.prose th, .prose td { padding: 12px 14px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose th, .prose thead td { background: var(--navy); color: var(--white); font-weight: 600; border-color: var(--navy-700); }
.prose tbody tr:nth-child(even) td { background: #fbf9f5; }
.prose iframe { display: block; width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; border-radius: var(--radius); margin: 1.6em 0; }
.prose pre { overflow-x: auto; padding: 16px; background: var(--paper); border-radius: var(--radius); font-size: .9rem; }
.prose details { margin: 1em 0; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius); }
.prose summary { cursor: pointer; font-weight: 600; color: var(--navy); }
.prose .lead, .prose--page > p:first-child { font-size: 1.1rem; color: var(--navy); }
.prose [style*="text-align: center"] img, .prose img[style*="margin-left: auto"] { margin-inline: auto; }

/* ---------- News list page ---------- */
.news-intro, .faculty-intro { max-width: 820px; margin-bottom: 40px; }
.filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.filter__item {
    padding: 7px 18px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); text-decoration: none; font-size: .92rem; transition: all .2s;
}
.filter__item:hover { border-color: var(--navy); color: var(--navy); }
.filter__item.is-active { background: var(--navy); border-color: var(--navy); color: var(--white); }

.news-cards { list-style: none; margin: 0; padding: 0; }
.news-card { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 32px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.news-card:first-child { padding-top: 0; }
.news-card__title { font-family: var(--font-serif); font-size: 1.28rem; margin: 6px 0 10px; }
.news-card__summary { margin: 0; color: var(--muted); }
.news-card.is-pinned .news-card__media { box-shadow: 0 0 0 2px var(--gold); }
@media (max-width: 720px) {
    .news-card { grid-template-columns: 1fr; gap: 16px; }
}

.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 48px; }
.pagination__item {
    display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-width: 42px; height: 42px; padding: 0 12px;
    border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); text-decoration: none; font-variant-numeric: tabular-nums;
}
.pagination__item:hover { border-color: var(--navy); color: var(--navy); }
.pagination__item.is-active { background: var(--navy); border-color: var(--navy); color: var(--white); }
.pagination__gap { display: inline-flex; align-items: center; padding: 0 4px; color: var(--muted); }

/* ---------- Article ---------- */
.preview-bar { position: sticky; top: calc(var(--header-h) + 38px); z-index: 50; padding: 10px var(--gutter); background: #fff4d6; color: #7a5300; text-align: center; font-weight: 600; border-bottom: 1px solid #f0d58c; }
.article-head { padding-block: clamp(40px, 6vw, 72px) 28px; background: var(--paper); }
.article-head .breadcrumb { margin-bottom: 18px; }
.article-head__title { margin: 10px 0 0; font-family: var(--font-serif); font-size: clamp(1.6rem, 3.4vw, 2.4rem); line-height: 1.35; text-wrap: balance; }
.article-head__summary { margin: 16px 0 0; color: var(--muted); font-size: 1.08rem; }
.article { padding-block: 40px clamp(56px, 8vw, 96px); }
.article__cover { margin: 0 0 40px; }
.article__cover img { width: 100%; border-radius: var(--radius-lg); }

.attachments { margin-top: 48px; padding: 28px; background: var(--paper); border-radius: var(--radius-lg); }
.attachments__title { font-size: 1.05rem; margin-bottom: 14px; }
.attachments ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.attachments a {
    display: flex; align-items: center; gap: 14px; padding: 12px 16px; background: var(--white); border: 1px solid var(--line);
    border-radius: var(--radius); color: var(--ink); text-decoration: none; transition: border-color .2s;
}
.attachments a:hover { border-color: var(--gold); }
.attachments__ext { flex: none; min-width: 46px; padding: 3px 6px; background: var(--navy); color: var(--white); border-radius: 4px; text-align: center; font-size: .72rem; font-weight: 700; letter-spacing: .05em; }
.attachments__name { flex: 1; min-width: 0; overflow-wrap: anywhere; font-weight: 500; }
.attachments__size { color: var(--muted); font-size: .84rem; white-space: nowrap; }
.attachments a .icon { color: var(--gold); }

.article__share { display: flex; align-items: center; gap: 10px; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.article__share a, .share-copy {
    display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line);
    background: var(--white); color: var(--navy); cursor: pointer; transition: all .2s;
}
.article__share a:hover, .share-copy:hover { background: var(--navy); color: var(--white); border-color: var(--navy); }
.share-copy.is-copied { background: var(--gold); border-color: var(--gold); color: var(--white); }
.article__nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 32px; }
.article__nav-item { display: flex; flex-direction: column; gap: 4px; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--navy); transition: border-color .2s; }
.article__nav-item:hover { border-color: var(--gold); color: var(--navy); }
.article__nav-item small { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); }
.article__nav-item span { font-weight: 600; line-height: 1.5; }
.article__nav-item--next { text-align: right; align-items: flex-end; grid-column: 2; }
.article__back { margin-top: 32px; }
@media (max-width: 600px) {
    .article__nav { grid-template-columns: 1fr; }
    .article__nav-item--next { grid-column: auto; }
}

/* ---------- Faculty page ---------- */
.faculty-group { margin-bottom: 56px; }
.faculty-group__title {
    display: flex; align-items: center; gap: 16px; margin-bottom: 28px; font-family: var(--font-serif); font-size: 1.45rem;
}
.faculty-group__title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.faculty-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); gap: 24px; list-style: none; margin: 0; padding: 0; }
.profile { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 24px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); transition: box-shadow .3s, border-color .3s; }
.profile:hover { box-shadow: var(--shadow-sm); border-color: #d6cdb9; }
.profile__photo { display: grid; place-items: center; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--paper-2); }
.profile__photo img { width: 100%; height: 100%; object-fit: cover; }
.profile__name { margin: 0 0 2px; font-family: var(--font-serif); font-size: 1.2rem; }
.profile__name span { margin-left: 8px; font-family: var(--font-sans); font-size: .85rem; font-weight: 500; color: var(--muted); }
.profile__title { margin: 0 0 12px; color: var(--gold-600); font-weight: 600; font-size: .9rem; }
.profile__meta { margin: 0 0 12px; font-size: .9rem; }
.profile__meta div { display: grid; grid-template-columns: 5.5em 1fr; gap: 8px; margin-bottom: 6px; }
.lang-en .profile__meta div { grid-template-columns: 6.5em 1fr; }
.profile__meta dt { color: var(--muted); }
.profile__meta dd { margin: 0; }
.profile__contact { display: flex; flex-wrap: wrap; gap: 6px 16px; list-style: none; margin: 0; padding: 12px 0 0; border-top: 1px dashed var(--line); font-size: .86rem; }
.profile__contact li { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); min-width: 0; }
.profile__contact a { overflow-wrap: anywhere; }
.profile__contact .icon { color: var(--gold); }
@media (max-width: 520px) {
    .profile { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding: 16px; }
    .profile__meta div { grid-template-columns: 1fr; gap: 0; }
}

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.contact__list { margin: 0 0 32px; }
.contact__list div { display: grid; grid-template-columns: 8em 1fr; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.contact__list dt { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .92rem; }
.contact__list dt .icon { color: var(--gold); }
.contact__list dd { margin: 0; color: var(--navy); font-weight: 500; overflow-wrap: anywhere; }
.contact__map { position: sticky; top: calc(var(--header-h) + 54px); }
.contact__map iframe { display: block; width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
@media (max-width: 860px) {
    .contact { grid-template-columns: 1fr; }
    .contact__map { position: static; }
}
@media (max-width: 480px) { .contact__list div { grid-template-columns: 1fr; gap: 2px; } }

/* ---------- Search ---------- */
.search-form { display: flex; gap: 10px; margin-bottom: 40px; }
.search-form input { flex: 1; min-width: 0; padding: 12px 20px; border: 1.5px solid var(--line); border-radius: 999px; font: inherit; }
.search-form input:focus { outline: none; border-color: var(--navy); }
.search-heading { font-size: 1.2rem; margin-bottom: 24px; }
.search-group { margin: 32px 0 8px; font-size: .85rem; letter-spacing: .15em; color: var(--gold-600); text-transform: uppercase; }
.search-results { list-style: none; margin: 0; padding: 0; }
.search-results a { display: flex; flex-direction: column; gap: 4px; padding: 18px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.search-results strong { color: var(--navy); font-size: 1.05rem; }
.search-results a:hover strong { color: var(--gold-600); }
.search-results time { font-size: .84rem; color: var(--muted); }
.search-results span { color: var(--muted); font-size: .93rem; }

/* ---------- Error ---------- */
.error-page { padding-block: clamp(80px, 12vw, 160px); text-align: center; }
.error-page__code { margin: 0; font-family: var(--font-serif); font-size: clamp(4rem, 12vw, 7rem); font-weight: 700; line-height: 1; color: var(--gold); }
.error-page__title { margin: 16px 0 12px; font-family: var(--font-serif); }
.error-page p { color: var(--muted); }
.error-page__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-900); color: rgba(255, 255, 255, .72); font-size: .93rem; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr; gap: clamp(32px, 5vw, 64px); padding-block: clamp(56px, 7vw, 80px); }
.footer__brand { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.footer__brand strong { display: block; color: var(--white); font-family: var(--font-serif); font-size: 1.05rem; }
.footer__brand span { font-size: .84rem; }
.footer__about p { max-width: 30em; }
.footer__title { margin-bottom: 18px; color: var(--white); font-size: .82rem; letter-spacing: .2em; text-transform: uppercase; font-weight: 600; }
.footer__links, .footer__contact { list-style: none; margin: 0; padding: 0; }
.footer__links { columns: 2; column-gap: 24px; }
.footer__links li { margin-bottom: 10px; break-inside: avoid; }
.site-footer a { color: rgba(255, 255, 255, .8); text-decoration: none; }
.site-footer a:hover { color: var(--gold-light); }
.footer__contact li { display: flex; gap: 10px; margin-bottom: 12px; }
.footer__contact .icon { margin-top: .35em; color: var(--gold-light); }
.footer__contact span, .footer__contact a { overflow-wrap: anywhere; }
.social { display: flex; gap: 10px; list-style: none; margin: 20px 0 0; padding: 0; }
.social a { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .2); transition: all .2s; }
.social a:hover { background: var(--gold); border-color: var(--gold); color: var(--white); }
.footer__bottom { border-top: 1px solid rgba(255, 255, 255, .1); font-size: .82rem; }
.footer__bottom-inner { display: flex; justify-content: space-between; gap: 8px 24px; flex-wrap: wrap; padding-block: 20px; }
@media (max-width: 860px) { .footer__grid { grid-template-columns: 1fr; } }

.to-top {
    position: fixed; right: 20px; bottom: 20px; z-index: 90; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
    background: var(--navy); color: var(--white); box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(10px); transition: all .3s var(--ease);
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--gold); color: var(--white); }

/* ---------- Scroll reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media print {
    .site-header, .site-footer, .to-top, .article__share, .article__nav, .hero__controls { display: none !important; }
    .page-hero, .hero { background: none; color: #000; }
    .page-hero__title, .hero__title { color: #000; }
    .js .reveal { opacity: 1 !important; transform: none !important; }
}
