/* ============================================================
   LiveBBS 下载中心页（downloads.html）
   只写页面专属样式，公共样式在 common.css
   ============================================================ */

main {
    width: 100%;
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 20px;
    box-sizing: border-box;
}

main h1 {
    font-size: 34px;
    margin: 10px 0 12px;
}

main h3 {
    display: none;
}

.dl-group,
.dl-group-title {
    display: none;
}

.dl-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 搜索框 */
#dl-search {
    position: relative;
    margin: 0 0 20px;
    text-align: left;
}

#dl-search-input {
    width: 100%;
    box-sizing: border-box;
    padding: 12px 90px 12px 40px;
    font-size: 15px;
    color: #1a3a5c;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(74, 158, 255, 0.35);
    border-radius: 12px;
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease;
}

#dl-search-input:focus {
    border-color: #1a6fbf;
    box-shadow: 0 0 0 3px rgba(74, 158, 255, 0.18);
}

#dl-search-input::placeholder {
    color: #9aabbe;
}

#dl-search::before {
    content: '';
    position: absolute;
    left: 14px;
    top: 50%;
    width: 16px;
    height: 16px;
    margin-top: -8px;
    border-radius: 50%;
    border: 2px solid #8a9fb5;
    box-shadow: 4px 4px 0 -2px #8a9fb5;
}

#dl-search-count {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    color: #8a9fb5;
}

/* 单个下载项 */
.dl-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(74, 158, 255, 0.25);
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(26, 58, 92, 0.08);
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.dl-item:hover,
.dl-item:focus-within {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(26, 58, 92, 0.16);
    border-color: rgba(74, 158, 255, 0.6);
    background: rgba(255, 255, 255, 0.98);
}

.dl-icon {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8f4fc, #d0e8f7);
    border-radius: 12px;
}

.dl-name {
    flex: 1 1 auto;
    font-size: 15px;
    font-weight: bold;
    color: #1a3a5c;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dl-meta {
    flex: 0 0 auto;
    font-size: 12px;
    color: #8a9fb5;
    white-space: nowrap;
}

.dl-btn {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: bold;
    color: #fff;
    background: linear-gradient(135deg, #4a9eff, #1a6fbf);
    padding: 6px 14px;
    border-radius: 10px;
    white-space: nowrap;
    pointer-events: none;
}

.dl-item:hover .dl-btn,
.dl-item:focus-within .dl-btn {
    background: linear-gradient(135deg, #1a6fbf, #1a5fa0);
}

/* 空态 */
.dl-empty {
    padding: 28px 16px;
    font-size: 14px;
    color: #8a9fb5;
    background: rgba(255, 255, 255, 0.6);
    border: 1px dashed rgba(74, 158, 255, 0.35);
    border-radius: 14px;
    text-align: center;
}

/* 移动端 */
@media (max-width: 520px) {
    main h1 { font-size: 26px; }
    #dl-search-input { padding-right: 60px; }
    .dl-item {
        flex-wrap: wrap;
        gap: 10px;
        padding: 12px 14px;
    }
    .dl-name { flex: 1 1 100%; }
    .dl-meta { display: none; }
    .dl-btn { margin-left: auto; }
}
