/* ============================================================
   大白米Blog — 极简浅色主题
   从深色三栏主题重构为干净的两栏布局
   ============================================================ */

/* ----- CSS 自定义属性 ----- */
:root {
    /* 背景色 */
    --bg:           #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary:  #f1f3f5;

    /* 文字色 */
    --text-primary:   #212529;
    --text-secondary: #495057;
    --text-tertiary:  #868e96;
    --text-muted:     #adb5bd;

    /* 强调色 */
    --accent:        #228be6;
    --accent-hover:  #1c7ed6;
    --accent-light:  #e7f5ff;

    /* 边框 */
    --border:       #dee2e6;
    --border-light: #e9ecef;

    /* 阴影 (极轻) */
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
    --shadow-md: 0 2px 8px rgba(0,0,0,0.06);

    /* 圆角 */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;

    /* 字体 */
    --font-sans: system-ui, -apple-system, "Segoe UI", Roboto,
                 "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
    --font-mono: "SF Mono", "Fira Code", "Consolas", "JetBrains Mono", monospace;

    /* 字号 */
    --font-xs:   0.8125rem; /* 13px */
    --font-sm:   0.9375rem; /* 15px */
    --font-base: 1.0625rem; /* 17px */
    --font-lg:   1.1875rem; /* 19px */
    --font-xl:   1.375rem;  /* 22px */
    --font-2xl:  1.625rem;  /* 26px */
    --font-3xl:  2rem;      /* 32px */

    /* 行高 */
    --line-tight:   1.4;
    --line-normal:  1.6;
    --line-relaxed: 1.8;

    /* 间距 */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;

    /* 布局 */
    --sidebar-width: 260px;
    --header-height: 60px;
    --content-max-width: 1600px;
}

/* ----- 全局重置 ----- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: var(--font-base);
    line-height: var(--line-normal);
    color: var(--text-primary);
    background-color: var(--bg-secondary);
    position: relative;
}

/* 背景模糊层 */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    background: url('../img/blog_home_background.jpg') center/cover no-repeat fixed;
    filter: blur(6px);
    transform: scale(1.03);
    opacity: 0.85;
}

/* ----- 排版 ----- */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: var(--line-tight);
    color: var(--text-primary);
}

h1 { font-size: var(--font-3xl); }
h2 { font-size: var(--font-2xl); }
h3 { font-size: var(--font-xl); }
h4 { font-size: var(--font-lg); }
h5, h6 { font-size: var(--font-base); }

p {
    margin-bottom: var(--space-4);
    line-height: var(--line-relaxed);
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--accent-hover);
}

img {
    max-width: 100%;
    height: auto;
}

/* ----- 布局容器 ----- */
.app-wrapper {
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: transparent;
}

/* ===========================================================
   顶部导航栏
   =========================================================== */
.top-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--header-height);
    background: rgba(255,255,255,0.55);
    border-bottom: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--space-6);
    gap: var(--space-4);
}

.logo-area {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo-area h1 {
    font-size: var(--font-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0;
    white-space: nowrap;
}

.logo-area h1 i {
    color: var(--accent);
    margin-right: var(--space-2);
}

/* 搜索区 */
.search-area {
    flex: 1;
    max-width: 480px;
    position: relative;
    display: flex;
    align-items: center;
}

.search-area i.fa-search {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
    font-size: var(--font-sm);
    pointer-events: none;
    z-index: 2;
}

.search-area input[type="text"] {
    width: 100%;
    height: 38px;
    padding: 0 90px 0 38px;
    font-size: var(--font-sm);
    border: 1px solid var(--border);
    border-radius: 20px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    outline: none;
    transition: border-color 0.2s, background 0.2s;
}

.search-area input[type="text"]:focus {
    border-color: var(--accent);
    background: rgba(255,255,255,0.55);
}

.search-area input[type="text"]::placeholder {
    color: var(--text-muted);
}

.search-area button {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    height: 30px;
    padding: 0 16px;
    font-size: var(--font-sm);
    color: #fff;
    background: var(--accent);
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-area button:hover {
    background: var(--accent-hover);
}

/* 用户操作 */
.user-actions a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: var(--font-xl);
    transition: color 0.2s, background 0.2s;
}

.user-actions a:hover {
    color: var(--accent);
    background: var(--accent-light);
}

/* 汉堡菜单 (默认隐藏) */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 101;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    border-radius: 1px;
    transition: transform 0.2s, opacity 0.2s;
}

/* ===========================================================
   主体布局
   =========================================================== */
.main-layout {
    display: flex;
    max-width: var(--content-max-width);
    width: 100%;
    margin: calc(var(--header-height)) auto 0;
    padding: var(--space-4) var(--space-6) 0;
    gap: 0;
    flex: 1;
    background: rgba(255,255,255,0.55);
}

/* ===========================================================
   左侧边栏
   =========================================================== */
.sidebar {
    width: var(--sidebar-width);
    flex-shrink: 0;
    position: sticky;
    top: calc(var(--header-height) + var(--space-2));
    height: calc(100vh - var(--header-height) - var(--space-2));
    overflow-x: hidden;
    padding: 0 var(--space-4) var(--space-6);
    display: flex;
    flex-direction: column;
}

/* 个人资料 */
.profile {
    text-align: center;
    padding: var(--space-4) 0 var(--space-3);
}

.avatar {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--space-3);
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--border-light);
    transition: transform 0.5s ease;
}

