:root {
    --primary-color: #eb5055;
    --primary-dark: #ff6b6b;
    --bg-light: gainsboro;
    --surface-light: #ffffff;
    --text-light: rgb(36, 41, 46);
    --border-light: #e7e2d9;
    --text-muted: #999;
    --text-secondary: #666;
    --c-text-1: #1a1a1a;
    --c-text-2: #666;
    --c-text-3: #999;
    --shadow-light: 0 10px 20px rgba(236, 236, 236, 0.86);

    --bg-dark: #0d0d12;
    --surface-dark: #1a1a24;
    --text-dark: #c9c9d6;
    --border-dark: #2a2a36;
    --text-muted-dark: #6c6c80;
    --text-secondary-dark: #888899;
    --shadow-dark: 0 10px 30px rgba(0, 0, 0, 0.5);

    --font-size-xs: 12px;
    --font-size-sm: 13px;
    --font-size-base: 14px;
    --font-size-md: 15px;
    --font-size-lg: 16px;
    --font-size-xl: 18px;
    --font-size-2xl: 22px;
    --font-size-3xl: 28px;

    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 10px;
    --spacing-lg: 20px;
    --spacing-xl: 30px;

    --radius-sm: 3px;
    --radius-md: 5px;
    --radius-lg: 8px;
    --radius-full: 50%;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html,
body {
    font-family: "zql", serif;
    color: var(--text-light);
    background: var(--bg-light);
    font-size: var(--font-size-md);
    line-height: 1.6;
}

body {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    padding-top: 60px;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    color: var(--primary-color);
}

ul,
ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    vertical-align: middle;
}

.main {
    max-width: 900px;
    width: 100%;
    padding: var(--spacing-xl);
    background: var(--surface-light);
    box-shadow: var(--shadow-light);
    border-radius: var(--radius-lg);
}

.header {
    margin-bottom: var(--spacing-lg);
}

.header-top {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    width: 100%;
    gap: var(--spacing-lg);
}

.header-avatar {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    animation: blur 1s;
}

.blog-info {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.personal-signature {
    font-size: var(--font-size-md);
    font-weight: 500;
    line-height: 1.8;
    text-align: right;
    margin-top: var(--spacing-sm);
}

.social-links ul.flat {
    display: flex;
    gap: var(--spacing-md);
    margin-top: var(--spacing-sm);
}

.main-nav {
    border-top: 1px solid #f4f4f4;
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-md);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
}

.main-nav ul.flat {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
}

.main-nav ul.flat li.active a {
    color: var(--primary-color);
}

@keyframes blur {
    from {
        filter: blur(10px);
        opacity: 0;
    }

    to {
        filter: blur(0);
        opacity: 1;
    }
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out forwards;
}

.stagger-fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.stagger-fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- 归档流水动画（复刻参考实现） ---------- */
@keyframes archiveSlideFadeIn {
    0% {
        opacity: 0;
        transform: translate(-12px, -12px) scale(0.96);
    }

    100% {
        opacity: 1;
        transform: translate(0, 0) scale(1);
    }
}

/* 初始状态：月份项与日期项默认隐藏，由 JS 通过 reflow trick 触发动画 */
.archive-mon-list>li,
.archive-post-list>li {
    opacity: 0;
    transform: translate(-12px, -12px) scale(0.96);
}

/* 归档区样式（替代原 inline style） */
.archive-year {
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    margin-bottom: 6px;
    color: #333;
}

.archive-mon-list {
    margin-left: 15px;
    list-style: none;
    padding-left: 0;
    display: none;
}

.archive-month-item {
    margin-bottom: 6px;
    list-style: none;
}

.archive-mon {
    font-size: 16px;
    cursor: pointer;
    display: contents;
    color: #333;
}

.archive-post-list {
    margin-left: 20px;
    list-style: none;
    padding-left: 0;
    display: none;
}

.archive-post-item {
    padding: 2px 0;
}

.archive-post-date {
    font-size: 14px;
    margin-right: 8px;
}

.archive-post-link {
    font-size: 14px;
}

/* 评论楼层链接（替代原 inline style） */
.comment-floor-link {
    color: var(--c-text-2, #666);
    text-decoration: none;
}

/* 归档空状态 */
.archive-empty {
    text-align: center;
}

/* 内联搜索框 */
.searchable-header-container {
    position: relative;
    margin: 0 0 var(--spacing-md) 0;
    display: none;
    align-items: center;
}

.searchable-header-container.show {
    display: flex;
}

.search-mode {
    width: 100%;
    animation: searchFadeIn .3s ease;
}

@keyframes searchFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.search-input-group {
    position: relative;
    display: flex;
    align-items: center;
    width: 230px;
    background: 0 0;
    transition: all .3s ease;
    box-shadow: none;
}

.search-input-group:focus-within {
    border-bottom-color: var(--primary-color);
}

.search-input-group input {
    width: 100%;
    border: none !important;
    padding: 0 4px !important;
    font-size: 12px;
    color: #333;
    background: transparent;
    outline: none;
    font-weight: 500;
}

.close-icon {
    position: absolute;
    right: 0;
    font-size: 12px;
    cursor: pointer;
    transition: all .2s;
    opacity: 0;
    transform: scale(.8);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-icon.show {
    opacity: 1;
    transform: scale(1);
}

/* 搜索下拉结果 */
.search-dropdown {
    position: absolute;
    top: 100%;
    right: auto;
    width: 600px;
    max-width: calc(100vw - 40px);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, .1);
    border: 1px solid #f0f0f0;
    margin-top: 8px;
    overflow: hidden;
    z-index: 1000;
    opacity: 0;
    transform: translateY(5px);
    visibility: hidden;
    transition: all .2s ease;
    max-height: 400px;
    overflow-y: auto;
}

.search-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.search-result-item {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, .05);
    cursor: pointer;
    transition: background .18s ease;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #f9f9fb;
}

