
/* 
全局样式设置，包括页面的基本字体、颜色、背景等
*/
body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif; /* 使用现代无衬线字体 */
    background: linear-gradient(135deg, #0d47a1, #546e7a); /* 主色调渐变背景 */
    color: #ffffff;
    line-height: 1.6;
}

/* 固定导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(13, 71, 161, 0.9);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
}

/* 导航栏列表 */
.navbar ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 导航栏列表项 */
.navbar li {
    margin-right: 20px;
    position: relative;
}

/* 导航链接样式 */
.navbar a {
    color: #ffffff;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s;
}

/* 导航链接悬停效果 */
.navbar a:hover {
    color: #00e5ff;
}

/* 多级菜单隐藏样式 */
.navbar ul ul {
    display: none;
    position: absolute;
    top: 40px;
    left: 0;
    background: #0d47a1;
    padding: 10px;
    list-style: none;
    border-radius: 5px;
}

/* 多级菜单显示触发 */
.navbar li:hover > ul {
    display: block;
}

/* 搜索框样式 */
.search-box {
    position: relative;
}

.search-box input {
    padding: 5px 10px;
    border: none;
    border-radius: 3px;
    font-size: 14px;
}

.search-box input:focus {
    outline: none;
    box-shadow: 0 0 5px #69f0ae;
}

/* 主内容区域样式 */
.main-content {
    padding: 80px 20px 20px 20px; /* 顶部留出导航栏空间 */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

/* 文章内容样式 */
article {
    background: rgba(84, 110, 122, 0.8);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* 文章标题样式 */
article h2, article h3, article h4 {
    color: #00e5ff;
    margin-top: 20px;
}

article h2 {
    font-size: 24px;
}

article h3 {
    font-size: 20px;
}

article h4 {
    font-size: 18px;
}

/* 段落样式 */
article p {
    font-size: 16px;
    margin-top: 10px;
    text-align: justify;
}

/* 代码块样式 */
article pre {
    background: #263238;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    margin-top: 10px;
}

article code {
    color: #00e5ff;
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
}

/* 图片样式 */
img.decorative {
    width: 100%;
    max-width: 320px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s, box-shadow 0.3s;
}

img.decorative:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 10px 20px;
    background: #00e5ff;
    color: #0d47a1;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-size: 16px;
    transition: background 0.3s, transform 0.3s;
}

.button:hover {
    background: #69f0ae;
    transform: translateY(-2px);
}

/* 折叠区域样式 */
.collapsible {
    background: #546e7a;
    color: #ffffff;
    cursor: pointer;
    padding: 10px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 16px;
    border-radius: 5px;
    margin-top: 10px;
    transition: background 0.3s;
}

.collapsible:hover {
    background: #00e5ff;
    color: #0d47a1;
}

.content {
    padding: 0 15px;
    display: none;
    background: rgba(84, 110, 122, 0.9);
    overflow: hidden;
    border-radius: 5px;
    margin-bottom: 10px;
}

/* 视觉提示文字样式 */
.visual-hint {
    font-size: 18px;
    color: #ffeb3b;
    text-align: center;
    margin: 20px 0;
}

/* 响应式设计调整 */
@media (max-width: 768px) {
    .navbar ul {
        flex-direction: column;
    }

    .navbar li {
        margin-right: 0;
        margin-bottom: 10px;
    }

    .main-content {
        grid-template-columns: 1fr;
    }

    .navbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .search-box {
        margin-top: 10px;
    }
}

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

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 动画应用到特定元素 */
.animated-illustration {
    animation: fadeIn 2s ease-in-out;
}

.loader::before {
    content: '';
    width: 50px;
    height: 50px;
    border: 5px solid #69f0ae;
    border-top: 5px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* 加载动画样式 */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #0d47a1;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

/* 数据可视化图表样式 */
.chart-bar {
    width: 0;
    height: 30px;
    background: #00e5ff;
    transition: width 1.5s ease-in-out;
}

.chart-bar.active {
    width: 80%;
}

.dashboard {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.widget {
    background: #546e7a;
    padding: 20px;
    border-radius: 5px;
    flex: 1 1 45%;
}

/* 点缀色应用 */
.accent-color {
    color: #ffeb3b;
}

/* 表格样式 */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table, th, td {
    border: 1px solid #00e5ff;
}

th, td {
    padding: 10px;
    text-align: left;
}

th {
    background: #0d47a1;
}

/* 链接样式 */
a.internal-link {
    color: #69f0ae;
    text-decoration: none;
}

a.internal-link:hover {
    text-decoration: underline;
}

/* 过渡效果应用 */
.transition-effect {
    transition: all 0.3s ease;
}

/* 光线穿梭效果 */
.light-beam {
    position: absolute;
    top: 0;
    left: 50%;
    width: 2px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, #00e5ff, transparent);
    animation: spin 2s linear infinite;
}

/* 图标样式 */
.icon {
    stroke: #00e5ff;
    stroke-width: 2;
    fill: none;
    transition: stroke 0.3s;
}

.icon:hover {
    stroke: #69f0ae;
}

