/* ==========================================================================
   crazying-dev.top · 个人主页样式表
   风格：现代极简 × 罗小黑国风水墨 × 二次元点缀
   配色：取自仓库 Color.md（玄墨/墨灰/青灰/黛青/竹青/月白/缟色/胭脂红）
   特性：浅色 + 深色（html[data-theme]）· PC 双栏 / 移动端 Hero + 卡片网格
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. 设计令牌（Design Tokens）
   -------------------------------------------------------------------------- */
:root {
    color-scheme: light;

    /* 国风色卡 */
    --c-xuan: #1A2423;   /* 玄墨 */
    --c-mo:   #546260;   /* 墨灰 */
    --c-qing: #96A9A7;   /* 青灰 */
    --c-dai:  #3A5F6B;   /* 黛青 */
    --c-zhu:  #579491;   /* 竹青 */
    --c-yue:  #D8E6E4;   /* 月白 */
    --c-gao:  #E8EEED;   /* 缟色 */
    --c-tian: #B4D2D8;   /* 天青 */
    --c-yan:  #B95757;   /* 胭脂红 */
    --c-cong: #72B88A;   /* 葱青 */
    --c-zhe:  #A06F4F;   /* 赭石 */

    /* 语义色 */
    --bg: #F1F5F4;
    --bg-2: #E8EEED;
    --surface: rgba(255, 255, 255, 0.86);
    --surface-2: rgba(255, 255, 255, 0.6);
    --surface-solid: #FFFFFF;
    --line: rgba(58, 95, 107, 0.14);
    --line-strong: rgba(58, 95, 107, 0.28);
    --fg: var(--c-xuan);
    --fg-2: var(--c-mo);
    --fg-3: var(--c-qing);
    --accent: #3A5F6B;
    --accent-2: #579491;
    --accent-fg: #FFFFFF;
    --hot: var(--c-yan);
    --ring: rgba(87, 148, 145, 0.32);
    --bg-photo-opacity: 0.16;

    /* 渐变（取自 Color.md 的经典渐变） */
    --grad-hero: linear-gradient(135deg, #2E4659 0%, #3A5F6B 36%, #579491 72%, #72B88A 100%);
    --grad-soft: linear-gradient(135deg, #3A5F6B 0%, #6A8C89 52%, #72B88A 100%);
    --grad-mist: linear-gradient(180deg, #E8EEED 0%, #D8E6E4 100%);
    --grad-line: linear-gradient(90deg, transparent, var(--line-strong), transparent);

    /* 阴影 */
    --shadow-xs: 0 1px 2px rgba(26, 36, 35, 0.05);
    --shadow-sm: 0 1px 2px rgba(26, 36, 35, 0.05), 0 3px 10px rgba(26, 36, 35, 0.05);
    --shadow-md: 0 6px 20px rgba(26, 36, 35, 0.08), 0 1px 3px rgba(26, 36, 35, 0.05);
    --shadow-lg: 0 22px 56px -16px rgba(26, 36, 35, 0.28);

    /* 尺寸与节奏 */
    --radius: 18px;
    --radius-sm: 12px;
    --radius-xs: 9px;
    --maxw: 1180px;
    --gap: 18px;
    --dur: 0.28s;
    --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
                 "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

html[data-theme="dark"] {
    color-scheme: dark;

    --bg: #0E1719;
    --bg-2: #13202330;
    --surface: rgba(23, 35, 36, 0.74);
    --surface-2: rgba(23, 35, 36, 0.5);
    --surface-solid: #162224;
    --line: rgba(180, 210, 216, 0.14);
    --line-strong: rgba(180, 210, 216, 0.3);
    --fg: #DDE9E8;
    --fg-2: #A6BBB9;
    --fg-3: #7B9392;
    --accent: #84A8B9;
    --accent-2: #72B88A;
    --accent-fg: #0E1719;
    --hot: #C97A7A;
    --ring: rgba(114, 184, 138, 0.36);
    --bg-photo-opacity: 0.12;

    --grad-hero: linear-gradient(135deg, #14282F 0%, #2E4659 42%, #3A5F6B 72%, #579491 100%);
    --grad-soft: linear-gradient(135deg, #315468 0%, #579491 55%, #72B88A 100%);
    --grad-mist: linear-gradient(180deg, #16292C 0%, #101C1E 100%);

    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.35);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35), 0 3px 12px rgba(0, 0, 0, 0.28);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.38), 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 24px 60px -18px rgba(0, 0, 0, 0.7);
}

/* --------------------------------------------------------------------------
   2. 基础重置
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.75;
    color: var(--fg);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

h1, h2, h3, h4, h5, h6 { margin: 0; font-weight: 600; line-height: 1.35; letter-spacing: -0.01em; }
p { margin: 0; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; transition: color var(--dur) var(--ease); }
a:hover { color: var(--hot); }
ul, ol { margin: 0; padding: 0; list-style: none; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
del { color: var(--fg-3); }

:focus-visible {
    outline: 2px solid var(--accent-2);
    outline-offset: 2px;
    border-radius: 4px;
}

::selection { background: rgba(87, 148, 145, 0.28); }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* 滚动条（灰青风） */
* { scrollbar-width: thin; scrollbar-color: rgba(150, 169, 167, 0.5) transparent; }
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: rgba(150, 169, 167, 0.42);
    border-radius: 999px;
    border: 2px solid transparent;
    background-clip: content-box;
}
::-webkit-scrollbar-thumb:hover { background: rgba(106, 140, 137, 0.7); background-clip: content-box; }

/* --------------------------------------------------------------------------
   3. 背景层（随机图 + 国风水墨晕染 + 淡淡网格）
   -------------------------------------------------------------------------- */
.bg-layer {
    position: fixed;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 0.8s var(--ease);
    filter: saturate(0.9) blur(0.2px);
}
.bg-layer--pc { display: block; }
.bg-layer--mobile { display: none; }

.bg-wash {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: var(--bg-photo-opacity);
    background: var(--grad-mist);
    transition: opacity var(--dur) var(--ease);
}

.bg-grain {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: 0.5;
    background-image:
        radial-gradient(circle at 12% 18%, rgba(87, 148, 145, 0.12), transparent 42%),
        radial-gradient(circle at 88% 8%, rgba(180, 210, 216, 0.16), transparent 38%),
        radial-gradient(circle at 70% 92%, rgba(185, 87, 87, 0.07), transparent 40%);
}

/* --------------------------------------------------------------------------
   4. 顶部导航
   -------------------------------------------------------------------------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: color-mix(in srgb, var(--bg) 78%, transparent);
    backdrop-filter: saturate(1.4) blur(16px);
    -webkit-backdrop-filter: saturate(1.4) blur(16px);
    border-bottom: 1px solid var(--line);
}

.site-header__inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 12px 22px;
    display: flex;
    align-items: center;
    gap: 18px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    color: var(--fg);
    flex-shrink: 0;
}
.brand:hover { color: var(--fg); }

.brand__avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid var(--line-strong);
    box-shadow: var(--shadow-xs);
    background: var(--surface-solid);
    transition: transform var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.brand:hover .brand__avatar { transform: rotate(-6deg) scale(1.06); border-color: var(--accent-2); }

.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-size: 16px; font-weight: 650; letter-spacing: 0.02em; }
.brand__sub {
    font-size: 11px;
    color: var(--fg-3);
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.nav {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-left: auto;
}

.nav__link {
    position: relative;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 14.5px;
    color: var(--fg-2);
    white-space: nowrap;
    transition: color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.nav__link:hover { color: var(--fg); background: var(--surface-2); }
.nav__link.is-active { color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.nav__link.is-active::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 2px;
    width: 16px;
    height: 2px;
    border-radius: 2px;
    background: var(--hot);
    transform: translateX(-50%);
}

.header-tools { display: flex; align-items: center; gap: 8px; }

.icon-btn {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--fg-2);
    transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease),
                background-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.icon-btn:hover { color: var(--accent); border-color: var(--line-strong); transform: translateY(-1px); }
.icon-btn svg { width: 18px; height: 18px; fill: currentColor; }

/* 主题切换按钮的双图标 */
.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; }

/* --------------------------------------------------------------------------
   5. 页面骨架
   -------------------------------------------------------------------------- */
.container {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 26px 22px 56px;
}

.layout {
    display: grid;
    grid-template-columns: 336px minmax(0, 1fr);
    gap: var(--gap);
    align-items: start;
}

.layout__side {
    display: flex;
    flex-direction: column;
    gap: var(--gap);
    position: sticky;
    top: 78px;
}

.layout__main { min-width: 0; }

/* 通用面板 */
.panel {
    background: var(--surface);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 18px;
    transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease),
                transform var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.panel--flush { padding: 0; overflow: hidden; }
.panel--hover:hover { border-color: var(--line-strong); box-shadow: var(--shadow-md); transform: translateY(-2px); }

.panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.panel__title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--fg-2);
}
.panel__title::before {
    content: "";
    width: 3px;
    height: 14px;
    border-radius: 2px;
    background: var(--grad-soft);
}
.panel__title-sub { font-size: 12px; color: var(--fg-3); font-weight: 400; letter-spacing: 0; }