.search-result-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
    display: block;
    color: #24292e;
}

.search-result-meta {
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    font-size: 12px;
    color: #666;
    margin-top: 2px;
}

.search-result-date {
    font-size: 12px;
    color: #999;
    flex-shrink: 0;
}

.search-result-summary-text {
    max-width: 280px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-result-empty {
    padding: 30px 16px;
    text-align: center;
    font-size: 14px;
    color: #999;
}

.search-result-loading {
    padding: 20px 16px;
    text-align: center;
    font-size: 14px;
    color: #999;
}

/* 搜索结果页 */
.search-section {
    padding: 20px 0;
}

.search-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--c-text-1, #333);
    margin-bottom: 16px;
}

.search-keyword {
    color: var(--primary-color, #0071e3);
}

.search-count {
    font-size: 14px;
    color: var(--c-text-2, #666);
    margin-bottom: 16px;
}

.search-empty {
    font-size: 15px;
    color: var(--c-text-2, #666);
    text-align: center;
    padding: 40px 0;
}

.search-result-list mark {
    background: rgba(255, 213, 79, 0.5);
    color: inherit;
    padding: 0 2px;
    border-radius: 2px;
}

/* 404 页面 */
.page-404 {
    text-align: center;
    padding: 80px 20px;
}

.page-404-code {
    font-size: 72px;
    color: #e74c3c;
    margin-bottom: 16px;
}

.page-404-text {
    font-size: 16px;
    color: var(--c-text-2, #666);
}

.page-404-link {
    display: inline-block;
    margin-top: 24px;
    padding: 8px 24px;
    background: #0071e3;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
}

.archive-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    gap: 16px;
}

.archive-loading .loader-ring {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(235, 80, 85, 0.1);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.archive-loading .loader-text {
    color: var(--text-muted);
    font-size: 14px;
}


.archive-skeleton {
    background: linear-gradient(90deg, var(--surface-light) 25%, var(--border-light) 50%, var(--surface-light) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

body.dark-mode .archive-skeleton {
    background: linear-gradient(90deg, var(--surface-dark) 25%, var(--border-dark) 50%, var(--surface-dark) 75%);
}

.archive-year-enter {
    animation: yearExpand 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes yearExpand {
    0% {
        opacity: 0;
        transform: translateY(-10px);
        max-height: 0;
    }

    100% {
        opacity: 1;
        transform: translateY(0);
        max-height: 2000px;
    }
}

.recent-posts .posts .post {
    margin-top: var(--spacing-md);
}

.post {
    min-height: 40px;
    margin-bottom: var(--spacing-xs);
}

.post .time {
    font-size: var(--font-size-sm);
    color: #bec8d2;
}

.article-title {
    font-size: 1.5rem;
    color: #222;
    font-weight: 400;
    line-height: 1;
    word-wrap: break-word;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out forwards;
}

.article-header-info {
    font-size: var(--font-size-base);
    margin-top: 5px;
    padding-bottom: 5px;
    border-bottom: 2px dashed #c5c5c5;
    color: #a5a5a5;
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out 0.15s forwards;
}

.article-header-info span {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

.article-header-info .fa {
    margin-right: 5px;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: var(--spacing-lg);
}

.single-copyright,
.single-tags {
    margin: var(--spacing-xs) 0;
    font-size: var(--font-size-base);
    color: #555;
}

.single-tags span {
    margin-left: var(--spacing-xs);
}

#article-toc-wrapper {
    position: fixed;
    left: 50%;
    margin-left: 470px;
    width: 16rem;
    max-height: 300px;
    overflow: hidden;
    overflow-y: auto;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    padding: 0;
    border: none;
    background: transparent;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#article-toc-wrapper.show {
    opacity: 1;
    visibility: visible;
}

#article-toc-wrapper::-webkit-scrollbar {
    width: 0;
}

.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    position: relative;
}

.toc-list::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #e0e0e0;
    border-radius: 2px;
    z-index: 0;
}

.toc-list .toc-active-dot {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: var(--primary-color);
    z-index: 2;
    transition: top 0.3s ease;
    transform: translateY(-50%);
}

.toc-item {
    margin-bottom: 0;
    position: relative;
    padding: .4rem 0 .4rem 36px;
    cursor: pointer;
    z-index: 1;
}

.toc-link {
    display: block;
    font-size: .95rem;
    color: #8590a6;
    text-decoration: none;
    transition: all 0.3s ease;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    word-break: keep-all;
}

.toc-link:hover,
.toc-link.active {
    color: var(--primary-color);
}

.toc-link.active {
    font-weight: 500;
}

.markdown-body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif;
    font-size: var(--font-size-lg);
    line-height: 1.8;
    color: #333;
}

.markdown-body h1 {
    font-size: var(--font-size-3xl);
    font-weight: 700;
    color: #222;
    margin: var(--spacing-xl) 0 var(--spacing-lg);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid var(--border-light);
    line-height: 1.4;
}

.markdown-body h2 {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    color: #333;
    margin: calc(var(--spacing-xl) - 2px) 0 var(--spacing-md);
    padding-left: 0;
    line-height: 1.4;
}

.markdown-body h2::before {
    content: '#';
    color: #e74c3c;
    margin-right: 6px;
    font-weight: 700;
}

.markdown-body h3 {
    font-size: var(--font-size-xl);
    font-weight: 600;
    color: #444;
    margin: calc(var(--spacing-lg) + 4px) 0 calc(var(--spacing-md) - 1px);
    line-height: 1.4;
}

.markdown-body h4 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: #555;
    margin: var(--spacing-lg) 0 calc(var(--spacing-md) - 3px);
}

.markdown-body h5,
.markdown-body h6 {
    font-size: var(--font-size-md);
    font-weight: 500;
    color: #666;
    margin: calc(var(--spacing-md) + 1px) 0 calc(var(--spacing-sm) + 2px);
}

.markdown-body p {
    margin: var(--spacing-md) 0;
    text-align: justify;
}

.markdown-body strong {
    font-weight: 600;
    color: #222;
}

.markdown-body em {
    color: #555;
}

.markdown-body del {
    color: #999;
    text-decoration: line-through;
}

.markdown-body blockquote {
    margin: var(--spacing-md) 0;
    padding: var(--spacing-md) var(--spacing-lg);
    background: #f8f9fa;
    border-left: 4px solid var(--bg-light);
    color: #666;
    font-style: normal;
    font-size: var(--font-size-md);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.markdown-body blockquote p {
    margin: 0;
}

.markdown-body ul,
.markdown-body ol {
    margin: var(--spacing-md) 0;
    padding-left: var(--spacing-xl);
}

/* 覆盖全局 list-style: none，恢复 markdown 列表标记 */

.markdown-body ol {
    list-style: decimal;
}

.markdown-body li {
    margin: 6px 0;
}

.markdown-body li>ul,
.markdown-body li>ol {
    margin: var(--spacing-xs) 0;
}

/* 任务列表：移除默认标记，使用自定义复选框 */
.markdown-body .task-list-item {
    list-style: none;
}

.markdown-body .task-list-item input[type="checkbox"] {
    margin-right: var(--spacing-sm);
    width: 16px;
    height: 16px;
    vertical-align: middle;
    cursor: default;
}

.markdown-body code {
    display: inline-block;
    padding: 2px 6px;
    background: #f4f4f4;
    border-radius: var(--radius-sm);
    font-family: 'JetBrains Mono', 'SF Mono', Monaco, 'Courier New', monospace;
    font-size: var(--font-size-base);
    color: #e74c3c;
    margin: 0 2px;
}

.markdown-body pre {
    margin: var(--spacing-md) 0;
    padding: var(--spacing-md);
    background: #1e1e1e;
    border-radius: var(--radius-lg);
    overflow-x: auto;
    position: relative;
    touch-action: pan-y;
}

.markdown-body pre code {
    display: block;
    padding: 0;
    background: none;
    color: #d4d4d4;
    font-family: 'JetBrains Mono', 'SF Mono', Monaco, 'Courier New', monospace;
    font-size: var(--font-size-base);
    line-height: 1.6;
    white-space: pre;
}

.markdown-body pre code.hljs {
    background: none;
    padding: 0;
}

.markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin: var(--spacing-md) 0;
    font-size: var(--font-size-base);
}

.markdown-body th,
.markdown-body td {
    padding: var(--spacing-md);
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.markdown-body th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
}

.markdown-body tr:hover {
    background: #fafafa;
}

.markdown-body a {
    color: var(--primary-color);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.markdown-body a:hover {
    border-bottom-color: var(--primary-color);
}

.markdown-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    margin: var(--spacing-sm) auto;
    display: block;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: zoom-in;
}

.markdown-body img.img-left {
    margin-left: 0;
    margin-right: auto;
}

.markdown-body img.img-right {
    margin-left: auto;
    margin-right: 0;
}

.markdown-body img.img-center {
    margin-left: auto;
    margin-right: auto;
}

.markdown-body hr {
    margin: var(--spacing-xl) 0;
    border: none;
    border-top: 1px solid #e0e0e0;
}

.markdown-body audio {
    width: 100%;
    margin: var(--spacing-md) 0;
    border-radius: var(--radius-lg);
    background: #f8f9fa;
}

.markdown-body video {
    max-width: 100%;
    border-radius: var(--radius-lg);
    margin: var(--spacing-sm) 0;
}

.markdown-body iframe {
    border-radius: var(--radius-lg);
    margin: var(--spacing-sm) 0;
    max-width: 100%;
    width: 100%;
    height: auto;
    min-height: 300px;
}

.markdown-body iframe[src*="youtube"],
.markdown-body iframe[src*="bilibili"] {
    aspect-ratio: 16 / 9;
    height: auto;
}

.markdown-body .footnotes {
    font-size: var(--font-size-base);
    color: #888;
    border-top: 1px solid #eee;
    padding-top: var(--spacing-lg);
    margin-top: var(--spacing-xl);
}

.markdown-body .emoji {
    font-size: 1.2em;
    vertical-align: middle;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    margin: var(--spacing-lg) 0;
    font-size: 0.9em;
}

.pagination li.active a,
.pagination li.active span {
    color: var(--primary-color);
    font-weight: bold;
    cursor: default;
}

.line-with-dot {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: var(--spacing-md) 0;
    height: 20px;
}

.line {
    flex: 1;
    height: 1px;
    background-color: #f4f4f4;
}

.dot {
    width: 12px;
    height: 12px;
    border: 1px solid #aaa;
    border-radius: 50%;
    margin: 0 var(--spacing-sm);
}

.comment-contariner-width {
    margin: var(--spacing-sm) auto 0;
}

.comment-reply-title {
    margin: var(--spacing-sm) 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comment-reply-title>span:first-child {
    border-left: 4px solid var(--primary-color);
    padding-left: var(--spacing-xs);
    font-size: var(--font-size-lg);
    line-height: 30px;
}

.comment-author-welcome {
    margin: 0.6rem 0;
}

.comment-author-welcome .edit-info-btn {
    cursor: pointer;
}

.comment-author-welcome .avatar {
    border-radius: 50%;
    vertical-align: middle;
    margin-right: .6em;
    width: 1.88em;
    height: 1.88em;
    user-select: none;
}

.comment-reply-title .reply-author {
    border-left: none;
    padding-left: 0;
}

.comment-author-info {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: var(--spacing-lg);
    gap: var(--spacing-md);
}

.comment-author-info>div {
    flex: 1;
    min-width: 200px;
}

.comment-author-info label {
    font-size: var(--font-size-xs);
    line-height: var(--spacing-lg);
    padding-bottom: var(--spacing-xs);
    display: block;
    color: #5a6c7d;
    font-weight: 500;
}

.comment-author-info input,
textarea {
    width: 100%;
    padding: var(--spacing-sm) var(--spacing-md);
    border: 1px solid #dce1e6;
    border-radius: var(--radius-md);
    font-size: var(--font-size-base);
    background-color: #f9fafc;
    outline: none;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.comment-form-comment {
    position: relative;
}

.comment-form-tools {
    margin-top: 0;
    margin-bottom: 0;
    border-bottom: 1px dashed #e5e9ef;
    padding-bottom: var(--spacing-xs);
    height: 0;
    overflow: hidden;
    opacity: 0;
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: height 0.3s ease-out, opacity 0.3s ease-out, margin-bottom 0.3s ease-out;
}

.comment-form-tools.show {
    height: 35px;
    opacity: 1;
    overflow: visible;
    margin-bottom: var(--spacing-sm);
}

.comment-form-tools span {
    display: inline-block;
    margin-right: var(--spacing-xs);
    padding-left: 1px;
    cursor: pointer;
    height: 25px;
    line-height: 25px;
    text-align: center;
    font-size: var(--font-size-base);
    border-radius: var(--radius-sm);
    color: #848484;
    opacity: 0;
    transition: opacity 0.2s ease-out;
}

.comment-form-tools.show span {
    opacity: 1;
}

.comment-form-tools.show span:first-child {
    transition-delay: 0.1s;
}

.comment-form-tools.show span:last-child {
    transition-delay: 0.15s;
    margin-right: 0;
}

.comment-form-tools .emoji-btn-wrap {
    display: inline-block;
}

.comment-form-tools #close {
    margin-left: auto;
}

#comment-tips {
    color: #4caf50;
    font-size: var(--font-size-sm);
}

#commentArea::placeholder {
    font-size: 13px;
}

label.error {
    font-size: 13px;
    color: #e74c3c;
    font-weight: normal;
    display: block;
    padding-left: var(--spacing-md);
    margin-top: 4px;
}

.comment-success {
    color: #4caf50;
}

.comment-submit-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.comment-form-submit #submit,
.comment-form-submit #submit:focus,
.comment-form-submit #submit:hover {
    border-radius: 2px;
    font-size: var(--font-size-xs);
    padding: 2px 20px;
    line-height: 25px;
    width: auto;
    float: right;
}

