/*
 * Aimole theme for Typecho
 * 参考 aimole.cn 视觉风格：卡片化、圆角、亮暗双模式
 */

:root {
    --bg: #f7f8fa;
    --bg-soft: #f6f8fb;
    --card: #ffffff;
    --card-hover: #ffffff;
    --border: #eef0f4;
    --border-strong: #d5d9e2;
    --text-1: #1f2329;
    --text-2: #4e5969;
    --text-3: #86909c;
    --text-4: #c9cdd4;
    --primary: #4f6ef7;
    --primary-strong: #3d5bf0;
    --primary-weak: #7c8ffb;
    --accent: #8b5cf6;
    --cyan: #06b6d4;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --gradient: linear-gradient(120deg, #4f6ef7 0%, #8b5cf6 100%);
    --nav-bg: rgba(255, 255, 255, 0.6);
    --code-bg: #f2f4f8;
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 4px 14px rgba(15, 23, 42, 0.08);
    --glow-hover: 0 0 0 1px rgba(79, 110, 247, 0.18), 0 12px 32px rgba(79, 110, 247, 0.12);
    --radius-sm: 8px;
    --radius: 10px;
    --radius-lg: 16px;
    --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

body[theme-mode="dark"] {
    --bg: #1b1c22;
    --bg-soft: #262a34;
    --card: #23242b;
    --card-hover: #2a2c35;
    --border: #3a3c47;
    --border-strong: #434552;
    --text-1: #f2f3f5;
    --text-2: #c9cdd4;
    --text-3: #86909c;
    --text-4: #5f6672;
    --primary: #7c8ffb;
    --primary-strong: #a5b4ff;
    --primary-weak: #4f6ef7;
    --accent: #a78bfa;
    --cyan: #22d3ee;
    --gradient: linear-gradient(120deg, #4f6ef7 0%, #8b5cf6 100%);
    --nav-bg: rgba(35, 36, 43, 0.6);
    --code-bg: #1b1c22;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.35);
    --glow-hover: 0 0 0 1px rgba(124, 143, 251, 0.18), 0 12px 32px rgba(0, 0, 0, 0.4);
}

/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    background: var(--bg);
    color: var(--text-1);
    font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.7;
    transition: background var(--transition), color var(--transition);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition);
}

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

img {
    max-width: 100%;
    height: auto;
}

ul, ol {
    list-style: none;
}

button {
    font-family: inherit;
    cursor: pointer;
}

input, textarea {
    font-family: inherit;
}

.container {
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 顶部导航：毛玻璃吸顶 */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--nav-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 2px 3px -2px rgba(15, 23, 42, 0.08);
}

body[theme-mode="dark"] .site-nav {
    box-shadow: 0 2px 3px -2px rgba(0, 0, 0, 0.35);
}

.nav-inner {
    display: flex;
    align-items: center;
    gap: 20px;
    height: 52px;
}

.nav-logo {
    font-size: 19px;
    font-weight: 800;
    letter-spacing: 0.5px;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    flex: 1;
    min-width: 0;
}

.nav-links a {
    color: var(--text-2);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    padding: 6px 2px;
}

.nav-links a:hover {
    color: var(--text-1);
}

.nav-links a.current {
    color: var(--primary);
    font-weight: 600;
}

/* 导航分类下拉 */
.nav-dropdown {
    position: relative;
}

.nav-drop-toggle {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.nav-drop-toggle .caret {
    width: 12px;
    height: 12px;
    transform: rotate(180deg);
    transition: transform var(--transition);
}

.drop-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translate(-50%, 6px);
    min-width: 160px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 6px;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
    z-index: 210;
}

.drop-menu a {
    display: block;
    padding: 7px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-2);
    font-size: 13px;
    transition: all var(--transition);
}

.drop-menu a:hover {
    background: var(--bg-soft);
    color: var(--primary);
}

.drop-menu a.current {
    color: var(--primary);
    font-weight: 600;
}

@media (min-width: 961px) {
    .nav-dropdown:hover .drop-menu, .nav-dropdown.open .drop-menu {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, 0);
    }

    .nav-dropdown:hover .caret,
    .nav-dropdown.open .caret,
    .nav-drop-toggle.current .caret {
        transform: rotate(0deg);
    }
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-2);
    transition: color var(--transition);
}

.icon-btn:hover {
    color: var(--primary);
}

.icon-btn svg {
    width: 18px;
    height: 18px;
}