/* 页面标题区 */
.page-head { margin-bottom: 22px; }
.page-head__title {
    font-size: clamp(22px, 3.4vw, 30px);
    font-weight: 700;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 10px;
}
.page-head__title::before {
    content: "";
    width: 6px;
    height: 22px;
    border-radius: 3px;
    background: var(--grad-soft);
}
.page-head__sub { margin-top: 6px; color: var(--fg-3); font-size: 14px; }

/* --------------------------------------------------------------------------
   6. Hero（移动端展示，PC 隐藏）
   -------------------------------------------------------------------------- */
.hero { display: none; }

/* --------------------------------------------------------------------------
   7. 主页 · 个人卡片
   -------------------------------------------------------------------------- */
.profile { text-align: center; }

.profile__avatar-wrap {
    position: relative;
    width: 116px;
    height: 116px;
    margin: 4px auto 14px;
}
.profile__avatar-wrap::before {
    content: "";
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: var(--grad-soft);
    opacity: 0.16;
    filter: blur(2px);
    animation: softSpin 18s linear infinite;
}
.profile__avatar-wrap::after {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 1px dashed var(--line-strong);
    animation: softSpin 26s linear infinite reverse;
}
.profile__avatar {
    position: relative;
    width: 116px;
    height: 116px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface-solid);
    border: 3px solid var(--surface-solid);
    box-shadow: var(--shadow-md);
    transition: transform var(--dur) var(--ease);
}
.profile__avatar-wrap:hover .profile__avatar { transform: scale(1.04); }

@keyframes softSpin { to { transform: rotate(360deg); } }

.profile__name {
    font-size: 21px;
    font-weight: 700;
    letter-spacing: 0.04em;
}
.profile__name span { color: var(--hot); }
.profile__handle { font-size: 12.5px; color: var(--fg-3); letter-spacing: 0.04em; }

.profile__bio {
    margin-top: 10px;
    font-size: 13.5px;
    color: var(--fg-2);
    line-height: 1.8;
}

.profile__status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 12.5px;
    color: var(--fg-2);
    background: var(--surface-2);
    border: 1px solid var(--line);
}
.profile__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--c-cong);
    box-shadow: 0 0 0 0 rgba(114, 184, 138, 0.6);
    animation: pulse 2.4s var(--ease) infinite;
}
@keyframes pulse {
    70% { box-shadow: 0 0 0 8px rgba(114, 184, 138, 0); }
    100% { box-shadow: 0 0 0 0 rgba(114, 184, 138, 0); }
}

/* 标签 / 徽章 */
.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    justify-content: center;
    margin-top: 14px;
}
.chip {
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    color: var(--fg-2);
    background: color-mix(in srgb, var(--accent) 8%, transparent);
    border: 1px solid var(--line);
    transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease),
                background-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.chip:hover { color: var(--accent); border-color: var(--line-strong); transform: translateY(-1px); }