.avatar:hover {
    transform: rotate(360deg) scale(1.1);
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile h3 {
    font-size: var(--font-lg);
    margin-bottom: var(--space-1);
}

.profile .bio {
    font-size: var(--font-sm);
    color: var(--text-tertiary);
    min-height: 1.5em;
}

.profile-introduction {
    font-size: var(--font-xs);
    color: var(--text-tertiary);
    line-height: var(--line-relaxed);
    padding: var(--space-2) 0;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
    margin-bottom: var(--space-3);
}

/* 导航菜单 */
.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0 0 var(--space-6);
}

.nav-item {
    margin-bottom: 2px;
}

.nav-item a {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: var(--font-sm);
    transition: background 0.15s, color 0.15s;
    gap: var(--space-3);
}

.nav-item a i {
    width: 18px;
    text-align: center;
    font-size: var(--font-sm);
}

.nav-item a:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.nav-item.active a {
    background: var(--accent-light);
    color: var(--accent);
    font-weight: 500;
}

.nav-item.has-sub > a i:last-child {
    margin-left: auto;
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.nav-item.has-sub.expanded > a i:last-child {
    transform: rotate(180deg);
}

.nav-divider {
    height: 1px;
    background: var(--border-light);
    margin: var(--space-3) 0;
}

/* 子菜单 */
.nav-sub {
    list-style: none;
    padding: 0 0 0 32px;
    margin: 0;
    display: none;
}

.nav-item.expanded .nav-sub {
    display: block;
    max-height: 320px;
    overflow-y: auto;
}

.nav-sub::-webkit-scrollbar {
    width: 3px;
}

.nav-sub::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 2px;
}

.nav-sub a {
    font-size: var(--font-xs);
    padding: 8px 12px;
}

.badge {
    margin-left: auto;
    background: var(--bg-tertiary);
    color: var(--text-tertiary);
    font-size: 11px;
    padding: 1px 7px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

.active-cate {
    color: var(--accent) !important;
    font-weight: 500;
}

/* 热门文章列表 */
.hot-articles {
    list-style: none;
    padding: 0;
}

.hot-article-item {
    padding: 6px 0;
}

.hot-article-item a {
    font-size: var(--font-sm);
    color: var(--text-secondary);
    display: block;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: color 0.15s, background 0.15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hot-article-item a:hover {
    color: var(--accent);
    background: var(--accent-light);
}

/* 博客信息 */
.blog-info {
    background: rgba(255,255,255,0.55);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.blog-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    font-size: var(--font-sm);
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-light);
}

.blog-info-item:last-child {
    border-bottom: none;
}

.blog-info-value {
    font-weight: 600;
    color: var(--accent);
}

/* 标签 */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-item {
    display: inline-block;
    font-size: var(--font-xs);
    color: var(--text-secondary);
    background: rgba(255,255,255,0.55);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 4px 10px;
    border-radius: 12px;
    cursor: default;
    transition: color 0.15s, background 0.15s, border-color 0.15s;
}

.tag-item:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: var(--accent-light);
}

/* 侧边栏底部链接 */
.sidebar-footer {
    display: flex;
    justify-content: space-around;
    padding-top: var(--space-4);
    border-top: 1px dashed var(--border-light);
    margin-top: auto;
}

.sidebar-footer a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: var(--font-xs);
    color: var(--text-tertiary);
    transition: color 0.2s;
}

.sidebar-footer a:hover {
    color: var(--accent);
}

.sidebar-footer a i {
    font-size: var(--font-lg);
}

/* ===========================================================
   右侧边栏
   =========================================================== */
