/* ==================================================================
   幻光回廊 LumiCori · 2027 站点统一样式
   全站唯一设计来源：页面只写结构，视觉全部在这里。
   ================================================================== */

/* ---------- 1. 设计变量 ---------- */
:root {
    /* 浅色：光缝回廊的纸面 */
    --bg: #FBFAFF;
    --bg-soft: #F5F2FD;
    --surface: rgba(255, 255, 255, .82);
    --surface-solid: #FFFFFF;
    --ink: #1D1833;
    --ink-2: #4C4566;
    --ink-3: #7C7595;
    --ink-4: #A9A3BD;
    --line: rgba(29, 24, 51, .08);
    --line-strong: rgba(29, 24, 51, .16);

    --brand: #7C3AED;
    --brand-2: #A78BFA;
    --brand-soft: rgba(124, 58, 237, .10);
    --blue: #818CF8;
    --sakura: #FFC8DD;
    --ice: #8EDCE8;
    --ice-soft: rgba(142, 220, 232, .16);

    --shadow-sm: 0 2px 10px rgba(45, 30, 90, .05);
    --shadow-md: 0 14px 40px -18px rgba(45, 30, 90, .28);
    --shadow-lg: 0 30px 80px -30px rgba(45, 30, 90, .35);

    --r-sm: 12px;
    --r-md: 20px;
    --r-lg: 28px;
    --r-pill: 999px;

    --nav-h: 72px;
    --container: 1200px;

    --ff: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", "Noto Sans SC",
          system-ui, -apple-system, "Segoe UI", sans-serif;

    --ease: cubic-bezier(.22, .61, .36, 1);
}

html[data-theme="dark"] {
    --bg: #0D0A18;
    --bg-soft: #141026;
    --surface: rgba(255, 255, 255, .045);
    --surface-solid: #171228;
    --ink: #F2EFFA;
    --ink-2: #C3BBD8;
    --ink-3: #8E86A8;
    --ink-4: #665F80;
    --line: rgba(255, 255, 255, .09);
    --line-strong: rgba(255, 255, 255, .18);

    --brand: #A78BFA;
    --brand-2: #8B6BF2;
    --brand-soft: rgba(167, 139, 250, .14);
    --ice-soft: rgba(142, 220, 232, .10);

    --shadow-sm: 0 2px 10px rgba(0, 0, 0, .30);
    --shadow-md: 0 16px 44px -18px rgba(0, 0, 0, .70);
    --shadow-lg: 0 32px 90px -30px rgba(0, 0, 0, .80);
}