.btn {
    border: 0;
    background: var(--primary-color);
    color: #fff;
    cursor: pointer;
    opacity: 1;
    user-select: none;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-md);
    transition: all 0.3s;
}

.comment-list>li {
    padding-top: var(--spacing-lg);
}

.comment-list>li:after {
    content: "";
    display: block;
    height: 1px;
    background-color: #e5e9ef;
    margin-top: var(--spacing-lg);
}

.comment-list>li:last-child:after {
    background-color: transparent;
}

.comment-body {
    position: relative;
    min-height: 55px;
}

.comment-avatar-area {
    position: absolute;
}

.comment-avatar-area .avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
}

.comment-content-area,
.comment-list>li:after,
.comment-list>.comment.depth-1>#respond,
.children {
    margin-left: 60px;
}

.comment-content-user {
    line-height: 1.5;
    padding-bottom: var(--spacing-xs);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.comment-content-user .comment-auth,
.comment-content-user .comment-auth a {
    font-size: var(--font-size-md);
    font-weight: 700;
    color: #6d757a;
}

.reply-author {
    color: var(--primary-color);
    font-weight: 500;
}

.comment-content-user .level {
    font-size: var(--font-size-xs);
    color: #fff;
    background-color: #666;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    opacity: 0.5;
}

.comment-content-text {
    line-height: 1.8;
    padding: var(--spacing-xs) 0;
    font-size: var(--font-size-base);
}

.comment-content-info,
.comment-content-info a {
    color: #99a2aa;
    font-size: var(--font-size-sm);
}

.comment-content-info span {
    margin-right: var(--spacing-lg);
}

.comment-content-user .level-1 {
    background: #348abe;
}

.comment-content-user .level-2 {
    background: #0bf;
}

.comment-content-user .level-admin {
    background: #fd5d3c;
}

.children .comment-body {
    margin-top: var(--spacing-md);
}

.comment-at {
    color: var(--primary-color);
    border: 0;
    margin-right: 0.3em;
}

.blog-alert {
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-sm);
    margin: var(--spacing-lg) 0;
    line-height: 1.5;
}

