/* 朱雀仿宋字体 */
@import 'https://chinese-fonts-cdn.deno.dev/packages/zqfs/dist/ZhuqueFangsong-Regular/result.css';

/* 自动加空格 - 仅在阅读器模式下生效 */
.reader-content hanla:after {
	content: " ";
	display: inline;
	font-family: Arial;
	font-size: 0.89em;
}

.reader-content code hanla,
.reader-content pre hanla,
.reader-content kbd hanla,
.reader-content samp hanla {
	display: none;
}

.reader-content ol > hanla,
.reader-content ul > hanla {
	display: none;
}

.reader-content tr > hanla {
    display: none;
}

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

/* CSS变量定义 */
:root {
    /* 颜色主题 - 基于主站 hsla(200, 100%, 50%, 1.0) */
    --primary-color: hsla(200, 100%, 50%, 1.0);  /* 主站主色 */
    --primary-hover: hsla(200, 100%, 45%, 1.0);  /* 悬停时稍深 */
    --primary-light: hsla(200, 100%, 85%, 1.0);  /* 浅色变体 */
    --primary-dark: hsla(200, 100%, 35%, 1.0);   /* 深色变体 */
    --secondary-color: hsla(200, 30%, 50%, 1.0); /* 次要颜色 */
    --accent-color: hsla(30, 95%, 55%, 1.0);     /* 橙色强调色 */
    --accent-color-rgb: 245, 158, 11;
    
    /* 背景色 - 基于蓝色调的中性色 */
    --bg-primary: hsla(200, 20%, 98%, 1.0);      /* 主背景 */
    --bg-secondary: hsla(200, 25%, 96%, 1.0);    /* 次要背景 */
    --bg-tertiary: hsla(200, 30%, 94%, 1.0);     /* 第三级背景 */
    --bg-card: hsla(200, 40%, 99%, 1.0);         /* 卡片背景 */
    
    /* 文字颜色 - 基于蓝色调的灰色 */
    --text-primary: hsla(200, 25%, 15%, 1.0);    /* 主文字 */
    --text-secondary: hsla(200, 15%, 45%, 1.0);  /* 次要文字 */
    --text-muted: hsla(200, 10%, 60%, 1.0);      /* 弱化文字 */
    
    /* 边框颜色 - 基于蓝色调 */
    --border-color: hsla(200, 20%, 88%, 1.0);    /* 边框色 */
    --border-hover: hsla(200, 30%, 80%, 1.0);    /* 悬停边框 */
    
    /* 阴影 */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    /* 圆角 - 基于8px原则 */
    --radius-sm: 4px;   /* 4px */
    --radius-md: 8px;   /* 8px */
    --radius-lg: 12px;  /* 12px */
    --radius-xl: 16px;  /* 16px */
    
    /* 间距 - 基于8px原则 */
    --spacing-xs: 4px;   /* 4px */
    --spacing-sm: 8px;   /* 8px */
    --spacing-md: 16px;  /* 16px */
    --spacing-lg: 16px;  /* 16px */
    --spacing-xl: 32px;  /* 32px */
    --spacing-2xl: 48px; /* 48px */
    --spacing-3xl: 64px; /* 64px */
    
    /* 字体 */
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    
    /* 中英文间距 */
    --text-autospace: normal;
}

/* 暗色主题 - 基于蓝色调优化 */
[data-theme="dark"] {
    --bg-primary: hsla(200, 30%, 8%, 1.0);       /* 深蓝灰主背景 */
    --bg-secondary: hsla(200, 25%, 12%, 1.0);    /* 次要背景 */
    --bg-tertiary: hsla(200, 20%, 16%, 1.0);     /* 第三级背景 */
    --bg-card: hsla(200, 25%, 10%, 1.0);         /* 卡片背景 */
    
    --text-primary: hsla(200, 20%, 92%, 1.0);    /* 主文字 */
    --text-secondary: hsla(200, 15%, 75%, 1.0);  /* 次要文字 */
    --text-muted: hsla(200, 10%, 55%, 1.0);      /* 弱化文字 */
    
    --border-color: hsla(200, 15%, 20%, 1.0);    /* 边框色 */
    --border-hover: hsla(200, 20%, 30%, 1.0);    /* 悬停边框 */
    
    /* 暗色主题下的主色调整 */
    --primary-color: hsla(200, 100%, 60%, 1.0);  /* 稍亮的主色 */
    --primary-hover: hsla(200, 100%, 65%, 1.0);  /* 悬停时更亮 */
}

/* 基础样式 */
body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 1680px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}



/* 瀑布流容器 - 旧定义已移除 */

/* 旧的响应式列数调整已移至瀑布流布局部分 */

/* 站点卡片样式 */
.site-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm), 0 0 0 1px hsla(200, 100%, 50%, 0.05);
    padding: 0;
    transition: all 0.3s ease;
    width: 100%;
    min-height: 0;
    max-height: none;
    display: flex;
    flex-direction: column;
    padding-bottom: var(--spacing-md);
    overflow-y: auto;
}

.site-card:hover {
    box-shadow: var(--shadow-md), 0 0 20px hsla(200, 100%, 50%, 0.15);
    transform: translateY(-2px);
    border-color: var(--primary-light);
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid var(--border-color);
}

.site-title {
    font-size: 20px;  /* 20px - 接近8的倍数 */
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
}