/* 期生三色编码：1 冰青 / 2 雾紫 / 3 樱粉 */
.gen-1 { --gen: #2E97AB; --gen-soft: rgba(142, 220, 232, .20); }
.gen-2 { --gen: #7757E8; --gen-soft: rgba(167, 139, 250, .20); }
.gen-3 { --gen: #D96A8C; --gen-soft: rgba(255, 200, 221, .38); }

html[data-theme="dark"] .gen-1 { --gen: #9FE6EF; --gen-soft: rgba(142, 220, 232, .16); }
html[data-theme="dark"] .gen-2 { --gen: #C0ABFF; --gen-soft: rgba(167, 139, 250, .18); }
html[data-theme="dark"] .gen-3 { --gen: #FFC0D4; --gen-soft: rgba(255, 200, 221, .16); }

/* ---------- 2. 基础 ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + 24px);
}

body {
    min-height: 100vh;
    font-family: var(--ff);
    font-size: 16px;
    line-height: 1.7;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img,
svg { display: block; max-width: 100%; }

img { height: auto; }

a { color: inherit; text-decoration: none; }

button { font: inherit; color: inherit; }

h1, h2, h3, h4 {
    font-weight: 650;
    line-height: 1.25;
    letter-spacing: -.012em;
    text-wrap: balance;
}

p { text-wrap: pretty; }

::selection {
    background: var(--brand-soft);
    color: var(--brand);
}

:focus-visible {
    outline: 2px solid var(--brand);
    outline-offset: 3px;
    border-radius: 6px;
}

[hidden] { display: none !important; }

.icon {
    width: 20px;
    height: 20px;
    flex: none;
}

.icon-sm { width: 16px; height: 16px; }
.icon-lg { width: 28px; height: 28px; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 999;
    padding: 10px 18px;
    border-radius: var(--r-pill);
    background: var(--brand);
    color: #fff;
    transform: translateY(-160%);
    transition: transform .25s var(--ease);
}

.skip-link:focus-visible { transform: none; }

/* 背景光厅：三色柔光（中缝光缝只在首页 hero，见 §7） */
.site-atmosphere {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(1100px 560px at 50% -12%, rgba(167, 139, 250, .20), transparent 62%),
        radial-gradient(820px 460px at 88% 6%, rgba(142, 220, 232, .16), transparent 62%),
        radial-gradient(760px 480px at 6% 26%, rgba(255, 200, 221, .18), transparent 62%),
        var(--bg);
}

html[data-theme="dark"] .site-atmosphere {
    background:
        radial-gradient(1100px 560px at 50% -12%, rgba(124, 58, 237, .28), transparent 62%),
        radial-gradient(820px 460px at 88% 6%, rgba(142, 220, 232, .10), transparent 62%),
        radial-gradient(760px 480px at 6% 26%, rgba(255, 200, 221, .07), transparent 62%),
        var(--bg);
}

.container {
    width: min(var(--container), calc(100% - 48px));
    margin-inline: auto;
}

/* ---------- 3. 通用元件 ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 22px;
    border: 1px solid transparent;
    border-radius: var(--r-pill);
    font-size: 15.5px;
    font-weight: 550;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    transition: transform .25s var(--ease), box-shadow .25s var(--ease),
                background-color .25s var(--ease), border-color .25s var(--ease),
                color .25s var(--ease);
}

.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
    background: linear-gradient(135deg, var(--brand), #9F7AFF 55%, #6FA8FF);
    color: #fff;
    box-shadow: 0 10px 26px -12px rgba(124, 58, 237, .70);
}

.btn-primary:hover { box-shadow: 0 16px 34px -12px rgba(124, 58, 237, .80); }

.btn-ghost {
    background: var(--surface);
    border-color: var(--line-strong);
    color: var(--ink-2);
    backdrop-filter: blur(10px);
}

.btn-ghost:hover {
    border-color: var(--brand-2);
    color: var(--brand);
}

.btn-sm { padding: 8px 16px; font-size: 14.5px; }
.btn-lg { padding: 15px 30px; font-size: 16.5px; }

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink-2);
    cursor: pointer;
    transition: color .25s var(--ease), border-color .25s var(--ease),
                background-color .25s var(--ease), transform .25s var(--ease);
}

.icon-btn:hover {
    color: var(--brand);
    border-color: var(--brand-2);
    transform: translateY(-1px);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    font-weight: 550;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--brand);
}

.eyebrow .icon { width: 15px; height: 15px; }

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14.5px;
    font-weight: 550;
    color: var(--brand);
}

.text-link .icon { transition: transform .25s var(--ease); }
.text-link:hover .icon { transform: translateX(3px); }

.icon-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--ink-3);
    border: 1px solid var(--line);
    transition: color .25s var(--ease), border-color .25s var(--ease);
}

.icon-link:hover {
    color: var(--brand);
    border-color: var(--brand-2);
}

.gen-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: var(--r-pill);
    background: var(--gen-soft, var(--brand-soft));
    color: var(--gen, var(--brand));
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .06em;
    line-height: 1.6;
}

/* ---------- 4. 导航 ---------- */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg);
    border-bottom: 1px solid transparent;
    transition: border-color .3s var(--ease), box-shadow .3s var(--ease),
                background-color .3s var(--ease);
}

/* 支持背景模糊时降低底色不透明度，让内容从毛玻璃下透出。
   这里必须用 rgba 字面量：旧内核会在 var() 替换后判定 color-mix 非法，
   把 background 回退成 transparent，导致导航栏透明、内容穿透。 */
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .navbar {
        background: rgba(251, 250, 255, .64);
        -webkit-backdrop-filter: blur(18px) saturate(1.5);
        backdrop-filter: blur(18px) saturate(1.5);
    }

    html[data-theme="dark"] .navbar {
        background: rgba(13, 10, 24, .64);
    }
}

.navbar.is-scrolled {
    border-bottom-color: var(--line);
    box-shadow: 0 12px 30px -24px rgba(45, 30, 90, .55);
}

.nav-container {
    display: flex;
    align-items: center;
    gap: 28px;
    width: min(var(--container), calc(100% - 48px));
    height: var(--nav-h);
    margin-inline: auto;
}

.logo { display: inline-flex; align-items: center; flex: none; }

.logo img {
    width: auto;
    height: 40px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-link {
    padding: 6px 12px;
    border-radius: var(--r-pill);
    font-size: 15.5px;
    line-height: 1.5;
    color: var(--ink-2);
    transition: color .25s var(--ease), background-color .25s var(--ease);
}

.nav-link:hover { color: var(--ink); background: var(--brand-soft); }

.nav-link.is-active {
    color: var(--brand);
    background: var(--brand-soft);
    font-weight: 550;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.theme-toggle .icon-sun { display: none; }
html[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

.nav-toggle { display: none; }
.nav-toggle .icon-close { display: none; }
.navbar.is-open .nav-toggle .icon-close { display: block; }
.navbar.is-open .nav-toggle .icon-menu { display: none; }

/* ---------- 5. 页脚 ---------- */
.site-footer {
    margin-top: clamp(48px, 7vw, 96px);
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, transparent, var(--bg-soft));
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 48px;
    width: min(var(--container), calc(100% - 48px));
    margin-inline: auto;
    padding: clamp(40px, 5vw, 64px) 0 clamp(28px, 4vw, 40px);
}

.footer-logo img { width: auto; height: 60px; }

.footer-tagline {
    margin-top: 16px;
    font-size: 17px;
    font-weight: 550;
    color: var(--ink);
}

.footer-note {
    margin-top: 6px;
    font-size: 14px;
    color: var(--ink-3);
}

.footer-cols {
    display: flex;
    justify-content: flex-end;
    gap: clamp(40px, 6vw, 88px);
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col h4 {
    margin-bottom: 2px;
    font-size: 13.5px;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ink-4);
}

.footer-col a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14.5px;
    color: var(--ink-3);
    transition: color .25s var(--ease);
}

.footer-col a:hover { color: var(--brand); }

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: min(var(--container), calc(100% - 48px));
    margin-inline: auto;
    padding: 18px 0 26px;
    border-top: 1px solid var(--line);
    font-size: 13.5px;
    color: var(--ink-4);
}

.footer-made { color: var(--ink-3); }

/* ---------- 6. 区块标题 ---------- */
.section { padding: clamp(52px, 7vw, 92px) 0; }

.section.is-tight { padding-top: 0; }

.empty-note {
    padding: clamp(28px, 4vw, 44px);
    border: 1px dashed var(--line-strong);
    border-radius: var(--r-md);
    background: var(--surface);
    font-size: 14.5px;
    line-height: 1.9;
    color: var(--ink-3);
    text-align: center;
}

.empty-note p + p { margin-top: 6px; }

/* 成员详情：公皮提示 */
.profile-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 24px;
    padding: 13px 16px;
    border: 1px solid var(--line);
    border-left: 3px solid var(--gen, var(--brand));
    border-radius: var(--r-sm);
    background: var(--gen-soft, var(--brand-soft));
    font-size: 14px;
    line-height: 1.75;
    color: var(--ink-2);
}

.profile-note .icon { flex: none; margin-top: 3px; color: var(--gen, var(--brand)); }

.section-head {
    max-width: 720px;
    margin: 0 auto clamp(32px, 4vw, 52px);
    text-align: center;
}

.section-head.is-left {
    margin-inline: 0;
    text-align: left;
}

.section-title {
    margin-top: 14px;
    font-size: clamp(26px, 3.4vw, 38px);
}

.section-desc {
    margin-top: 12px;
    font-size: 16px;
    line-height: 1.85;
    color: var(--ink-3);
}

/* ---------- 7. 首页 Hero ---------- */
.home-hero {
    position: relative;
    padding: clamp(52px, 7vw, 96px) 0 clamp(44px, 6vw, 76px);
}

/* 中缝光缝：仅首页，且随 hero 定位（不固定视口） */
.home-hero::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1px;
    transform: translateX(-.5px);
    pointer-events: none;
    background: linear-gradient(180deg,
        transparent,
        rgba(167, 139, 250, .30) 18%,
        rgba(142, 220, 232, .22) 52%,
        transparent 92%);
    opacity: .75;
}

html[data-theme="dark"] .home-hero::before { opacity: .35; }

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr);
    align-items: center;
    gap: clamp(32px, 5vw, 64px);
}

.hero-copy { max-width: 560px; }

.hero-title {
    margin-top: 20px;
    font-size: clamp(38px, 5.4vw, 64px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -.02em;
}

.hero-title .grad {
    background: linear-gradient(115deg, #7C3AED 8%, #A78BFA 42%, #6FA8FF 72%, #FFA9C9 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-sub {
    max-width: 480px;
    margin-top: 22px;
    font-size: 17px;
    line-height: 1.9;
    color: var(--ink-2);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 32px;
}

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: clamp(24px, 4vw, 44px);
    margin-top: 44px;
    padding-top: 26px;
    border-top: 1px solid var(--line);
}

.hero-stats .stat-label {
    font-size: 13.5px;
    letter-spacing: .08em;
    color: var(--ink-4);
}

.hero-stats .stat-value {
    margin-top: 2px;
    font-size: 24px;
    font-weight: 650;
    letter-spacing: -.02em;
    color: var(--ink);
}

.hero-stats .stat-value small {
    margin-left: 2px;
    font-size: 13px;
    font-weight: 400;
    color: var(--ink-3);
}

.hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 320px;
}

.hero-halo {
    position: absolute;
    inset: -8% -4%;
    border-radius: 50%;
    background:
        radial-gradient(closest-side, rgba(167, 139, 250, .30), transparent 72%),
        radial-gradient(closest-side at 62% 60%, rgba(142, 220, 232, .24), transparent 70%),
        radial-gradient(closest-side at 36% 72%, rgba(255, 200, 221, .26), transparent 70%);
    filter: blur(12px);
    opacity: .95;
}