.blog-alert.success {
    background-color: #f0f9eb;
    color: #67c23a;
}

.blog-alert.warning {
    background-color: #fdf6ec;
    color: #e6a23c;
}

#cancel-comment-reply-link {
    display: none;
    font-size: var(--font-size-xs);
    color: #e26f6f;
    cursor: pointer;
    margin-left: var(--spacing-sm);
}

#cancel-comment-reply-link:hover {
    color: var(--primary-color);
}

#cancel-comment-reply-link.show {
    display: inline-block;
}

.link-grid {
    display: flex;
    flex-wrap: wrap;
    margin-top: var(--spacing-lg);
}

.link-list-mobile {
    list-style: none;
    padding: 0;
    margin: var(--spacing-lg) 0;
}

.link-item-mobile {
    padding: var(--spacing-sm) 0;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.link-item-mobile:hover {
    background: #fafafa;
}

.link-name-tag {
    display: inline-block;
    font-size: var(--font-size-base);
    font-weight: 400;
    color: #333;
    border: 1px solid #e0e0e0;
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    white-space: nowrap;
    background: #fff;
}

.link-desc-mobile {
    font-size: var(--font-size-xs);
    color: #999;
    flex: 1;
}

.link-item {
    width: 33.33%;
    padding: var(--spacing-sm);
}

.link-card {
    display: flex;
    align-items: center;
    padding: var(--spacing-sm);
    border-radius: 10px;
    transition: all 0.3s;
}

.link-card:hover {
    background-color: #f9f9f9;
}

.link-avatar {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.link-avatar img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-full);
}