.site-category {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    font-size: 12px;  /* 12px - 8的倍数 */
    font-weight: 500;
    border-radius: var(--radius-sm);
    padding: var(--spacing-xs) var(--spacing-sm);  /* 4px 8px */
    margin-left: var(--spacing-xs);
    box-shadow: 0 1px 3px hsla(200, 100%, 50%, 0.3);
}

.site-time {
    color: var(--text-secondary);
    font-size: 12px;  /* 12px - 8的倍数 */
    font-weight: 400;
}

.site-count {
    background: var(--accent-color);
    color: white;
    font-size: 12px;  /* 12px - 8的倍数 */
    font-weight: 500;
    border-radius: var(--radius-sm);
    padding: var(--spacing-xs) var(--spacing-sm);  /* 4px 8px */
}

.site-articles-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    overflow-y: auto;
    max-height: none;
    padding-bottom: var(--spacing-md);
}



/* 文章项样式 */
.article-item {
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--bg-secondary);
    position: relative; /* 为推荐标记提供定位基准 */
}



.article-title {
    font-size: 14px;  /* 14px - 接近8的倍数 */
    font-weight: 400;  /* 默认字重改为400 */
    color: var(--text-primary);
    line-height: 1.5;  /* 更好的行高比例 */
    position: relative;
    margin: 0;
    word-wrap: break-word;
    word-break: break-word;
    flex: 1; /* 标题占据剩余空间 */
    text-align: left;
    transition: color 0.2s ease, opacity 0.2s ease;
}

/* 已读文章标题样式 */
.article-title.read {
    opacity: 0.5;
}

/* 2小时内的新文章标题样式 */
.article-title.recent {
    font-weight: 600;
}

.recommended-article .article-title {
    color: hsla(20, 100%, 50%, 1);
}

.recommended-article .article-title:hover {
    color: var(--primary-color);
}

/* 移除原有的外部链接伪元素样式，现在使用独立图标 */

.article-source {
    font-size: 12px;  /* 12px - 8的倍数 */
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

/* 推荐文章样式 */
.article-title-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    text-align: left;
}

.left-icon, .right-icon {
    display: flex;
    align-items: center;
    min-width: 20px;
}

.right-icon {
    justify-content: center;
}

.recommended-badge {
    width: 6px;
    height: 6px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(238, 90, 36, 0.4);
    animation: pulse-glow 2s infinite;
    flex-shrink: 0; /* 防止图标被压缩 */
}

.external-link-icon {
    font-size: 12px;
    color: rgb(230, 126, 34);
    opacity: 0.7;
    cursor: pointer;
    flex-shrink: 0; /* 防止图标被压缩 */
}



/* 推荐标记的脉冲动画 */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 2px 4px rgba(238, 90, 36, 0.3), 0 0 0 0 rgba(255, 107, 107, 0.4);
    }
    50% {
        box-shadow: 0 2px 8px rgba(238, 90, 36, 0.4), 0 0 0 4px rgba(255, 107, 107, 0.1);
    }
}

.article-time {
    font-size: 11px;  /* 11px - 接近8的倍数 */
    color: var(--text-muted);
    margin-left: auto;
}

/* 按钮样式 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-sm) var(--spacing-md);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background-color: var(--bg-card);
    color: var(--text-primary);
    font-size: 14px;  /* 14px - 接近8的倍数 */
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.btn:hover {
    background-color: var(--bg-tertiary);
    border-color: var(--border-hover);
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
}

.btn-icon {
    padding: var(--spacing-sm);
    width: 40px;  /* 40px - 8的倍数 */
    height: 40px; /* 40px - 8的倍数 */
}

.btn-sm {
    padding: var(--spacing-xs) var(--spacing-sm);
    font-size: 12px;  /* 12px - 8的倍数 */
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

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

/* 主要内容 */
.main-content {
    padding: var(--spacing-sm) 0;
    min-height: 100vh;
}

/* 版式切换按钮容器 - 右上角定位 */
.view-mode-toggle-container {
    position: fixed;
    top: var(--spacing-md);
    right: var(--spacing-md);
    z-index: 100;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

/* 版式切换按钮 */
.view-mode-toggle {
    display: flex;
    align-items: center;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 4px;
    box-shadow: 0 10px 30px hsla(220, 22%, 10%, 0.10), 0 2px 8px hsla(220, 22%, 10%, 0.06);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* 顶部信息提示 - 始终居中显示 */
.info-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-md) 0;
    margin-bottom: var(--spacing-md);
    font-size: 14px;  /* 14px - 接近8的倍数 */
    color: var(--text-muted);
    width: 100%;
}

.info-content {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.info-banner .separator {
    color: var(--text-muted);
}

.view-mode-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 32px;
    height: 32px;
    font-size: 16px;
    line-height: 1;
}

.view-mode-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.view-mode-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.view-mode-btn svg {
    width: 16px;
    height: 16px;
    opacity: 0.8;
}

.view-mode-btn.active svg {
    opacity: 1;
}

.podcast-player-container {
    position: fixed;
    top: var(--spacing-md);
    left: var(--spacing-md);
    z-index: 100;
}

.podcast-player {
    gap: 2px;
}

.podcast-player.view-mode-toggle {
    --podcast-accent-1: hsla(276, 90%, 58%, 1);
    --podcast-accent-2: hsla(320, 92%, 62%, 1);
    --podcast-ink: hsla(220, 18%, 18%, 1);
    --podcast-ink-muted: hsla(220, 12%, 38%, 1);
    --podcast-surface: hsla(0, 0%, 100%, 0.86);
    --podcast-border: hsla(220, 18%, 86%, 0.85);
    --podcast-track: hsla(220, 14%, 90%, 1);
    --podcast-track-active: hsla(276, 90%, 58%, 1);

    background: var(--podcast-surface);
    border: 1px solid var(--podcast-border);
    border-radius: 999px;
    box-shadow: 0 10px 30px hsla(220, 22%, 10%, 0.10), 0 2px 8px hsla(220, 22%, 10%, 0.06);
    padding: 4px;
}

.podcast-player.view-mode-toggle .podcast-label {
    color: var(--podcast-ink-muted);
    margin-left: 6px;
    padding: 0 12px;
}

.podcast-player.view-mode-toggle #podcast-play-toggle.view-mode-btn {
    background: linear-gradient(135deg, var(--podcast-accent-1), var(--podcast-accent-2));
    color: white;
    border-radius: 999px;
    box-shadow: none;
}