.hero-logo {
    position: relative;
    width: auto;
    max-height: 500px;
    max-width: 100%;
    filter: drop-shadow(0 30px 50px rgba(70, 40, 140, .22));
    animation: hero-float 8s ease-in-out infinite;
}

@keyframes hero-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-14px); }
}

/* ---------- 8. 首页成员区 ---------- */
.home-pages { display: grid; gap: 28px; }

.home-page {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.home-page + .home-page { margin-top: 4px; }

.home-card {
    position: relative;
    display: grid;
    /* 立绘列按原图 4:5 给足宽度，配合 contain 完整显示不裁切 */
    grid-template-columns: 186px minmax(0, 1fr);
    min-height: 232px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow-sm);
    transition: transform .35s var(--ease), box-shadow .35s var(--ease),
                border-color .35s var(--ease);
}

.home-card:hover {
    transform: translateY(-4px);
    border-color: var(--line-strong);
    box-shadow: var(--shadow-md);
}

.home-card-media {
    position: relative;
    display: block;
    overflow: hidden;
    background: linear-gradient(160deg, var(--gen-soft, var(--brand-soft)), transparent 70%);
}

.home-card-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform .8s var(--ease);
}

.home-card:hover .home-card-media img { transform: scale(1.05); }

.home-card-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    padding: 22px 22px 20px;
}

/* 期生徽章 + 姓名 + 小标题，手机端整块挪到立绘右侧 */
.home-card-head {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
}

.home-card-name {
    font-size: 21px;
    letter-spacing: -.01em;
}

.home-card-name a { transition: color .25s var(--ease); }
.home-card-name a:hover { color: var(--brand); }

.home-card .member-desc { -webkit-line-clamp: 3; }

.home-card .text-link { margin-top: auto; padding-top: 10px; }

/* 首页空位 */
.home-card.is-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 28px;
    border: 1.5px dashed var(--line-strong);
    background:
        radial-gradient(120% 90% at 50% 0%, var(--brand-soft), transparent 70%),
        var(--surface);
    text-align: center;
    box-shadow: none;
}

.home-card.is-empty:hover { transform: none; box-shadow: none; }

.slot-mark {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: var(--surface-solid);
    border: 1px solid var(--line);
    color: var(--brand-2);
    box-shadow: var(--shadow-sm);
}

.slot-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--ink-2);
}

.slot-desc {
    font-size: 13.5px;
    line-height: 1.7;
    color: var(--ink-4);
}

/* 空位卡：查看全部成员 + 加入我们 并排 */
.slot-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px 20px;
    margin-top: 2px;
}

.home-more {
    margin-top: 36px;
    text-align: center;
}

/* 分页器 */
.pager {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 38px;
}

.pager-btn {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: var(--r-pill);
    background: var(--line-strong);
    cursor: pointer;
    transition: width .3s var(--ease), background-color .3s var(--ease);
}

.pager-btn:hover { background: var(--brand-2); }

.pager-btn.is-active {
    width: 30px;
    background: var(--brand);
}

/* 左右翻页箭头 */
.pager-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink-2);
    cursor: pointer;
    transition: color .25s var(--ease), border-color .25s var(--ease),
                transform .25s var(--ease), opacity .25s var(--ease);
}

.pager-arrow:hover:not(:disabled) {
    color: var(--brand);
    border-color: var(--brand-2);
    transform: translateY(-1px);
}

.pager-arrow:disabled {
    opacity: .35;
    cursor: not-allowed;
}

/* 首页收尾 CTA */
.home-cta {
    position: relative;
    overflow: hidden;
    padding: clamp(40px, 5vw, 64px);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background:
        radial-gradient(90% 140% at 12% 0%, rgba(167, 139, 250, .20), transparent 60%),
        radial-gradient(90% 140% at 92% 100%, rgba(255, 200, 221, .22), transparent 60%),
        var(--surface);
    text-align: center;
}

.home-cta h2 {
    font-size: clamp(24px, 3vw, 34px);
}

.home-cta p {
    max-width: 520px;
    margin: 12px auto 0;
    font-size: 15.5px;
    line-height: 1.85;
    color: var(--ink-3);
}

.home-cta .hero-actions { justify-content: center; margin-top: 26px; }

/* ---------- 9. 成员卡片（总览） ---------- */
.member-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(238px, 1fr));
    gap: 26px;
}

.member-card {
    position: relative;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    transition: transform .35s var(--ease), box-shadow .35s var(--ease),
                border-color .35s var(--ease);
}

.member-card:hover {
    transform: translateY(-5px);
    border-color: var(--line-strong);
    box-shadow: var(--shadow-md);
}

/* 整卡热区：透明覆盖层，让卡片空白处也能点进详情页（底部操作区另在上层） */
.card-hit {
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
}

.member-card-media {
    position: relative;
    display: block;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    border-radius: var(--r-lg) var(--r-lg) 0 0;
    background: linear-gradient(165deg, var(--gen-soft, var(--brand-soft)), transparent 72%);
}

.member-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    transition: transform .8s var(--ease);
}

.member-card:hover .member-card-media img { transform: scale(1.05); }

/* 通用立绘 member_default 是横幅 logo 图：容器尺寸不变，改为完整显示而不裁切 */
.home-card-media img[src*="member_default"],
.member-card-media img[src*="member_default"],
.profile-avatar img[src*="member_default"] {
    object-fit: contain;
    object-position: center;
}

.member-card-media .gen-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    background: var(--surface-solid);
    /* rgba 字面量：旧内核会让 color-mix 计算失效，徽章会丢底色 */
    background: rgba(255, 255, 255, .78);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow-sm);
}

html[data-theme="dark"] .member-card-media .gen-badge {
    background: rgba(23, 18, 40, .78);
}

.member-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 7px;
    padding: 20px 22px 22px;
}

.member-name { font-size: 19.5px; }
.member-name a:hover { color: var(--brand); }

.member-role {
    font-size: 13.5px;
    letter-spacing: .04em;
    color: var(--gen, var(--brand));
    font-weight: 550;
}

.member-desc {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    font-size: 14px;
    line-height: 1.72;
    color: var(--ink-3);
}

.member-card-foot {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

/* 多平台：卡片只显示首个平台图标，点击弹出菜单 */
.member-link-wrap {
    position: relative;
    display: inline-flex;
}

/* 卡片上的图标按钮：去掉原生 button 的默认内边距与底色 */
button.icon-link.member-link-toggle {
    padding: 0;
    background: none;
    font: inherit;
    cursor: pointer;
}

.member-link-menu {
    position: absolute;
    right: 0;
    bottom: calc(100% + 10px);
    z-index: 20;
    min-width: 136px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    background: var(--surface-solid);
    box-shadow: var(--shadow-md);
}

.member-link-menu[hidden] { display: none; }

.member-link-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--ink-2);
    white-space: nowrap;
}

.member-link-item:hover {
    color: var(--brand);
    background: var(--brand-soft);
}

.member-card.is-menu-open { z-index: 5; }

/* 详情页「更多主页」：菜单向下展开、左对齐 */
.member-link-wrap.is-drop .member-link-menu {
    top: calc(100% + 8px);
    bottom: auto;
    right: auto;
    left: 0;
}

