body { 
    font-family: 'Noto Sans SC', sans-serif; 
    line-height: 1.6;
}

.loading { 
    display: flex; 
    justify-content: center; 
}

/* 自定义动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.6s ease-out forwards;
}

/* 平滑的颜色过渡 */
.transition-colors {
    transition: color 0.3s ease;
}

/* 回到顶部按钮样式优化 */
#backToTop {
    transition: all 0.3s ease;
}

#backToTop:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(147, 51, 234, 0.3);
}

/* 卡片悬停效果 */
article {
    transition: all 0.3s ease;
}

article:hover {
    transform: translateY(-2px);
}

/* 移动端菜单动画 */
.mobile-menu {
    transition: all 0.3s ease;
}

/* 导航链接活跃状态 */
nav a.active {
    color: #9333ea;
    font-weight: 600;
}

/* 响应式字体大小 */
@media (max-width: 768px) {
    h1 {
        font-size: 1.5rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    h3 {
        font-size: 1.4rem;
    }
}

/* 优化滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* 焦点可见性优化 */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #9333ea;
    outline-offset: 2px;
}

/* 提升可访问性的跳过链接 */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #9333ea;
    color: white;
    padding: 8px;
    border-radius: 4px;
    text-decoration: none;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}

/* 优化加载状态 */
.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* 防止内容跳跃的占位符 */
.content-placeholder {
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border-radius: 8px;
}

/* 网格布局优化 */
.grid-responsive {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

@media (min-width: 768px) {
    .grid-responsive {
        gap: 1.5rem;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* 提升文本可读性 */
.text-shadow {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* 优化按钮交互 */
.btn-primary {
    transform: translateY(0);
    transition: all 0.2s ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(147, 51, 234, 0.2);
}

.btn-primary:active {
    transform: translateY(0);
}