/* ============================================================
   IT时代网 /aibangong 频道页增强 · v1（2026-10-14）
   挂载点：home-pro-v1.js 按 URL 检测注入（.ab-hero 容器）
   内容：
   1) 频道 hero 区（标题+副标+简介+元信息）
   2) AI办公软件直达 8 卡矩阵（复用首页 kj-acc 结构与数据源 kj_ai_cards）
   3) 分隔标题「最新报道」
   4) 列表卡片 hover 精致化
   回滚：home-pro-v1.js 移除 AB 段即恢复原样
   ============================================================ */

/* ---------- Hero 区 ---------- */
.ab-hero {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    margin: 14px 0 4px;
    padding: 26px 28px 22px;
    background:
        radial-gradient(1200px 300px at 85% -60%, rgba(22, 103, 220, .16), transparent 60%),
        radial-gradient(800px 260px at -10% 130%, rgba(124, 92, 214, .12), transparent 55%),
        var(--theme-warp-background-color, #fff);
    border: 1px solid var(--theme-line-color, #eee);
}
.ab-hero::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #1667dc 0%, #7c5cd6 100%);
}
.ab-hero-title {
    font-size: 26px;
    font-weight: 700;
    color: var(--theme-text-color, #222);
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    line-height: 1.3;
}
.ab-hero-title .ab-en {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .14em;
    color: #1667dc;
    background: rgba(22, 103, 220, .08);
    border: 1px solid rgba(22, 103, 220, .22);
    padding: 2px 8px;
    border-radius: 999px;
    vertical-align: middle;
}
.ab-hero-sub {
    margin-top: 8px;
    font-size: 13.5px;
    color: var(--theme-text-secondary, #888);
    line-height: 1.7;
}
.ab-hero-meta {
    margin-top: 12px;
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--theme-text-secondary, #999);
}
.ab-hero-meta b {
    color: #1667dc;
    font-weight: 600;
}

/* ---------- 直达卡矩阵（双功能区 v2：主体资讯 tab + 底部双按钮） ---------- */
.ab-cards {
    margin: 14px 0 0;
    background: var(--theme-warp-background-color, #fff);
    border: 1px solid var(--theme-line-color, #eee);
    border-radius: 10px;
    padding: 12px 14px 14px;
}
.ab-cards-head {
    font-size: 14px;
    font-weight: 600;
    position: relative;
    padding-left: 9px;
    margin-bottom: 10px;
    color: var(--theme-text-color, #333);
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.ab-cards-head::before {
    content: '';
    position: absolute;
    left: 0; top: 50%;
    transform: translateY(-50%);
    width: 3px; height: 13px;
    border-radius: 2px;
    background: linear-gradient(180deg, #1667dc, #7c5cd6);
}
.ab-cards-tip {
    font-size: 11px;
    font-weight: 400;
    color: var(--theme-text-secondary, #999);
}
.ab-cards-body {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}
/* v2 卡片：上半主体（logo+名+描述，点击=资讯 tab）+ 下半双按钮 */
.ab-acc {
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    border: 1px solid var(--theme-line-color, #eee);
    background: var(--theme-background-secondary, #fafafa);
    cursor: pointer;
    overflow: hidden;
    transition: border-color .2s, transform .2s, box-shadow .2s;
    user-select: none;
}
.ab-acc:hover {
    border-color: rgba(22, 103, 220, .45);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(22, 103, 220, .10);
}
.ab-acc.active {
    border-color: #1667dc;
    background: rgba(22, 103, 220, .05);
    box-shadow: 0 0 0 1px rgba(22, 103, 220, .35);
}
.ab-acc-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 10px 4px 8px;
}
.ab-acc-main .kj-acc-ico {
    width: 26px;
    height: 26px;
    border-radius: 6px;
    object-fit: cover;
    display: block;
    margin-bottom: 1px;
}
.ab-acc-main .kj-acc-name { font-size: 13px; font-weight: 600; color: var(--theme-text-color, #333); line-height: 1.25; }
.ab-acc-main .kj-acc-desc { font-size: 10.5px; color: var(--theme-text-secondary, #999); line-height: 1.25; }
.ab-acc-btns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-top: 1px solid var(--theme-line-color, #eee);
    margin-top: 2px;
}
.ab-acc-btns > * {
    font-size: 11px;
    line-height: 1;
    padding: 7px 2px;
    text-align: center;
    text-decoration: none;
    transition: background .15s, color .15s;
}
.ab-acc-go {
    color: var(--theme-text-secondary, #666);
    border-right: 1px solid var(--theme-line-color, #eee);
}
.ab-acc-go:hover { color: #1667dc; background: rgba(22, 103, 220, .07); }
.ab-acc-news {
    color: var(--theme-text-secondary, #666);
    cursor: pointer;
}
.ab-acc-news:hover { color: #7c5cd6; background: rgba(124, 92, 214, .08); }
.ab-acc.active .ab-acc-news { color: #1667dc; font-weight: 600; }

/* ---------- 产品资讯视图 ---------- */
.ab-pv-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 14px 0 8px;
    padding: 10px 14px;
    background: var(--theme-warp-background-color, #fff);
    border: 1px solid var(--theme-line-color, #eee);
    border-left: 3px solid #1667dc;
    border-radius: 8px;
}
.ab-pv-title {
    font-size: 14.5px;
    font-weight: 600;
    color: var(--theme-text-color, #333);
}
.ab-pv-back {
    font-size: 12px;
    color: var(--theme-text-secondary, #999);
    cursor: pointer;
    padding: 3px 10px;
    border-radius: 999px;
    border: 1px solid var(--theme-line-color, #eee);
    transition: all .15s;
    user-select: none;
}
.ab-pv-back:hover {
    color: #1667dc;
    border-color: rgba(22, 103, 220, .4);
    background: rgba(22, 103, 220, .06);
}
.ab-pv-list {
    background: var(--theme-warp-background-color, #fff);
    border: 1px solid var(--theme-line-color, #eee);
    border-radius: 8px;
    padding: 8px 14px;
}
.ab-pv-ul { list-style: none; margin: 0; padding: 0; }
.ab-pv-ul li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 9px 2px;
    border-bottom: 1px dashed var(--theme-line-color, #eee);
}
.ab-pv-ul li:last-child { border-bottom: 0; }
.ab-pv-ul li a {
    flex: 1;
    font-size: 13.5px;
    color: var(--theme-text-color, #333);
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ab-pv-ul li a:hover { color: #1667dc; }
.ab-pv-empty {
    padding: 22px 0;
    text-align: center;
    font-size: 13px;
    color: var(--theme-text-secondary, #999);
}

/* ---------- 分隔标题 ---------- */
.ab-latest-head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 20px 0 10px;
    font-size: 15px;
    font-weight: 600;
    color: var(--theme-text-color, #333);
    position: relative;
    padding-left: 9px;
}
.ab-latest-head::before {
    content: '';
    position: absolute;
    left: 0; top: 50%;
    transform: translateY(-50%);
    width: 3px; height: 13px;
    border-radius: 2px;
    background: linear-gradient(180deg, #1667dc, #7c5cd6);
}
.ab-latest-head .ab-count {
    font-size: 11px;
    font-weight: 400;
    color: var(--theme-text-secondary, #999);
}

/* ---------- 列表 hover 精致化 ---------- */
.post-list-warp-archive .post-item {
    transition: transform .2s ease, box-shadow .2s ease;
    border-radius: 8px;
}
.post-list-warp-archive .post-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(22, 103, 220, .10);
}

/* ---------- 深色模式 ---------- */
.dark .ab-hero { background:
    radial-gradient(1200px 300px at 85% -60%, rgba(22, 103, 220, .22), transparent 60%),
    radial-gradient(800px 260px at -10% 130%, rgba(124, 92, 214, .16), transparent 55%),
    var(--theme-warp-background-color, #1b1b1f); }
.dark .ab-hero-title .ab-en { background: rgba(22, 103, 220, .18); border-color: rgba(22, 103, 220, .45); }
.dark .ab-acc.active { background: rgba(22, 103, 220, .12); }
.dark .ab-acc-go:hover { background: rgba(22, 103, 220, .16); }
.dark .ab-acc-news:hover { background: rgba(124, 92, 214, .18); }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
    .ab-cards-body { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 560px) {
    .ab-hero { padding: 18px 16px 16px; }
    .ab-hero-title { font-size: 21px; }
    .ab-hero-sub { font-size: 12.5px; }
    .ab-cards-body { grid-template-columns: repeat(2, 1fr); gap: 6px; }
    .ab-acc-main { padding: 8px 2px 6px; }
    .ab-acc-main .kj-acc-ico { width: 22px; height: 22px; }
    .ab-acc-btns > * { font-size: 10.5px; padding: 6px 2px; }
}