/* 主题切换按钮在暗色下的图标互换 */
.icon-btn .icon-sun {
    display: none;
}

body[theme-mode="dark"] .icon-btn .icon-moon {
    display: none;
}

body[theme-mode="dark"] .icon-btn .icon-sun {
    display: block;
}

/* 主布局：主列 + 侧栏 */
.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 316px;
    gap: 24px;
    align-items: start;
    margin-top: 24px;
    padding-bottom: 40px;
}

/* 网格项允许收缩, 防止正文长内容(min-content)撑破布局 */
#main {
    min-width: 0;
}

/* 归档页头(分类/标签/搜索/作者) */
.archive-header {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 12px 16px;
    margin-bottom: 18px;
}

.archive-kicker {
    font-size: 12px;
    color: var(--text-3);
    white-space: nowrap;
}

.archive-name {
    font-size: 24px;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 文章卡片 */
.post-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    margin-bottom: 18px;
    transition: all var(--transition);
}

/* 列表卡片悬浮反馈; 文章/单页容器不参与 */
.post-card:not(.single-card):hover {
    border-color: var(--primary-weak);
    box-shadow: var(--glow-hover);
}

/* 文章页/单页的卡片需要内边距 */
.post-card.single-card {
    padding: 14px 16px;
}

/* 详情页: 标题+meta 与正文用横线分割 */
/* 详情页: 标题与 meta 之间、meta 与正文之间各一条横线 */
.single-card .post-meta {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.single-card .post-title + .post-content {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border);
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-3);
}

.post-meta .meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    line-height: 1;
}

.post-meta .meta-item svg {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
}

.post-title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.45;
}

.post-title a {
    color: var(--text-1);
}

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

.post-meta a {
    color: var(--text-3);
}

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

/* 分类: 主题色文字链接, 无框 */
.post-meta .meta-category a {
    color: var(--primary);
    font-weight: 500;
    transition: all var(--transition);
}

.post-meta .meta-category a:hover {
    color: var(--primary-strong);
}

.post-excerpt {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px dashed var(--border);
    color: var(--text-2);
    font-size: 14px;
    flex: 1;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.post-card-foot {
    display: flex;
    justify-content: flex-end;
    margin-top: auto;
    padding-top: 12px;
}

.post-more {
    display: inline-block;
    padding: 4px 14px;
    border-radius: var(--radius);
    background: var(--primary);
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    transition: all var(--transition);
}

.post-more:hover {
    background: var(--primary-strong);
    color: #fff;
}

/* 文章页大标题 */
.single-card .post-title {
    font-size: 26px;
}

/* 文章正文排版 */
.post-content {
    margin-top: 18px;
    font-size: 15px;
    color: var(--text-1);
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.post-content h2, .post-content h3, .post-content h4 {
    margin: 26px 0 12px;
    font-weight: 700;
    line-height: 1.5;
}

.post-content h2 {
    font-size: 20px;
    padding-left: 10px;
    border-left: 4px solid var(--primary);
}

.post-content h3 {
    font-size: 17px;
}

.post-content h4 {
    font-size: 15px;
}

.post-content p {
    margin: 12px 0;
}

.post-content a {
    border-bottom: 1px dashed var(--primary-weak);
}

.post-content ul, .post-content ol {
    margin: 12px 0;
    padding-left: 24px;
}

.post-content ul {
    list-style: disc;
}

.post-content ol {
    list-style: decimal;
}

.post-content li {
    margin: 4px 0;
}

.post-content blockquote {
    margin: 16px 0;
    padding: 12px 16px;
    background: var(--bg-soft);
    border-left: 3px solid var(--primary-weak);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    color: var(--text-2);
}

.post-content img {
    border-radius: var(--radius);
}

.post-content code {
    padding: 2px 6px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 13px;
    font-family: Consolas, Monaco, "Courier New", monospace;
    color: var(--danger);
}

.post-content pre {
    margin: 16px 0;
    padding: 16px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow-x: auto;
    line-height: 1.6;
}

.post-content pre code {
    padding: 0;
    background: none;
    border: none;
    color: var(--text-1);
}

.post-content table {
    width: 100%;
    margin: 16px 0;
    border-collapse: collapse;
    font-size: 14px;
}

.post-content th, .post-content td {
    padding: 8px 12px;
    border: 1px solid var(--border);
    text-align: left;
}

.post-content th {
    background: var(--bg-soft);
    font-weight: 600;
}

.post-content hr {
    margin: 24px 0;
    border: none;
    border-top: 1px solid var(--border);
}

/* 文章标签 */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.post-tags-icon {
    display: inline-flex;
    color: var(--text-3);
}

.post-tags-icon svg {
    width: 14px;
    height: 14px;
}

.post-tags a {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 999px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    color: var(--text-2);
    font-size: 12px;
    transition: all var(--transition);
}

.post-tags a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* 上一篇下一篇 */
.post-near {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
    margin: 24px 0;
}

.post-near li {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 10px 14px;
    font-size: 13px;
    color: var(--text-3);
    transition: all var(--transition);
    min-width: 0;
}
.post-near li:hover {
    border-color: var(--primary-weak);
    box-shadow: var(--glow-hover);
}

.post-near a {
    display: block;
    margin-top: 4px;
    color: var(--text-1);
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

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

.post-near li:last-child {
    text-align: right;
}

/* 分页 */
.page-navigator {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 28px 0 8px;
}

.page-navigator li a, .page-navigator li span {
    display: inline-block;
    min-width: 34px;
    padding: 6px 12px;
    border-radius: var(--radius);
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--text-2);
    font-size: 13px;
    text-align: center;
    transition: all var(--transition);
}

.page-navigator li a:hover {
    border-color: var(--primary-weak);
    color: var(--primary);
}

.page-navigator li a:hover {
    border-color: var(--primary-weak);
    color: var(--primary);
}

.page-navigator li.current a {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    font-weight: 600;
}

.page-navigator li.current a:hover {
    color: #fff;
}

.page-navigator li.current span {
    background: var(--primary);
    border-color: transparent;
    color: #fff;
    font-weight: 600;
}

/* 侧栏组件卡片 */
.widget {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 12px 14px;
    margin-bottom: 18px;
}

.widget-title {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 12px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
    font-weight: 700;
    color: var(--text-1);
}

.widget-title::before {
    content: "";
    width: 4px;
    height: 14px;
    border-radius: 2px;
    background: var(--gradient);
}

.widget-list li {
    position: relative;
    padding: 6px 0 6px 14px;
    border-bottom: 1px dashed var(--border);
    font-size: 13px;
}

.widget-list li::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 13px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--primary-weak);
    opacity: 0.7;
    transition: all var(--transition);
}