/* 社交按钮 */
.socials {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 16px;
}
.social {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--fg-2);
    transition: all var(--dur) var(--ease);
}
.social:hover {
    color: var(--accent-fg);
    background: var(--grad-soft);
    border-color: transparent;
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.social svg { width: 20px; height: 20px; fill: currentColor; }
.social img { width: 20px; height: 20px; object-fit: contain; }
.social--wechat:hover svg { fill: var(--accent-fg); }

.profile__divider { height: 1px; background: var(--grad-line); margin: 16px 0; border: 0; }

/* --------------------------------------------------------------------------
   8. 音乐播放器
   -------------------------------------------------------------------------- */
.music__now {
    display: flex;
    align-items: center;
    gap: 14px;
}

.music__disc {
    position: relative;
    width: 58px;
    height: 58px;
    flex-shrink: 0;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--grad-soft);
    box-shadow: var(--shadow-sm);
    color: #fff;
    overflow: hidden;
}
.music__disc::after {
    content: "";
    position: absolute;
    inset: 30%;
    border-radius: 50%;
    background: var(--surface-solid);
    opacity: 0.9;
}
.music__disc svg {
    position: relative;
    z-index: 1;
    width: 20px;
    height: 20px;
    fill: currentColor;
    color: var(--accent);
}
.music.is-playing .music__disc { animation: softSpin 6s linear infinite; }

.music__meta { min-width: 0; flex: 1; }
.music__title {
    font-size: 14.5px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.music__artist {
    font-size: 12px;
    color: var(--fg-3);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 进度条 */
.music__progress {
    position: relative;
    height: 5px;
    margin: 14px 0 6px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 14%, transparent);
    cursor: pointer;
}
.music__bar {
    position: absolute;
    inset: 0 auto 0 0;
    width: 0;
    border-radius: 999px;
    background: var(--grad-soft);
}
.music__bar::after {
    content: "";
    position: absolute;
    right: -4px;
    top: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--surface-solid);
    border: 2px solid var(--accent-2);
    transform: translateY(-50%) scale(0);
    transition: transform var(--dur) var(--ease);
}
.music__progress:hover .music__bar::after { transform: translateY(-50%) scale(1); }
.music__time {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--fg-3);
    font-variant-numeric: tabular-nums;
}

/* 控制按钮 */
.music__controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 12px;
}
.music__btn {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--fg-2);
    transition: all var(--dur) var(--ease);
}
.music__btn:hover { color: var(--accent); background: var(--surface-2); }
.music__btn svg { width: 17px; height: 17px; fill: currentColor; }
.music__btn--main {
    width: 46px;
    height: 46px;
    background: var(--grad-soft);
    color: #fff;
    box-shadow: var(--shadow-md);
}
.music__btn--main:hover { color: #fff; transform: scale(1.06); background: var(--grad-soft); }
.music__btn--main svg { width: 20px; height: 20px; }
.music__btn.is-active { color: var(--hot); }

/* 音量 */
.music__volume {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-top: 12px;
    color: var(--fg-3);
}
.music__volume svg { width: 15px; height: 15px; fill: currentColor; flex-shrink: 0; }
.music__volume input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    flex: 1;
    height: 4px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 16%, transparent);
    outline: none;
}
.music__volume input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-2);
    border: 2px solid var(--surface-solid);
    box-shadow: var(--shadow-xs);
    cursor: pointer;
}
.music__volume input[type="range"]::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border: 2px solid var(--surface-solid);
    border-radius: 50%;
    background: var(--accent-2);
    cursor: pointer;
}

