/* 教程专用样式 */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.tutorial-container {
    flex: 1;
    display: flex;
    max-width: 1400px;
    margin: 80px auto 0;
    padding: 2rem;
    gap: 3rem;
    width: 100%;
}

/* 侧边栏导航 */
.tutorial-sidebar {
    width: 250px;
    position: sticky;
    top: 100px;
    height: fit-content;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    border-right: 1px solid var(--border);
    padding-right: 1.5rem;
}

.tutorial-sidebar h4 {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    margin-top: 1.5rem;
}

.tutorial-sidebar h4:first-child {
    margin-top: 0;
}

.tutorial-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tutorial-sidebar li {
    margin-bottom: 0.5rem;
}

.tutorial-sidebar a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.95rem;
    display: block;
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.tutorial-sidebar a:hover, .tutorial-sidebar a.active {
    background: rgba(139, 92, 246, 0.1);
    color: var(--primary);
}

/* 主内容区 */
.tutorial-content {
    flex: 1;
    max-width: 800px;
    line-height: 1.8;
    padding-bottom: 4rem;
}

.tutorial-content h1 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tutorial-content h2 {
    font-size: 1.8rem;
    margin-top: 3rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
    color: var(--text-primary);
}

.tutorial-content h3 {
    font-size: 1.3rem;
    margin-top: 2rem;
    margin-bottom: 0.8rem;
    color: var(--text-primary);
}

.tutorial-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.tutorial-content img {
    max-width: 100%;
    border-radius: 12px;
    border: 1px solid var(--border);
    margin: 1.5rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.info-box {
    background: rgba(139, 92, 246, 0.05);
    border-left: 4px solid var(--primary);
    padding: 1.5rem;
    border-radius: 0 8px 8px 0;
    margin: 1.5rem 0;
}

.info-box p {
    margin: 0;
    color: var(--text-primary);
}

.warning-box {
    background: rgba(239, 68, 68, 0.05);
    border-left: 4px solid #ef4444;
    padding: 1.5rem;
    border-radius: 0 8px 8px 0;
    margin: 1.5rem 0;
}

.step-badge {
    display: inline-block;
    background: var(--primary);
    color: white;
    width: 28px;
    height: 28px;
    text-align: center;
    line-height: 28px;
    border-radius: 50%;
    margin-right: 10px;
    font-weight: bold;
    font-size: 0.9rem;
}

code {
    background: rgba(255,255,255,0.1);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: var(--primary-light);
}

[data-theme='light'] code {
    background: rgba(0,0,0,0.05);
    color: var(--primary);
}

@media (max-width: 900px) {
    .tutorial-container {
        flex-direction: column;
    }
    .tutorial-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border);
        padding-right: 0;
        padding-bottom: 1.5rem;
        position: static;
    }
}