.podcast-player.view-mode-toggle #podcast-play-toggle.view-mode-btn:hover {
    background: linear-gradient(135deg, hsla(276, 92%, 62%, 1), hsla(320, 94%, 66%, 1));
    transform: translateY(-1px);
}

.podcast-player.view-mode-toggle #podcast-play-toggle.view-mode-btn:active {
    transform: translateY(0);
}

.podcast-player.view-mode-toggle #podcast-play-toggle.view-mode-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

.podcast-player .podcast-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    padding: 0 10px;
    margin-left: 4px;
    font-size: 12px;
    line-height: 1;
    font-weight: 500;
    color: var(--text-muted);
    user-select: none;
    white-space: nowrap;
}

.podcast-progress {
    width: 104px;
    height: 32px;
    margin: 0 4px;
    accent-color: var(--podcast-track-active, var(--primary-color));
    cursor: pointer;
}

.podcast-player.view-mode-toggle .podcast-time {
    color: var(--podcast-ink-muted);
}

.podcast-player.view-mode-toggle .podcast-progress {
    width: 112px;
    margin: 0 6px;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
}

.podcast-player.view-mode-toggle .podcast-progress::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 999px;
    background: var(--podcast-track);
}

.podcast-player.view-mode-toggle .podcast-progress::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--podcast-accent-1), var(--podcast-accent-2));
    border: 2px solid hsla(0, 0%, 100%, 0.95);
    box-shadow: 0 6px 14px hsla(276, 80%, 45%, 0.24);
    margin-top: -3px;
}

.podcast-player.view-mode-toggle .podcast-progress::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: var(--podcast-track);
}

.podcast-player.view-mode-toggle .podcast-progress::-moz-range-progress {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--podcast-accent-1), var(--podcast-accent-2));
}

.podcast-player.view-mode-toggle .podcast-progress::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--podcast-accent-1), var(--podcast-accent-2));
    border: 2px solid hsla(0, 0%, 100%, 0.95);
    box-shadow: 0 6px 14px hsla(276, 80%, 45%, 0.24);
}

.podcast-progress:disabled {
    cursor: not-allowed;
    opacity: 0.45;
}

.podcast-time {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: var(--text-muted);
    min-width: 44px;
    padding: 0 6px;
    user-select: none;
}

@media (max-width: 480px) {
    .podcast-player-container {
        top: var(--spacing-sm);
        left: var(--spacing-sm);
    }

    .podcast-progress {
        width: 76px;
        margin: 0 2px;
    }
}



@media (max-width: 480px) {
    .info-banner {
        font-size: 12px;  /* 12px - 8的倍数 */
    }
    
    .view-mode-toggle-container {
        top: var(--spacing-sm);
        right: var(--spacing-sm);
    }
}

/* 时间线视图样式 */
.timeline-container {
    max-width: 880px;
    margin: 0 auto;
    padding: 0;
    text-align: left !important;
}

.timeline-group {
    margin-bottom: var(--spacing-lg); /* 减少组间距，创造更紧凑的布局 */
}

.timeline-header {
    position: sticky;
    top: 0;
    background: var(--bg-primary);
    padding: var(--spacing-md) 0;
    margin-bottom: var(--spacing-lg);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* 移除边框，使用更微妙的分隔效果 */
    border-bottom: 1px solid hsla(200, 20%, 88%, 0.3);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.timeline-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    text-align: left;
}

.timeline-count {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-align: right;
}

.timeline-title::before {
    content: '';
    width: 4px;
    height: 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: 2px;
}

.timeline-articles {
    display: flex;
    flex-direction: column;
    gap: 2px; /* 减少间距，创造更紧凑的视觉效果 */
    padding: 0;
    text-align: left;
    align-items: stretch;
    width: 100%;
}

.timeline-article-card {
    background: transparent; /* 默认透明背景，减少视觉噪音 */
    border: none; /* 完全移除边框 */
    border-radius: var(--radius-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease, border-left-color 0.2s ease;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-md);
    min-height: 60px;
    /* 添加微妙的左侧指示线 */
    border-left: 2px solid transparent;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
}

.timeline-article-card:hover {
    background: var(--bg-card); /* hover时显示卡片背景 */
    border-left-color: var(--primary-color); /* 左侧指示线变为主色 */
    transform: translateX(6px); /* 增加移动距离，增强交互感 */
    box-shadow: 0 2px 8px hsla(200, 100%, 50%, 0.08); /* 添加微妙阴影 */
}

