/* ==========================================================================
   企业文档知识库 - 样式表
   Doc.Secy.CN
   ========================================================================== */

/* CSS变量定义 */
:root {
    /* 主色调 - 优雅的蓝色系 */
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    
    /* 辅助色 */
    --secondary-color: #64748b;
    --accent-color: #06b6d4;
    
    /* 背景色 */
    --bg-color: #f8fafc;
    --bg-white: #ffffff;
    --bg-dark: #1e293b;
    
    /* 文字颜色 */
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-light: #f1f5f9;
    
    /* 边框颜色 */
    --border-color: #e2e8f0;
    --border-dark: #cbd5e1;
    
    /* 阴影 */
    --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);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    
    /* 圆角 */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-full: 9999px;
    
    /* 过渡 */
    --transition-fast: 150ms ease;
    --transition-normal: 250ms ease;
    --transition-slow: 350ms ease;
    
    /* 字体 */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
}

/* 重置样式 */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

/* 容器 */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ==========================================================================
   头部导航
   ========================================================================== */
.header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    gap: 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.logo i {
    font-size: 1.75rem;
}

.main-nav {
    display: flex;
    gap: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.nav-link:hover {
    background: var(--bg-color);
    color: var(--primary-color);
}

.nav-link.active {
    background: var(--primary-color);
    color: white;
}

.nav-link.active:hover {
    color: white;
}

.search-box {
    flex: 1;
    max-width: 400px;
}

.search-box form {
    display: flex;
    position: relative;
}

.search-box input {
    width: 100%;
    padding: 0.625rem 1rem;
    padding-right: 3rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-full);
    font-size: 0.9375rem;
    transition: all var(--transition-fast);
    background: var(--bg-color);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--bg-white);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-box button {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem;
    transition: color var(--transition-fast);
}

.search-box button:hover {
    color: var(--primary-color);
}

/* ==========================================================================
   主要内容区域
   ========================================================================== */
.main-content {
    flex: 1;
    padding: 2rem 0;
}

/* 横幅区域 */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 4rem 0;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    position: relative;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.stat-item i {
    font-size: 2rem;
    opacity: 0.8;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
}

.stat-label {
    font-size: 0.875rem;
    opacity: 0.8;
}

/* 内容布局 */
.content-wrapper {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
}

/* 侧边栏 */
.sidebar {
    position: sticky;
    top: 90px;
    height: fit-content;
}

.sidebar-section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
}

.sidebar-section h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.category-list {
    list-style: none;
}

.category-list li {
    margin-bottom: 0.25rem;
}

.category-list a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.category-list a:hover {
    background: var(--bg-color);
    color: var(--primary-color);
}

.category-list a i {
    width: 1.25rem;
    text-align: center;
    color: var(--primary-color);
}