.right-sidebar {
    width: 230px;
    flex-shrink: 0;
    position: sticky;
    top: calc(var(--header-height) + var(--space-2));
    height: calc(100vh - var(--header-height) - var(--space-2));
    overflow-y: auto;
    padding: 0 var(--space-4) var(--space-6);
}

.right-sidebar::-webkit-scrollbar {
    width: 3px;
}

.right-sidebar::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 2px;
}

.right-sidebar-section {
    margin-bottom: var(--space-5);
}

.right-sidebar-section:first-child {
    padding-top: var(--space-4);
}

.right-sidebar-section h3 {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: var(--space-2);
    padding-bottom: var(--space-1);
    border-bottom: 1px solid var(--border-light);
}

.right-sidebar-section h3 i {
    margin-right: var(--space-1);
    color: var(--accent);
}

/* ===========================================================
   主内容区
   =========================================================== */
.content {
    flex: 1;
    min-width: 0;
    padding: 0 0 var(--space-16) var(--space-6);
}

/* 公告栏 */
.notice-board {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: 12px 16px;
    background: #fff8e1;
    border: 1px solid #ffcc02;
    border-radius: var(--radius-md);
    margin-bottom: var(--space-6);
    font-size: var(--font-sm);
    color: #8d6e00;
}

.notice-board i.fa-bullhorn {
    color: #f9a825;
}

.close-notice {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    color: #bcaa79;
    font-size: var(--font-sm);
    padding: 4px;
    transition: color 0.2s;
}

.close-notice:hover {
    color: #8d6e00;
}

/* 页面头部 */
.page-header {
    margin-bottom: var(--space-8);
}

.page-header h2 {
    font-size: var(--font-2xl);
    font-weight: 700;
    margin-bottom: var(--space-2);
}

.page-header p {
    color: var(--text-tertiary);
    font-style: italic;
    margin-bottom: 0;
}

/* 搜索结果提示 */
.search-tip {
    padding: 10px 16px;
    background: var(--accent-light);
    border-radius: var(--radius-md);
    font-size: var(--font-sm);
    color: var(--text-secondary);
    margin-bottom: var(--space-6);
}

.search-tip strong {
    color: var(--accent);
}

/* ===========================================================
   文章列表卡片
   =========================================================== */
.post-item-link {
    text-decoration: none;
    color: inherit;
    display: block;
    margin-bottom: var(--space-5);
}

.post-item-link:hover .post-item {
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.post-item {
    background: rgba(255,255,255,0.55);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--radius-lg);
    padding: var(--space-6) var(--space-8);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.post-category {
    color: var(--text-secondary);
    font-weight: 500;
}

.post-title {
    font-size: var(--font-xl);
    font-weight: 600;
    margin-bottom: var(--space-3);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
}

.post-title a {
    color: var(--text-primary);
}

.post-title a:hover {
    color: var(--accent);
}

.sticky-label {
    display: inline-block;
    font-size: var(--font-xs);
    color: #fff;
    background: #f59e0b;
    padding: 2px 8px;
    border-radius: 3px;
    margin-right: var(--space-2);
    font-weight: 500;
}

.post-excerpt {
    color: var(--text-secondary);
    font-size: var(--font-sm);
    line-height: var(--line-relaxed);
    margin-bottom: var(--space-4);
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-5);
    padding-top: var(--space-4);
    border-top: 1px solid var(--border-light);
    font-size: var(--font-xs);
    color: var(--text-tertiary);
}

.post-meta span i {
    margin-right: 4px;
}

/* ===========================================================
   文章详情页
   =========================================================== */

/* 返回链接 */
.back-home {
    display: inline-block;
    margin-bottom: var(--space-6);
    font-size: var(--font-sm);
    color: var(--text-tertiary);
}

.back-home:hover {
    color: var(--accent);
}

/* 文章标题 */
.article-title {
    font-size: var(--font-3xl);
    font-weight: 700;
    margin-bottom: var(--space-4);
    line-height: 1.3;
}

/* 文章元信息 */
.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-5);
    padding: var(--space-4) var(--space-5);
    background: rgba(255,255,255,0.55);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-8);
    font-size: var(--font-sm);
    color: var(--text-secondary);
}

.article-meta span i {
    margin-right: 4px;
    color: var(--accent);
}

/* 文章内容区 */
.article-content {
    background: rgba(255,255,255,0.55);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    margin-bottom: var(--space-8);
    line-height: var(--line-relaxed);
    overflow-wrap: break-word;
}

