/* 全局重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    list-style: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ==============================
   导航栏容器（桌面端）
   ============================== */
.nav {
    background-color: #417dff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

/* 左侧Logo */
.nav-logo {
    flex-shrink: 0;
}

.qing {
    color: #ffffff;
    font-size: 30px;
    font-family: kaiti, "楷体", serif;
    line-height: 40px;
}

/* 桌面端导航 */
/*.desktop-nav {*/
/*    display: flex;*/
/*    height: 100%;*/
/*}*/

.desktop-nav {
    display: flex;
    height: 100%;
    flex: 1 1 auto;          /* 允许伸缩 */
    justify-content: center; /* 内部菜单项居中对齐 */
    gap: 0;                  /* 原有间距由 .btli 控制 */
}

.btli {
    width: 100px;
    height: 100%;
    line-height: 40px;
    text-align: center;
}

.desktop-nav a {
    color: #ffffff;
    font-size: 18px;
    display: block;
    height: 100%;
    transition: background-color 0.2s ease;
}

.desktop-nav a:hover {
    background-color: #666;
}

/* 桌面端用户信息 */
.desktop-user {
    display: flex;
    align-items: center;
}

.bail {
    margin-left: 20px;
    color: #ffffff;
    font-size: 18px;
    line-height: 40px;
    transition: opacity 0.2s ease;
}

.bail:hover {
    opacity: 0.8;
}

/* ==============================
   移动端汉堡菜单
   ============================== */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 30px;
    height: 30px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background-color: #ffffff;
    margin: 3px 0;
    transition: all 0.3s ease;
}

/* 汉堡按钮激活状态（变成叉号） */
.hamburger.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* 移动端菜单抽屉 */
.mobile-menu {
    position: fixed;
    top: 40px;
    right: -100%;
    width: 70%;
    max-width: 280px;
    height: calc(100vh - 40px);
    background-color: #ffffff;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    z-index: 999;
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
}

/* 移动端导航列表 */
.mobile-navlist {
    padding: 20px 0;
}

.mobile-navlist li {
    width: 100%;
}

.mobile-navlist a {
    display: block;
    padding: 15px 25px;
    color: #333;
    font-size: 16px;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s ease;
}

.mobile-navlist a:hover {
    background-color: #f5f5f5;
}

/* 移动端用户信息 */
.mobile-user {
    padding: 20px 25px;
    border-top: 1px solid #e0e0e0;
}

.mobile-welcome {
    display: block;
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.mobile-login, .mobile-logout {
    display: block;
    width: 100%;
    padding: 10px 0;
    text-align: center;
    background-color: #417dff;
    color: #ffffff;
    border-radius: 4px;
    font-size: 14px;
    transition: background-color 0.2s ease;
}

.mobile-login:hover, .mobile-logout:hover {
    background-color: #3366cc;
}

/* 菜单遮罩层 */
.menu-overlay {
    position: fixed;
    top: 40px;
    left: 0;
    width: 100%;
    height: calc(100vh - 40px);
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ==============================
   Flash 弹窗核心样式
   ============================== */
.flash-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.flash-overlay.show {
    opacity: 1;
    visibility: visible;
}

.flash-modal {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 400px;
    padding: 24px;
    position: relative;
    transform: translateY(-20px);
    transition: transform 0.3s ease;
}

.flash-overlay.show .flash-modal {
    transform: translateY(0);
}

.flash-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 24px;
    height: 24px;
    border: none;
    background: none;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
    padding: 0;
}

.flash-close:hover {
    opacity: 1;
}

.flash-close::before,
.flash-close::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 2px;
    background-color: #666;
}

.flash-close::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.flash-close::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.flash-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 16px;
    font-size: 24px;
    font-weight: bold;
}

.flash-content {
    text-align: center;
}