.timeline-article-left {
    flex: 1;
    min-width: 0;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.timeline-title-container {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    justify-content: flex-start;
}

.timeline-left-icon {
    flex-shrink: 0;
    width: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.timeline-right-icon {
    flex-shrink: 0;
    width: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.timeline-article-title {
    font-size: 15px;
    color: var(--text-primary);
    line-height: 1.4;
    margin: 0;
    text-align: left !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.timeline-article-title.recent {
    font-weight: 600;
}

.timeline-article-title.recommended {
    color: hsla(20, 100%, 50%, 1);
    font-weight: 600;
}

/* 推荐文章hover时使用橙色左侧指示线 */
.timeline-article-card.recommended:hover {
    background: var(--bg-card);
    border-left-color: hsla(20, 100%, 50%, 1); /* 推荐文章hover时显示橙色指示线 */
    transform: translateX(6px);
    box-shadow: 0 2px 8px hsla(200, 100%, 50%, 0.08);
}

/* 时间线视图已读文章样式 */
.timeline-article-title.read {
    opacity: 0.6; /* 稍微提高已读文章的可见度 */
}

.timeline-article-card.read-article {
    opacity: 0.7; /* 调整已读卡片透明度，保持层次感 */
}

.timeline-article-card.read-article:hover {
    opacity: 0.9; /* hover时提高可见度 */
}

.timeline-article-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: var(--spacing-sm);
    flex-shrink: 0;
}

.timeline-article-source {
    font-size: 12px;
    color: var(--text-muted);
    background: var(--bg-secondary);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    white-space: nowrap;
}

.timeline-article-time {
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
}

/* 时间线视图移动端适配 */
@media (max-width: 768px) {
    .timeline-articles {
        gap: 1px; /* 移动端进一步减少间距 */
    }
    
    .timeline-article-card {
        padding: var(--spacing-sm);
        min-height: 50px;
    }
    
    .timeline-article-card:hover {
        transform: translateX(3px); /* 移动端减少移动距离 */
    }
    
    .timeline-article-title {
        font-size: 14px;
    }
    
    .timeline-article-source {
        font-size: 11px;
    }
    
    .timeline-article-time {
        font-size: 10px;
    }
    
    .timeline-title {
        font-size: 16px;
    }
    
    .timeline-header {
        padding: var(--spacing-sm) 0;
        margin-bottom: var(--spacing-md);
        border-bottom: 1px solid hsla(200, 20%, 88%, 0.2); /* 移动端更微妙的分隔线 */
    }
    
    .timeline-group {
        margin-bottom: var(--spacing-md); /* 移动端减少组间距 */
    }
}

/* 分类卡片布局 */
.category-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm), 0 0 0 1px hsla(200, 100%, 50%, 0.03);
    overflow: hidden;
    transition: all 0.3s ease;
}

.category-card:hover {
    box-shadow: var(--shadow-md), 0 0 25px hsla(200, 100%, 50%, 0.12);
    border-color: var(--primary-light);
    transform: translateY(-1px);
}

.category-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: var(--spacing-md) var(--spacing-lg);
    margin: 0;
    position: relative;
    box-shadow: 0 2px 8px hsla(200, 100%, 50%, 0.2);
}

/* 推荐语卡片样式 */
.recommendation-reason {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-xl);
    line-height: 1.6;
    box-shadow: var(--shadow-md), 0 0 20px hsla(200, 100%, 50%, 0.15);
    position: relative;
    transition: all 0.3s ease;
}

.recommendation-reason:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg), 0 0 30px hsla(200, 100%, 50%, 0.25);
}

.recommendation-header {
    display: flex;
    align-items: center;
    margin-bottom: var(--spacing-sm);
    font-weight: 600;
    font-size: 0.8em;
    opacity: 0.95;
    letter-spacing: 1px;
}

.recommendation-icon {
    font-size: 16px;
    margin-right: var(--spacing-sm);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.recommendation-content {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* 暗色主题下的推荐语样式优化 */
[data-theme="dark"] .recommendation-reason {
    background: linear-gradient(135deg, 
        hsla(200, 60%, 25%, 0.9), 
        hsla(200, 50%, 20%, 0.9)
    );
    box-shadow: var(--shadow-md), 0 0 20px hsla(200, 100%, 50%, 0.1);
}

[data-theme="dark"] .recommendation-reason:hover {
    box-shadow: var(--shadow-lg), 0 0 30px hsla(200, 100%, 50%, 0.2);
}

/* 响应式优化 */
@media (max-width: 768px) {
    .recommendation-reason {
        padding: var(--spacing-sm) var(--spacing-md);
        margin-bottom: var(--spacing-lg);
        font-size: 14px;
    }
    
    .recommendation-header {
        font-size: 12px;
    }
    
    .recommendation-icon {
        font-size: 14px;
    }
}

@media (min-width: 1200px) {
    .category-container {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: var(--spacing-xl);
    }
}

/* 加载指示器 */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl);
    text-align: center;
}

.loading-spinner {
    width: 3rem;
    height: 3rem;
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: var(--spacing-md);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 错误状态样式 */
.error-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl);
    text-align: center;
    margin: var(--spacing-lg);
}

.error-container * {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol" !important;
}


.error-title {
    font-size: 18px;
    font-weight: 500;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-sm) 0;
}

.error-message {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0 0 var(--spacing-lg) 0;
    line-height: 1.4;
    max-width: 400px;
}