.category-list .badge {
    margin-left: auto;
    background: var(--bg-color);
    color: var(--text-muted);
    padding: 0.125rem 0.5rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

/* 主内容列 */
.main-column {
    min-width: 0;
}

/* 区块样式 */
.section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.section-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.view-all {
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.view-all:hover {
    text-decoration: underline;
}

/* 文档卡片网格 */
.document-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.doc-card {
    background: var(--bg-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    cursor: pointer;
    transition: all var(--transition-normal);
    border: 1px solid var(--border-color);
}

.doc-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.doc-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.doc-info h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.doc-excerpt {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.doc-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.doc-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* ==========================================================================
   文档详情页
   ========================================================================== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    padding: 0.75rem 1rem;
    background: var(--bg-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.breadcrumb a {
    color: var(--text-secondary);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

.breadcrumb .separator {
    color: var(--border-color);
}

.breadcrumb .current {
    color: var(--text-primary);
    font-weight: 500;
}

.document-view {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.doc-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(to right, var(--bg-color), var(--bg-white));
}

.doc-title-row {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.doc-icon-large {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.75rem;
    flex-shrink: 0;
}

.doc-title-info h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.doc-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.meta-item i {
    color: var(--primary-color);
}

/* 文档内容区域 - 防复制 */
.doc-content {
    padding: 2rem;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-primary);
    min-height: 400px;
}

.doc-content.protected-content {
    /* 防复制样式 */
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    position: relative;
}

.doc-content.protected-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to bottom, rgba(255,255,255,0.9), transparent);
    pointer-events: none;
    z-index: 10;
}

.doc-content.protected-content::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to top, rgba(255,255,255,0.9), transparent);
    pointer-events: none;
    z-index: 10;
}

/* 文档内容样式 */
.doc-content h1,
.doc-content h2,
.doc-content h3,
.doc-content h4,
.doc-content h5,
.doc-content h6 {
    color: var(--text-primary);
    margin-top: 1.5em;
    margin-bottom: 0.75em;
    font-weight: 600;
    line-height: 1.3;
}

.doc-content h1 { font-size: 2em; }
.doc-content h2 { font-size: 1.5em; border-bottom: 2px solid var(--border-color); padding-bottom: 0.5rem; }
.doc-content h3 { font-size: 1.25em; }
.doc-content h4 { font-size: 1.125em; }

.doc-content p {
    margin-bottom: 1em;
}

.doc-content ul,
.doc-content ol {
    margin: 1em 0;
    padding-left: 2em;
}

.doc-content li {
    margin-bottom: 0.5em;
}

.doc-content code {
    background: var(--bg-color);
    padding: 0.2em 0.4em;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.9em;
    color: var(--primary-color);
}

.doc-content pre {
    background: var(--bg-dark);
    color: #e2e8f0;
    padding: 1.25rem;
    border-radius: var(--radius-md);
    overflow-x: auto;
    margin: 1.5em 0;
}

.doc-content pre code {
    background: none;
    padding: 0;
    color: inherit;
    font-size: 0.875rem;
}

.doc-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.5rem;
    margin: 1.5em 0;
    background: var(--bg-color);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.doc-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5em 0;
}

.doc-content th,
.doc-content td {
    border: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    text-align: left;
}

.doc-content th {
    background: var(--bg-color);
    font-weight: 600;
}

.doc-content img {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

/* 文档底部 */
.doc-footer {
    padding: 1.5rem 2rem;
    background: var(--bg-color);
    border-top: 1px solid var(--border-color);
}

.doc-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

/* 按钮样式 */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
}

.btn-secondary {
    background: var(--bg-white);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-color);
    border-color: var(--border-dark);
}

.copyright-notice {
    font-size: 0.8125rem;
    color: var(--text-muted);
    padding-top: 1rem;
    border-top: 1px dashed var(--border-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* 目录侧边栏 */
.toc-sidebar {
    position: fixed;
    right: 2rem;
    top: 100px;
    width: 240px;
    display: none;
}

.toc-widget {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 90px;
}

.toc-widget h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#toc {
    max-height: calc(100vh - 200px);
    overflow-y: auto;
}

#toc ul {
    list-style: none;
    padding-left: 1rem;
}

#toc li {
    margin-bottom: 0.5rem;
}

#toc a {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    display: block;
    padding: 0.25rem 0;
    border-left: 2px solid transparent;
    padding-left: 0.75rem;
    transition: all var(--transition-fast);
}

#toc a:hover {
    color: var(--primary-color);
    border-left-color: var(--primary-color);
}

#toc a.active {
    color: var(--primary-color);
    border-left-color: var(--primary-color);
}

/* ==========================================================================
   分类页面
   ========================================================================== */
.category-page {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.category-header {
    padding: 2rem;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.category-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    flex-shrink: 0;
}

.category-info h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.category-info p {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.doc-count {
    display: inline-block;
    background: var(--bg-white);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: 500;
}

/* 文档列表 */
.document-list {
    padding: 1.5rem;
}

.doc-list-item {
    display: flex;
    gap: 1.25rem;
    padding: 1.25rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid transparent;
    margin-bottom: 0.75rem;
}

.doc-list-item:hover {
    background: var(--bg-color);
    border-color: var(--border-color);
}

.doc-list-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.125rem;
    flex-shrink: 0;
}

.doc-list-content {
    flex: 1;
    min-width: 0;
}

.doc-list-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
}