.widget-list li:hover::before {
    background: var(--primary);
    opacity: 1;
    transform: scale(1.3);
}

.widget-list li:last-child {
    border-bottom: none;
}

.widget-list a {
    color: var(--text-2);
}

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

/* 侧栏标签云 */
.widget .tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.widget .tag-cloud a {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    color: var(--text-2);
    font-size: 12px;
    transition: all var(--transition);
}

.widget .tag-cloud a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* 侧栏搜索框 */
.search-form {
    display: flex;
    gap: 8px;
}

.search-form input {
    flex: 1;
    min-width: 0;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-soft);
    color: var(--text-1);
    font-size: 13px;
    outline: none;
    transition: all var(--transition);
}

.search-form input:focus {
    border-color: var(--primary-weak);
    background: var(--card);
    box-shadow: 0 0 0 3px rgba(79, 110, 247, 0.08);
}

/* 通用按钮 */
.btn-primary {
    display: inline-block;
    padding: 8px 18px;
    border: none;
    border-radius: var(--radius);
    background: var(--gradient);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    transition: all var(--transition);
}

.btn-primary:hover {
    filter: brightness(1.08);
    box-shadow: 0 6px 16px rgba(79, 110, 247, 0.35);
    color: #fff;
}

/* 评论列表 */
#comments {
    margin-top: 28px;
}

.comments-title, .respond-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 700;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 14px;
}

.comments-title::before, .respond-title::before {
    content: "";
    width: 4px;
    height: 15px;
    border-radius: 2px;
    background: var(--gradient);
}

/* 表单卡标题: 渐变竖条 */
.respond-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 14px;
}

.respond-title::before {
    content: "";
    width: 4px;
    height: 15px;
    border-radius: 2px;
    background: var(--gradient);
}

/* 登录态身份条 */
.respond-identity {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 14px;
}

.respond-identity img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: block;
}

.respond-identity .respond-name {
    font-weight: 600;
    font-size: 13px;
    color: var(--text-1);
}

.respond-identity .respond-logout {
    font-size: 12px;
    color: var(--text-3);
    transition: color var(--transition);
}

.respond-identity .respond-logout:hover {
    color: var(--danger);
}

.comment-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 12px 14px;
    margin-bottom: 12px;
}