.article-content * {
    max-width: 100%;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
    margin-top: var(--space-8);
    margin-bottom: var(--space-4);
    color: var(--text-primary);
}

.article-content h1 { font-size: var(--font-2xl); }
.article-content h2 { font-size: var(--font-xl); }
.article-content h3 { font-size: var(--font-lg); }

.article-content p {
    margin-bottom: var(--space-4);
    line-height: var(--line-relaxed);
}

.article-content img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    margin: var(--space-6) auto;
    transition: opacity 0.4s ease;
}

.article-content img.lazy-img {
    opacity: 0.5;
    background: #e9ecef;
    min-height: 100px;
}

.article-content img.lazy-loaded {
    opacity: 1;
}

.article-content a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* 代码块 */
.article-content pre {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: var(--space-6);
    overflow-x: auto;
    margin: var(--space-6) 0;
    font-family: var(--font-mono);
    font-size: var(--font-sm);
    line-height: 1.6;
}

.article-content code {
    font-family: var(--font-mono);
    font-size: 0.9em;
    background: var(--bg-tertiary);
    padding: 2px 6px;
    border-radius: 3px;
    color: #d63384;
}

.article-content pre code {
    background: none;
    padding: 0;
    color: inherit;
    font-size: inherit;
    border-radius: 0;
}

/* 文章标签 */
.post-tags {
    margin-left: var(--space-4);
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-link {
    display: inline-block;
    font-size: var(--font-xs);
    color: var(--accent);
    background: var(--accent-light);
    padding: 2px 10px;
    border-radius: 12px;
    transition: background 0.2s;
}

.tag-link:hover {
    background: #d0ebff;
}

/* ===========================================================
   图片预览遮罩
   =========================================================== */
.image-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.image-overlay-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: var(--radius-md);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.image-overlay-hint {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--font-sm);
    pointer-events: none;
}

/* ===== 全站加载动画 ===== */
#loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#loading-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

#loading-overlay .loader-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255,255,255,0.8);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    animation: loaderSpin 8s ease-in-out infinite;
}