.error-actions {
    display: flex;
    gap: var(--spacing-md);
    flex-wrap: wrap;
    justify-content: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 400;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
    min-width: 100px;
    height: 40px;
    box-sizing: border-box;
}

.btn-primary {
    background: var(--primary-color);
    color: white !important;
}

.btn-primary:hover {
    background: var(--primary-hover);
    opacity: 0.9;
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: none;
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* 响应式调整 */
@media (max-width: 600px) {
    .error-container {
        margin: var(--spacing-md);
        padding: var(--spacing-lg);
    }
    
    .error-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .btn {
        width: 100%;
        min-width: auto;
    }
}



/* Masonry 容器 */
.grid-container {
    position: relative;
    padding-bottom: var(--spacing-md);
    margin: 0 auto;
    text-align: center; /* 确保内容居中 */
}

/* Masonry 项目 */
.grid-item {
    /* 宽度由JavaScript动态设置 */
    margin-bottom: 16px; /* 固定底部间距，与JS中的gutter值保持一致 */
    box-sizing: border-box;
    display: inline-block; /* 使卡片能够居中对齐 */
    float: none !important; /* 覆盖Masonry的float属性 */
    vertical-align: top; /* 顶部对齐 */
}

/* 移动端特殊处理 */
@media (max-width: 600px) {
    .grid-container {
        padding: var(--spacing-sm);
    }
    
    .grid-item {
        width: calc(100% - 24px) !important; /* 移动端占满宽度，减去固定间距 */
        margin-left: auto;
        margin-right: auto;
    }
    
    /* 移动端卡片高度调整 */
    .site-card {
        min-height: 150px;
        max-height: 600px; /* 增加移动端最大高度 */
    }
    
    /* 移动端文章列表高度调整 */
    .site-articles-list {
        max-height: 500px; /* 增加移动端文章列表最大高度 */
    }
    
    /* 确保移动端环境中文章标题左对齐 */
    .article-title-container,
    .article-title {
        text-align: left !important;
    }
}



/* 订阅源分组 */
.feed-group {
    margin-bottom: var(--spacing-xl);
}

.feed-header {
    padding: var(--spacing-md) 0;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: var(--spacing-md);
}

.feed-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

/* 文章列表 */
.articles-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.article-item {
    padding: var(--spacing-sm);
    transition: all 0.2s ease;
    cursor: pointer;
    border-radius: var(--radius-sm);
    border-left: 3px solid transparent;
    background-color: transparent;
    display: block;
    width: 100%;
    box-sizing: border-box;
}
.article-item:hover {
    background-color: hsla(200, 100%, 50%, 0.05);
}



.article-source {
    display: inline-block;
    font-size: 0.65rem;
    color: var(--text-muted);
    font-weight: 400;
    opacity: 0.8;
    margin: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 文章项动画效果 */
.article-item {
    animation: fadeInUp 0.3s ease-out;
    animation-fill-mode: both;
}

.article-item:nth-child(1) { animation-delay: 0.05s; }
.article-item:nth-child(2) { animation-delay: 0.1s; }
.article-item:nth-child(3) { animation-delay: 0.15s; }
.article-item:nth-child(4) { animation-delay: 0.2s; }
.article-item:nth-child(5) { animation-delay: 0.25s; }

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

/* 响应式优化 */
/* 小屏幕移动端样式已移除，专注于web端使用 */

.open-mode-badge {
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-sm);
    font-size: 0.625rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.open-mode-reader {
    background-color: #fef3c7;
    color: #92400e;
}

.open-mode-window {
    background-color: #dbeafe;
    color: #1e40af;
}

[data-theme="dark"] .open-mode-reader {
    background-color: #451a03;
    color: #fbbf24;
}

[data-theme="dark"] .open-mode-window {
    background-color: #1e3a8a;
    color: #93c5fd;
}

/* 无文章状态 */
.no-articles {
    text-align: center;
    padding: var(--spacing-xl);
    color: var(--text-secondary);
}

.no-articles-icon {
    font-size: 4rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.5;
}

.no-articles h3 {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.no-articles h3:hover {
    color: var(--primary-color);
}

/* 通用h3 hover效果 */
h3 {
    transition: color 0.3s ease;
}

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

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: var(--spacing-xl);
    right: var(--spacing-xl);
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    border: none;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
}

/* 阅读器模态框 */
.reader-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overscroll-behavior: contain;
}

body.modal-open {
    overflow: hidden;
}

.resize-handle {
    position: absolute;
    top: 0;
    right: -5px;
    width: 10px;
    height: 100%;
    cursor: col-resize;
    background: transparent;
    z-index: 1001;
}

.resize-handle:hover {
    background: rgba(0, 0, 0, 0.1);
}

/* 图片隐藏样式 */
.hide-images img {
    display: none !important;
}

.reader-modal.show {
    opacity: 1;
    visibility: visible;
}

.reader-container {
    width: 880px;
    min-width: 480px;
    max-width: 1200px;
    position: relative;
    height: 90vh;
    max-height: 90vh;
    background: var(--bg-primary);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    transition: height 0.3s ease;
}

/* 工具栏样式 - 参考底部导航栏设计 */
.reader-toolbar {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: var(--spacing-sm) var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md);
    flex-shrink: 0;
}

.reader-left-controls,
.reader-center-controls,
.reader-right-controls {
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
}

.reader-left-controls {
    flex: 1;
    justify-content: flex-start;
}

