/* 重置和基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: url('https://dg.jjtui.com/bg.png') no-repeat center center fixed;
    background-size: cover;
    color: #fff;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* 头部样式 */
header {
    text-align: center;
    margin-bottom: 40px;
    padding: 20px 0;
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 30px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

.logo i {
    color: #4CAF50;
    text-shadow: 0 0 10px rgba(76, 175, 80, 0.7);
}

/* 搜索区域 */
.search-container {
    max-width: 600px;
    margin: 0 auto 40px;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 18px 60px 18px 25px;
    font-size: 1.1rem;
    border: none;
    border-radius: 50px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    color: white;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-input:focus {
    outline: none;
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
    border-color: rgba(76, 175, 80, 0.5);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-icon {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.2rem;
}

/* 搜索结果 */
.search-results {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    display: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.search-results.active {
    display: block;
}

.search-results h3 {
    margin-bottom: 15px;
    color: #4CAF50;
    font-size: 1.2rem;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.result-item {
    padding: 15px;
    margin-bottom: 10px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    transition: all 0.3s ease;
    cursor: pointer;
    border-left: 3px solid transparent;
}

.result-item:hover {
    background: rgba(0, 0, 0, 0.6);
    border-left-color: #4CAF50;
    transform: translateX(5px);
}

.result-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.result-item p {
    font-size: 0.9rem;
    opacity: 0.9;
    color: white;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.no-results {
    text-align: center;
    padding: 30px;
    opacity: 0.8;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

/* 软件卡片网格 */
.software-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.software-card {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
    height: 380px;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.software-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.7);
    background: rgba(0, 0, 0, 0.7);
    border-color: rgba(76, 175, 80, 0.3);
}

.software-img {
    height: 220px;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.software-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.software-card:hover .software-img img {
    transform: scale(1.08);
}

.software-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.software-info h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    color: #fff;
    line-height: 1.3;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.9);
}

.software-info p {
    font-size: 1rem;
    opacity: 0.95;
    line-height: 1.5;
    margin-bottom: 15px;
    color: #fff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.software-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.software-category {
    font-size: 0.8rem;
    padding: 3px 10px;
    background: rgba(76, 175, 80, 0.3);
    border-radius: 12px;
}

.software-size {
    font-size: 0.9rem;
    opacity: 0.8;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

/* 可用状态标签 */
.available {
    position: relative;
}

.available::after {
    content: "可下载";
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(76, 175, 80, 0.9);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.waiting {
    position: relative;
}

.waiting::after {
    content: "等待添加";
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 152, 0, 0.9);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* 二维码弹窗 */
.qr-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}

.qr-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.qr-content {
    background: rgba(0, 0, 0, 0.9);
    border-radius: 20px;
    padding: 30px;
    width: 90%;
    max-width: 350px;
    text-align: center;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(76, 175, 80, 0.3);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

.qr-modal.active .qr-content {
    transform: translateY(0);
}

.qr-title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #4CAF50;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.qr-image-container {
    margin: 20px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.qr-image {
    width: 200px;
    height: 200px;
    margin: 0 auto;
    background-color: white;
    padding: 10px;
    border-radius: 5px;
}

.qr-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.qr-desc {
    margin: 15px 0;
    font-size: 1rem;
    opacity: 0.9;
}

.qr-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-close-btn:hover {
    color: #4CAF50;
    background: rgba(255, 255, 255, 0.1);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* 页脚 */
footer {
    text-align: center;
    margin-top: 50px;
    padding: 20px 0;
    font-size: 0.9rem;
    opacity: 0.9;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    backdrop-filter: blur(5px);
}

.footer-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: inherit;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .software-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 900px) {
    .software-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .qr-content {
        width: 95%;
        padding: 20px;
        max-width: 320px;
    }
}

@media (max-width: 600px) {
    .software-grid {
        grid-template-columns: 1fr;
    }
    
    .logo {
        font-size: 2rem;
    }
    
    .search-container {
        padding: 0 15px;
    }
    
    .search-input {
        padding: 15px 50px 15px 20px;
        font-size: 1rem;
    }
    
    .qr-content {
        padding: 15px;
        max-width: 280px;
    }
    
    .qr-image {
        width: 180px;
        height: 180px;
    }
    
    .qr-title {
        font-size: 1.3rem;
    }
    
    .footer-link {
        flex-direction: column;
        gap: 5px;
    }
}