/* ---------- 10. 页头（内页） ---------- */
.page-hero {
    padding: clamp(48px, 6.5vw, 84px) 0 clamp(28px, 4vw, 44px);
    text-align: center;
}

.page-title {
    margin-top: 16px;
    font-size: clamp(34px, 4.6vw, 54px);
    letter-spacing: -.02em;
}

.page-desc {
    max-width: 620px;
    margin: 16px auto 0;
    font-size: 16.5px;
    line-height: 1.9;
    color: var(--ink-3);
}

.page-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 26px;
}

.page-meta span {
    padding: 6px 14px;
    border: 1px solid var(--line);
    border-radius: var(--r-pill);
    background: var(--surface);
    font-size: 13.5px;
    color: var(--ink-3);
}

/* ---------- 11. 成员总览 ---------- */
.gen-section { margin-bottom: clamp(48px, 6vw, 76px); }

.gen-section:last-child { margin-bottom: 0; }

.gen-head {
    display: flex;
    align-items: center;
    gap: clamp(16px, 2.4vw, 26px);
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--line);
}

.gen-index {
    font-size: clamp(44px, 6vw, 72px);
    font-weight: 700;
    line-height: .78;
    letter-spacing: -.05em;
    font-variant-numeric: tabular-nums;
    color: transparent;
    -webkit-text-stroke: 1.2px var(--line-strong);
    user-select: none;
}

.gen-title { font-size: clamp(23px, 2.6vw, 30px); }

.gen-count {
    margin-left: auto;
    padding: 5px 14px;
    border: 1px solid var(--line);
    border-radius: var(--r-pill);
    font-size: 13.5px;
    color: var(--ink-3);
    white-space: nowrap;
}

/* 预备役折叠 */
.reserve {
    margin-top: clamp(40px, 5vw, 64px);
    border-top: 1px solid var(--line);
    padding-top: clamp(28px, 4vw, 40px);
}

.reserve-summary {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    border: 1px dashed var(--line-strong);
    border-radius: var(--r-md);
    background: var(--surface);
    cursor: pointer;
    list-style: none;
    transition: border-color .25s var(--ease), background-color .25s var(--ease);
}

.reserve-summary::-webkit-details-marker { display: none; }

.reserve-summary:hover { border-color: var(--brand-2); }

.reserve-label {
    font-size: 16.5px;
    font-weight: 600;
    color: var(--ink-2);
}

.reserve-count {
    padding: 3px 11px;
    border-radius: var(--r-pill);
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 13px;
    font-weight: 600;
}

.reserve-hint {
    margin-left: auto;
    font-size: 13.5px;
    color: var(--ink-4);
}

.reserve-summary::after {
    content: "";
    width: 8px;
    height: 8px;
    margin-left: 6px;
    border-right: 1.6px solid var(--ink-3);
    border-bottom: 1.6px solid var(--ink-3);
    transform: rotate(45deg) translateY(-2px);
    transition: transform .3s var(--ease);
}

.reserve[open] .reserve-summary::after {
    transform: rotate(-135deg) translateY(-2px);
}

.reserve-body { padding-top: clamp(28px, 4vw, 40px); }

.reserve-title {
    font-size: clamp(24px, 3vw, 32px);
    margin-bottom: 26px;
}

/* ---------- 12. 成员详情 ---------- */
.profile-hero {
    position: relative;
    isolation: isolate;
    padding: clamp(44px, 6vw, 76px) 0 clamp(28px, 4vw, 40px);
}

/* 页面级柔光：两团淡色，随期生色变化，与页面底色自然融合 */
.profile-hero::before {
    content: "";
    position: absolute;
    inset: -6% 0 -10%;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(46% 62% at 76% 30%, var(--gen-soft, var(--brand-soft)) 0%, transparent 72%),
        radial-gradient(38% 54% at 56% 88%, var(--ice-soft) 0%, transparent 74%);
    opacity: .9;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 340px);
    align-items: center;
    gap: clamp(32px, 5vw, 72px);
}

/* 立绘不套卡片：透明底直接落在页面上 */
.profile-avatar {
    position: relative;
}

.profile-avatar img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: contain;
    object-position: center bottom;
    /* 竖向 80% → 100% 渐隐，让人物与页面背景自然衔接 */
    -webkit-mask-image: linear-gradient(180deg, #000 80%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 80%, transparent 100%);
}

.profile-name {
    margin-top: 16px;
    font-size: clamp(38px, 5vw, 64px);
    line-height: 1.08;
    letter-spacing: -.03em;
}

.profile-role {
    margin-top: 12px;
    font-size: 15px;
    color: var(--gen, var(--brand));
    font-weight: 550;
    letter-spacing: .04em;
}

.profile-desc {
    max-width: 30em;
    margin-top: 20px;
    font-size: clamp(16px, 1.3vw, 18px);
    line-height: 1.85;
    color: var(--ink-2);
}

.profile-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}

.profile-body { padding-top: clamp(16px, 3vw, 28px); }

/* 每个区块两栏：左侧窄标题列，右侧内容列（所有内容块同宽，不会互相错位） */
.profile-section {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    column-gap: clamp(24px, 4vw, 56px);
    align-items: start;
    padding: clamp(28px, 4vw, 44px) 0;
    border-top: 1px solid var(--line);
}

.profile-section > :not(.profile-section-head) { grid-column: 2; }

.profile-section > .empty-note { grid-column: 1 / -1; }

.profile-section-head {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.profile-section-head h2 {
    font-size: clamp(20px, 2.4vw, 26px);
}

.profile-section-head .en {
    font-size: 12.5px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--ink-4);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.info-item {
    padding: 20px 22px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
}

.info-label {
    font-size: 12.5px;
    letter-spacing: .1em;
    color: var(--ink-4);
}

.info-value {
    margin-top: 6px;
    font-size: 17px;
    font-weight: 550;
    color: var(--ink);
}

.trait-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.trait-item {
    padding: 20px 22px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
}

.trait-label {
    font-size: 13px;
    letter-spacing: .08em;
    color: var(--gen, var(--brand));
    font-weight: 600;
}

.trait-value {
    margin-top: 6px;
    font-size: 15px;
    line-height: 1.8;
    color: var(--ink-2);
}

.intro-text {
    font-size: 15.5px;
    line-height: 2;
    color: var(--ink-2);
}

.intro-text p + p { margin-top: 14px; }

.qa-list {
    display: grid;
    gap: 14px;
}

.qa-item {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 16px;
    padding: 22px 24px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
}

.qa-number {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--gen-soft, var(--brand-soft));
    color: var(--gen, var(--brand));
    font-size: 14px;
    font-weight: 650;
}

.qa-title { font-size: 16.5px; font-weight: 600; }

.qa-content {
    margin-top: 6px;
    font-size: 14.5px;
    line-height: 1.85;
    color: var(--ink-3);
}

.profile-back {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 14px;
    padding-top: 28px;
    border-top: 1px solid var(--line);
}