.reader-center-controls {
    flex: 1;
    justify-content: center;
}

.reader-right-controls {
    flex: 1;
    justify-content: flex-end;
}

/* 主题控制区域 */
.theme-control {
    display: flex;
    gap: 4px;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    padding: 4px;
    border: 1px solid var(--border-color);
}

.theme-btn {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    color: #666666;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.theme-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-1px);
}

.theme-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
}

/* 字体控制区域 */
.reader-font-controls {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    background: transparent;
    border-radius: var(--radius-md);
    padding: 4px 8px;
    border: none;
}

.font-control-btn {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: #666666;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.font-control-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

#font-size-display {
    font-size: 12px;
    color: var(--text-secondary);
    min-width: 20px;
    text-align: center;
    font-weight: 500;
    padding: 0 4px;
}

/* 功能按钮样式 - 参考底部导航栏 */
.reader-action-btn {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: #666666;
    padding: var(--spacing-sm);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
}

.reader-action-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.reader-close {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: #ff4757;
    padding: var(--spacing-sm);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
}

.reader-close:hover {
    background: #ff4757;
    color: white;
    border-color: #ff4757;
    transform: translateY(-1px);
}

.font-size-btn:hover {
    background: var(--bg-secondary);
}

#font-size-display {
    min-width: 40px;
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
    background: var(--bg-secondary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

/* Chrome插件按钮样式 */
.reader-plugin-btn {
    background: var(--bg-primary);
    color: #666666;
    border: 1px solid var(--border-color);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    height: 36px;
}

.reader-plugin-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
    text-decoration: none;
}



.reader-content {
    padding: 0;
    margin: 0;
    max-width: 100%;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
}

.reader-content *::selection {
    background:hsla(60, 100%, 80%, 1); 
}
.theme-dark .reader-content *::selection {
    background:hsla(60, 100%, 20%, 1); 
}



/* 内容区域使用padding控制宽度 */
.reader-content > * {
    padding: 0 var(--spacing-3xl);
}

.reader-meta {
    padding-top: var(--spacing-2xl);
}

#article-content {
    padding-top: var(--spacing-2xl);
    padding-bottom: var(--spacing-3xl);
}

.reader-meta {
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-xl);
    border-bottom: 1px solid var(--border-color);
}

.reader-meta #article-title {
    font-size: 32px;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-md) 0;
    width: 100%;
    text-align: left;
}

.reader-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-lg);
    color: var(--text-secondary);
    font-size: 16px;
    width: 100%;
    margin-top: var(--spacing-sm);
}

.article-source {
    flex: 1;
    text-align: left;
}

.article-time {
    flex-shrink: 0;
    text-align: right;
}

#article-content {
    color: var(--text-primary);
    line-height: 1.8;
    font-size: 18px;
    text-align: justify;
    letter-spacing: 0.5px;
    word-wrap: break-word
}

/* 文章内容详细样式 */
#article-content p, #article-content section {
    margin: 0 0 var(--spacing-xl) 0;
    word-wrap: break-word;
}

#article-content blockquote p {
    margin: 0 0 var(--spacing-sm) 0;
}

#article-content video {
    width: 100%;
}

#article-content br {
    display: none;
}

.theme-sepia #article-content * {
    font-family: 'Zhuque Fangsong (technical preview)', "Times New Roman", "NSimSun", "SimSun", "STSong", "STFangsong", "FangSong", "FangSongGB2312", "Source Serif Pro", serif;
}
.theme-sepia #article-content strong {
    font-family: serif;
    /*border-bottom: 1px rgba(0,0,0,.3) dashed;*/
}
.theme-sepia h1, .theme-sepia h2, .theme-sepia h3, .theme-sepia h4, .theme-sepia h5, .theme-sepia h6 {
    font-family: serif !important;
}

#article-content h1,
#article-content h2,
#article-content h3,
#article-content h4,
#article-content h5,
#article-content h6 {
    margin: var(--spacing-3xl) 0 var(--spacing-xl) 0;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
}

#article-content h1 {
    font-size: 1.8em;
}

#article-content h2 {
    font-size: 1.5em;
}

#article-content h3 {
    font-size: 1.3em;
    transition: color 0.3s ease;
}

#article-content h4 {
    font-size: 1.1em;
}

#article-content h5,
#article-content h6 {
    font-size: 1em;
}

#article-content a {
    color: var(--accent-color, #007bff);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

#article-content a:hover {
    border-bottom-color: var(--accent-color, #007bff);
}

#article-content ul,
#article-content ol {
    margin: 0 0 var(--spacing-md) 0;
    padding-left: var(--spacing-xl);
}

#article-content li {
    margin-bottom: var(--spacing-xs);
}

#article-content blockquote {
    margin: var(--spacing-lg) 0;
    padding: var(--spacing-md) var(--spacing-lg);
    border-left: 4px solid var(--accent-color, #007bff);
    background: var(--bg-secondary);
    font-style: italic;
    color: var(--text-secondary);
    border-radius: var(--radius-lg);
}

#article-content code {
    background: var(--bg-secondary);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
    color: var(--text-primary);
}

#article-content pre {
    background: var(--bg-secondary);
    padding: var(--spacing-md);
    border-radius: 6px;
    overflow-x: auto;
    margin: var(--spacing-md) 0;
    border: 1px solid var(--border-color);
}

#article-content pre code {
    background: none;
    padding: 0;
    border-radius: 0;
    font-size: 0.9em;
}