.doc-list-content p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.doc-list-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.doc-list-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.doc-list-action {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ==========================================================================
   搜索页面
   ========================================================================== */
.search-page {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.search-header {
    padding: 2rem;
    background: linear-gradient(to right, var(--bg-color), var(--bg-white));
    border-bottom: 1px solid var(--border-color);
}

.search-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.search-header h1 i {
    color: var(--primary-color);
}

.search-header p {
    color: var(--text-muted);
}

.search-results {
    padding: 1.5rem;
}

.search-result-item {
    display: flex;
    gap: 1.25rem;
    padding: 1.25rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid transparent;
    margin-bottom: 0.75rem;
}

.search-result-item:hover {
    background: var(--bg-color);
    border-color: var(--border-color);
}

.result-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--accent-color), var(--primary-color));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.125rem;
    flex-shrink: 0;
}

.result-content {
    flex: 1;
    min-width: 0;
}

.result-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
}

.result-content h3 mark {
    background: #fef08a;
    color: var(--text-primary);
    padding: 0.125rem 0.25rem;
    border-radius: 2px;
}

.result-content p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.result-content p mark {
    background: #fef08a;
    color: var(--text-primary);
    padding: 0.125rem 0.25rem;
    border-radius: 2px;
}

.result-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.result-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* ==========================================================================
   空状态
   ========================================================================== */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1rem;
}

/* ==========================================================================
   错误页面
   ========================================================================== */
.error-page {
    text-align: center;
    padding: 6rem 2rem;
}

.error-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    color: white;
    font-size: 3rem;
}

.error-page h1 {
    font-size: 6rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.error-page p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* ==========================================================================
   页脚
   ========================================================================== */
.footer {
    background: var(--bg-dark);
    color: var(--text-light);
    padding: 3rem 0 1.5rem;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-section p {
    color: var(--text-muted);
    font-size: 0.875rem;
    line-height: 1.7;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--text-muted);
    font-size: 0.875rem;
    transition: color var(--transition-fast);
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.8125rem;
}

.footer-bottom .powered {
    margin-top: 0.25rem;
    opacity: 0.7;
}

/* ==========================================================================
   响应式设计
   ========================================================================== */
@media (max-width: 1200px) {
    .toc-sidebar {
        display: none;
    }
}

@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-stats {
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-wrap: wrap;
        height: auto;
        padding: 1rem 0;
        gap: 1rem;
    }
    
    .main-nav {
        order: 3;
        width: 100%;
        justify-content: center;
    }
    
    .search-box {
        order: 2;
        max-width: 100%;
        width: 100%;
    }
    
    .hero {
        padding: 3rem 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .document-grid {
        grid-template-columns: 1fr;
    }
    
    .doc-title-row {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .doc-meta-row {
        justify-content: center;
    }
    
    .doc-content {
        padding: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-section h4 {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }
    
    .nav-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .section {
        padding: 1rem;
    }
    
    .doc-card {
        padding: 1rem;
    }
    
    .doc-footer {
        padding: 1rem 1.5rem;
    }
    
    .doc-actions {
        flex-direction: column;
    }
}

/* ==========================================================================
   打印样式
   ========================================================================== */
@media print {
    .header,
    .footer,
    .sidebar,
    .toc-sidebar,
    .doc-footer,
    .breadcrumb {
        display: none !important;
    }
    
    .main-content {
        padding: 0;
    }
    
    .document-view {
        box-shadow: none;
    }
    
    .doc-content {
        padding: 0;
    }
    
    body {
        background: white;
    }
}

/* ==========================================================================
   动画效果
   ========================================================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.doc-card,
.doc-list-item,
.search-result-item {
    animation: fadeIn 0.3s ease forwards;
}

.document-grid .doc-card:nth-child(1) { animation-delay: 0.05s; }
.document-grid .doc-card:nth-child(2) { animation-delay: 0.1s; }
.document-grid .doc-card:nth-child(3) { animation-delay: 0.15s; }
.document-grid .doc-card:nth-child(4) { animation-delay: 0.2s; }
.document-grid .doc-card:nth-child(5) { animation-delay: 0.25s; }
.document-grid .doc-card:nth-child(6) { animation-delay: 0.3s; }