/* ---------- 12.1 成员开场动画 ----------
   只有存在专属 logo 的成员页才启用：
   member-detail.php 在 <body> 后同步引入 js/member-intro.js，
   由脚本创建 .member-intro 遮罩；没有 JS 时不会出现，不影响正常浏览。

   节奏（三段，全部用 transition 驱动，便于和 JS 计时对齐）：
     1. .is-ready  大尺寸渐显，同时缩小到正常尺寸
     2. 停留      保持正常尺寸
     3. .is-out   继续缩小并渐隐，遮罩同步淡出，页面元素此时开始入场
   具体配色由成员主题文件覆盖，这里只提供通用结构与动效。
   遮罩从导航栏下沿开始（top: var(--nav-h)），navbar 全程可见、不参与开场。 */
.member-intro {
    position: fixed;
    top: var(--nav-h);
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;   /* 柔光放大时不越界盖到导航栏 */
    background: var(--bg);
    transition: opacity .65s var(--ease);
    will-change: opacity;
}

.member-intro.is-out {
    opacity: 0;
    pointer-events: none;
}

.member-intro-halo {
    position: absolute;
    width: 640px;
    height: 640px;
    border-radius: 50%;
    pointer-events: none;
    background: radial-gradient(closest-side, var(--brand-soft) 0%, transparent 72%);
    opacity: 0;
    transform: scale(.62);
    transition: opacity 1.2s ease-out, transform 1.5s var(--ease);
}

.member-intro.is-ready .member-intro-halo {
    opacity: .6;
    transform: scale(1);
}

.member-intro.is-out .member-intro-halo {
    opacity: 0;
    transform: scale(1.12);
    transition-duration: .6s, .7s;
}

.member-intro-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* 起始就是 1.45 倍并透明，is-ready 后边渐显边缩到 1 倍 */
.member-intro-logo {
    width: 260px;
    height: auto;
    max-width: 60vw;
    opacity: 0;
    transform: scale(1.45);
    transition: opacity .9s ease-out, transform .9s var(--ease);
    will-change: opacity, transform;
}

.member-intro.is-ready .member-intro-logo {
    opacity: 1;
    transform: scale(1);
}

.member-intro.is-out .member-intro-logo {
    opacity: 0;
    transform: scale(.82);
    transition-duration: .55s, .65s;
}

/* 用 margin 而不是 flex gap，兼容旧内核 */
.member-intro-thread {
    width: 128px;
    height: 1px;
    margin-top: 20px;
    background: linear-gradient(90deg, transparent, var(--brand), transparent);
    transform-origin: 50% 50%;
    opacity: 0;
    transform: scaleX(0);
    transition: opacity .5s ease-out, transform .8s var(--ease);
}

.member-intro.is-ready .member-intro-thread {
    opacity: .9;
    transform: scaleX(1);
    transition-delay: .55s, .55s;
}

.member-intro.is-out .member-intro-thread {
    opacity: 0;
    transform: scaleX(.55);
    transition-delay: 0s, 0s;
}

@media (max-width: 560px) {
    .member-intro-halo { width: 88vw; height: 88vw; }
    .member-intro-logo { width: 200px; }
}

@media (prefers-reduced-motion: reduce) {
    .member-intro { transition-duration: .2s; }
    .member-intro-logo,
    .member-intro.is-out .member-intro-logo,
    .member-intro-halo,
    .member-intro-thread { transition-duration: .01ms; }
    .member-intro.is-ready .member-intro-thread { transition-delay: 0s, 0s; }
}

/* ---------- 13. 关于我们 ---------- */
/* 社团理念：纯文字引用，不加卡片底与描边 */
.about-quote {
    padding: 0;
    text-align: center;
}

.about-quote blockquote {
    font-size: clamp(19px, 2.6vw, 26px);
    font-weight: 550;
    line-height: 1.7;
    letter-spacing: -.01em;
    color: var(--ink);
}

.about-quote cite {
    display: block;
    margin-top: 16px;
    font-size: 13.5px;
    font-style: normal;
    letter-spacing: .1em;
    color: var(--ink-4);
}

.value-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.value-card {
    padding: clamp(24px, 3vw, 34px);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
    transition: transform .35s var(--ease), box-shadow .35s var(--ease),
                border-color .35s var(--ease);
}

.value-card:hover {
    transform: translateY(-4px);
    border-color: var(--line-strong);
    box-shadow: var(--shadow-md);
}

.value-icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 20px;
    line-height: 1;
}

.value-card h3 {
    margin-top: 18px;
    font-size: 18px;
}

.value-card p {
    margin-top: 8px;
    font-size: 14.5px;
    line-height: 1.85;
    color: var(--ink-3);
}

.about-block {
    padding: clamp(26px, 3.4vw, 38px);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
}

/* 两栏：左侧窄标题列，右侧正文 */
.about-block-split {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: clamp(24px, 4vw, 56px);
    align-items: start;
}

.about-block-split .about-block-body { max-width: 860px; }
.about-block-split .about-block-body p { margin-top: 0; }
.about-block-split .about-block-body p + p { margin-top: 12px; }

.about-block h3 { font-size: 20px; }

.about-block p {
    margin-top: 10px;
    font-size: 15px;
    line-height: 1.9;
    color: var(--ink-2);
}

/* ---------- 14. 加入我们 ---------- */
.role-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.role-card {
    position: relative;
    overflow: hidden;
    padding: clamp(26px, 3.4vw, 38px);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
}

.role-card.is-featured {
    background:
        radial-gradient(110% 130% at 0% 0%, rgba(167, 139, 250, .24), transparent 62%),
        radial-gradient(110% 130% at 100% 100%, rgba(255, 200, 221, .20), transparent 62%),
        var(--surface);
    border-color: rgba(167, 139, 250, .32);
}

.role-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--r-pill);
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .08em;
}

.role-card h3 {
    margin-top: 16px;
    font-size: 22px;
}

.role-card p {
    margin-top: 10px;
    font-size: 14.5px;
    line-height: 1.85;
    color: var(--ink-3);
}

.check-list {
    display: grid;
    gap: 8px;
    margin-top: 18px;
    padding: 0;
    list-style: none;
}

.check-list li {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: 14.5px;
    line-height: 1.7;
    color: var(--ink-2);
}

.check-list li::before {
    content: "";
    flex: none;
    width: 6px;
    height: 6px;
    margin-top: 8px;
    border-radius: 50%;
    background: var(--brand-2);
}

.step-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    counter-reset: step;
}

.step {
    padding: 26px 24px;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
    counter-increment: step;
}

.step::before {
    content: "0" counter(step);
    display: block;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -.04em;
    color: transparent;
    -webkit-text-stroke: 1px var(--brand-2);
}

.step h3 {
    margin-top: 12px;
    font-size: 16.5px;
}

.step p {
    margin-top: 6px;
    font-size: 14px;
    line-height: 1.8;
    color: var(--ink-3);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.contact-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 22px 24px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
    transition: transform .3s var(--ease), border-color .3s var(--ease),
                box-shadow .3s var(--ease);
}

.contact-card:hover {
    transform: translateY(-3px);
    border-color: var(--brand-2);
    box-shadow: var(--shadow-md);
}

.contact-icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    flex: none;
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand);
}

.contact-value {
    font-size: 15px;
    font-weight: 550;
    color: var(--ink);
    overflow-wrap: anywhere;
}