#article-content img {
    max-width: 100%;
    height: auto;
    margin: var(--spacing-xl) auto;
    border-radius: var(--radius-lg);
    /* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); */
    display: block;
}

#article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: var(--spacing-xl) 0;
    border: 1px solid var(--border-color);
}

#article-content th,
#article-content td {
    padding: var(--spacing-sm) var(--spacing-md);
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

#article-content th {
    background: var(--bg-secondary);
    font-weight: 600;
}

#article-content hr {
    border: none;
    height: 1px;
    background: var(--border-color);
    margin: var(--spacing-xl) 0;
}

#article-content strong,
#article-content b a,
#article-content b {
    font-weight: 600;
}

#article-content em,
#article-content i {
    font-style: italic;
}

#article-content del {
    text-decoration: line-through;
    color: var(--text-secondary);
}

#article-content u {
    text-decoration: none;
    border-bottom: 1px rgba(0,0,0,.3) dashed;
    padding-bottom: 4px;
    font-weight: bold;
}


#article-content sup,
#article-content sub {
    font-size: 0.8em;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}

#article-content sup {
    top: -0.5em;
}

#article-content sub {
    bottom: -0.25em;
}

/* 首段不需要上边距 */
#article-content > *:first-child {
    margin-top: 0;
}

/* 最后一个元素不需要下边距 */
#article-content > *:last-child {
    margin-bottom: 0;
}

/* 阅读器主题 */
.reader-modal.theme-light {
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --text-primary: #333333;
    --text-secondary: #666666;
    --border-color: #e0e0e0;
}

.reader-modal.theme-dark {
    --bg-primary: #1e1e1e;
    --bg-secondary: #252525;
    --text-primary: #e8e8e8;
    --text-secondary: #b0b0b0;
    --border-color: #3a3a3a;
}

.reader-modal.theme-sepia {
    --bg-primary: #f4f1ea;
    --bg-secondary: #ede6d3;
    --text-primary: #5c4b37;
    --text-secondary: #8b7355;
    --border-color: #d4c5a9;
}

/* 字体大小 */
.reader-content[data-font-size="size-14"] #article-content,
.reader-content.font-size-14 #article-content {
    font-size: 14px;
}

.reader-content[data-font-size="size-16"] #article-content,
.reader-content.font-size-16 #article-content {
    font-size: 16px;
}

.reader-content[data-font-size="size-18"] #article-content,
.reader-content.font-size-18 #article-content {
    font-size: 18px;
}

.reader-content[data-font-size="size-20"] #article-content,
.reader-content.font-size-20 #article-content {
    font-size: 20px;
}

.reader-content[data-font-size="size-22"] #article-content,
.reader-content.font-size-22 #article-content {
    font-size: 22px;
}

.reader-content[data-font-size="size-24"] #article-content,
.reader-content.font-size-24 #article-content {
    font-size: 24px;
}

.reader-content[data-font-size="size-26"] #article-content,
.reader-content.font-size-26 #article-content {
    font-size: 26px;
}

.reader-content[data-font-size="size-28"] #article-content,
.reader-content.font-size-28 #article-content {
    font-size: 28px;
}

.reader-content[data-font-size="size-30"] #article-content,
.reader-content.font-size-30 #article-content {
    font-size: 30px;
}

.reader-content[data-font-size="size-32"] #article-content,
.reader-content.font-size-32 #article-content {
    font-size: 32px;
}

