/* 现代简约设计系统 - 简约科技风格暗黑模式配色方案 */
:root {
    --primary-color: #3B82F6;
    --secondary-color: #1E40AF;
    --cta-color: #22C55E;
    --background-color: #020617;
    --text-color: #F8FAFC;
    --light-text: #94A3B8;
    --border-color: #334155;
    --card-background: #0F172A;
    --hover-color: #1E293B;
    --accent-color: #F59E0B;
    --warning-color: #EF4444;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -2px rgba(0, 0, 0, 0.4);
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-xxl: 48px;
    --border-radius: 8px;
    --border-radius-large: 12px;
    --transition-speed: 0.3s;
    --font-size-xs: 13px;
    --font-size-sm: 15px;
    --font-size-md: 17px;
    --font-size-lg: 19px;
    --font-size-xl: 25px;
    --font-size-xxl: 33px;
}

/* 立即应用背景色，避免闪烁 */
html, body {
    margin: 0;
    padding: 0;
    background-color: var(--background-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

/* 响应式容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 20px 50px;
}

/* 控制按钮容器 */
.control-buttons {
    position: fixed;
    top: 20px;
    left: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1000;
    background-color: var(--card-background);
    padding: 10px;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}

/* 侧边目录切换按钮 */
.sidebar-toggle {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background-color: var(--card-background);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.sidebar-toggle:hover {
    background-color: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-sm);
}

.sidebar-toggle.active {
    background-color: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-sm);
}

/* 侧边目录 */
.sidebar {
    position: fixed;
    top: 50%;
    left: -320px;
    transform: translateY(-50%);
    width: 280px;
    height: 80vh;
    max-height: 600px;
    background-color: var(--background-color);
    border: 1px solid var(--border-color);
    padding: 40px 20px 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    overflow-y: auto;
}

.sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(79, 70, 229, 0.05) 0%, rgba(79, 70, 229, 0) 100%);
    pointer-events: none;
}

.sidebar.show {
    left: 30px;
    transform: translateY(-50%);
}

/* 侧边栏滚动条样式 */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: var(--card-background);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

.sidebar-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.sidebar-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-menu li {
    margin-bottom: 4px;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-color);
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
    position: relative;
    overflow: hidden;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.sidebar-menu a::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background-color: var(--primary-color);
    transform: scaleY(0);
    transition: transform 0.3s ease;
    border-radius: 0 2px 2px 0;
}

.sidebar-menu a:hover {
    background-color: rgba(79, 70, 229, 0.1);
    color: var(--primary-color);
    transform: translateX(8px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.sidebar-menu a:hover::before {
    transform: scaleY(1);
}

.sidebar-menu a i {
    font-size: 16px;
    width: 20px;
    text-align: center;
    transition: transform 0.3s ease;
}

.sidebar-menu a:hover i {
    transform: scale(1.1) rotate(5deg);
}

/* 子菜单样式 */
.sidebar-menu .submenu {
    list-style: none;
    padding: 0;
    margin: 4px 0 4px 24px;
    border-left: 2px solid var(--border-color);
}

.sidebar-menu .submenu li {
    margin-bottom: 2px;
}

.sidebar-menu .submenu a {
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 400;
}

.sidebar-menu .submenu a:hover {
    transform: translateX(4px);
    background-color: rgba(79, 70, 229, 0.08);
}

/* 活动状态 */
.sidebar-menu a.active {
    background-color: rgba(79, 70, 229, 0.15);
    color: var(--primary-color);
    font-weight: 600;
}

.sidebar-menu a.active::before {
    transform: scaleY(1);
}

/* 右上角挂件按钮 */
.calendar-widget {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    font-size: 18px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    z-index: 1000;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.calendar-widget:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.calendar-widget:active {
    transform: translateY(0);
}

/* 顶部滑入弹窗 - 版本活动日历 */
.calendar-popup {
    position: fixed;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 800px;
    background-color: var(--card-background);
    border-radius: 0 0 16px 16px;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    transition: top 0.3s ease;
    border: 1px solid var(--border-color);
    border-top: none;
}

.calendar-popup.show {
    top: 0;
}

.calendar-popup-content {
    padding: 20px;
}

.calendar-popup-content img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    cursor: zoom-in;
    transition: all 0.2s ease;
    border: 1px solid var(--border-color);
}

.calendar-popup-content img:hover {
    transform: scale(1.01);
    box-shadow: var(--shadow-md);
}

/* 全屏图片容器 */
.fullscreen-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    cursor: zoom-out;
}

/* 全屏图片样式 */
.fullscreen-overlay img {
    max-width: 95%;
    max-height: 95%;
    object-fit: contain;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

/* 公告容器 */
.notice-container {
    padding: 0px 20px 50px;
    max-width: 1000px;
    margin: 0 auto;
}

/* 公告分类 */
.notice-category {
    margin-bottom: 40px;
}

/* 分类标题 */
.category-title {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
}

/* 公告列表 */
.notice-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* 公告卡片 */
.notice-card {
    background-color: var(--card-background);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.notice-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

/* 公告头部 */
.notice-header {
    margin-bottom: 16px;
}

.notice-head {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0 0 8px;
}

/* 公告内容 */
.notice-content {
    line-height: 1.7;
    font-size: 15px;
    color: var(--text-color);
}

/* 红色强调文本 */
.color-red {
    color: var(--cta-color);
    font-weight: 600;
}

/* 公告图片 */
.notice-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 16px 0;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.notice-image:hover {
    transform: scale(1.01);
    box-shadow: var(--shadow-md);
}

/* 页面标题 */
.page-title {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.page-title h1 {
    font-size: 32px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.page-title p {
    font-size: 16px;
    color: var(--light-text);
    max-width: 800px;
    margin: 0 auto 8px;
    line-height: 1.5;
}

/* 更新日志列表 */
.update-log-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
    margin-top: 32px;
}

/* 更新日志项 */
.update-log-item {
    background-color: var(--card-background);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.update-log-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

/* 左侧边框 */
.update-log-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 4px 0 0 4px;
}

/* 更新日期 */
.update-log-date {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 12px;
}

/* 更新标题 */
.update-log-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 12px;
}

/* 更新描述 */
.update-log-description {
    font-size: 14px;
    color: var(--light-text);
    margin-bottom: 16px;
    line-height: 1.6;
}

/* 查看详情链接 */
.update-log-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 14px;
}

.update-log-link:hover {
    color: var(--secondary-color);
}

.update-log-link i {
    margin-left: 8px;
    transition: transform 0.2s ease;
}

.update-log-item:hover .update-log-link i {
    transform: translateX(5px);
}

/* 部分标题 */
.section-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-color);
    margin-top: 48px;
    margin-bottom: 24px;
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background-color: var(--primary-color);
}