/* 播放列表 */
.playlist {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.42s var(--ease);
}
.playlist.is-open { max-height: 320px; }
.playlist__inner {
    max-height: 300px;
    overflow-y: auto;
    padding-right: 4px;
    margin-top: 12px;
    border-top: 1px solid var(--line);
}
.playlist__item {
    display: flex;
    align-items: center;
    gap: 9px;
    width: 100%;
    padding: 8px 10px;
    border-radius: var(--radius-xs);
    font-size: 13px;
    color: var(--fg-2);
    text-align: left;
    transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.playlist__item:hover { background: var(--surface-2); color: var(--fg); }
.playlist__item.is-current { color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.playlist__no {
    width: 20px;
    flex-shrink: 0;
    font-size: 11px;
    color: var(--fg-3);
    font-variant-numeric: tabular-nums;
    text-align: center;
}
.playlist__item.is-current .playlist__no { color: var(--hot); }
.playlist__name { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* --------------------------------------------------------------------------
   9. 日历
   -------------------------------------------------------------------------- */
.calendar__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.calendar__title {
    font-size: 15px;
    font-weight: 650;
    letter-spacing: 0.04em;
    font-variant-numeric: tabular-nums;
}
.calendar__title small { color: var(--fg-3); font-weight: 400; font-size: 12px; margin-left: 6px; letter-spacing: 0; }
.calendar__nav {
    display: flex;
    gap: 4px;
}
.calendar__btn {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-xs);
    color: var(--fg-2);
    background: var(--surface-2);
    border: 1px solid var(--line);
    font-size: 13px;
    line-height: 1;
    transition: all var(--dur) var(--ease);
}
.calendar__btn:hover { color: var(--accent); border-color: var(--line-strong); background: var(--surface-solid); }
.calendar__grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
}
.calendar__dow {
    padding: 4px 0;
    text-align: center;
    font-size: 11px;
    color: var(--fg-3);
    letter-spacing: 0.04em;
}
.calendar__dow:first-child, .calendar__dow:last-child { color: var(--hot); opacity: 0.72; }
.calendar__day {
    position: relative;
    padding: 6px 0;
    text-align: center;
    font-size: 12.5px;
    color: var(--fg-2);
    border-radius: 8px;
    font-variant-numeric: tabular-nums;
    transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.calendar__day:not(:empty):hover { background: var(--surface-2); }
.calendar__day.is-empty { pointer-events: none; }
.calendar__day.is-today {
    color: #fff;
    font-weight: 650;
    background: var(--grad-soft);
    box-shadow: 0 2px 8px -1px rgba(58, 95, 107, 0.4);
}
.calendar__day.is-weekend:not(.is-today) { color: var(--hot); opacity: 0.85; }

/* --------------------------------------------------------------------------
   10. 作品列表
   -------------------------------------------------------------------------- */
.works {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 340px;
    overflow-y: auto;
    padding-right: 4px;
}
.work {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 11px;
    border-radius: var(--radius-sm);
    background: var(--surface-2);
    border: 1px solid var(--line);
    transition: all var(--dur) var(--ease);
}
.work:hover {
    border-color: var(--line-strong);
    background: var(--surface-solid);
    transform: translateX(2px);
    box-shadow: var(--shadow-sm);
}
.work__main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.work__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
    background: var(--fg-3);
}
.work__dot.is-running { background: var(--c-cong); box-shadow: 0 0 0 3px rgba(114, 184, 138, 0.16); }
.work__link { color: var(--fg); min-width: 0; flex: 1; }
.work__link:hover { color: var(--accent); }
.work__name {
    display: block;
    font-size: 13.5px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.work__badge {
    flex-shrink: 0;
    padding: 1px 7px;
    border-radius: 999px;
    font-size: 10.5px;
    letter-spacing: 0.04em;
    color: var(--fg-3);
    border: 1px solid var(--line);
}
.work__badge.is-running { color: var(--c-cong); border-color: rgba(114, 184, 138, 0.4); }
.work__actions { display: flex; gap: 5px; flex-shrink: 0; }

/* 作品列表放到独立页面时不需要限高滚动 */
.works--page { max-height: none; overflow-y: visible; gap: 10px; padding-right: 0; }

/* 通用按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 500;
    border: 1px solid var(--line-strong);
    color: var(--fg-2);
    background: var(--surface-solid);
    transition: all var(--dur) var(--ease);
}
.btn:hover:not(:disabled) { color: var(--accent); border-color: var(--accent-2); transform: translateY(-1px); }
.btn--primary {
    color: var(--accent-fg);
    background: var(--grad-soft);
    border-color: transparent;
}
.btn--primary:hover:not(:disabled) { color: var(--accent-fg); box-shadow: var(--shadow-md); }
.btn:disabled, .btn.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none !important;
}
.btn--wide { width: 100%; padding: 11px 16px; border-radius: var(--radius-sm); font-size: 14px; }

/* ‘更多’小按钮 */
.btn-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: var(--accent);
}
.btn-link:hover { color: var(--hot); }

/* --------------------------------------------------------------------------
   11. 文章列表
   -------------------------------------------------------------------------- */
.posts { display: flex; flex-direction: column; gap: 12px; }

.post {
    position: relative;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--surface);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow-xs);
    overflow: hidden;
    transition: all var(--dur) var(--ease);
}
.post::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--grad-soft);
    opacity: 0;
    transition: opacity var(--dur) var(--ease);
}
.post:hover { border-color: var(--line-strong); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.post:hover::before { opacity: 1; }

.post__link {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
    color: inherit;
}
.post__link:hover { color: inherit; }
.post__body { flex: 1; min-width: 0; }
.post__title {
    font-size: 17px;
    font-weight: 650;
    color: var(--fg);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color var(--dur) var(--ease);
}
.post:hover .post__title { color: var(--accent); }
.post__excerpt {
    margin-top: 5px;
    font-size: 13.5px;
    color: var(--fg-2);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.post__more {
    margin-top: 9px;
    font-size: 12.5px;
    color: var(--fg-3);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color var(--dur) var(--ease), gap var(--dur) var(--ease);
}
.post:hover .post__more { color: var(--accent); gap: 8px; }
.post__thumb {
    width: 108px;
    height: 76px;
    flex-shrink: 0;
    border-radius: var(--radius-sm);
    object-fit: cover;
    background: var(--surface-2);
    border: 1px solid var(--line);
}

/* 空 / 加载状态 */
.state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 34px 18px;
    text-align: center;
    color: var(--fg-3);
    font-size: 13.5px;
}
.state__icon { font-size: 26px; opacity: 0.75; }

/* 骨架屏 */
.skeleton {
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--surface);
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.sk-line {
    height: 11px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--line) 25%, var(--line-strong) 37%, var(--line) 63%);
    background-size: 400% 100%;
    animation: sk 1.5s var(--ease) infinite;
}
.sk-line + .sk-line { margin-top: 9px; }
.sk-block { width: 108px; height: 76px; border-radius: var(--radius-sm); flex-shrink: 0; }
@keyframes sk { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

/* --------------------------------------------------------------------------
   12. 移动端 Hero（<980px 显示）
   -------------------------------------------------------------------------- */
.hero__card {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--grad-hero);
    color: #fff;
    padding: 26px 22px 22px;
    box-shadow: var(--shadow-md);
}
.hero__card::after {
    content: "";
    position: absolute;
    right: -46px;
    top: -46px;
    width: 168px;
    height: 168px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
}
.hero__card::before {
    content: "";
    position: absolute;
    right: 26px;
    bottom: -60px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
}
.hero__main { position: relative; display: flex; align-items: center; gap: 16px; }
.hero__avatar {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    object-fit: cover;
    border: 2.5px solid rgba(255, 255, 255, 0.55);
    background: var(--surface-solid);
    flex-shrink: 0;
}
.hero__name { font-size: 22px; font-weight: 700; letter-spacing: 0.04em; }
.hero__tagline { margin-top: 3px; font-size: 13px; color: rgba(255, 255, 255, 0.82); }
.hero__chips { margin-top: 14px; position: relative; }
.hero__chips .chip {
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.22);
}
.hero__chips .chip:hover { color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.hero__socials { margin-top: 16px; position: relative; justify-content: flex-start; }
.hero__socials .social {
    width: 38px;
    height: 38px;
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.22);
}
.hero__socials .social:hover { background: #fff; color: var(--accent); border-color: transparent; }
.hero__socials .social--wechat:hover svg { fill: var(--accent); }

/* --------------------------------------------------------------------------
   13. 页脚
   -------------------------------------------------------------------------- */
.site-footer {
    margin-top: 26px;
    border-top: 1px solid var(--line);
    background: color-mix(in srgb, var(--bg) 72%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}
.site-footer__inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 34px 22px 26px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 26px;
}
.footer-col__title {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--fg-3);
    margin-bottom: 12px;
}
.footer-col p, .footer-col li { font-size: 13px; color: var(--fg-2); line-height: 2; }
.footer-col a { color: var(--fg-2); }
.footer-col a:hover { color: var(--accent); }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.footer-brand img { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); }
.footer-brand strong { font-size: 15px; }
.footer-time {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: 12px;
    color: var(--fg-2);
    background: var(--surface-2);
    border: 1px solid var(--line);
    font-variant-numeric: tabular-nums;
}
.footer-bottom {
    margin-top: 26px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    font-size: 12.5px;
    color: var(--fg-3);
}
.footer-bottom a { color: var(--fg-3); }
.footer-bottom a:hover { color: var(--accent); }
.footer-bottom__links { display: flex; flex-wrap: wrap; gap: 14px; }