/* 底部导航栏 */
.reader-navigation {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: var(--spacing-sm) var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.nav-btn {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    min-width: 160px;
    max-width: 280px;
    justify-content: center;
}

.nav-btn:hover:not(:disabled) {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: var(--bg-tertiary);
}

.nav-btn-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.nav-btn-label {
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}

.nav-btn-title {
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    opacity: 0.8;
}

.nav-btn:hover:not(:disabled) .nav-btn-title {
    color: rgba(255, 255, 255, 0.9);
}



/* 分类汇总卡片样式 - 与普通站点卡片保持一致 */
.category-card {
    /* 移除特殊样式，使用默认的site-card样式 */
}

/* 响应式设计 */
/* 超大屏幕优化 */
@media (min-width: 2000px) {
    .site-card {
        padding: 0;
        padding-bottom: var(--spacing-md);
    }
    
    .site-title {
        font-size: 1.5rem;
    }
    
    .article-item {
        padding: var(--spacing-sm);
    }
}

/* 大屏幕优化 */
@media (min-width: 1600px) and (max-width: 1999px) {
    .site-card {
        padding-bottom: var(--spacing-md);
    }
}

/* 中等屏幕 */
@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    .header .container {
        padding: var(--spacing-sm);
    }
    
    .site-title {
        font-size: 20px;  /* 20px - 8的倍数 */
    }
    
    .status-bar .container {
        flex-direction: column;
        gap: var(--spacing-sm);
        align-items: flex-start;
    }
    
    .status-info {
        flex-direction: column;
        gap: var(--spacing-xs);
    }
    
    .feed-header {
        padding: var(--spacing-sm) var(--spacing-md);
        flex-direction: column;
        gap: var(--spacing-sm);
        align-items: flex-start;
    }
    
    .article-item {
        padding: var(--spacing-md);
    }
    
    .article-header {
        flex-direction: column;
        gap: var(--spacing-sm);
    }
    
    .article-meta {
        flex-direction: column;
        gap: var(--spacing-xs);
    }
    
    .reader-info {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-xs);
    }
    
    .article-source,
    .article-time {
        text-align: left;
        width: 100%;
    }
    
    .article-actions {
        flex-wrap: wrap;
    }
    
    .reader-controls {
        flex-wrap: wrap;
        gap: var(--spacing-sm);
    }
    
    .reader-content {
        padding: var(--spacing-md);
    }
    
    #reader-title {
        font-size: 24px;  /* 24px - 8的倍数 */
    }
    
    .reader-meta {
        flex-direction: column;
        gap: var(--spacing-sm);
    }
    
    .back-to-top {
        bottom: var(--spacing-md);
        right: var(--spacing-md);
        width: 40px;  /* 40px - 8的倍数 */
        height: 40px; /* 40px - 8的倍数 */
    }
    
    /* 阅读器响应式 */
    .reader-modal {
        padding: 0;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
    
    .reader-container {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
        height: 100vh;
    }
    
    .reader-toolbar {
        padding: var(--spacing-sm);
        flex-wrap: wrap;
        gap: var(--spacing-sm);
    }
    
    .toolbar-left,
    .toolbar-right {
        gap: var(--spacing-xs);
    }
    
    .toolbar-right {
        flex-wrap: wrap;
    }
    
    .reader-btn {
        padding: var(--spacing-xs);
        font-size: 12px;
    }
    
    .theme-btn {
        width: 24px;
        height: 24px;
    }
    
    .font-size-btn {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
    
    .reader-navigation {
        padding: var(--spacing-sm);
    }
    
    .nav-btn {
        min-width: 80px;
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: 12px;
    }
    
    /* 时间线移动端适配 */
    .timeline-article-card {
        padding: 10px 12px;
        min-height: 50px;
    }
    
    .timeline-article-title {
        font-size: 13px;
    }
    
    .timeline-article-source,
    .timeline-article-time {
        font-size: 11px;
    }
    
    .timeline-left-icon {
        width: 16px;
    }
    
    .timeline-title-container {
        gap: 6px;
    }

}

/* 文本选择气泡样式 */
.text-selection-bubble {
    position: fixed;
    z-index: 10000;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 2px;
    padding: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.text-selection-bubble.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.bubble-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
}

.bubble-button:hover {
    background: var(--bg-secondary);
    color: var(--primary-color);
    transform: scale(1.1);
}

.bubble-button:active {
    transform: scale(0.95);
}

.bubble-button svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* Toast提示动画 */
@keyframes fadeInOut {
    0% { opacity: 0; transform: translateY(-20px); }
    10%, 90% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(-20px); }
}

.toast-message {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--primary-color, #667eea);
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    z-index: 10000;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    max-width: 300px;
    word-wrap: break-word;
    transition: all 0.3s ease;
}

.toast-message:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2) !important;
}

/* 更新通知样式 */
.update-notification {
    position: fixed;
    top: 16px;
    right: 16px;
    background: var(--primary-color, #667eea);
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 10000;
    animation: slideInFromRight 0.3s ease-out;
    font-size: 14px;
    max-width: 300px;
    word-wrap: break-word;
}

.update-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.update-btn {
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: background 0.2s ease;
}

.update-btn:hover {
    background: rgba(255,255,255,0.3);
}

@keyframes slideInFromRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* 暗色主题下的气泡样式调整 */
[data-theme="dark"] .text-selection-bubble {
    background: var(--bg-card);
    border-color: var(--border-color);
}

[data-theme="dark"] .bubble-button:hover {
    background: var(--bg-tertiary);
}



/* 阅读器主题下的气泡样式 */
.reader-modal.theme-light .text-selection-bubble {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 0, 0, 0.1);
}

.reader-modal.theme-dark .text-selection-bubble {
    background: rgba(30, 30, 30, 0.95);
    border-color: rgba(255, 255, 255, 0.1);
    color: #e0e0e0;
}

.reader-modal.theme-sepia .text-selection-bubble {
    background: rgba(251, 248, 240, 0.95);
    border-color: rgba(139, 125, 107, 0.2);
    color: #5c4b37;
}



@media (max-width: 480px) {
    .articles-list {
        gap: 0;
    }
    

    
    .font-controls {
        display: none;
    }
    
    .toolbar-left {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-xs);
    }
    
    .theme-controls {
        margin-right: 0;
    }
    
    .reader-toolbar {
        flex-direction: column;
        align-items: stretch;
    }
    
    .toolbar-right {
        justify-content: center;
        margin-top: var(--spacing-xs);
    }
    
    .nav-btn {
        min-width: 100px;
        max-width: 200px;
        padding: var(--spacing-xs) var(--spacing-sm);
    }
    
    .nav-btn-title {
        font-size: 10px;
        max-width: 120px;
    }
    
    .nav-btn-label {
        font-size: 11px;
    }
    

}

/* 打印样式 */
@media print {
    .header,
    .status-bar,
    .back-to-top,
    .reader-header {
        display: none;
    }
    
    .main-content {
        padding: 0;
    }
    
    .article-item {
    }
    
    .reader-content {
        max-width: none;
        padding: 0;
    }
}

/* 高对比度模式 */
@media (prefers-contrast: high) {
    :root {
        --border-color: #000000;
        --text-secondary: #000000;
    }
    
    [data-theme="dark"] {
        --border-color: #ffffff;
        --text-secondary: #ffffff;
    }
}

/* 减少动画偏好 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