/* 回到顶部按钮 */
.back-to-top {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background-color: var(--card-background);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.back-to-top:hover {
    background-color: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-sm);
}

/* 按钮效果 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid var(--border-color);
    background-color: var(--card-background);
    color: var(--text-color);
}

.btn:hover {
    background-color: var(--hover-color);
    border-color: var(--primary-color);
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

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

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

::-webkit-scrollbar-track {
    background: var(--card-background);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* 打印样式 */
@media print {
    .sidebar, .control-buttons, .calendar-widget {
        display: none;
    }
    
    .notice-container {
        margin-left: 0;
        padding: 0;
    }
    
    body {
        background: white;
        color: black;
    }
}

/* 移动端触摸优化 */
@media (hover: none) and (pointer: coarse) {
    .sidebar-menu a:active {
        background-color: rgba(79, 70, 229, 0.1);
    }
    
    .sidebar-toggle:active, .calendar-widget:active {
        transform: scale(0.95);
    }
    
    .notice-card:active {
        transform: scale(0.98);
    }
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .notice-container {
        padding: 20px 20px 40px;
    }

    .category-title {
        font-size: 24px;
    }

    .notice-head {
        font-size: 18px;
    }

    .notice-card {
        padding: 20px;
    }

    .update-log-list {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 20px;
    }

    .page-title h1 {
        font-size: 28px;
    }

    .container {
        padding: 80px 20px 40px;
    }
}

@media (max-width: 768px) {
    .control-buttons {
        top: 15px;
        left: 15px;
        padding: 8px;
    }

    .sidebar-toggle {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .calendar-widget {
        top: 15px;
        right: 15px;
        width: 44px;
        height: 44px;
        font-size: 16px;
    }

    .notice-container {
        padding: 15px 15px 30px;
    }

    .category-title {
        font-size: 22px;
    }

    .notice-head {
        font-size: 16px;
    }

    .notice-card {
        padding: 18px;
    }

    .notice-content {
        font-size: 14px;
    }

    .update-log-list {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .update-log-item {
        padding: 20px;
    }

    .page-title h1 {
        font-size: 24px;
    }

    .page-title p {
        font-size: 14px;
        padding: 0 16px;
    }

    .section-title {
        font-size: 20px;
        margin-top: 40px;
    }

    .container {
        padding: 70px 15px 30px;
    }

    .back-to-top {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .sidebar {
        width: 250px;
        left: -290px;
    }

    .sidebar.show {
        left: 15px;
    }
}

@media (max-width: 375px) {
    .container {
        padding: 60px 10px 20px;
    }

    .notice-container {
        padding: 60px 10px 20px;
    }

    .category-title {
        font-size: 20px;
    }

    .notice-head {
        font-size: 16px;
    }

    .notice-card {
        padding: 16px;
    }

    .notice-content {
        font-size: 13px;
    }

    .page-title h1 {
        font-size: 20px;
    }

    .update-log-item {
        padding: 16px;
    }

    .update-log-date {
        font-size: 16px;
    }

    .update-log-title {
        font-size: 15px;
    }

    .update-log-description {
        font-size: 13px;
    }
}