#doc-modal .doc-modal-content {
    width: 900px;
    max-width: 95vw;
    height: 85vh;
    max-height: 92vh;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    border-radius: 6px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    background-color: var(--bg-secondary);
}

.doc-container {
    display: flex;
    flex: 1;
    height: 100%;
}

.doc-sidebar {
    width: 200px;
    background-color: var(--bg-tertiary);
    border-right: 1px solid var(--border-primary);
    padding: 20px 0;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--scrollbar-thumb) transparent;
}

.doc-tab-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 12px 20px;
    text-align: left;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

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

.doc-tab-btn.active {
    color: var(--app-color);
    background-color: var(--app-transparent);
    border-left-color: var(--app-color);
    font-weight: 500;
}

.doc-content-area {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
    position: relative;
    background-color: var(--bg-secondary);
    scrollbar-width: thin;
    scrollbar-color: var(--scrollbar-thumb) transparent;
}

.doc-pane {
    display: none;
    color: var(--text-primary);
    animation: fadeIn 0.3s ease-in-out;
}

.doc-pane.active {
    display: block;
}

.doc-pane h2 {
    color: var(--app-color);
    margin-bottom: 20px;
    margin-top: 0;
    font-size: 1.5em;
    border-bottom: 1px solid var(--border-primary);
    padding-bottom: 10px;
}

.doc-pane h3 {
    margin-top: 25px;
    margin-bottom: 10px;
    font-size: 1.2em;
    color: var(--text-primary);
}

.doc-pane p {
    line-height: 1.6;
    margin-bottom: 15px;
    color: var(--text-secondary);
}

.doc-pane ul {
    list-style: none;
    padding-left: 0px;
    margin-bottom: 20px;
}

.doc-pane li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
    line-height: 1.5;
    color: var(--text-secondary);
}

.doc-pane li::before {
    content: "•";
    color: var(--app-color);
    position: absolute;
    left: 0;
    font-size: 1.2em;
    line-height: 1;
}

.doc-pane strong {
    color: var(--app-color);
    font-weight: 600;
}

.doc-pane kbd {
    background-color: var(--bg-icons);
    border: 1px solid var(--app-color);
    border-radius: 4px;
    padding: 2px 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: var(--app-color);
}

.doc-shortcuts-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}

.shortcut-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    font-size: 0.95em;
    padding: 8px;
    border-radius: 4px;
    background-color: var(--bg-tertiary);
    transition: background-color 0.2s;
}

.shortcut-item:hover {
    background-color: var(--bg-hover);
}

.shortcut-item kbd {
    min-width: 24px;
    text-align: center;
}

.shortcut-item span {
    flex: 1;
}


.doc-bmc-box {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--app-border-transparent);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    text-align: center;
}

.doc-bmc-box p {
    margin: 0;
}

.doc-bmc-box .bmc-link {
    background-color: var(--bg-button);
    border: 1px solid var(--border-handle);
    color: var(--text-primary);
    padding: 8px 20px;
}
.doc-bmc-box .bmc-link:hover {
    background-color: var(--bg-hover);
    border-color: var(--app-color);
    color: var(--text-primary);
}

.doc-legal-box {
    background-color: var(--bg-tertiary);
    border-left: 4px solid var(--app-color);
    padding: 15px 20px;
    margin-top: 30px;
    border-radius: 4px;
}

.doc-legal-box h3 {
    color: var(--app-color);
    margin-top: 0;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@media screen and (max-width: 768px) {
    .doc-container {
        flex-direction: column;
    }
    .doc-sidebar {
        width: 100%;
        flex-direction: row;
        border-right: none;
        border-bottom: 1px solid var(--border-primary);
        overflow-x: auto;
        padding: 0;
    }
    .doc-tab-btn {
        border-left: none;
        border-bottom: 3px solid transparent;
        white-space: nowrap;
    }
    .doc-tab-btn.active {
        border-left-color: transparent;
        border-bottom-color: var(--app-color);
    }
}