.back-top {
    position: fixed;
    right: 22px;
    bottom: 24px;
    z-index: 50;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--fg-2);
    background: var(--surface-solid);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--dur) var(--ease);
}
.back-top.is-show { opacity: 1; visibility: visible; transform: none; }
.back-top:hover { color: var(--accent); transform: translateY(-3px); }
.back-top svg { width: 18px; height: 18px; fill: currentColor; }

/* --------------------------------------------------------------------------
   14. 子页面 · 关于我
   -------------------------------------------------------------------------- */
.about {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    gap: var(--gap);
    align-items: start;
}

.about__toc {
    position: sticky;
    top: 78px;
    padding: 16px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--surface);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow-xs);
}
.about__toc-title {
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--fg-3);
    margin-bottom: 10px;
}
.about__toc a {
    display: block;
    padding: 6px 10px;
    border-radius: var(--radius-xs);
    font-size: 13.5px;
    color: var(--fg-2);
    border-left: 2px solid transparent;
    transition: all var(--dur) var(--ease);
}
.about__toc a:hover { color: var(--accent); background: var(--surface-2); border-left-color: var(--accent-2); }
.about__toc a.is-active { color: var(--accent); background: color-mix(in srgb, var(--accent) 9%, transparent); border-left-color: var(--hot); }

.about__body { display: flex; flex-direction: column; gap: var(--gap); }

.about__section { scroll-margin-top: 84px; }
.about__section > h2 {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 17px;
    margin-bottom: 12px;
}
.about__section > h2::before {
    content: "";
    width: 5px;
    height: 18px;
    border-radius: 3px;
    background: var(--grad-soft);
    flex-shrink: 0;
}
.about__section h3 {
    font-size: 14.5px;
    color: var(--accent);
    margin: 14px 0 6px;
    font-weight: 600;
}
.about__section p { font-size: 14px; color: var(--fg-2); line-height: 1.9; }
.about__section p + p { margin-top: 4px; }

/* 信息行（key-value） */
.about__rows { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; }
.about__row {
    display: flex;
    gap: 10px;
    padding: 8px 12px;
    border-radius: var(--radius-xs);
    font-size: 14px;
    color: var(--fg-2);
    transition: background-color var(--dur) var(--ease);
}
.about__row:hover { background: var(--surface-2); }
.about__row-key {
    flex-shrink: 0;
    width: 88px;
    color: var(--fg-3);
    font-size: 13px;
}
.about__row-val { flex: 1; min-width: 0; word-break: break-word; }
.about__row-val a { border-bottom: 1px dashed var(--line-strong); }

/* 可展开内容 */
.about__more {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.42s var(--ease), opacity var(--dur) var(--ease), margin-top var(--dur) var(--ease);
}
.about__more.is-open { max-height: 640px; opacity: 1; margin-top: 8px; }
.about__more p {
    font-size: 13.5px;
    color: var(--fg-2);
    padding-left: 14px;
    position: relative;
    line-height: 1.9;
}
.about__more p::before {
    content: "·";
    position: absolute;
    left: 4px;
    color: var(--hot);
    font-weight: 700;
}

.about__note { border-left: 3px solid var(--hot); }
.about__note h4 { font-size: 13px; color: var(--hot); letter-spacing: 0.08em; margin-bottom: 6px; }

/* --------------------------------------------------------------------------
   15. 子页面 · 联系我
   -------------------------------------------------------------------------- */
.contact {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: var(--gap);
    align-items: start;
}

.contact__list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }

.contact-card {
    display: flex;
    align-items: center;
    gap: 11px;
    width: 100%;
    padding: 13px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    background: var(--surface-2);
    text-align: left;
    transition: all var(--dur) var(--ease);
}
.contact-card:hover {
    border-color: var(--line-strong);
    background: var(--surface-solid);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}
.contact-card__icon {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
    border-radius: var(--radius-xs);
    background: color-mix(in srgb, var(--accent) 11%, transparent);
    color: var(--accent);
}
.contact-card__icon svg { width: 19px; height: 19px; fill: currentColor; }
.contact-card__icon img { width: 19px; height: 19px; object-fit: contain; }
.contact-card__body { min-width: 0; }
.contact-card__name { font-size: 12px; color: var(--fg-3); letter-spacing: 0.04em; }
.contact-card__value {
    font-size: 13.5px;
    color: var(--fg);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 表单 */
.form { display: flex; flex-direction: column; gap: 4px; }
.form__label {
    margin-top: 10px;
    font-size: 12.5px;
    color: var(--fg-3);
    letter-spacing: 0.04em;
}
.form__input, .form__textarea, .form__select {
    width: 100%;
    padding: 10px 13px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--line);
    background: var(--surface-solid);
    font-size: 14px;
    color: var(--fg);
    transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.form__textarea { min-height: 108px; resize: vertical; line-height: 1.7; }
.form__input::placeholder, .form__textarea::placeholder { color: var(--fg-3); opacity: 0.8; }
.form__input:focus, .form__textarea:focus, .form__select:focus {
    outline: none;
    border-color: var(--accent-2);
    box-shadow: 0 0 0 3px var(--ring);
}
.form__submit { margin-top: 14px; }
.form__tip { min-height: 20px; margin-top: 9px; font-size: 12.5px; color: var(--fg-3); }
.form__tip.is-ok { color: var(--c-cong); }
.form__tip.is-err { color: var(--hot); }

.contact__tips { display: flex; flex-direction: column; gap: 7px; }
.contact__tips p {
    position: relative;
    padding-left: 16px;
    font-size: 13px;
    color: var(--fg-2);
    line-height: 1.8;
}
.contact__tips p::before {
    content: "";
    position: absolute;
    left: 3px;
    top: 11px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent-2);
}

/* --------------------------------------------------------------------------
   16. 子页面 · 友人
   -------------------------------------------------------------------------- */
.friends { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 14px; }

