/* 基础背景和字体 */
body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #f0f2f5;
    margin: 0;
    padding: 40px 20px;
    display: flex;
    justify-content: center;
}

.container {
    max-width: 1000px;
    width: 100%;
    text-align: center;
}

/* 主标题：大气、醒目 */
.main-title {
    font-size: 2.5rem;
    color: #1a1a1a;
    margin-bottom: 8px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* 副标题：低调、清晰 */
.sub-title {
    font-size: 1.1rem;
    color: #666;
    font-weight: normal;
    margin-bottom: 40px;
}

/* 导航网格：响应式布局 */
.nav-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

/* 卡片样式 */
.card {
    background: #fff;
    padding: 24px;
    border-radius: 15px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    border-color: #007aff;
}

.card h3 {
    margin: 0 0 10px 0;
    color: #007aff;
}

.card p {
    margin: 0;
    font-size: 0.9rem;
    color: #888;
}
/* 搜索框样式 */
.search-container {
    margin-bottom: 40px;
    position: relative;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

#searchInput {
    width: 100%;
    padding: 15px 25px;
    border-radius: 30px;
    border: 2px solid #eee;
    font-size: 1rem;
    transition: all 0.3s;
    outline: none;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

#searchInput:focus {
    border-color: #007aff;
    box-shadow: 0 6px 15px rgba(0,123,255,0.2);
}

.search-engines {
    margin-top: 10px;
    font-size: 0.8rem;
    color: #888;
}

.engine {
    margin: 0 10px;
    cursor: pointer;
    transition: color 0.3s;
}

.engine.active {
    color: #007aff;
    font-weight: bold;
}

/* 卡片增强交互 */
.card:active {
    transform: scale(0.95); /* 点击时微缩，模拟物理按压感 */
}
.floating-feedback {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #007aff; /* 宁财蓝风格 */
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: bold;
    z-index: 999;
}

.floating-feedback:hover {
    transform: scale(1.1) rotate(10deg); /* 悬停时放大并稍微旋转，增加交互感 */
    background-color: #0056b3;
}/* 玻璃拟态卡片示例 */
.card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}/* 定义白天模式变量 */
:root {
    --bg-color: #f0f2f5;
    --card-bg: #ffffff;
    --text-main: #1a1a1a;
    --text-sub: #666;
    --accent-color: #007aff;
}

/* 定义深色模式变量 */
[data-theme="dark"] {
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --text-main: #e0e0e0;
    --text-sub: #aaa;
    --accent-color: #3793ff;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    transition: background 0.3s, color 0.3s; /* 让切换更平滑 */
}

.card {
    background: var(--card-bg);
    color: var(--text-main);
}
/* ... 其他元素的 color 和 background 都要改成 var(--xxx) ... */
/* 遮罩扩散动画的核心 CSS */
::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}

/* 扩散圆圈的动画定义 */
::view-transition-image-pair(root) {
  isolation: auto;
}

/* 深色模式下的背景微光 */
[data-theme="dark"] body {
    background: radial-gradient(circle at center, #1e293b 0%, #0f172a 100%);
}
.semester-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 10px 20px;
    /* 配合你的玻璃拟态主题 */
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.semester-bar {
    width: 80%; /* 宽度适中，不压抑 */
    height: 4px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 4px;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #007aff, #00c6ff);
    box-shadow: 0 0 10px rgba(0, 122, 255, 0.5);
    transition: width 1.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.semester-info {
    font-size: 10px;
    color: var(--text-sub);
    letter-spacing: 1px;
    text-transform: uppercase;
    display: flex;
    gap: 15px;
}

/* 深色模式适配 */
[data-theme="dark"] .semester-bar {
    background: rgba(255, 255, 255, 0.1);
}
/* 搜索框聚焦时的发光效果 */
#searchInput:focus {
    box-shadow: 0 0 20px var(--accent-color);
    transform: scale(1.02);
}

/* 搜索引擎指示器动画 */
.engine {
    position: relative;
    padding: 5px 10px;
}

.engine.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background: var(--accent-color);
    border-radius: 50%;
}#themeToggle {
    position: fixed;
    top: 60px; /* 避开顶部约 50px 高度的进度条区域 */
    right: 30px;
    z-index: 1001; /* 确保在所有层级之上 */
    background: var(--card-bg);
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    cursor: pointer;
}/* --- 页面最底部沉浸式入口 --- */

/* 1. 底部容器：强制换行并全局居中 */
.mini-portal-footer {
    width: 100%;
    margin-top: 80px;      /* 与上方导航卡片保持充足呼吸感 */
    padding: 30px 0 50px;  /* 底部留白，防止贴边 */
    display: flex;
    flex-direction: column;
    align-items: center;   /* 水平居中 */
    justify-content: center;
    clear: both;           /* 清除可能的浮动干扰 */
    position: relative;
    z-index: 10;           /* 确保在背景层之上 */
}

/* 2. 分割线：精致的工业感细节 */
.footer-divider {
    width: 60px;
    height: 2px;
    background: rgba(128, 128, 128, 0.2);
    border-radius: 2px;
    margin-bottom: 25px;
}

/* 3. 胶囊链接：小巧精致的入口 */
.mini-visual-link {
    display: inline-flex;  /* 保持内部元素水平排列 */
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(255, 255, 255, 0.08); /* 极淡的半透明 */
    backdrop-filter: blur(12px);           /* 磨砂玻璃效果 */
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 40px;                   /* 完美圆角胶囊 */
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* 4. 悬停动效：亮色模式/深色模式通用 */
.mini-visual-link:hover {
    background: rgba(0, 122, 255, 0.12);
    border-color: rgba(0, 122, 255, 0.4);
    transform: translateY(-3px);           /* 轻微浮起 */
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.15);
}

/* 5. 内部文字与图标 */
.sparkle-icon {
    font-size: 14px;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

.link-text {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-main);              /* 使用你定义的主文字颜色变量 */
    letter-spacing: 0.5px;
}

.arrow-icon {
    font-size: 10px;
    color: #007aff;                       /* 经典的交互蓝色 */
    transition: transform 0.3s ease;
}

.mini-visual-link:hover .arrow-icon {
    transform: translateX(3px);           /* 箭头指向动效 */
}

/* 6. 版权信息 */
.copyright {
    margin-top: 15px;
    font-size: 10px;
    color: var(--text-sub);               /* 使用你定义的辅助文字颜色变量 */
    opacity: 0.4;
    text-align: center;
    letter-spacing: 1px;
}

/* --- 深色模式适配（如果你的变量名不同请微调） --- */
[data-theme="dark"] .mini-visual-link {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}