.comment-list .comment-children {
    margin-top: 10px;
    padding-left: 12px;
    border-left: 2px solid var(--border);
}

.comment-list .comment-children li {
    background: var(--bg-soft);
    margin-bottom: 10px;
}

.comment-list .comment-children li:last-child {
    margin-bottom: 0;
}

.comment-avatar {
    flex-shrink: 0;
}

.comment-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border);
    display: block;
}

.comment-avatar .avatar-tile {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient);
    color: #fff;
    font-weight: 700;
    font-size: 15px;
}

.comment-main {
    flex: 1;
    min-width: 0;
}

.comment-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.comment-name {
    font-weight: 600;
    font-size: 13px;
    color: var(--text-1);
}

.comment-name a {
    color: inherit;
}

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

.comment-awaiting {
    font-style: normal;
    font-size: 12px;
    color: var(--warning);
}

.comment-date {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    line-height: 1;
    color: var(--text-3);
}

.comment-date svg {
    width: 12px;
    height: 12px;
}

.comment-content {
    margin-top: 6px;
    font-size: 14px;
    color: var(--text-2);
}

.comment-content p {
    margin: 6px 0;
}

.comment-foot {
    margin-top: 8px;
    font-size: 12px;
}

/* 评论操作胶囊按钮(回复/通过/删除) */
.comment-reply a, .comment-delete, .comment-approve {
    display: inline-block;
    padding: 2px 12px;
    margin-right: 6px;
    border-radius: 999px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    color: var(--text-3);
    transition: all var(--transition);
}

.comment-reply a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.comment-approve:hover {
    background: var(--success);
    border-color: var(--success);
    color: #fff;
}

.comment-delete:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: #fff;
}

/* 待审核评论管理卡(编辑可见) */
.moderation-card {
    margin-top: 20px;
    background: var(--card);
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
}

.moderation-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--warning);
    margin-bottom: 10px;
}

.moderation-item {
    padding: 10px 12px;
    background: var(--bg-soft);
    border-radius: var(--radius);
    margin-bottom: 10px;
}

.moderation-item:last-child {
    margin-bottom: 0;
}

.moderation-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
}

.moderation-head b {
    color: var(--text-1);
}

.moderation-head time {
    color: var(--text-3);
    font-size: 12px;
}

.moderation-text {
    margin-top: 6px;
    font-size: 13px;
    color: var(--text-2);
}

.moderation-actions {
    margin-top: 8px;
}

/* 评论表单 */
.respond {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    margin-top: 20px;
}

.respond p {
    margin: 12px 0;
}

.respond label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: var(--text-2);
}

.respond label.required::after {
    content: " *";
    color: var(--danger);
}

.respond input.text, .respond textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-soft);
    color: var(--text-1);
    font-size: 14px;
    outline: none;
    transition: all var(--transition);
}

.respond input.text:focus, .respond textarea:focus {
    border-color: var(--primary-weak);
    background: var(--card);
    box-shadow: 0 0 0 3px rgba(79, 110, 247, 0.08);
}

.respond textarea {
    resize: vertical;
}

.respond .submit {
    padding: 9px 22px;
    border: none;
    border-radius: var(--radius);
    background: var(--gradient);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    transition: all var(--transition);
}

.respond .submit:hover {
    filter: brightness(1.08);
    box-shadow: 0 6px 16px rgba(79, 110, 247, 0.35);
}

.respond .submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    filter: none;
    box-shadow: none;
}

/* 评论提交被拦截等错误提示 */
.comment-error-tip {
    margin-top: 12px;
    padding: 8px 12px;
    border: 1px solid rgba(239, 68, 68, 0.35);
    background: rgba(239, 68, 68, 0.08);
    border-radius: var(--radius);
    color: var(--danger);
    font-size: 13px;
}

.cancel-comment-reply {
    font-size: 13px;
}

/* 404 页面 */
.error-page {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
}

.error-page h2 {
    font-size: 40px;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.error-page p {
    margin: 12px 0 20px;
    color: var(--text-2);
}

.error-page .search-form {
    max-width: 360px;
    margin: 0 auto;
}

/* 关于页 */
.about-card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border);
    font-size: 22px;
    font-weight: 700;
    color: var(--text-1);
}

.about-card-title::before {
    content: "";
    width: 4px;
    height: 18px;
    border-radius: 2px;
    background: var(--gradient);
}

.about-card .post-content {
    margin-top: 14px;
    font-size: 15px;
    line-height: 2;
}