.friend {
    display: flex;
    gap: 13px;
    padding: 15px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--surface);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow-xs);
    transition: all var(--dur) var(--ease);
}
.friend:hover { border-color: var(--line-strong); box-shadow: var(--shadow-md); transform: translateY(-3px); }
.friend__avatar {
    width: 52px;
    height: 52px;
    flex-shrink: 0;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface-2);
    border: 2px solid var(--surface-solid);
    box-shadow: var(--shadow-xs);
}
.friend__body { min-width: 0; flex: 1; }
.friend__name { font-size: 15px; font-weight: 600; }
.friend__about {
    margin-top: 2px;
    font-size: 12.5px;
    color: var(--fg-2);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.friend__link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    font-size: 12.5px;
    color: var(--accent);
}
.friend__link:hover { color: var(--hot); gap: 8px; }

/* --------------------------------------------------------------------------
   17. 子页面 · 隐私 / 长文排版
   -------------------------------------------------------------------------- */
.prose { max-width: 780px; }
.prose h2 {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 16px;
    margin: 26px 0 10px;
    padding-left: 12px;
    border-left: 3px solid var(--accent-2);
}
.prose h2:first-child { margin-top: 0; }
.prose p { font-size: 14px; color: var(--fg-2); line-height: 1.95; }
.prose ul { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.prose li {
    position: relative;
    padding-left: 18px;
    font-size: 14px;
    color: var(--fg-2);
    line-height: 1.9;
}
.prose li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 12px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent-2);
}
.prose__last { margin-top: 26px; font-size: 12.5px; color: var(--fg-3); }

/* --------------------------------------------------------------------------
   18. 文章页
   -------------------------------------------------------------------------- */
.article { max-width: 780px; margin: 0 auto; }
.article__title {
    font-size: clamp(23px, 4vw, 33px);
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: -0.02em;
    margin-bottom: 18px;
}
.article__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
    position: relative;
}
.article__meta::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 64px;
    height: 2px;
    border-radius: 2px;
    background: var(--grad-soft);
}
.article__avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface-2);
    border: 1px solid var(--line);
}
.article__author { font-size: 13.5px; font-weight: 600; }
.article__date { font-size: 12.5px; color: var(--fg-3); }
.article__sep { color: var(--line-strong); }

.article__body { margin-top: 26px; font-size: 15.5px; line-height: 1.95; color: var(--fg); }
.article__body > * + * { margin-top: 18px; }
.article__body h2 { font-size: 21px; margin-top: 34px; }
.article__body h3 { font-size: 17.5px; margin-top: 28px; }
.article__body h4, .article__body h5, .article__body h6 { font-size: 15.5px; margin-top: 24px; }
.article__body a { border-bottom: 1px solid var(--ring); }
.article__body img { border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); margin: 6px auto; }
.article__body blockquote {
    margin: 0;
    padding: 12px 18px;
    border-left: 3px solid var(--accent-2);
    border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
    background: var(--surface-2);
    color: var(--fg-2);
}
.article__body code {
    padding: 2px 6px;
    border-radius: 6px;
    font-family: var(--font-mono);
    font-size: 0.88em;
    background: color-mix(in srgb, var(--accent) 12%, transparent);
    color: var(--accent);
}
.article__body pre {
    padding: 16px 18px;
    border-radius: var(--radius-sm);
    overflow-x: auto;
    background: var(--surface-solid);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}
.article__body pre code { padding: 0; background: none; color: var(--fg); font-size: 13px; line-height: 1.7; }
.article__body ul, .article__body ol { padding-left: 22px; list-style: revert; display: flex; flex-direction: column; gap: 6px; }
.article__body li { font-size: 15px; color: var(--fg-2); }
.article__body ol { list-style: decimal; }
.article__body hr { margin: 30px 0; }

/* --------------------------------------------------------------------------
   19. 404 页
   -------------------------------------------------------------------------- */
.notfound {
    min-height: 52vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
}
.notfound__code {
    font-size: clamp(76px, 18vw, 148px);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    background: var(--grad-soft);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: drop-shadow(0 6px 18px rgba(58, 95, 107, 0.22));
}
.notfound__cn {
    display: flex;
    gap: 4px;
    font-size: clamp(18px, 4vw, 26px);
    font-weight: 650;
    letter-spacing: 0.1em;
}
.notfound__cn span {
    opacity: 0;
    transform: translateY(-10px);
    animation: dropIn 0.4s var(--ease) forwards;
}
@keyframes dropIn { to { opacity: 1; transform: none; } }
.notfound__desc { font-size: 14px; color: var(--fg-3); max-width: 420px; }
.notfound__actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 12px; }

/* --------------------------------------------------------------------------
   20. 弹窗（PageWindow）
   -------------------------------------------------------------------------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal.is-open { display: flex; }
.modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(14, 23, 25, 0.42);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: fadeIn var(--dur) var(--ease);
}
@keyframes fadeIn { from { opacity: 0; } }
.modal__box {
    position: relative;
    width: 100%;
    max-width: 440px;
    max-height: 86vh;
    overflow-y: auto;
    padding: 24px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--surface-solid);
    box-shadow: var(--shadow-lg);
    animation: boxIn 0.32s var(--ease);
}
@keyframes boxIn {
    from { opacity: 0; transform: translateY(14px) scale(0.98); }
}
.modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-size: 17px;
    line-height: 1;
    color: var(--fg-3);
    transition: all var(--dur) var(--ease);
}
.modal__close:hover { color: var(--fg); background: var(--surface-2); }
.modal__title {
    font-size: 18px;
    font-weight: 650;
    margin-bottom: 6px;
    padding-right: 28px;
}
.modal__desc { font-size: 13px; color: var(--fg-3); }
.modal__label { margin-top: 14px; font-size: 12.5px; color: var(--fg-3); }
.modal__code {
    margin-top: 12px;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 14.5px;
    letter-spacing: 0.06em;
    word-break: break-all;
    background: var(--surface-2);
    border: 1px dashed var(--line-strong);
    text-align: center;
}
.modal__actions { display: flex; gap: 9px; margin-top: 16px; }
.modal__actions .btn { flex: 1; }
.modal__img { width: 100%; max-width: 260px; margin: 0 auto; border-radius: var(--radius-sm); }

/* --------------------------------------------------------------------------
   21. 提示气泡（原 .card[from] 机制）
   -------------------------------------------------------------------------- */