.link-content {
    overflow: hidden;
    flex: 1;
    margin-left: var(--spacing-md);
}

.link-description {
    font-size: 0.8rem;
    color: #6c757d;
}

.toggle-container {
    width: 100%;
    margin: var(--spacing-md) auto;
}

.toggle-header {
    background-color: #f0f0f0;
    color: #333;
    padding: var(--spacing-xs);
    border-radius: var(--radius-md);
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-size-base);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.toggle-header:hover {
    background-color: #e0e0e0;
}

.toggle-content {
    overflow: hidden;
    max-height: 0;
    background-color: #fff;
    border-radius: var(--radius-md);
    margin-top: var(--spacing-sm);
    padding: 0 var(--spacing-lg);
    line-height: 1.8;
    transition: max-height 0.4s ease, padding 0.3s ease;
}

.toggle-content.show {
    max-height: 1000px;
    padding: var(--spacing-lg);
}

.toggle-content ul {
    font-size: 0.85rem;
    line-height: 1.8;
    padding-left: var(--spacing-lg);
}

.toggle-content li {
    margin: var(--spacing-sm) 0;
    padding-left: var(--spacing-sm);
}

.toggle-content h3 {
    margin-bottom: var(--spacing-sm);
    color: #2c3e50;
    font-size: 1.1rem;
}

/* 暗色模式：折叠面板（关于页等） */
body.dark-mode .toggle-header {
    background-color: #252532;
    color: #c0c0d0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

body.dark-mode .toggle-header:hover {
    background-color: #2f2f3c;
}

body.dark-mode .toggle-content {
    background-color: var(--surface-dark);
    color: var(--text-dark);
}

body.dark-mode .toggle-content h3 {
    color: #d4d4e0;
}

body.dark-mode .toggle-content.show {
    opacity: 1;
}

.arrow {
    transition: transform 0.4s ease;
    color: #807e7e;
    margin-right: var(--spacing-sm);
}

.arrow.rotate {
    transform: rotate(180deg);
}

.empty-state {
    text-align: center;
}

.empty-title {
    font-size: 1.2rem;
}

.empty-desc {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.entry-content {
    margin-top: var(--spacing-lg);
}

#all-post-archives {
    margin-bottom: 2em;
}


#all-post-archives .post-list li {
    color: #c1c1c1;
    display: flex;
    align-items: center;
    padding: var(--spacing-xs) 0;
}

#all-post-archives .post-list li a {
    margin-left: var(--spacing-sm);
    color: #000;
    transition: color 0.2s ease;
}

#all-post-archives .post-list li a:hover {
    color: var(--primary-color);
}

.post-date {
    display: inline-block;
    width: 60px;
    text-align: right;
    font-variant-numeric: tabular-nums;
    color: #555;
}

.footer {
    border-top: 1px solid #f4f4f4;
    padding-top: var(--spacing-md);
    margin-top: var(--spacing-xl);
    font-size: 0.8em;
    color: #999;
    text-align: right;
}

/* 共用悬浮按钮样式（theme-switch-btn + scroll-to-top） */
#theme-switch-btn,
#scroll-to-top {
    position: fixed;
    right: 36px;
    width: 36px;
    height: 36px;
    background: #fff;
    color: #9c9c9c;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
}

#scroll-to-top {
    bottom: 36px;
}

#theme-switch-btn {
    bottom: 84px;
}

#theme-switch-btn.show,
#scroll-to-top.show {
    opacity: 1;
    visibility: visible;
}

#theme-switch-btn:hover,
#scroll-to-top:hover {
    background: var(--primary-color);
    color: #fff;
}

#theme-switch-btn:active,
#scroll-to-top:active {
    transform: scale(0.94);
}

#theme-switch-btn .icon-sun,
#theme-switch-btn .icon-moon {
    position: absolute;
    font-size: 16px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#theme-switch-btn .icon-sun {
    opacity: 0;
    transform: scale(0.3) rotate(-90deg);
}

#theme-switch-btn .icon-moon {
    opacity: 1;
    transform: scale(1) rotate(0deg);
}

.overlay-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99999;
    pointer-events: none;
}

.overlay-container.active {
    pointer-events: auto;
}

#calendar {
    font-family: "Microsoft YaHei", sans-serif;
    max-width: 900px;
    margin: 0 auto;
    height: 150px;
}

.link {
    margin-top: var(--spacing-lg);
}

.link p.indent {
    text-indent: 2em;
    font-size: var(--font-size-base);
    margin: var(--spacing-sm) 0;
}

.social-links .fa {
    font-size: 20px;
}

body.dark-mode {
    background: var(--bg-dark);
    color: var(--text-dark);
}

/* 防闪屏：html 元素在 body 获得暗色类之前先设置暗色背景 */
html.dark-mode {
    background: var(--bg-dark);
}

html.dark-mode body {
    background-image: none !important;
    background-color: var(--bg-dark);
}

body.dark-mode .main {
    background: var(--surface-dark);
    box-shadow: var(--shadow-dark);
}

body.dark-mode a {
    color: var(--text-dark);
}

body.dark-mode a:hover {
    color: var(--primary-dark);
}

body.dark-mode .main-nav {
    border-top-color: var(--border-dark);
}

body.dark-mode .main-nav li a {
    color: #a0a0b0;
}

body.dark-mode .main-nav li.active a {
    color: var(--primary-dark);
}