/* 友情链接页 */
.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 12px;
}

.link-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: all var(--transition);
    min-width: 0;
}

.link-card:hover {
    border-color: var(--primary-weak);
    box-shadow: var(--glow-hover);
    transform: translateY(-2px);
}

.link-tile {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
}

.link-card:nth-child(4n+1) .link-tile {
    background: linear-gradient(135deg, #4f6ef7, #7c8ffb);
}

.link-card:nth-child(4n+2) .link-tile {
    background: linear-gradient(135deg, #8b5cf6, #a78bfa);
}

.link-card:nth-child(4n+3) .link-tile {
    background: linear-gradient(135deg, #06b6d4, #22d3ee);
}

.link-card:nth-child(4n+4) .link-tile {
    background: linear-gradient(135deg, #10b981, #34d399);
}

.link-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.link-info b {
    color: var(--text-1);
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-info i {
    color: var(--text-2);
    font-size: 12px;
    font-style: normal;
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-info em {
    color: var(--text-4);
    font-size: 11px;
    font-style: normal;
    margin-top: 2px;
}

.links-empty {
    color: var(--text-3);
    font-size: 14px;
    text-align: center;
    padding: 20px 0;
}

.links-note {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed var(--border);
    color: var(--text-2);
    font-size: 14px;
}

@media (max-width: 560px) {
    .links-grid {
        grid-template-columns: 1fr;
    }
}

/* 返回顶部按钮 */
.back-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 150;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: var(--card);
    color: var(--text-2);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--transition);
    cursor: pointer;
}

.back-top.show {
    opacity: 1;
    visibility: visible;
    transform: none;
}

.back-top:hover {
    color: var(--primary);
    border-color: var(--primary-weak);
}

.back-top svg {
    width: 18px;
    height: 18px;
}

/* 页脚 */
.site-footer {
    border-top: 1px solid #dddddd;
    padding: 12px 0;
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-3);
}

body[theme-mode="dark"] .site-footer {
    border-top-color: var(--border);
}

.site-footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-align: center;
}

.site-footer a {
    color: var(--text-3);
}

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

/* 文章卡片：左图右文 */
.post-card-body {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
}

.post-thumb {
    display: block;
    align-self: stretch;
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--bg-soft);
}

.post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.post-card:hover .post-thumb img {
    transform: scale(1.05);
}

.post-card-main {
    min-width: 0;
    height: 165px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.post-card-main .post-title {
    margin-top: 0;
}

/* 全宽布局（时光轴等无侧栏页面） */
.layout-full {
    grid-template-columns: minmax(0, 1fr);
}

/* 时光轴 */
.timeline {
    position: relative;
    margin: 4px 0 8px 6px;
    padding-left: 28px;
    border-left: 2px solid var(--border);
}

.timeline-year {
    position: relative;
    margin: 30px 0 16px;
    font-size: 22px;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.timeline-year:first-child {
    margin-top: 8px;
}

.timeline-year::before {
    content: "";
    position: absolute;
    left: -36px;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--gradient);
    box-shadow: 0 0 0 4px rgba(79, 110, 247, 0.15);
}

.timeline-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
    padding: 10px 14px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: all var(--transition);
    min-width: 0;
}

.timeline-item::before {
    content: "";
    position: absolute;
    left: -34px;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-weak);
    transition: transform var(--transition);
}

/* 卡片悬浮右移时圆点反向平移, 保持压在时间轴线上 */
.timeline-item:hover::before {
    transform: translateY(-50%) translateX(-3px);
}

.timeline-item:hover {
    border-color: var(--primary-weak);
    box-shadow: var(--glow-hover);
    transform: translateX(3px);
}

.timeline-item .t-date {
    flex-shrink: 0;
    font-size: 12px;
    color: var(--text-3);
    min-width: 56px;
}

.timeline-item .t-title {
    color: var(--text-1);
    font-weight: 400;
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timeline-item .t-title:hover {
    color: var(--primary);
}

/* 移动端汉堡菜单(aimole.cn 同款平铺药丸) */
.nav-burger {
    display: none;
}

.nav-drawer {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card);
    border-top: 1px solid var(--border);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 12px 14px 14px;
    z-index: 210;
}

.nav-drawer.open {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.nav-drawer a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 6px;
    font-size: 14px;
    color: var(--text-2);
    background: var(--bg-soft);
    border-radius: var(--radius-sm);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: all var(--transition);
}

.nav-drawer a:hover {
    color: var(--primary);
    background: rgba(79, 110, 247, 0.1);
}