.hint-bubble {
    position: fixed;
    z-index: 90;
    max-width: min(260px, 70vw);
    margin: 14px 0 0 14px;
    padding: 7px 12px;
    border-radius: var(--radius-xs);
    font-size: 12.5px;
    line-height: 1.6;
    color: var(--fg);
    background: var(--surface-solid);
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow-md);
    pointer-events: none;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}
.hint-bubble.is-visible { opacity: 1; transform: none; }
.hint-bubble img { max-width: 180px; border-radius: var(--radius-xs); }

/* --------------------------------------------------------------------------
   22. 进场动效 & 工具类
   -------------------------------------------------------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }

.text-center { text-align: center; }
.mt-0 { margin-top: 0 !important; }
.mt-2 { margin-top: 8px !important; }
.mt-3 { margin-top: 14px !important; }
.mt-4 { margin-top: 20px !important; }
.hide { display: none !important; }

/* --------------------------------------------------------------------------
   23. 响应式
   -------------------------------------------------------------------------- */
@media (max-width: 1080px) {
    .layout { grid-template-columns: 306px minmax(0, 1fr); }
}

/* 移动端：Hero + 卡片网格 */
@media (max-width: 980px) {
    .layout { display: flex; flex-direction: column; gap: var(--gap); }
    .layout__side {
        order: 1;
        position: static;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }
    .layout__main {
        order: 2;
        display: flex;
        flex-direction: column;
        gap: var(--gap);
    }

    /* 移动端顶部已有 Hero 卡，就不重复展示个人卡了 */
    #SideProfile { display: none; }

    .hero { display: block; margin-bottom: 20px; }

    .contact { grid-template-columns: 1fr; }
    .about { grid-template-columns: 1fr; }
    .about__toc { position: static; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 12px; }
    .about__toc-title { width: 100%; margin-bottom: 4px; }
    .about__toc a { padding: 4px 10px; border-radius: 999px; border-left: 0; border: 1px solid var(--line); }
    .about__toc a.is-active { border-left: 0; border-color: var(--accent-2); }

    .footer-grid { grid-template-columns: 1fr 1fr; gap: 20px; }
}

@media (max-width: 760px) {
    .container { padding: 18px 15px 42px; }
    .site-header__inner { padding: 10px 15px; gap: 10px; }

    /* 导航折叠 */
    .nav-toggle { display: grid; }
    .nav {
        position: fixed;
        top: 59px;
        left: 0;
        right: 0;
        margin: 0;
        padding: 10px 15px 16px;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        background: color-mix(in srgb, var(--bg) 96%, transparent);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: all var(--dur) var(--ease);
    }
    .nav.is-open { opacity: 1; visibility: visible; transform: none; }
    .nav__link { padding: 11px 14px; border-radius: var(--radius-xs); font-size: 15px; }
    .nav__link.is-active::after { display: none; }

    .panel { padding: 15px; }
    .post__thumb { width: 84px; height: 62px; }
    .post__title { font-size: 15.5px; }
    .contact__list { grid-template-columns: 1fr; }
    .friends { grid-template-columns: 1fr; }
    .article__body { font-size: 15px; }
    .back-top { right: 14px; bottom: 16px; }
}

@media (max-width: 520px) {
    .footer-grid { grid-template-columns: 1fr; gap: 18px; }
    .hero__card { padding: 20px 16px 18px; }
    .hero__avatar { width: 62px; height: 62px; }
    .hero__name { font-size: 19px; }
    .post__thumb { display: none; }
    .panel__title { font-size: 13px; }
}

/* 桌面显示 PC 背景，移动显示竖屏背景 */
@media (max-width: 700px) {
    .bg-layer--pc { display: none; }
    .bg-layer--mobile { display: block; }
    /* 小屏：卡片网格也收成单列 */
    .layout__side { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   24. 无障碍 / 降级
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
    .reveal { opacity: 1; transform: none; }
}

/* color-mix 降级（老浏览器） */
@supports not (background: color-mix(in srgb, red 50%, blue)) {
    .site-header, .site-footer { background: var(--surface-solid); }
}

/* --------------------------------------------------------------------------
   25. 网站状态统计图（数据源：yjlt.top /api/status-log）
   -------------------------------------------------------------------------- */
/* 桌面端主栏是普通块级容器，相邻面板之间得自己留白
   （≤980px 时主栏变成 flex + gap，就不重复了） */
@media (min-width: 981px) {
    .layout__main > .panel + .panel { margin-top: var(--gap); }
}

.status {
    /* 状态分类配色：2xx 葱青 / 3xx 天青 / 4xx 琥珀 / 5xx 胭脂红 */
    --st-2xx: #72B88A;
    --st-3xx: #6EA8C7;
    --st-4xx: #D8A657;
    --st-5xx: #B95757;
    --st-other: #96A9A7;
    --st-grid: rgba(58, 95, 107, 0.16);
    --st-axis: rgba(58, 95, 107, 0.34);
}

html[data-theme="dark"] .status {
    --st-2xx: #8FD3A4;
    --st-3xx: #8CC3E0;
    --st-4xx: #EBC078;
    --st-5xx: #D98A8A;
    --st-other: #7B9392;
    --st-grid: rgba(180, 210, 216, 0.14);
    --st-axis: rgba(180, 210, 216, 0.3);
}

.status__head-right {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.status__updated {
    font-size: 12px;
    color: var(--fg-3);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* --- 汇总数字卡 --- */
.status__stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(86px, 1fr));
    gap: 8px;
    margin-bottom: 14px;
}
.status__stat {
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    border-left-width: 3px;
    border-left-color: var(--st-other);
    background: var(--surface-2);
}
.status__stat.is-total { border-left-color: var(--accent-2); }
.status__stat.is-2xx { border-left-color: var(--st-2xx); }
.status__stat.is-3xx { border-left-color: var(--st-3xx); }
.status__stat.is-4xx { border-left-color: var(--st-4xx); }
.status__stat.is-5xx { border-left-color: var(--st-5xx); }
.status__stat-num {
    font-size: 19px;
    font-weight: 600;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}
.status__stat-label { font-size: 11.5px; color: var(--fg-2); }
.status__stat-pct { font-size: 11px; color: var(--fg-3); font-variant-numeric: tabular-nums; }

/* --- 工具条：形态切换 + 图例 --- */
.status__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 12px;
    margin-bottom: 10px;
}
.status__modes {
    display: inline-flex;
    gap: 2px;
    padding: 2px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface-2);
}
.status__mode {
    padding: 3px 13px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--fg-2);
    font-size: 12.5px;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--dur) var(--ease);
}
.status__mode:hover { color: var(--accent); }
.status__mode.is-active {
    color: var(--accent);
    font-weight: 600;
    background: var(--surface-solid);
    box-shadow: var(--shadow-xs);
}
.status__legend { display: flex; flex-wrap: wrap; gap: 4px 11px; }
.status__legend-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 11.5px;
    color: var(--fg-2);
    white-space: nowrap;
}
.status__legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 2px;
    background: var(--st-other);
}
.status__legend-dot.is-2xx { background: var(--st-2xx); }
.status__legend-dot.is-3xx { background: var(--st-3xx); }
.status__legend-dot.is-4xx { background: var(--st-4xx); }
.status__legend-dot.is-5xx { background: var(--st-5xx); }