body.dark-mode .post-list li {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .post-list .post-title {
    color: #d4d4e0;
}

body.dark-mode .post-list .post-title:hover {
    color: var(--primary-dark);
}

body.dark-mode .post-list .post-meta {
    color: var(--text-muted-dark);
}

body.dark-mode .read-more {
    color: var(--primary-dark);
}

body.dark-mode .pagination a,
body.dark-mode .pagination span {
    background: transparent !important;
    color: #c0c0d0 !important;
    border-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

body.dark-mode .pagination a:hover,
body.dark-mode .pagination span:hover {
    color: var(--primary-dark) !important;
}

body.dark-mode .pagination .current {
    background: transparent !important;
    color: var(--primary-dark) !important;
    font-weight: bold;
    border: none !important;
}

body.dark-mode .footer {
    border-top-color: var(--border-dark);
    color: var(--text-muted-dark);
}

body.dark-mode .article-header h1,
body.dark-mode .article-title {
    color: #d4d4e0 !important;
}

body.dark-mode .article-meta {
    color: var(--text-muted-dark);
}

body.dark-mode .markdown-body {
    color: var(--text-dark);
}

body.dark-mode .markdown-body h1,
body.dark-mode .markdown-body h2,
body.dark-mode .markdown-body h3,
body.dark-mode .markdown-body h4,
body.dark-mode .markdown-body h5,
body.dark-mode .markdown-body h6 {
    color: #d4d4e0;
}

body.dark-mode .markdown-body h1 {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .markdown-body h2 {
    border-left-color: var(--primary-dark);
    background: #20202a;
}

body.dark-mode .markdown-body p {
    color: #b0b0c0;
}

body.dark-mode .markdown-body strong {
    color: #e0e0eb;
}

body.dark-mode .markdown-body em {
    color: #c8c8d8;
}

body.dark-mode .markdown-body blockquote {
    background: #20202a;
    border-left-color: var(--primary-dark);
    color: #9090a0;
}

body.dark-mode .markdown-body code {
    background: var(--border-dark);
    color: #f08d49;
}

body.dark-mode .markdown-body pre {
    background: #1e1e28;
    border-color: var(--border-dark);
}

body.dark-mode .markdown-body pre code {
    background: transparent;
    color: #d4d4e0;
}

body.dark-mode .markdown-body table th {
    background: #252532;
    border-color: var(--border-dark);
    color: #d4d4e0;
}

body.dark-mode .markdown-body table td {
    border-color: var(--border-dark);
    color: #b0b0c0;
}

body.dark-mode .markdown-body table tr:hover {
    background: #20202a;
}

body.dark-mode .markdown-body hr {
    border-top-color: var(--border-dark);
}

body.dark-mode .markdown-body ul li::before,
body.dark-mode .markdown-body ol li::before {
    color: var(--primary-dark);
}

body.dark-mode .markdown-body .task-list-item::before {
    border-color: #555;
}

body.dark-mode .markdown-body .task-list-item.checked::before {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
}

body.dark-mode .markdown-body audio {
    background: #252532;
}

body.dark-mode .comment-section h3 {
    color: #d4d4e0;
}

body.dark-mode .comment-list li {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .comment-list li:after {
    background: var(--border-dark);
}

body.dark-mode .comment-content-user .name {
    color: #d4d4e0;
}

body.dark-mode .comment-content-user .time {
    color: var(--text-muted-dark);
}

body.dark-mode .comment-content-body {
    color: #b0b0c0;
}

body.dark-mode .comment-header {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .comment-form textarea,
body.dark-mode .comment-form input[type="text"],
body.dark-mode .comment-form input[type="email"],
body.dark-mode .comment-form input[type="url"] {
    background: #20202a;
    border-color: var(--border-dark);
    color: var(--text-dark);
}

body.dark-mode .comment-form textarea:focus,
body.dark-mode .comment-form input:focus {
    border-color: var(--primary-dark);
}

body.dark-mode .comment-form button {
    background: var(--primary-dark);
    color: #fff;
}

body.dark-mode .comment-form button:hover {
    background: #e55a5a;
}

body.dark-mode .comment-emoji-btn {
    background: #252532;
    border-color: var(--border-dark);
    color: #a0a0b0;
}

body.dark-mode .comment-form-tools {
    background: #20202a;
    border-bottom-color: var(--border-dark);
}

body.dark-mode .comment-footer {
    border-top-color: var(--border-dark);
    color: var(--text-muted-dark);
}

body.dark-mode .comment-content-user .comment-auth,
body.dark-mode .comment-content-user .comment-auth a {
    color: #c1c1c1;
}

body.dark-mode .comment-content-info,
body.dark-mode .comment-content-info a {
    color: #848484;
}

body.dark-mode .comment-form-tools span {
    color: #636366;
}

body.dark-mode .markdown-body del {
    color: #666;
}

body.dark-mode .line {
    background-color: #2c2c2e;
}

body.dark-mode .dot {
    border-color: #48484a;
}

body.dark-mode .blog-alert.warning {
    opacity: 0.8;
}

body.dark-mode #respond {
    opacity: 0.8;
}

body.dark-mode #all-post-archives .archive-year {
    color: #c0c0d0 !important;
    border-bottom-color: var(--border-dark);
}

body.dark-mode #all-post-archives .archive-mon,
body.dark-mode #all-post-archives .archive-post-date,
body.dark-mode #all-post-archives .archive-post-link,
body.dark-mode #all-post-archives .post-link,
body.dark-mode #all-post-archives .article-link {
    color: #c0c0d0;
}

body.dark-mode #all-post-archives .post-link:hover,
body.dark-mode #all-post-archives .article-link:hover {
    color: var(--primary-dark);
}

body.dark-mode #all-post-archives .post-date {
    color: #c0c0d0;
}

body.dark-mode #all-post-archives .post-list li a {
    color: var(--c-text-1, #e0e0e0);
}

body.dark-mode #all-post-archives .post-list li {
    color: var(--c-text-2, #aaa);
}

body.dark-mode .line-with-dot {
    opacity: 0.6;
}

body.dark-mode .toggle-container.fade-in {
    opacity: 0.8;
}