.nav-drawer a.current {
    color: var(--primary);
    background: rgba(79, 110, 247, 0.1);
    font-weight: 600;
}

body[theme-mode="dark"] .nav-drawer a.current {
    background: rgba(124, 143, 251, 0.15);
}

body[theme-mode="dark"] .nav-drawer a:hover {
    background: rgba(124, 143, 251, 0.15);
}

/* 导航展开式搜索 */
.nav-search {
    display: flex;
    align-items: center;
}

.nav-search input {
    width: 0;
    opacity: 0;
    padding: 0;
    border: 1px solid transparent;
    border-radius: var(--radius);
    background: var(--bg-soft);
    color: var(--text-1);
    font-size: 13px;
    outline: none;
    transition: all var(--transition);
}

.nav-search.open input {
    width: 180px;
    opacity: 1;
    padding: 6px 12px;
    margin-right: 4px;
    border-color: var(--border);
}

.nav-search.open input:focus {
    border-color: var(--primary-weak);
    background: var(--card);
}

/* 导航登录态头像与下拉菜单 */
.nav-user {
    position: relative;
}

.nav-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
}

.nav-avatar img {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: block;
}

.user-menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    min-width: 140px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 6px;
    z-index: 210;
}

.user-menu.open {
    display: block;
}

.user-menu a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-2);
    font-size: 13px;
    transition: all var(--transition);
}

.user-menu a svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.user-menu a:hover {
    background: var(--bg-soft);
    color: var(--primary);
}

/* 登录弹窗 */
.login-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(15, 23, 42, 0.45);
    align-items: center;
    justify-content: center;
    padding: 20px;
}

body[theme-mode="dark"] .login-overlay {
    background: rgba(0, 0, 0, 0.6);
}

.login-overlay.open {
    display: flex;
}

.login-modal {
    position: relative;
    width: 340px;
    max-width: 100%;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    box-shadow: var(--shadow-md);
}

.login-close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: none;
    background: none;
    font-size: 20px;
    line-height: 1;
    color: var(--text-3);
}

.login-close:hover {
    color: var(--danger);
}

.login-title {
    margin-bottom: 14px;
    text-align: center;
    font-size: 17px;
    font-weight: 700;
    color: var(--text-1);
}

.login-modal input[type="text"], .login-modal input[type="password"] {
    width: 100%;
    padding: 9px 12px;
    margin-bottom: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-soft);
    color: var(--text-1);
    font-size: 13px;
    outline: none;
    transition: all var(--transition);
}

.login-modal input[type="text"]:focus, .login-modal input[type="password"]:focus {
    border-color: var(--primary-weak);
    background: var(--card);
    box-shadow: 0 0 0 3px rgba(79, 110, 247, 0.08);
}

.login-remember {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    font-size: 12px;
    color: var(--text-2);
}

.login-submit {
    width: 100%;
    text-align: center;
    padding: 9px 0;
    font-size: 14px;
}

.login-foot {
    margin-top: 12px;
    text-align: center;
    font-size: 12px;
    color: var(--text-3);
}

/* 响应式：窄屏收起侧栏 */
@media (max-width: 960px) {
    .layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .nav-inner {
        gap: 12px;
    }

    .nav-logo {
        font-size: 18px;
    }

    /* 移动端: 隐藏横向导航与分类下拉, 显示汉堡 */
    .nav-links {
        display: none;
    }

    .nav-burger {
        display: inline-flex;
    }

    .nav-actions {
        margin-left: auto;
    }
}

@media (max-width: 640px) {
    .post-card-body {
        grid-template-columns: 1fr;
    }

    .post-thumb {
        height: 150px;
        border-radius: var(--radius);
    }

    .post-card-main {
        padding: 0;
        height: auto;
        overflow: visible;
    }

    .timeline-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .timeline-item .t-title {
        max-width: 100%;
    }

    /* meta 行移动端压缩到单行 */
    .post-card .post-meta {
        flex-wrap: nowrap;
        gap: 5px;
        font-size: 10.5px;
        overflow: hidden;
    }

    .post-card .post-meta .meta-item {
        gap: 3px;
        flex-shrink: 0;
    }

    .post-card .post-meta .meta-item svg {
        width: 11px;
        height: 11px;
    }

    .single-card .post-title {
        font-size: 22px;
    }

    .post-near {
        grid-template-columns: minmax(0, 1fr);
    }

    .post-near li:last-child {
        text-align: left;
    }
}
