/* 自定义样式 */

/* 全局样式 */
html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
}

/* 导航栏样式 */
header {
    transition: background-color 0.3s, box-shadow 0.3s;
}

/* 活动导航项样式 */
.doc-nav-item.active {
    background-color: #EBF5FF;
    color: #2563EB;
    font-weight: 500;
}

/* FAQ 折叠面板样式 */
.faq-toggle svg {
    transition: transform 0.3s ease;
}

.faq-toggle.active svg {
    transform: rotate(180deg);
}

/* 代码块样式 */
pre {
    font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* 响应式图片 */
img {
    max-width: 100%;
    height: auto;
}

/* 链接悬停效果 */
a:not(.doc-nav-item):not([class*="bg-"]):hover {
    text-decoration: underline;
}

/* 文档导航固定位置 */
@media (min-width: 1024px) {
    .sticky {
        position: sticky;
        top: 6rem;
    }
}

/* 移动端菜单动画 */
#mobile-menu {
    transition: max-height 0.3s ease-out;
    max-height: 0;
    overflow: hidden;
}

#mobile-menu.show {
    max-height: 300px;
}

/* 按钮悬停效果 */
button:hover, 
a[class*="bg-"]:hover {
    transform: translateY(-1px);
    transition: transform 0.2s;
}

/* 页面过渡效果 */
.container {
    animation: fadeIn 0.5s ease-in-out;
}

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

/* 打印样式 */
@media print {
    header, footer, #mobile-menu-button {
        display: none !important;
    }
    
    body {
        padding-top: 0 !important;
    }
    
    .container {
        width: 100% !important;
        max-width: none !important;
    }
}