
/* 
整体页面样式定义
此样式表应用于现代化教育平台的网页设计，融合了玻璃拟态与互动学习元素，确保页面具有现代感与用户友好性。使用了CSS3的高级特性，如线性渐变、柔和阴影、关键帧动画等，营造出丰富的视觉层次和沉浸式体验。
*/

/* 基础样式重置，确保跨浏览器一致性 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 设置全局字体和背景 */
body {
    font-family: 'Roboto', 'Open Sans', sans-serif;
    background: linear-gradient(135deg, #e0f7fa, #ffffff);
    color: #333;
    line-height: 1.6;
}

/* 顶部导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

/* 导航链接样式 */
.navbar a {
    color: #333;
    text-decoration: none;
    margin: 0 15px;
    font-weight: 500;
    transition: color 0.3s;
}

.navbar a:hover {
    color: #FFA500;
}

/* 下拉菜单样式 */
.dropdown-menu {
    display: none;
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(8px);
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
}

.navbar .dropdown:hover .dropdown-menu {
    display: block;
}

/* 主要内容区域的容器样式 */
.container {
    max-width: 1200px;
    margin: 100px auto 50px;
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 30px;
}

/* 玻璃拟态卡片样式 */
.card {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    border: 1px solid rgba(255, 255, 255, 0.18);
    padding: 30px;
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 40px rgba(31, 38, 135, 0.5);
}

/* 标题样式 */
h2, h3, h4 {
    color: #1E90FF;
    margin-bottom: 15px;
}

h2 {
    font-size: 2em;
    text-align: center;
}

h3 {
    font-size: 1.5em;
    margin-top: 20px;
}

/* 段落样式 */
p {
    font-size: 16px;
    margin-bottom: 20px;
    color: #555;
}

/* 代码块样式 */
pre {
    background: rgba(0, 0, 0, 0.05);
    padding: 15px;
    border-radius: 10px;
    overflow: auto;
    position: relative;
}

pre code {
    font-family: 'Courier New', Courier, monospace;
    color: #d63384;
}

/* 代码块前置标题 */
pre code::before {
    content: "代码示例";
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
    color: #1E90FF;
}

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

table th, table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

table th {
    background-color: rgba(30, 144, 255, 0.2);
    color: #1E90FF;
}

table tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 图片样式 */
img.decorative {
    width: 100%;
    border-radius: 15px;
    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);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .container {
        grid-template-columns: 1fr;
    }
    
    h2 {
        font-size: 1.8em;
    }
}

/* 动画样式 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.article-content {
    animation: fadeIn 2s ease-in;
}

/* 提示信息样式 */
.alert {
    background: #ffecb3;
    border-left: 6px solid #ffc107;
    padding: 10px 20px;
    margin-bottom: 20px;
    border-radius: 5px;
    font-size: 16px;
}

/* 链接样式 */
a.nofollow-link {
    color: #1E90FF;
    text-decoration: none;
}

a.nofollow-link:hover {
    color: #FFA500;
}

/* 按钮样式 */
button {
    background: linear-gradient(45deg, #1E90FF, #00CED1);
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: transform 0.3s, background 0.3s;
}

button:hover {
    transform: scale(1.05);
    background: linear-gradient(45deg, #FFD700, #FFA500);
}

/* 折叠区域样式 */
.collapsible {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 10px 20px;
    cursor: pointer;
    margin-bottom: 10px;
    transition: background 0.3s;
}

.collapsible:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.content {
    display: none;
    padding: 10px 20px;
    border-left: 3px solid #1E90FF;
}

/* 展开状态 */
.collapsible.active + .content {
    display: block;
}

/* 加载动画样式 */
.loader {
    border: 8px solid rgba(255, 255, 255, 0.3);
    border-top: 8px solid #00CED1;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

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

/* 底部信息区样式 */
.footer {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 40px 20px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    color: #333;
}

.footer a {
    color: #00CED1;
    text-decoration: none;
    margin: 0 10px;
    transition: color 0.3s;
}

.footer a:hover {
    color: #FFA500;
}

/* 视觉引导区样式 */
.hero-section {
    background: linear-gradient(135deg, #1E90FF, #00CED1);
    color: #fff;
    padding: 100px 20px;
    text-align: center;
    border-radius: 10px;
    margin-bottom: 50px;
    position: relative;
    overflow: hidden;
}

.hero-section h1 {
    font-size: 3em;
    margin-bottom: 20px;
}

.hero-section p {
    font-size: 1.2em;
    max-width: 800px;
    margin: 0 auto;
}

.hero-section::after {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(45deg);
    z-index: -1;
    animation: rotateBackground 10s linear infinite;
}

@keyframes rotateBackground {
    from { transform: rotate(45deg); }
    to { transform: rotate(405deg); }
}

