/* 完整的 main.css - 修复版（包含子分类背景） */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    min-height: 100vh;
    padding: 20px 12px;
    position: relative;
    overflow-x: hidden;
}

.container {
    max-width: 100%;
    width: 100%;
    margin: 0 auto;
    padding: 0 8px;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
}

.logo-text {
    font-size: 26px;
    font-weight: bold;
}

.site-domain {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 4px;
    font-weight: normal;
}

.datetime {
    text-align: right;
}

.date {
    font-size: 16px;
    margin-bottom: 4px;
}

.time {
    font-size: 22px;
    font-family: 'JetBrains Mono', monospace;
}

/* 滚动字幕样式 */
.marquee-container {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px 16px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    width: 100%;
}

.marquee-content {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    animation: marquee 20s linear infinite;
}

.marquee-content i {
    font-size: 15px;
    color: #000000;
}

.marquee-text {
    font-size: 13px;
    font-weight: 500;
    color: #000000;
}

@keyframes marquee {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

/* 父分类板块容器 */
.parent-categories-section {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(15px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.parent-categories-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}

.categories-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    gap: 8px;
}

.categories-title i {
    font-size: 18px;
}

/* 父分类导航样式 */
.parent-categories-nav {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    width: 100%;
}

.parent-category-tab {
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    font-weight: 500;
    position: relative;
    overflow: hidden;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 56px;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
}

.parent-category-tab:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.parent-category-tab.active {
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    font-weight: bold;
}

.parent-category-tab.active::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 3px;
    background: currentColor;
    border-radius: 2px;
}

/* 子分类板块容器 - 已修复：添加与父分类一致的背景 */
.child-categories-section {
    background: rgba(255, 255, 255, 0.1); /* 修复：添加毛玻璃背景 */
    border-radius: 16px; /* 修复：与父分类一致的圆角 */
    padding: 20px; /* 修复：与父分类一致的内边距 */
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2); /* 修复：添加边框 */
    backdrop-filter: blur(15px); /* 修复：毛玻璃效果 */
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1); /* 修复：阴影效果 */
    display: none;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    position: relative; /* 新增 */
    overflow: hidden; /* 新增 */
}

.child-categories-section::before {
    content: ''; /* 修复：添加顶部装饰线 */
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}

.child-categories-section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

.child-categories-title {
    font-size: 16px; /* 修复：与父分类标题一致大小 */
    font-weight: 600;
    margin-bottom: 16px; /* 修复：增加下边距 */
    color: rgba(255, 255, 255, 0.9); /* 修复：提高可读性 */
    display: flex;
    align-items: center;
    gap: 8px; /* 修复：增加图标间距 */
}

.child-categories-title i {
    font-size: 18px; /* 修复：调整图标大小 */
}

/* 子分类导航样式 */
.child-categories-nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    width: 100%;
}

@media (max-width: 768px) {
    .child-categories-nav {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .child-categories-nav {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
}

.child-category-tab {
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.15); /* 与父分类标签一致 */
    border-radius: 12px; /* 与父分类标签一致 */
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.25); /* 与父分类标签一致 */
    backdrop-filter: blur(10px); /* 与父分类标签一致 */
    font-weight: 500;
    position: relative;
    overflow: hidden;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 56px; /* 与父分类标签一致 */
    cursor: pointer;
    font-size: 14px; /* 稍小一点的字号 */
    width: 100%;
    box-sizing: border-box;
}

.child-category-tab:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.child-category-tab.active {
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    font-weight: bold;
}

.child-category-tab.active::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 3px;
    background: currentColor;
    border-radius: 2px;
}

/* 应用列表样式 */
.apps-container {
    min-height: 400px;
    width: 100%;
}

.category-apps {
    display: none;
    animation: fadeIn 0.5s ease;
    width: 100%;
}

.category-apps.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 单排应用布局 */
.nav-links.single {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    width: 100%;
}

/* 双排应用布局 */
.nav-links.double {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    width: 100%;
}

/* 应用链接布局 */
.nav-link {
    display: grid;
    grid-template-columns: 50px 1fr;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    min-height: 68px;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.15);
}

/* 图片懒加载样式 */
.nav-link .app-icon img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 10px;
    display: block;
    margin: 0;
    padding: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-link .app-icon img.loaded {
    opacity: 1;
}

.nav-link .app-icon .lazy-placeholder {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.5);
}

/* 首屏应用图标立即加载 */
.category-apps.active .nav-link .app-icon img {
    opacity: 1 !important;
}

/* 加大应用图标 */
.nav-link i {
    font-size: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none !important;
    padding: 0;
    margin: 0;
    line-height: 1;
    width: 50px;
    height: 50px;
}

.nav-link .app-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none !important;
    padding: 0;
    margin: 0;
    width: 50px;
    height: 50px;
}

/* 文字内容区域 */
.nav-link > div:not(.badge-container) {
    min-width: 0;
    text-align: left;
    margin: 0;
    padding: 0;
}

.nav-link div div {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

.nav-link small {
    opacity: 0.8;
    font-size: 11px;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

/* 角标样式 */
.badge-container {
    position: absolute;
    top: 6px;
    right: 6px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    z-index: 2;
}

.badge-red, .badge-blue, .badge-green {
    padding: 2px 5px;
    border-radius: 6px;
    font-size: 8px;
    font-weight: bold;
    text-transform: uppercase;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.badge-red {
    background: linear-gradient(135deg, #ff4757, #ff3838);
    color: white;
}

.badge-blue {
    background: linear-gradient(135deg, #3742fa, #5352ed);
    color: white;
}

.badge-green {
    background: linear-gradient(135deg, #2ed573, #1e90ff);
    color: white;
}

/* 加载指示器 */
.loading-indicator {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.7);
}

.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

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

/* 微信相关样式 */
.wechat-btn {
    position: fixed;
    right: 12px;
    bottom: 12px;
    min-width: 110px;
    height: 38px;
    background-color: #07C160;
    border-radius: 19px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    z-index: 1000;
    transition: all 0.3s ease;
    padding: 0 14px;
    font-size: 13px;
    gap: 6px;
}

.wechat-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(7, 193, 96, 0.4);
}

.wechat-btn i {
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wechat-btn span {
    white-space: nowrap;
    line-height: 1;
}

.wechat-qr {
    display: none;
    position: fixed;
    right: 130px;
    bottom: 12px;
    background: white;
    padding: 12px;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    z-index: 1000;
}

.wechat-qr::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-left: 8px solid white;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.wechat-qr img {
    max-width: 180px;
    height: auto;
    border-radius: 6px;
}

/* 悬浮客服图标样式 */
.customer-service-float {
    position: fixed;
    right: 12px;
    bottom: 70px;
    z-index: 1000;
    cursor: pointer;
}

.service-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    position: relative;
}

.service-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.service-icon i {
    font-size: 26px;
    color: white;
}

.service-tooltip {
    position: absolute;
    right: 65px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 6px 10px;
    border-radius: 5px;
    font-size: 11px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-icon:hover + .service-tooltip {
    opacity: 1;
}

/* 底部备案号容器配色优化 */
.footer {
    margin-top: 30px;
    padding: 16px 12px;
    text-align: center;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: 100%;
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.footer a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
}

.footer a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.footer i {
    font-size: 14px;
}

.copyright {
    margin-bottom: 4px;
    color: rgba(255, 255, 255, 0.9);
}

/* 备案号特殊样式 */
.beian-link {
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.beian-link:hover {
    border-color: rgba(255, 255, 255, 0.5);
}

/* 响应式样式已经在 responsive.css 中，这里不再重复 */