/* ORLAN 商业计划书 - Larksuite 风格样式 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --text-color: rgb(31, 35, 41);
    --text-secondary: rgb(100, 106, 115);
    --bg-color: #fff;
    --sidebar-bg: #f5f6f7;
    --border-color: #e5e6e8;
    --link-color: #3370ff;
    --link-hover: #245bdb;
    --heading-color: rgb(31, 35, 41);
    --table-border: #dee0e3;
    --table-header-bg: #f5f6f7;
    --code-bg: #f5f6f7;
    --blockquote-border: #3370ff;
    --sidebar-width: 260px;
    --content-max-width: 850px;
}

body {
    font-family: LarkHackSafariFont, LarkEmojiFont, LarkChineseQuote, -apple-system, "system-ui", "Helvetica Neue", Tahoma, "PingFang SC", "Microsoft Yahei", Arial, "Hiragino Sans GB", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    font-size: 16px;
    line-height: 1.75;
    color: var(--text-color);
    background-color: var(--bg-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 水印 */
.watermark {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 100;
    pointer-events: none;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="280" height="120"><text x="50%" y="50%" font-family="Arial, PingFang SC, Microsoft YaHei" font-size="18" fill="rgba(0,0,0,0.12)" text-anchor="middle" dominant-baseline="middle" transform="rotate(-25 140 60)">万通资本WANTCAPITAL</text></svg>');
    background-repeat: repeat;
}

/* 侧边栏 */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    z-index: 50;
}

.sidebar-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    font-size: 14px;
    position: sticky;
    top: 0;
    background: var(--sidebar-bg);
    color: #3370ff;
}

.doc-icon {
    font-size: 18px;
}

.doc-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.toc {
    padding: 12px 0;
}

.toc a {
    display: block;
    padding: 6px 20px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 14px;
    line-height: 1.5;
    transition: background-color 0.15s;
}

.toc a:hover {
    background-color: rgba(31, 35, 41, 0.06);
}

.toc a.active {
    background-color: rgba(51, 112, 255, 0.08);
    color: #3370ff;
    font-weight: 500;
}

/* 侧边栏标题（第一个链接）高亮蓝色 */
.toc a.level-1:first-child {
    color: #3370ff;
    font-weight: 500;
}

.toc a.level-2 {
    padding-left: 32px;
    font-size: 13px;
    color: var(--text-secondary);
}

.toc a.level-3 {
    padding-left: 44px;
    font-size: 13px;
    color: var(--text-secondary);
}

/* 主内容区 */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    padding: 40px 60px 80px;
    display: flex;
    justify-content: center;
}

.document {
    max-width: var(--content-max-width);
    width: 100%;
}

/* 标题样式 */
h1 {
    font-size: 26px;
    font-weight: 500;
    color: var(--heading-color);
    margin: 32px 0 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
    line-height: 1.4;
}

h1:first-child {
    margin-top: 0;
}

h2 {
    font-size: 22px;
    font-weight: 500;
    color: var(--heading-color);
    margin: 28px 0 14px;
    line-height: 1.4;
}

h3 {
    font-size: 18px;
    font-weight: 500;
    color: var(--heading-color);
    margin: 24px 0 12px;
    line-height: 1.4;
}

h4, h5, h6 {
    font-size: 16px;
    font-weight: 500;
    color: var(--heading-color);
    margin: 20px 0 10px;
    line-height: 1.4;
}

/* 段落 */
p {
    margin: 12px 0;
    line-height: 1.75;
}

/* 链接 */
a {
    color: var(--link-color);
    text-decoration: none;
}

a:hover {
    color: var(--link-hover);
    text-decoration: underline;
}

/* 列表 */
ul, ol {
    margin: 12px 0;
    padding-left: 28px;
}

li {
    margin: 6px 0;
    line-height: 1.75;
}

/* 表格 */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 14px;
}

th, td {
    border: 1px solid var(--table-border);
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}

th {
    background-color: var(--table-header-bg);
    font-weight: 500;
    color: var(--heading-color);
}

tr:hover td {
    background-color: rgba(31, 35, 41, 0.02);
}

/* 引用块 */
blockquote {
    margin: 16px 0;
    padding: 12px 16px;
    border-left: 4px solid var(--blockquote-border);
    background-color: rgba(51, 112, 255, 0.04);
    color: var(--text-secondary);
}

blockquote p {
    margin: 0;
}

/* 代码 */
code {
    font-family: "SF Mono", Monaco, "Cascadia Code", Menlo, Consolas, monospace;
    background-color: var(--code-bg);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
}

pre {
    background-color: var(--code-bg);
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 16px 0;
}

pre code {
    background: none;
    padding: 0;
}

/* 分割线 */
hr {
    border: none;
    border-top: 1px solid var(--border-color);
    margin: 24px 0;
}

/* 图片 */
img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 16px 0;
    display: block;
}

/* 强调文本 */
em {
    font-style: italic;
    color: var(--text-secondary);
}

strong {
    font-weight: 600;
}

/* 响应式 */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }

    .main-content {
        margin-left: 220px;
        padding: 30px 40px 60px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }

    .main-content {
        margin-left: 0;
        padding: 20px 20px 40px;
    }
}

/* 图片占位符 */
.image-placeholder {
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    border: 1px dashed #c4c9d0;
    border-radius: 8px;
    padding: 40px;
    margin: 16px 0;
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
}

.image-placeholder span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* 表格容器 */
.table-wrapper {
    overflow-x: auto;
    margin: 16px 0;
    border-radius: 8px;
    border: 1px solid var(--table-border);
}

.table-wrapper table {
    margin: 0;
    border: none;
}

.table-wrapper th:first-child,
.table-wrapper td:first-child {
    border-left: none;
}

.table-wrapper th:last-child,
.table-wrapper td:last-child {
    border-right: none;
}

.table-wrapper tr:first-child th {
    border-top: none;
}

.table-wrapper tr:last-child td {
    border-bottom: none;
}

/* 打印样式 */
@media print {
    .watermark {
        display: none;
    }

    .sidebar {
        display: none;
    }

    .main-content {
        margin-left: 0;
        padding: 0;
    }
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(31, 35, 41, 0.2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(31, 35, 41, 0.3);
}

/* 封面区域 */
.cover-section {
    text-align: center;
    margin-bottom: 40px;
}

.cover-section img {
    max-width: 100%;
    max-height: 500px;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.cover-section .subtitle {
    font-size: 18px;
    color: var(--text-color);
    margin: 16px 0 8px;
    font-weight: 400;
}

.cover-section .version {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 8px 0 16px;
}

.cover-section a {
    display: inline-block;
    margin: 8px 0;
}

.cover-section .confidential {
    display: inline-block;
    background: rgba(255, 77, 79, 0.08);
    color: #ff4d4f;
    padding: 6px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-style: normal;
    margin: 12px 0;
}

/* 图表标题（斜体三星号） */
p > em:only-child,
p > strong > em:only-child {
    display: block;
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
    margin: 8px 0 4px;
}

/* 图表图片居中 */
p > img {
    display: block;
    margin: 16px auto;
    max-width: 100%;
}