.flash-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.flash-message {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* 不同类型消息的颜色 */
.flash-success .flash-icon {
    background-color: #d4edda;
    color: #155724;
}

.flash-success .flash-title {
    color: #155724;
}

.flash-error .flash-icon {
    background-color: #f8d7da;
    color: #721c24;
}

.flash-error .flash-title {
    color: #721c24;
}

.flash-warning .flash-icon {
    background-color: #fff3cd;
    color: #856404;
}

.flash-warning .flash-title {
    color: #856404;
}

.flash-info .flash-icon {
    background-color: #d1ecf1;
    color: #0c5460;
}

.flash-info .flash-title {
    color: #0c5460;
}

/* ==============================
   响应式断点
   ============================== */
/* 平板：768px以下 */
@media (max-width: 768px) {
    .btli {
        width: 80px;
    }

    .desktop-nav a {
        font-size: 16px;
    }

    .bail {
        font-size: 16px;
        margin-left: 15px;
    }
}

/* 手机：480px以下 - 显示汉堡菜单 */
@media (max-width: 480px) {
    .desktop-nav, .desktop-user {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .nav-container {
        padding: 0 15px;
    }

    .qing {
        font-size: 24px;
    }

    /* 弹窗移动端优化 */
    .flash-modal {
        max-width: 95%;
        padding: 20px;
        border-radius: 10px;
    }

    .flash-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
        margin-bottom: 12px;
    }

    .flash-title {
        font-size: 16px;
    }

    .flash-message {
        font-size: 13px;
    }

    .flash-close {
        top: 12px;
        right: 12px;
        width: 20px;
        height: 20px;
    }

    .flash-close::before,
    .flash-close::after {
        width: 14px;
    }
}

/* 超小屏幕：360px以下 */
@media (max-width: 360px) {
    .qing {
        font-size: 22px;
    }

    .mobile-menu {
        width: 80%;
    }
}

.footer {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
    color: #a0aec0;
    padding: 40px 20px;
    text-align: center;
}

.footer-links {
    margin-bottom: 20px;
    /* 手机端自动换行 */
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.footer-links a {
    color: #a0aec0;
    margin: 0 15px;
    transition: color 0.2s ease;
    /* 解决手机点击区域太小 */
    display: inline-block;
    padding: 5px 0;
}

.footer-links a:hover {
    color: white;
}

.copyright {
    font-size: 14px;
}

/* ======================
   手机端适配（核心代码）
====================== */
@media (max-width: 768px) {
    .footer {
        /* 手机端减少内边距 */
        padding: 30px 15px;
    }

    .footer-links a {
        /* 手机端链接间距缩小 */
        margin: 0 8px;
        font-size: 14px;
    }

    .copyright {
        /* 手机端版权文字缩小 */
        font-size: 12px;
        line-height: 1.5;
    }
}

/* 导航栏Logo图片样式 */
.nav-logo-img {
    height: 38px;      /* 高度，自动适配宽度 */
    width: auto;
    display: block;
    object-fit: contain;
}








/* ===== 深色页脚（宽度与 .section 一致） ===== */
.footer {
    background: linear-gradient(145deg, #1e293b 0%, #0f172a 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding: 48px 20px 32px;
    box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    margin-top: 0; /* 保证与上方无额外间隙 */
}

/* 装饰光晕 */
.footer::before {
    content: '';
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 120px;
    background: radial-gradient(ellipse, rgba(116, 158, 227, 0.12) 0%, transparent 70%);
    pointer-events: none;
    border-radius: 50%;
}

/* 内部容器 ———— 与主体保持相同最大宽度 */
.footer-inner {
    max-width: 1200px;      /* 与您的 .section 一致 */
    margin: 0 auto;
    position: relative;
    z-index: 1;
    padding: 0 20px;        /* 左右内边距，与主体呼应 */
}

/* ---- 导航链接 ---- */
.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px 36px;
    margin-bottom: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: #d1d9e6;
    text-decoration: none;
    letter-spacing: 1px;
    padding: 6px 4px;
    position: relative;
    transition: color 0.3s ease, transform 0.25s ease;
}

.footer-links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #8bb3f0, #aac8ff);
    border-radius: 4px;
    transition: width 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.footer-links a:hover {
    color: #8bb3f0;
    transform: translateY(-1px);
}

.footer-links a:hover::after {
    width: 100%;
}

.footer-links .dot {
    display: inline-block;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
}

/* ---- 版权 ---- */
.footer-copyright {
    text-align: center;
    font-size: 0.85rem;
    color: #b0c0d0;
    letter-spacing: 0.5px;
    margin-bottom: 18px;
}

.footer-copyright .brand {
    font-weight: 600;
    color: #e8edf5;
    letter-spacing: 2px;
}

.footer-copyright .version {
    display: inline-block;
    background: rgba(255, 255, 255, 0.06);
    padding: 0 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    color: #9bb9f0;
    font-weight: 500;
    margin-left: 6px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

/* ---- 备案信息 ---- */
.footer-legal {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 16px 28px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-legal .legal-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    color: #a0b0c0;
    transition: color 0.25s ease;
}

.footer-legal .legal-item:hover {
    color: #c0d0e0;
}

.footer-legal .legal-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.footer-legal .legal-item:hover .legal-icon {
    opacity: 1;
}

.footer-legal .legal-icon img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
}

.footer-legal a {
    color: inherit;
    text-decoration: none;
    transition: color 0.25s ease;
    border-bottom: 1px dashed transparent;
}

.footer-legal a:hover {
    color: #8bb3f0;
    border-bottom-color: rgba(139, 179, 240, 0.3);
}

.legal-divider {
    color: rgba(255, 255, 255, 0.1);
    font-weight: 300;
    font-size: 0.6rem;
}

/* 响应式 */
@media (max-width: 700px) {
    .footer {
        padding: 32px 16px 24px;
    }
    .footer-inner {
        padding: 0 12px;
    }
    .footer-links {
        gap: 6px 20px;
        margin-bottom: 20px;
        padding-bottom: 20px;
    }
    .footer-links a {
        font-size: 0.85rem;
    }
    .footer-links .dot {
        display: none;
    }
    .footer-copyright {
        font-size: 0.75rem;
    }
    .footer-legal {
        flex-direction: column;
        gap: 10px;
        padding-top: 14px;
    }
    .footer-legal .legal-item {
        font-size: 0.7rem;
    }
    .legal-divider {
        display: none;
    }
}

@media (max-width: 400px) {
    .footer-links {
        gap: 4px 14px;
    }
    .footer-links a {
        font-size: 0.8rem;
        padding: 4px 2px;
    }
    .footer-copyright .version {
        font-size: 0.6rem;
        padding: 0 8px;
    }
}

















/* ==============================
   桌面端下拉菜单
   ============================== */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 130px;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    pointer-events: none;
    z-index: 100;
}

.dropdown:hover .dropdown-menu,
.dropdown.open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-menu li {
    width: 100%;
    height: auto;
    line-height: 1.5;
}

.dropdown-menu a {
    display: block;
    padding: 10px 20px;
    color: #333;
    font-size: 15px;
    text-align: left;
    transition: background 0.15s ease;
    white-space: nowrap;
}

.dropdown-menu a:hover {
    background: #f0f4ff;
    color: #417dff;
}

.dropdown-menu a.disabled {
    color: #bbb;
    cursor: not-allowed;
}

.dropdown-menu a.disabled:hover {
    background: transparent;
    color: #bbb;
}

/* 为保持与其他导航项高度一致，调整 .btli 宽度（可选） */

/* ==============================
   移动端下拉子菜单
   ============================== */
.dropdown-mobile {
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-toggle-mobile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 25px;
    color: #333;
    font-size: 16px;
    cursor: pointer;
}

.dropdown-toggle-mobile .arrow {
    transition: transform 0.3s ease;
    font-size: 12px;
    color: #999;
}

.dropdown-toggle-mobile.active .arrow {
    transform: rotate(180deg);
}

.sub-menu-mobile {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
    opacity: 0;
    background: #f9fafc;
}

.sub-menu-mobile.open {
    max-height: 300px; /* 足够容纳四项 */
    opacity: 1;
}

.sub-menu-mobile li {
    border-bottom: none;
}

.sub-menu-mobile a {
    display: block;
    padding: 12px 25px 12px 40px;
    color: #555;
    font-size: 15px;
    transition: background 0.15s ease;
}

.sub-menu-mobile a:hover {
    background: #eef2f7;
}

.sub-menu-mobile a.disabled {
    color: #bbb;
    cursor: not-allowed;
}

.sub-menu-mobile a.disabled:hover {
    background: transparent;
}

/* 移动端用户区上方加分割线，但已存在，无需额外 */