.faq-list {
    display: grid;
    gap: 12px;
}

.faq-item {
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
    transition: border-color .3s var(--ease);
}

.faq-item[open] { border-color: var(--line-strong); }

.faq-item summary {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    font-size: 16px;
    font-weight: 550;
    color: var(--ink);
    cursor: pointer;
    list-style: none;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
    content: "";
    flex: none;
    width: 8px;
    height: 8px;
    margin-left: auto;
    border-right: 1.6px solid var(--ink-3);
    border-bottom: 1.6px solid var(--ink-3);
    transform: rotate(45deg) translateY(-2px);
    transition: transform .3s var(--ease);
}

.faq-item[open] summary::after {
    transform: rotate(-135deg) translateY(-2px);
}

.faq-answer {
    padding: 0 24px 20px;
    font-size: 14.5px;
    line-height: 1.9;
    color: var(--ink-3);
}

/* ---------- 15. 404 ---------- */
.error-page {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: clamp(360px, 58vh, 540px);
    padding: clamp(56px, 8vw, 104px) 0;
    text-align: center;
}

/* 与详情页一致的页面级柔光，避免 404 显得空 */
.error-page::before {
    content: "";
    position: absolute;
    inset: -8% 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(42% 58% at 50% 32%, var(--brand-soft) 0%, transparent 72%),
        radial-gradient(34% 48% at 62% 80%, var(--ice-soft) 0%, transparent 74%);
    opacity: .85;
}

.error-code {
    font-size: clamp(88px, 15vw, 156px);
    font-weight: 700;
    line-height: .9;
    letter-spacing: -.05em;
    background: linear-gradient(120deg, #6D28D9 0%, #8B5CF6 46%, #6FB9CC 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.error-title {
    margin-top: 22px;
    font-size: clamp(22px, 3vw, 30px);
}

.error-desc {
    max-width: 620px;
    margin: 18px auto 0;
    font-size: 16px;
    line-height: 1.95;
    color: var(--ink-2);
}

.error-page .hero-actions {
    margin-top: 40px;
    justify-content: center;
}

/* ---------- 15.1 时间线 ---------- */
.timeline-year {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 40px;
}

.timeline-year + .timeline-year { margin-top: clamp(40px, 5vw, 64px); }

/* 年份标签：与成员总览的期数同一种描边数字 */
.timeline-year-label {
    position: sticky;
    top: calc(var(--nav-h) + 28px);
    align-self: start;
    font-size: clamp(38px, 4.4vw, 54px);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -.04em;
    font-variant-numeric: tabular-nums;
    color: transparent;
    -webkit-text-stroke: 1.2px var(--line-strong);
    user-select: none;
}

.timeline-list {
    position: relative;
    margin: 0;
    padding: 2px 0 2px 32px;
    list-style: none;
}

/* 竖向主轴 */
.timeline-list::before {
    content: "";
    position: absolute;
    top: 24px;
    bottom: 25px;
    left: 5px;
    width: 1px;
    background: linear-gradient(180deg, var(--line-strong), var(--line) 66%, transparent);
}

.timeline-item { position: relative; }

/* 节点圆点：中心落在主轴上（列表左内边距 32px，主轴在 5px） */
.timeline-dot {
    position: absolute;
    top: 19px;
    left: -32px;
    width: 11px;
    height: 11px;
    border: 2px solid var(--brand-2);
    border-radius: 50%;
    background: var(--bg);
    transition: background-color .25s var(--ease), border-color .25s var(--ease),
                box-shadow .25s var(--ease);
}

.timeline-item:hover .timeline-dot {
    border-color: var(--brand);
    background: var(--brand);
    box-shadow: 0 0 0 4px var(--brand-soft);
}

.timeline-row {
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr) 16px;
    align-items: center;
    gap: 16px;
    padding: 11px 16px;
    border: 1px solid transparent;
    border-radius: var(--r-sm);
    transition: background-color .25s var(--ease), border-color .25s var(--ease),
                transform .25s var(--ease);
}

.timeline-row.is-plain { grid-template-columns: 62px minmax(0, 1fr); }

a.timeline-row:hover {
    background: var(--surface);
    border-color: var(--line);
    transform: translateX(2px);
}

.timeline-date {
    font-size: 13.5px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    letter-spacing: .05em;
    color: var(--ink-4);
}

.timeline-title {
    min-width: 0;
    font-size: 16.5px;
    font-weight: 550;
    line-height: 1.55;
    color: var(--ink);
    transition: color .25s var(--ease);
}

a.timeline-row:hover .timeline-title { color: var(--brand); }

.timeline-arrow {
    color: var(--ink-4);
    opacity: .45;
    transition: color .25s var(--ease), opacity .25s var(--ease),
                transform .25s var(--ease);
}

a.timeline-row:hover .timeline-arrow {
    color: var(--brand);
    opacity: 1;
    transform: translateX(3px);
}

/* 载入骨架：沿用成员卡的扫光 */
.timeline-skeleton { display: grid; gap: 14px; }

.timeline-skeleton-row {
    height: 52px;
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    background-color: var(--surface);
    background-image: linear-gradient(100deg, transparent 18%, var(--brand-soft) 50%, transparent 82%);
    background-size: 220% 100%;
    animation: skeleton-sweep 1.6s linear infinite;
}

/* ---------- 16. 滚动揭示（仅在 JS 就绪时启用） ---------- */
.js-reveal [data-reveal]:not(.member-card):not(.home-card) {
    opacity: 0;
    transform: translate3d(var(--reveal-x, 0px), var(--reveal-y, 24px), 0) scale(var(--reveal-scale, 1));
    transition: opacity var(--reveal-duration, .8s) var(--ease),
                transform var(--reveal-duration, .8s) var(--ease);
    transition-delay: var(--reveal-delay, 0s);
}

.js-reveal [data-reveal].is-revealed:not(.member-card):not(.home-card) {
    opacity: 1;
    transform: none;
}

/* 列表卡片：逐级从左侧下方飞出 */
.info-item[data-reveal],
.trait-item[data-reveal],
.qa-item[data-reveal] {
    --reveal-x: -18px;
    --reveal-y: 14px;
    --reveal-scale: .97;
    --reveal-duration: .62s;
}

/* ---------- 16.1 入场与载入动效 ---------- */
@keyframes enter-up {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: none; }
}

/* 首屏文案逐行上浮 */
.hero-copy > *,
.page-hero .container > *,
.profile-info > *,
.error-page .container > * {
    animation: enter-up .8s var(--ease) backwards;
}

.hero-copy > :nth-child(2),
.page-hero .container > :nth-child(2),
.profile-info > :nth-child(2),
.error-page .container > :nth-child(2) { animation-delay: .07s; }

.hero-copy > :nth-child(3),
.page-hero .container > :nth-child(3),
.profile-info > :nth-child(3),
.error-page .container > :nth-child(3) { animation-delay: .14s; }

.hero-copy > :nth-child(4),
.page-hero .container > :nth-child(4),
.profile-info > :nth-child(4),
.error-page .container > :nth-child(4) { animation-delay: .21s; }

.hero-copy > :nth-child(5),
.page-hero .container > :nth-child(5),
.profile-info > :nth-child(5),
.error-page .container > :nth-child(5) { animation-delay: .28s; }