/* --- 图表画布（内联 SVG） --- */
.status__chart-wrap { position: relative; }
.status__canvas { min-height: 190px; }
.status__canvas svg { display: block; width: 100%; height: auto; }

.status__canvas .st-grid { stroke: var(--st-grid); stroke-width: 1; }
.status__canvas .st-axis { stroke: var(--st-axis); stroke-width: 1; }
.status__canvas .st-tick {
    fill: var(--fg-3);
    font-size: 10px;
    font-family: var(--font-mono);
}
.status__canvas .st-line {
    fill: none;
    stroke: var(--accent-2);
    stroke-width: 1.6;
    stroke-linejoin: round;
    stroke-linecap: round;
    opacity: 0.7;
}
.status__canvas .st-pt { stroke: var(--surface-solid); stroke-width: 1; }
.status__canvas .st-seg { stroke: none; }
.status__canvas .st-total {
    fill: none;
    stroke: var(--accent);
    stroke-width: 1.4;
    stroke-dasharray: 4 3;
    opacity: 0.65;
}
.status__canvas .is-2xx { fill: var(--st-2xx); }
.status__canvas .is-3xx { fill: var(--st-3xx); }
.status__canvas .is-4xx { fill: var(--st-4xx); }
.status__canvas .is-5xx { fill: var(--st-5xx); }
.status__canvas .is-other { fill: var(--st-other); }

/* --- 悬浮提示 --- */
.status__tip {
    position: absolute;
    z-index: 5;
    min-width: 104px;
    padding: 7px 10px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--line-strong);
    background: var(--surface-solid);
    box-shadow: var(--shadow-md);
    color: var(--fg-2);
    font-size: 11.5px;
    line-height: 1.65;
    font-variant-numeric: tabular-nums;
    pointer-events: none;
}
.status__tip[hidden] { display: none; }
.status__tip-row { display: flex; align-items: center; gap: 6px; }
.status__tip-code {
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 700;
    color: var(--fg);
}
.status__tip-code.is-2xx { color: var(--st-2xx); }
.status__tip-code.is-3xx { color: var(--st-3xx); }
.status__tip-code.is-4xx { color: var(--st-4xx); }
.status__tip-code.is-5xx { color: var(--st-5xx); }
.status__tip-code.is-other { color: var(--st-other); }
.status__tip-bars {
    margin-top: 3px;
    display: flex;
    flex-wrap: wrap;
    gap: 3px 9px;
}
.status__tip-bars i { font-style: normal; font-weight: 600; color: var(--fg); }
.status__tip-bars .is-2xx { color: var(--st-2xx); }
.status__tip-bars .is-3xx { color: var(--st-3xx); }
.status__tip-bars .is-4xx { color: var(--st-4xx); }
.status__tip-bars .is-5xx { color: var(--st-5xx); }
.status__tip-bars .is-other { color: var(--st-other); }

/* --- 最近请求明细 --- */
.status__recent {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed var(--line);
}
.status__recent:empty { margin-top: 0; padding-top: 0; border-top: 0; }
.status__recent-title {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
    font-size: 12.5px;
    color: var(--fg-2);
}
.status__recent-title span { font-size: 11.5px; color: var(--fg-3); }
.status__recent-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(108px, 1fr));
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.status__row {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 9px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--line);
    background: var(--surface-2);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}
.status__row-pill {
    padding: 0 6px;
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 10.5px;
    font-weight: 600;
    color: var(--fg-2);
    background: var(--line);
}
.status__row.is-2xx .status__row-pill { color: var(--st-2xx); background: color-mix(in srgb, var(--st-2xx) 18%, transparent); }
.status__row.is-3xx .status__row-pill { color: var(--st-3xx); background: color-mix(in srgb, var(--st-3xx) 18%, transparent); }
.status__row.is-4xx .status__row-pill { color: var(--st-4xx); background: color-mix(in srgb, var(--st-4xx) 18%, transparent); }
.status__row.is-5xx .status__row-pill { color: var(--st-5xx); background: color-mix(in srgb, var(--st-5xx) 18%, transparent); }
.status__row.is-other .status__row-pill { color: var(--st-other); background: color-mix(in srgb, var(--st-other) 18%, transparent); }
.status__row-time { color: var(--fg-3); }

/* 作品卡上的「网站状态」入口（首页 / 作品页共用同一张卡片） */
.work__actions { flex-wrap: wrap; justify-content: flex-end; }
.work__actions a.btn { text-decoration: none; }
.btn--status { color: var(--accent); border-color: var(--accent-2); }

/* --- 响应式 --- */
@media (max-width: 980px) {
    .status__stats { grid-template-columns: repeat(auto-fit, minmax(76px, 1fr)); }
}
@media (max-width: 760px) {
    .status__stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .status__canvas { min-height: 168px; }
    .status__recent-list { grid-template-columns: repeat(auto-fill, minmax(98px, 1fr)); }
    .status__updated { font-size: 11px; }
    .status__stat-num { font-size: 17px; }
}
@media (max-width: 520px) {
    .status__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .status__legend { gap: 3px 8px; }
    .status__legend-item { font-size: 11px; }
}