body.dark-mode .tag-list a {
    background: #252532;
    color: #a0a0b0;
}

body.dark-mode .tag-list a:hover {
    background: var(--primary-dark);
    color: #fff;
}

body.dark-mode .link-grid li {
    background: #252532;
    border-color: var(--border-dark);
}

body.dark-mode .link-grid li:hover {
    background: var(--border-dark);
    border-color: var(--primary-dark);
}

body.dark-mode .link-name {
    color: #d4d4e0;
}

body.dark-mode .link-desc {
    color: var(--text-secondary-dark);
}

body.dark-mode .link-list-mobile .link-item-mobile {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .link-list-mobile .link-item-mobile:hover {
    background: #20202a;
}

body.dark-mode .link-name-tag {
    background: var(--surface-dark);
    color: #d4d4e0;
    border-color: #3a3a4a;
}

body.dark-mode .link-desc-mobile {
    color: var(--text-secondary-dark);
}

body.dark-mode #article-toc-wrapper {
    background: transparent;
}

body.dark-mode .toc-list::before {
    background: #3a3a4a;
}

body.dark-mode .toc-link {
    color: var(--text-muted-dark);
}

body.dark-mode .toc-link:hover,
body.dark-mode .toc-link.active {
    color: var(--primary-dark);
}

body.dark-mode .hljs {
    background: #1e1e28 !important;
}

body.dark-mode #scroll-to-top,
body.dark-mode #theme-switch-btn {
    background: var(--text-light);
    color: var(--text-dark);
    box-shadow: 0 4px 20px rgba(123, 94, 167, 0.3);
}

body.dark-mode #scroll-to-top:hover,
body.dark-mode #theme-switch-btn:hover {
    background: var(--primary-dark);
    color: #fff;
}

body.dark-mode #calendar {
    color: #a0a0b0;
}

body.dark-mode .search-input {
    background: #20202a;
    border-color: var(--border-dark);
    color: var(--text-dark);
}

body.dark-mode .search-input:focus {
    border-color: var(--primary-dark);
}

body.dark-mode .user-level.admin {
    background: var(--primary-dark);
}

body.dark-mode .user-level.vip {
    background: #f0c060;
    color: #1a1814;
}

body.dark-mode .comment-no-more {
    color: var(--text-muted-dark);
}

body.dark-mode .comment-at,
body.dark-mode .reply-author {
    color: var(--primary-dark) !important;
}

body.dark-mode .comment-content-user .level {
    color: #fff !important;
    background-color: #666 !important;
    opacity: 0.5;
}

body.dark-mode .comment-content-user .level-1 {
    background: #348abe !important;
}

body.dark-mode .comment-content-user .level-2 {
    background: #0bf !important;
}

body.dark-mode .comment-content-user .level-admin {
    background: #fd5d3c !important;
}

body.dark-mode #theme-switch-btn .icon-sun {
    opacity: 1;
    transform: scale(1) rotate(0deg);
}

body.dark-mode #theme-switch-btn .icon-moon {
    opacity: 0;
    transform: scale(0.3) rotate(90deg);
}

/* fancyBox v6 深色模式联动（通过覆盖 CSS 变量自动跟随主题） */
body.dark-mode .fancybox__container {
    --fancybox-backdrop-bg: rgba(20, 20, 22, 0.95);
    --fancybox-color: #f5f5f7;
}

@media (max-width: 1280px) {
    #article-toc-wrapper {
        display: none;
    }
}

@media (max-width: 900px) {
    .main {
        max-width: 100%;
        width: calc(100% - 40px);
        padding: var(--spacing-xl);
    }
}

@media (max-width: 768px) {
    #article-toc-wrapper {
        display: none;
    }

    .container {
        padding-top: 10px;
    }

    body {
        padding-top: 0;
        background-image: none !important;
        background-color: var(--surface-light);
    }

    body.dark-mode {
        background-color: var(--surface-dark);
    }

    .searchable-header-container {
        margin-left: 0;
        width: 100%;
        margin-top: 8px;
    }

    .search-input-group {
        max-width: 100%;
    }

    .search-dropdown {
        left: 0;
        width: 100%;
        max-width: 100%;
    }

    .search-result-summary-text {
        max-width: 200px;
    }

    .main {
        width: 100%;
        padding: var(--spacing-lg) var(--spacing-md);
        margin: 0;
        max-width: none;
        border-radius: 0;
        box-shadow: none;
    }

    .footer {
        margin-top: var(--spacing-lg);
    }

    .header {
        padding: 0 10px;
    }

    article {
        padding: 0 10px;
    }

    #guestbook-poem {
        padding: 0 10px;
    }

    .header-top {
        flex-direction: row;
        align-items: flex-end;
        justify-content: space-between;
        gap: var(--spacing-md);
    }

    .header-avatar {
        width: 60px;
        height: 60px;
    }

    .blog-info {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 6px;
        text-align: right;
        justify-content: flex-end;
    }

    .social-links {
        font-size: var(--font-size-md);
    }

    .social-links ul.flat {
        margin-top: 0;
        justify-content: flex-end;
    }

    .personal-signature {
        margin-top: 0;
        white-space: nowrap;
        font-size: var(--font-size-md);
    }

    .main-nav ul.flat {
        justify-content: center;
        gap: var(--spacing-md);
    }

    .entry-content,
    .link {
        padding: 0 var(--spacing-md);
    }

    .link-item {
        width: 50%;
        display: flex;
        justify-content: center;
        padding: var(--spacing-xs);
    }

    .link-card {
        width: 100%;
        max-width: 320px;
    }

    #calendar {
        display: none;
    }

    .comment-author-info {
        flex-direction: column;
    }

    .comment-author-info>div {
        min-width: 100%;
        margin-right: 0;
    }

    .pagination {
        flex-wrap: wrap;
    }

    .comment-content-area,
    .comment-list>li:after,
    .comment-list>.comment.depth-1>#respond,
    .children {
        margin-left: 55px;
    }

    .article-header-info span {
        display: block;
        margin-right: 0;
        margin-bottom: var(--spacing-xs);
    }

    .comment-contariner-width,
    .guestbook-content {
        padding: 0 var(--spacing-sm);
    }

    .markdown-body {
        font-size: var(--font-size-md);
    }

    .markdown-body h1 {
        font-size: var(--font-size-2xl);
    }

    .markdown-body h2 {
        font-size: var(--font-size-xl);
    }

    .markdown-body h3 {
        font-size: var(--font-size-lg);
    }

    .markdown-body pre {
        padding: var(--spacing-md);
        font-size: var(--font-size-xs);
    }

    .markdown-body code {
        font-size: var(--font-size-xs);
    }

    .markdown-body table {
        font-size: var(--font-size-xs);
    }

    .markdown-body th,
    .markdown-body td {
        padding: var(--spacing-sm) 6px;
    }

    .markdown-body iframe {
        min-height: 200px;
    }
}

