/*
 * 申天模型 - 资源下载页样式 v1.0
 * 风格：横向卡片列表，清晰的信息层级
 */

:root {
    --st-bg: #fbfbfd;
    --st-card: #ffffff;
    --st-text: #1d1d1f;
    --st-grey: #86868b;
    --st-blue: #0071e3;
    --st-border: #e5e5e7;
    --shadow-sm: 0 4px 12px rgba(0,0,0,0.03);
    --shadow-md: 0 8px 24px rgba(0,0,0,0.06);
}

.st-download-page {
    background-color: var(--st-bg);
    color: var(--st-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    margin: 0;
}

.st-main-container {
    max-width: 1000px; /* 限制宽度，阅读体验更好 */
    margin: 0 auto;
    padding: 80px 20px;
}

/* 标题区 */
.st-hero-section { text-align: center; margin-bottom: 60px; }
.st-title { font-size: 3rem; font-weight: 800; letter-spacing: -1px; margin-bottom: 10px; }
.st-subtitle { font-size: 1.2rem; color: var(--st-grey); font-weight: 400; }

/* 筛选按钮组 */
.st-filter-wrapper { display: flex; justify-content: center; margin-top: 40px; }
.st-filter-bar {
    display: flex; gap: 10px; flex-wrap: wrap; justify-content: center;
}
.st-filter-btn {
    border: none; background: #e5e5ea; padding: 10px 24px;
    border-radius: 100px; font-size: 0.9rem; font-weight: 600;
    color: var(--st-grey); cursor: pointer; transition: all 0.3s ease;
}
.st-filter-btn:hover { background: #d1d1d6; color: var(--st-text); }
.st-filter-btn.active { background: var(--st-text); color: #fff; transform: scale(1.05); }

/* --- 下载列表 (Grid) --- */
.st-download-grid {
    display: grid;
    grid-template-columns: 1fr; /* 单列布局，适合展示详细信息 */
    gap: 20px;
    margin-bottom: 60px;
}

/* 下载卡片 */
.dl-card {
    background: var(--st-card);
    border-radius: 24px;
    padding: 20px;
    display: flex; /* 横向布局 */
    gap: 25px;
    border: 1px solid var(--st-border);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
}
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.dl-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(0,113,227,0.3); }

/* 左侧图片区 */
.dl-img {
    width: 240px;
    height: 160px; /* 固定尺寸 3:2 */
    flex-shrink: 0;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    background: #f5f5f7;
    border: 1px solid rgba(0,0,0,0.05);
}
.dl-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.dl-card:hover .dl-img img { transform: scale(1.05); }

/* 分类标签 (显示在图片上) */
.dl-tag {
    position: absolute; top: 10px; left: 10px;
    padding: 4px 10px; border-radius: 6px;
    font-size: 10px; font-weight: 700; color: #fff;
    backdrop-filter: blur(4px); box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.dl-tag.manual { background: rgba(52, 199, 89, 0.9); }   /* 绿色 */
.dl-tag.software { background: rgba(0, 122, 255, 0.9); } /* 蓝色 */
.dl-tag.model { background: rgba(255, 149, 0, 0.9); }    /* 橙色 */
.dl-tag.image { background: rgba(175, 82, 222, 0.9); }   /* 紫色 */

/* 右侧内容区 */
.dl-content { flex: 1; display: flex; flex-direction: column; justify-content: center; }

.dl-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 8px; }
.dl-header h3 { font-size: 1.25rem; font-weight: 700; color: var(--st-text); margin: 0; line-height: 1.3; }
.dl-date { font-size: 0.8rem; color: var(--st-grey); font-family: monospace; background: #f2f2f7; padding: 2px 8px; border-radius: 6px; }

.dl-desc { font-size: 0.9rem; color: var(--st-grey); line-height: 1.5; margin-bottom: 20px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* 底部元数据与按钮 */
.dl-meta { display: flex; gap: 15px; font-size: 0.8rem; color: var(--st-grey); font-weight: 500; margin-bottom: auto; }
.meta-item { display: flex; align-items: center; gap: 6px; }

.dl-btn {
    align-self: flex-start;
    background: #f2f2f7; color: var(--st-blue);
    padding: 10px 24px; border-radius: 100px;
    font-size: 0.9rem; font-weight: 700;
    text-decoration: none; transition: all 0.2s;
    display: flex; align-items: center; gap: 8px;
    margin-top: 15px;
}
.dl-btn:hover { background: var(--st-blue); color: #fff; box-shadow: 0 4px 12px rgba(0,113,227,0.3); }

/* 下载须知 */
.st-notice-section { border-top: 1px solid var(--st-border); padding-top: 40px; margin-top: 40px; }
.notice-box { background: #f9f9fb; border-radius: 16px; padding: 20px; border: 1px solid #eee; }
.notice-box h4 { font-size: 0.9rem; font-weight: 700; margin-bottom: 8px; color: var(--st-text); }
.notice-box p { font-size: 0.8rem; color: var(--st-grey); margin: 0; line-height: 1.5; }

/* 响应式适配 */
@media (max-width: 768px) {
    .dl-card { flex-direction: column; gap: 15px; }
    .dl-img { width: 100%; height: 200px; }
    .dl-header { flex-direction: column; gap: 5px; }
    .dl-btn { width: 100%; justify-content: center; }
    .st-filter-bar { overflow-x: auto; padding-bottom: 10px; justify-content: flex-start; flex-wrap: nowrap; }
    .st-filter-btn { flex-shrink: 0; }
}