@keyframes loaderSpin {
    0%   { transform: rotate(0deg); }
    25%  { transform: rotate(-720deg); }
    50%  { transform: rotate(-720deg); }
    75%  { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}

.loader-progress {
    width: 200px;
    height: 4px;
    background: rgba(0,0,0,0.1);
    border-radius: 2px;
    overflow: hidden;
}

.loader-progress-bar {
    height: 100%;
    background: var(--accent, #228be6);
    border-radius: 2px;
    width: 0%;
    transition: width 0.3s ease;
}

.loader-text {
    font-size: 13px;
    color: #868e96;
}

/* ===========================================================
   评论区
   =========================================================== */
.comment-module {
    margin-top: var(--space-8);
    padding-top: var(--space-6);
    border-top: 1px solid var(--border-light);
}

.comment-title {
    font-size: var(--font-lg);
    font-weight: 600;
    margin-bottom: var(--space-5);
    color: var(--text-primary);
}

/* 评论表单 */
.comment-form {
    background: rgba(255,255,255,0.55);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    margin-bottom: var(--space-8);
}

.form-group {
    margin-bottom: var(--space-4);
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    font-size: var(--font-sm);
    font-family: var(--font-sans);
    color: var(--text-primary);
    background: rgba(255,255,255,0.55);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    outline: none;
    resize: vertical;
    transition: border-color 0.2s;
}

.form-control:focus {
    border-color: var(--accent);
}

.form-control::placeholder {
    color: var(--text-muted);
}

textarea.form-control {
    min-height: 100px;
}

.btn-submit {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: 10px 24px;
    font-size: var(--font-sm);
    font-weight: 500;
    color: #fff;
    background: var(--accent);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: background 0.2s;
}

.btn-submit:hover {
    background: var(--accent-hover);
}

/* 评论消息 */
.message {
    display: none;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    margin-top: var(--space-3);
    font-size: var(--font-sm);
}

.message.success {
    display: block;
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    display: block;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* 评论列表 */
.comment-list {
    list-style: none;
    padding: 0;
}

.comment-item {
    background: rgba(255,255,255,0.55);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    margin-bottom: var(--space-4);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-3);
}

.comment-username {
    font-weight: 600;
    font-size: var(--font-sm);
    color: var(--accent);
}

.comment-time {
    font-size: var(--font-xs);
    color: var(--text-tertiary);
}

.comment-content {
    font-size: var(--font-sm);
    color: var(--text-primary);
    line-height: var(--line-relaxed);
}

.no-comment {
    text-align: center;
    color: var(--text-muted);
    font-size: var(--font-sm);
    padding: var(--space-8) 0;
}

/* ===========================================================
   分页
   =========================================================== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    margin-top: var(--space-8);
}

.pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 8px;
    font-size: var(--font-sm);
    color: var(--text-secondary);
    background: rgba(255,255,255,0.55);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.pagination a:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.pagination a.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.pagination a.disabled {
    opacity: 0.4;
    pointer-events: none;
}

.pagination .ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    font-size: var(--font-sm);
    color: var(--text-muted);
}

/* ===========================================================
   空状态
   =========================================================== */
.no-articles {
    text-align: center;
    padding: var(--space-8);
    color: var(--text-muted);
    font-size: var(--font-sm);
}

/* ===========================================================
   页脚
   =========================================================== */
.footer {
    text-align: center;
    padding: var(--space-8) var(--space-6);
    margin-top: auto;
    border-top: 1px solid var(--border-light);
    color: var(--text-muted);
    font-size: var(--font-xs);
    line-height: 1.8;
}

.footer a {
    color: var(--text-tertiary);
}

.footer a:hover {
    color: var(--accent);
}

.footer-badge {
    font-weight: 600;
    color: var(--accent);
}

/* ===========================================================
   返回顶部按钮
   =========================================================== */
.back-to-top {
    position: fixed;
    right: 28px;
    bottom: 28px;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 99;
    font-size: var(--font-lg);
    transition: opacity 0.3s, transform 0.2s;
    opacity: 0;
    pointer-events: none;
}

.back-to-top.show {
    opacity: 1;
    pointer-events: auto;
}

.back-to-top.hide {
    opacity: 0;
    pointer-events: none;
}

.back-to-top:hover {
    transform: translateY(-3px);
}

/* ===========================================================
   响应式设计
   =========================================================== */

/* 平板端 (≤1023px): 侧边栏变为滑出式抽屉 */
@media (max-width: 1023px) {
    .menu-toggle {
        display: flex;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        width: 280px;
        height: 100vh;
        z-index: 200;
        background: rgba(255,255,255,0.55);
        padding: calc(var(--header-height) + var(--space-4)) var(--space-5) var(--space-8);
        border-right: 1px solid var(--border);
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .sidebar.active {
        transform: translateX(0);
        box-shadow: 2px 0 20px rgba(0,0,0,0.15);
    }

    .right-sidebar {
        display: none;
    }

    .main-layout {
        padding: 0 var(--space-4);
    }

    .content {
        padding-left: 0;
    }

    .top-header {
        padding: 0 var(--space-4);
    }

    .search-area {
        max-width: 360px;
    }
}

/* 手机端 (≤767px) */
@media (max-width: 767px) {
    .top-header {
        gap: var(--space-3);
    }

    .logo-area h1 {
        font-size: var(--font-base);
    }

    .search-area {
        max-width: none;
        flex: 1;
    }

    .search-area button {
        font-size: 0;
        padding: 0 12px;
    }

    .search-area button i {
        font-size: var(--font-sm);
    }

    .main-layout {
        padding: 0 var(--space-3);
        margin-top: calc(var(--header-height) + var(--space-3));
    }

    .content {
        padding: 0;
    }

    .post-item {
        padding: var(--space-4);
    }

    .post-title {
        font-size: var(--font-lg);
    }

    .post-meta {
        gap: var(--space-3);
    }

    .article-content {
        padding: var(--space-4);
    }

    .article-title {
        font-size: var(--font-2xl);
    }

    .article-meta {
        gap: var(--space-3);
    }

    .pagination a {
        min-width: 32px;
        height: 32px;
        font-size: var(--font-xs);
    }

    .blog-info-item {
        font-size: var(--font-xs);
        padding: 8px 12px;
    }

    .back-to-top {
        right: 16px;
        bottom: 16px;
        width: 38px;
        height: 38px;
    }
}

/* 小屏手机 (≤479px) */
@media (max-width: 479px) {
    .logo-area h1 {
        font-size: var(--font-sm);
    }

    .top-header {
        padding: 0 var(--space-3);
    }

    .search-area {
        max-width: none;
    }

    .post-item {
        padding: var(--space-3);
        border-radius: var(--radius-md);
    }

    .post-title {
        font-size: var(--font-base);
    }

    .blog-info-item {
        flex-direction: column;
        gap: 4px;
        text-align: center;
    }
}
