/* ==================== 基础全局样式 ==================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: #fff;
}
    body.no-scroll {
        overflow: hidden;
    }

.site-logo {
    height: 30px; /* 保持与后台管理一致的高度 */
    margin-right: 10px;
    vertical-align: middle;
    transition: opacity 0.3s ease;
}

.site-title {
    cursor: pointer;
    display: flex;
    align-items: center;
    font-size: 1.2rem;
}

    .site-title:hover .site-logo {
        opacity: 0.8;
    }

/* ==================== 搜索框样式 ==================== */
.search-box {
    max-width: 800px;
    margin: 20px auto;
    display: flex;
    gap: 10px;
    padding: 0 15px;
}

#searchInput {
    flex: 1;
    padding: 15px;
    border: 2px solid #4d6fff;
    border-radius: 30px;
    font-size: 16px;
    transition: all 0.3s;
}

    #searchInput:focus {
        outline: none;
        box-shadow: 0 0 8px rgba(77,111,255,0.2);
    }

.search-box button {
    padding: 0 30px;
    border: none;
    border-radius: 30px;
    background: #4d6fff;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

    .search-box button:hover {
        background: #3653d1;
    }

/* ==================== 卡片系统 ==================== */
.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    padding: 20px 0;
}

.category-card {
    padding: 20px;
    border: 1px solid #eee;
    border-radius: 12px;
    transition: transform 0.2s;
    background: white;
    cursor: pointer;
}

    .category-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    }

.card-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 12px;
}

.card-icon {
    font-size: 28px;
    width: 40px;
    text-align: center;
    color: #4d6fff;
}

.heat-indicator {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 16px;
    transition: all 0.3s ease;
}

    /* 热度分级颜色 */
    .heat-indicator.low {
        background: #f0f0f0;
        color: #888;
    }

    .heat-indicator.medium {
        background: #fff3e0;
        color: #ff9800;
    }

    .heat-indicator.high {
        background: #ffebee;
        color: #f44336;
    }

/* 动态火焰图标 */
.fa-fire {
    font-size: 14px;
    transition: transform 0.2s;
}

.heat-indicator.high .fa-fire {
    animation: flame 1s infinite alternate;
}

@keyframes flame {
    from {
        transform: scale(1);
    }

    to {
        transform: scale(1.1);
    }
}

/* 数字样式增强 */
.heat-count {
    font-weight: 600;
    font-family: 'Segoe UI', Arial, sans-serif;
}

/* 卡片标签系统 */
.card-flags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.flag {
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}

    .flag.official {
        background: #4d6fff1a;
        color: #4d6fff;
    }

    .flag.free {
        background: #28a7451a;
        color: #28a745;
    }

    .flag.hot {
        background: #dc35451a;
        color: #dc3545;
    }

    .flag.new {
        background: #ffc1071a;
        color: #ffc107;
    }

/* ==================== 页脚样式 ==================== */
.site-footer {
    background: #2d3e50;
    color: #a8b2c0;
    padding: 2rem;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    line-height: 1.6;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

    .footer-links a {
        color: #a8b2c0;
        text-decoration: none;
        transition: color 0.3s;
    }

        .footer-links a:hover {
            color: #4d6fff;
        }

/* ==================== 响应式设计 ==================== */
@media (max-width: 768px) {
    .site-logo {
        height: 24px;
    }

    .site-title {
        font-size: 1rem;
    }

    /* 其他调整 */
    .search-box {
        flex-direction: column;
    }

        .search-box button {
            width: 100%;
            padding: 12px;
        }

    .card-container {
        grid-template-columns: 1fr;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}