.hero-copy > :nth-child(6),
.page-hero .container > :nth-child(6),
.profile-info > :nth-child(6),
.error-page .container > :nth-child(6) { animation-delay: .35s; }

.hero-visual,
.profile-avatar {
    animation: enter-up 1s var(--ease) .18s backwards;
}

/* 光晕缓慢呼吸 */
.hero-halo { animation: halo-breathe 9s ease-in-out infinite; }

@keyframes halo-breathe {
    0%, 100% { opacity: .82; transform: scale(1); }
    50%      { opacity: 1;   transform: scale(1.05); }
}

/* 成员卡：进入视口后错峰上浮（用 animation，避免覆盖 hover 位移） */
.js-reveal .member-card[data-reveal]:not(.is-revealed),
.js-reveal .home-card[data-reveal]:not(.is-revealed) {
    opacity: 0;
}

.js-reveal .member-card.is-revealed,
.js-reveal .home-card.is-revealed {
    animation: enter-up .55s var(--ease) backwards;
    animation-delay: var(--reveal-delay, 0s);
}

/* 成员列表载入骨架 */
.skeleton-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
}

.skeleton-card::before {
    content: "";
    display: block;
    aspect-ratio: 4 / 5;
    background: linear-gradient(100deg, transparent 18%, var(--brand-soft) 50%, transparent 82%);
    background-size: 220% 100%;
    animation: skeleton-sweep 1.6s linear infinite;
}

.skeleton-card::after {
    content: "";
    display: block;
    height: 58px;
    margin: 18px;
    border-radius: 10px;
    background: linear-gradient(100deg, transparent 18%, var(--brand-soft) 50%, transparent 82%);
    background-size: 220% 100%;
    animation: skeleton-sweep 1.6s linear infinite;
}

@keyframes skeleton-sweep {
    from { background-position: 180% 0; }
    to   { background-position: -80% 0; }
}

/* ---------- 16.2 旧内核降级（Chrome 62 / Android 5-8 等） ----------
   clamp()、min()/max()、inset、flex/grid 的 gap、aspect-ratio 在旧内核里
   要么整条声明失效（间距归零），要么被忽略（元素贴在一起）。
   这里给出一套固定值兜底；支持 aspect-ratio 的新内核完全跳过本段。 */
@supports not (aspect-ratio: 1 / 1) {
    /* 容器宽度：min() + margin-inline 都不可用 */
    .container,
    .nav-container,
    .footer-inner,
    .footer-bottom {
        width: calc(100% - 48px);
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
    }

    /* 纵向节奏 */
    .section { padding: 64px 0; }
    .empty-note { padding: 32px; }
    .section-head { margin: 0 auto 40px; }
    .section-title { font-size: 32px; }
    .home-hero { padding: 72px 0 56px; }
    .hero-inner { grid-gap: 44px; }
    .hero-title { font-size: 52px; }
    .hero-stats > * { margin: 0 32px 16px 0; }
    .home-cta { padding: 48px; }
    .home-cta h2 { font-size: 29px; }
    .page-hero { padding: 64px 0 36px; }
    .page-title { font-size: 44px; }
    .gen-section { margin-bottom: 60px; }
    .gen-index { font-size: 58px; }
    .gen-title { font-size: 26px; }
    .reserve-body { padding-top: 34px; }
    .reserve-title { font-size: 28px; }
    .profile-hero { padding: 60px 0 34px; }
    .profile-grid { grid-gap: 48px; }
    .profile-name { font-size: 50px; }
    .profile-desc { font-size: 17px; }
    .profile-body { padding-top: 22px; }
    .profile-section { padding: 36px 0; grid-column-gap: 40px; }
    .profile-section-head h2 { font-size: 23px; }
    .about-quote blockquote { font-size: 23px; }
    .value-card { padding: 29px; }
    .about-block { padding: 32px; }
    .about-block-split { grid-gap: 40px; }
    .role-card { padding: 32px; }
    .site-footer { margin-top: 72px; }
    .footer-inner { padding: 52px 0 34px; }
    .error-page { min-height: 460px; padding: 80px 0; }
    .error-code { font-size: 128px; }
    .error-title { font-size: 26px; }
    .timeline-year { grid-gap: 40px; }
    .timeline-year-label { font-size: 46px; }
    .timeline-row { grid-gap: 16px; }
    .timeline-skeleton { grid-gap: 14px; }

    /* 绝对定位的 inset 简写不可用，改为四边声明 */
    .site-atmosphere,
    .card-hit { top: 0; right: 0; bottom: 0; left: 0; }
    .hero-halo { top: -8%; right: -4%; bottom: -8%; left: -4%; }
    .profile-hero::before { top: -6%; right: 0; bottom: -10%; left: 0; }
    .error-page::before { top: -8%; right: 0; bottom: -8%; left: 0; }

    /* grid 的 gap 前缀写法 */
    .home-pages { grid-gap: 28px; }
    .home-page { grid-gap: 24px; }
    .member-grid { grid-gap: 26px; }
    .info-grid { grid-gap: 16px; }
    .trait-grid { grid-gap: 16px; }
    .qa-list { grid-gap: 14px; }
    .qa-item { grid-gap: 16px; }
    .value-grid { grid-gap: 22px; }
    .role-grid { grid-gap: 22px; }
    .step-list { grid-gap: 20px; }
    .check-list { grid-gap: 8px; }

    /* flex 的 gap 在旧内核无效，用外边距还原 */
    .nav-container > * + * { margin-left: 28px; }
    .nav-links > * + * { margin-left: 10px; }
    .nav-right > * + * { margin-left: 10px; }
    .hero-actions > * { margin: 0 14px 14px 0; }
    .footer-cols > * + * { margin-left: 64px; }
    .footer-col > * + * { margin-top: 10px; }
    .footer-col a .icon { margin-right: 8px; }
    .slot-actions > * { margin: 6px 10px 0; }
    .pager > * + * { margin-left: 10px; }
    .member-card-foot > * + * { margin-left: 12px; }
    .page-meta > * { margin: 0 10px 6px 0; }
    .gen-head > * + * { margin-left: 20px; }
    .profile-actions > * { margin: 0 12px 12px 0; }
    .profile-back > * { margin: 0 14px 14px 0; }
    .member-link-item .icon { margin-right: 8px; }
    .check-list li::before { margin-right: 9px; }
    .eyebrow .icon { margin-right: 8px; }
    .text-link .icon { margin-left: 6px; }
    .btn > svg + span { margin-left: 8px; }
    .home-card-body > * + *,
    .home-card-head > * + *,
    .member-card-body > * + *:not(.member-card-foot) { margin-top: 7px; }

    /* 无模糊支持时卡片用更实的底色 */
    .home-card { backdrop-filter: none; }

    @media (max-width: 1080px) {
        .hero-inner { grid-gap: 32px; }
    }

    @media (max-width: 900px) {
        .nav-container > * + * { margin-left: 16px; }
        .nav-links > * + * { margin: 4px 0 0; }
        .profile-grid { grid-gap: 28px; }
        .footer-inner { grid-gap: 32px; }
        .about-block-split { grid-gap: 14px; }
        .timeline-year { grid-gap: 18px; }
    }

    @media (max-width: 720px) {
        .member-grid { grid-gap: 18px; }
    }

    @media (max-width: 560px) {
        .home-pages { grid-gap: 16px; }
        .home-page { grid-gap: 12px; }
        .member-grid { grid-gap: 12px; }
        .hero-stats > * { margin: 0 20px 14px 0; }
        .home-card .member-desc,
        .member-card .member-desc { padding-top: 10px; }
        .timeline-row { grid-gap: 12px; }
    }
}

