/* 新版首页样式（2026-09-19 从视图内联 <style> 抽出）
   原因：视图内容渲染在 <div id="app"> 内，Vue 2 挂载重建 DOM 时会丢弃内联 <style>，
   必须用外部 <link> 引入（link 会被保留）。 */

/* ============ 新版首页 ============ */
.hp-wrap { width: 1200px; margin: 0 auto; }

/* ---- HERO ---- */
.hp-hero {
    width: 100%;
    background: linear-gradient(135deg, #1e4fd8 0%, #409EFF 55%, #38bdf8 100%);
    position: relative;
    overflow: hidden;
    padding: 54px 0 46px;
    margin-bottom: 26px;
}
.hp-hero::before,
.hp-hero::after {
    content: ""; position: absolute; border-radius: 50%;
    background: rgba(255,255,255,.10);
}
.hp-hero::before { width: 420px; height: 420px; right: -120px; top: -180px; }
.hp-hero::after  { width: 300px; height: 300px; left: -100px; bottom: -160px; }
.hp-hero-inner { position: relative; z-index: 2; width: 1200px; margin: 0 auto; text-align: center; }
.hp-hero-title {
    font-size: 40px; font-weight: 800; color: #fff; letter-spacing: 2px;
    margin: 0 0 12px; text-shadow: 0 2px 12px rgba(0,0,0,.18);
}
.hp-hero-sub { font-size: 16px; color: rgba(255,255,255,.92); margin-bottom: 28px; letter-spacing: 1px; }
.hp-hero-tags { display: flex; justify-content: center; gap: 10px; margin-bottom: 26px; flex-wrap: wrap; }
.hp-hero-tag {
    background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.35);
    color: #fff; padding: 5px 14px; border-radius: 20px; font-size: 13px;
    backdrop-filter: blur(4px);
}
.hp-search-box {
    display: flex; width: 720px; margin: 0 auto; background: #fff;
    border-radius: 8px; overflow: hidden; box-shadow: 0 8px 24px rgba(0,0,0,.16);
}
.hp-search-box .el-select .el-input__inner { border: none; height: 50px; line-height: 50px; }
.hp-search-box .el-input__inner { border: none; height: 50px; line-height: 50px; font-size: 15px; }
.hp-search-btn {
    width: 118px; background: linear-gradient(90deg,#ffb020,#ff8c00); color: #fff;
    border: none; font-size: 15px; font-weight: 600; cursor: pointer; letter-spacing: 2px;
}
.hp-search-btn:hover { background: linear-gradient(90deg,#ffa000,#f57c00); }
.hp-hotwords { margin-top: 16px; color: rgba(255,255,255,.9); font-size: 13px; }
.hp-hotwords a { color: #fff; text-decoration: none; margin: 0 8px; opacity: .92; }
.hp-hotwords a:hover { text-decoration: underline; opacity: 1; }

/* ---- 统计条 ---- */
.hp-stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 32px; }
.hp-stat {
    background: #fff; border-radius: 12px; padding: 20px 18px; text-align: center;
    box-shadow: 0 2px 12px rgba(15,40,90,.07); border: 1px solid #eef2f8;
    transition: transform .22s ease, box-shadow .22s ease;
}
.hp-stat:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(15,40,90,.12); }
.hp-stat-num {
    font-size: 30px; font-weight: 800; line-height: 1.1;
    background: linear-gradient(90deg,#2563eb,#38bdf8); -webkit-background-clip: text;
    -webkit-text-fill-color: transparent; background-clip: text;
}
.hp-stat-num.orange { background: linear-gradient(90deg,#f59e0b,#fbbf24); -webkit-background-clip: text; background-clip: text; }
.hp-stat-label { font-size: 13px; color: #7a869a; margin-top: 8px; letter-spacing: 1px; }

/* ---- 区块通用 ---- */
.hp-section { margin-bottom: 34px; }
.hp-sec-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.hp-sec-title { display: flex; align-items: center; font-size: 21px; font-weight: 700; color: #1f2d3d; }
.hp-sec-title::before {
    content: ""; width: 5px; height: 21px; border-radius: 3px; margin-right: 11px;
    background: linear-gradient(180deg,#409EFF,#1e4fd8);
}
.hp-sec-more { font-size: 13px; color: #98a6b8; cursor: pointer; }
.hp-sec-more:hover { color: #409EFF; }

/* ---- 学段卡片 ---- */
.hp-cat-grid { display: grid; grid-template-columns: repeat(7,1fr); gap: 12px; }
.hp-cat {
    position: relative; background: #fff; border-radius: 12px; padding: 22px 12px 18px;
    text-align: center; cursor: pointer; overflow: hidden;
    border: 1px solid #eef2f8; box-shadow: 0 2px 10px rgba(15,40,90,.05);
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.hp-cat:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(30,79,216,.16); border-color: #bcd8ff; }
.hp-cat-icon {
    width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; font-weight: 800; color: #fff;
}
.hp-cat-name { font-size: 15px; font-weight: 600; color: #24303f; }
.hp-cat-count { font-size: 12px; color: #93a1b3; margin-top: 5px; }
.hp-cat-count b { color: #409EFF; font-size: 14px; }

/* ---- 专题 ---- */
.hp-topic-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
.hp-topic {
    background: #fff; border-radius: 12px; overflow: hidden; cursor: pointer;
    border: 1px solid #eef2f8; box-shadow: 0 2px 10px rgba(15,40,90,.05);
    transition: transform .22s ease, box-shadow .22s ease;
}
.hp-topic:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(30,79,216,.16); }
.hp-topic-cover { width: 100%; height: 118px; object-fit: cover; display: block; background: #f2f5fa; }
.hp-topic-body { padding: 12px 14px 14px; }
.hp-topic-title { font-size: 15px; font-weight: 700; color: #24303f; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hp-topic-desc { font-size: 12px; color: #93a1b3; margin-top: 6px; height: 34px; overflow: hidden; line-height: 17px; }
.hp-topic-go { margin-top: 10px; font-size: 12px; color: #409EFF; font-weight: 600; }

/* ---- 热门榜 ---- */
.hp-hot-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
.hp-hot {
    display: flex; gap: 12px; background: #fff; border-radius: 11px; padding: 12px;
    border: 1px solid #eef2f8; box-shadow: 0 2px 10px rgba(15,40,90,.05);
    cursor: pointer; transition: transform .2s ease, box-shadow .2s ease;
}
.hp-hot:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(30,79,216,.15); }
.hp-hot-rank {
    flex: 0 0 26px; height: 26px; border-radius: 7px; display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 800; color: #fff; background: #c3ccd8; margin-top: 2px;
}
.hp-hot-rank.r1 { background: linear-gradient(135deg,#ff6b3d,#ff3d00); }
.hp-hot-rank.r2 { background: linear-gradient(135deg,#ffa726,#fb8c00); }
.hp-hot-rank.r3 { background: linear-gradient(135deg,#ffca28,#f9a825); }
.hp-hot-cover { flex: 0 0 62px; width: 62px; height: 62px; border-radius: 8px; object-fit: cover; background: #f2f5fa; }
.hp-hot-body { flex: 1; min-width: 0; }
.hp-hot-title {
    font-size: 13px; color: #2b3948; line-height: 18px; height: 36px; overflow: hidden;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.hp-hot-meta { font-size: 11px; color: #9aa7b6; margin-top: 6px; }

/* ---- 最新素材 ---- */
.hp-new-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 18px; }
.hp-card {
    background: #fff; border-radius: 12px; overflow: hidden; cursor: pointer;
    border: 1px solid #eef2f8; box-shadow: 0 2px 10px rgba(15,40,90,.05);
    transition: transform .2s ease, box-shadow .2s ease;
    display: flex; flex-direction: column;
}
.hp-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(30,79,216,.16); }
.hp-card-cover { width: 100%; height: 156px; object-fit: cover; background: #f2f5fa; display: block; position: relative; }
.hp-card-badge {
    position: absolute; left: 10px; top: 10px; background: rgba(0,0,0,.55); color: #fff;
    font-size: 11px; padding: 3px 9px; border-radius: 20px; backdrop-filter: blur(3px);
}
.hp-card-body { padding: 12px 13px 13px; flex: 1; display: flex; flex-direction: column; }
.hp-card-title {
    font-size: 14px; color: #26313f; line-height: 20px; height: 40px; overflow: hidden; font-weight: 500;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.hp-card:hover .hp-card-title { color: #1e4fd8; }
.hp-card-foot {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 12px; padding-top: 10px; border-top: 1px dashed #eef2f8;
    font-size: 11px; color: #9aa7b6;
}
.hp-card-foot .hp-price { color: #ff6b3d; font-weight: 700; font-size: 13px; }
.hp-card-foot .hp-price.free { color: #22c55e; }

/* ---- 加载更多 ---- */
.hp-loadmore { text-align: center; margin: 28px 0 10px; }
.hp-loadmore-btn {
    display: inline-block; padding: 12px 46px; border-radius: 26px; cursor: pointer;
    background: linear-gradient(90deg,#409EFF,#1e4fd8); color: #fff; font-size: 14px;
    box-shadow: 0 6px 18px rgba(30,79,216,.24); transition: opacity .2s;
}
.hp-loadmore-btn:hover { opacity: .9; }
.hp-loadmore-btn.done { background: #e8edf5; color: #9aa7b6; box-shadow: none; cursor: default; }

/* ---- 空态兜底 ---- */
.hp-empty-tip { text-align: center; color: #9aa7b6; padding: 30px 0; font-size: 14px; }

/* ---- 响应式 ---- */
@media (max-width: 1240px) {
    .hp-wrap, .hp-hero-inner { width: 96%; }
    .hp-cat-grid { grid-template-columns: repeat(3,1fr); }
    .hp-topic-grid, .hp-hot-grid, .hp-new-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 768px) {
    .hp-hero-title { font-size: 27px; }
    .hp-search-box { width: 100%; }
    .hp-stats { grid-template-columns: repeat(2,1fr); }
    .hp-cat-grid, .hp-topic-grid, .hp-hot-grid, .hp-new-grid { grid-template-columns: repeat(2,1fr); }
}