@media (max-width: 480px) {
    body {
        padding-top: 0;
    }

    .main {
        padding: var(--spacing-md) var(--spacing-sm);
        margin: 0;
    }

    .header-avatar {
        width: 80px;
        height: 80px;
    }

    .entry-content,
    .link {
        padding: 0 var(--spacing-sm);
    }

    .link-item {
        width: 100%;
        display: flex;
        justify-content: center;
        padding: var(--spacing-xs);
    }

    .link-card {
        width: 100%;
        max-width: 320px;
    }

    #calendar {
        display: none;
    }

    .article-title {
        font-size: 1.5rem;
    }

    .article-header-info {
        font-size: 13px;
        flex-wrap: wrap;
        gap: var(--spacing-sm);
    }

    .comment-content-area,
    .comment-list>li:after,
    .comment-list>.comment.depth-1>#respond,
    .children {
        margin-left: 50px;
    }

    .comment-avatar-area .avatar {
        width: 40px;
        height: 40px;
    }

    #theme-switch-btn,
    #scroll-to-top {
        right: 16px;
        width: 32px;
        height: 32px;
        font-size: 14px;
    }

    #scroll-to-top {
        bottom: 16px;
    }

    #theme-switch-btn {
        bottom: 58px;
    }

    #theme-switch-btn .icon-sun,
    #theme-switch-btn .icon-moon {
        font-size: 14px;
    }

    .markdown-body {
        font-size: var(--font-size-base);
        line-height: 1.7;
    }

    .markdown-body h1 {
        font-size: 20px;
    }

    .markdown-body h2 {
        font-size: var(--font-size-lg);
    }

    .markdown-body iframe {
        min-height: 150px;
    }
}

/* 暗色模式：内联搜索框与下拉结果 */
body.dark-mode .search-input-group {
    border-bottom-color: transparent;
}

body.dark-mode .search-input-group:focus-within {
    border-bottom-color: transparent;
}

body.dark-mode .search-icon {
    color: #aaa;
}

body.dark-mode .search-input-group input {
    color: #fff;
}

body.dark-mode .close-icon {
    color: #aaa;
}

body.dark-mode .search-dropdown {
    background: var(--surface-dark);
    border: 1px solid var(--border-dark);
    box-shadow: 0 4px 20px rgba(0, 0, 0, .3);
}

body.dark-mode .search-result-item {
    border-bottom-color: var(--border-dark);
}

body.dark-mode .search-result-item:hover {
    background: #20202a;
}

body.dark-mode .search-result-title {
    color: #e0e0e0;
}

body.dark-mode .search-result-meta {
    color: #aaa;
}

body.dark-mode .search-result-date {
    color: var(--text-muted-dark);
}

body.dark-mode .search-result-empty,
body.dark-mode .search-result-loading {
    color: var(--text-muted-dark);
}

body.dark-mode .search-title {
    color: var(--text-dark);
}

body.dark-mode .search-count,
body.dark-mode .search-empty {
    color: #a0a0b0;
}

body.dark-mode .search-result-list mark {
    background: rgba(235, 80, 85, 0.3);
    color: var(--text-dark);
}

/* 暗色模式：404 页面 */
body.dark-mode .page-404-text {
    color: #a0a0b0;
}

/* 暗色模式：补充样式 */
body.dark-mode .single-copyright,
body.dark-mode .single-tags {
    color: #a0a0b0;
}

body.dark-mode .link-card:hover {
    background-color: #20202a;
}

body.dark-mode .link-description {
    color: var(--text-secondary-dark);
}

body.dark-mode .arrow {
    color: #6c6c80;
}

body.dark-mode .empty-title {
    color: #d4d4e0;
}

body.dark-mode .empty-desc {
    color: var(--text-muted-dark);
}

body.dark-mode .markdown-body .footnotes {
    color: var(--text-muted-dark);
    border-top-color: var(--border-dark);
}

body.dark-mode .blog-alert.success {
    background-color: #1a2a18;
    color: #67c23a;
}

body.dark-mode #cancel-comment-reply-link {
    color: #e57373;
}

body.dark-mode #cancel-comment-reply-link:hover {
    color: var(--primary-dark);
}

/* 暗色模式：图片/视频轻微减亮以融入暗色背景 */
body.dark-mode .markdown-body img {
    opacity: 0.9;
}

body.dark-mode .markdown-body video {
    background: #000;
}

/* 暗色模式：文章头部信息与评论标题 */
body.dark-mode .article-header-info {
    border-bottom-color: var(--border-dark);
    color: var(--text-muted-dark);
}

body.dark-mode .post .time {
    color: var(--text-muted-dark);
}

body.dark-mode .comment-reply-title>span:first-child {
    border-left-color: var(--primary-dark);
    color: #d4d4e0;
}