/* ---------- 17. 响应式 ---------- */
@media (max-width: 1080px) {
    .hero-inner { grid-template-columns: 1fr; }
    .home-hero::before { display: none; }
    .hero-copy { max-width: none; }
    .hero-visual { order: -1; min-height: 260px; }
    .hero-logo { max-height: 340px; }
    .hero-stats { margin-top: 34px; }

    .step-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .value-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    :root { --nav-h: 64px; }

    .nav-container { gap: 16px; }
    .nav-links {
        position: absolute;
        top: calc(100% + 10px);
        left: 24px;
        right: 24px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: var(--r-md);
        background: var(--surface-solid);
        box-shadow: var(--shadow-lg);
    }

    .navbar.is-open .nav-links { display: flex; }
    .nav-link { padding: 12px 16px; }
    .nav-toggle { display: inline-flex; }
    .nav-cta { display: none; }

    .footer-inner { grid-template-columns: 1fr; gap: 32px; }
    .footer-cols { justify-content: flex-start; }

    .home-page { grid-template-columns: 1fr; }

    .profile-grid { grid-template-columns: 1fr; gap: 28px; }
    /* 手机端：立绘移到信息上方（DOM 顺序保持 info → avatar，靠 order 反转） */
    .profile-avatar { order: -1; max-width: 300px; justify-self: center; }

    .profile-section { grid-template-columns: 1fr; row-gap: 16px; }
    .profile-section > :not(.profile-section-head) { grid-column: 1; }

    /* 基础设定在窄屏保持一行两个（560 断点不再降为单列） */
    .info-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .about-block-split { grid-template-columns: 1fr; gap: 14px; }
    .role-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }

    /* 时间线：年份标签从左侧列移到列表上方 */
    .timeline-year { grid-template-columns: 1fr; gap: 18px; }
    .timeline-year-label { position: static; font-size: 34px; }
}

@media (max-width: 720px) {
    .container,
    .nav-container,
    .footer-inner,
    .footer-bottom {
        width: calc(100% - 32px);
    }

    .home-card {
        grid-template-columns: 150px minmax(0, 1fr);
        min-height: 200px;
    }

    .home-card-body { padding: 18px 18px 16px; }
    .home-card-name { font-size: 19px; }

    .member-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; }
    .value-grid { grid-template-columns: 1fr; }
    .trait-grid { grid-template-columns: 1fr; }
    .step-list { grid-template-columns: 1fr; }
    .gen-head { flex-wrap: wrap; gap: 14px; }
    .gen-index { font-size: 42px; }
    .gen-count { margin-left: 0; }
    .reserve-hint { display: none; }

    .footer-bottom { flex-direction: column; align-items: flex-start; gap: 8px; }
}

@media (max-width: 560px) {
    .hero-actions .btn { flex: 1 1 auto; }
    .hero-stats { gap: 20px 28px; }

    /* 手机端成员卡：左上立绘（按原图 4:5）+ 右上期生/姓名/小标题 + 下半通栏一句话简介与操作 */
    .home-pages { gap: 16px; }
    .home-page { gap: 12px; }
    .member-grid { grid-template-columns: 1fr; gap: 12px; }

    .home-card,
    .member-card {
        position: relative;
        display: grid;
        grid-template-columns: 92px minmax(0, 1fr);
        min-height: 0;
        /* 左右统一 16px 内边距：立绘与下方文案同一条竖线 */
        padding: 0 16px;
    }

    .home-card-media,
    .member-card-media {
        grid-column: 1;
        grid-row: 1;
        aspect-ratio: 4 / 5;
        min-height: 0;
        border-radius: var(--r-lg) 0 0 0;
        overflow: hidden;
        /* 手机端立绘不再铺期生色渐变底 */
        background: none;
    }

    /* 右上：期生徽章 + 姓名 + 小标题 */
    .home-card-body,
    .member-card-body { display: contents; }

    .home-card-head {
        grid-column: 2;
        grid-row: 1;
        align-self: start;
        gap: 4px;
        padding: 14px 0 10px 16px;
    }

    .home-card-name,
    .member-name { font-size: 17.5px; }

    .home-card .member-role,
    .member-card .member-role { font-size: 12.5px; }

    /* 总览卡：徽章从图面移到右上，姓名贴顶、小标题贴底 */
    .member-card-media {
        position: static;
        overflow: visible;
    }

    .member-card-media img { border-radius: var(--r-lg) 0 0 0; }

    .member-card-media .gen-badge { top: 12px; left: calc(16px + 92px + 16px); }

    .member-card-top {
        grid-column: 2;
        grid-row: 1;
        align-self: start;
        padding: 48px 0 0 16px;
    }

    .member-card .member-role {
        grid-column: 2;
        grid-row: 1;
        align-self: end;
        padding: 0 0 10px 16px;
    }

    /* 下半通栏：一句话简介 + 查看档案（及平台入口） */
    .home-card .member-desc,
    .member-card .member-desc {
        grid-column: 1 / -1;
        grid-row: 2;
        padding: 10px 0 0;
        -webkit-line-clamp: 1;
        font-size: 13.5px;
        line-height: 1.6;
    }

    .home-card .text-link,
    .member-card-foot {
        grid-column: 1 / -1;
        grid-row: 3;
    }

    .home-card .text-link { margin: 8px 0 14px; padding-top: 0; }

    .member-card-foot {
        margin: 0;
        padding: 8px 0 14px;
        border-top: 0;
        gap: 8px;
    }

    .member-card-foot .text-link { font-size: 13.5px; }

    .home-card.is-empty { padding: 22px 18px; gap: 6px; }
    .home-card.is-empty .slot-mark { width: 44px; height: 44px; }
    .home-card.is-empty .slot-title { font-size: 15.5px; }

    .profile-actions .btn { flex: 1 1 auto; }
    .profile-actions .member-link-wrap { flex: 1 1 auto; }
    .profile-actions .member-link-wrap > .btn { width: 100%; }
    .qa-item { grid-template-columns: 1fr; gap: 10px; }
    .page-meta { gap: 8px; }

    .timeline-year-label { font-size: 30px; }
    .timeline-row { grid-template-columns: 54px minmax(0, 1fr) 16px; gap: 12px; padding: 10px 12px; }
    .timeline-row.is-plain { grid-template-columns: 54px minmax(0, 1fr); }
    .timeline-date { font-size: 12.5px; }
    .timeline-title { font-size: 15.5px; }
    .timeline-skeleton-row { height: 46px; }
}

/* ---------- 18. 动效偏好 ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    *,
    *::before,
    *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        animation-delay: 0s !important;
        transition-duration: .001ms !important;
    }

    .js-reveal [data-reveal] { opacity: 1; transform: none; }
}
