/* ==================== 文章专属样式 ==================== */

/* SVG 图示字体类 */
.af, .af2 {
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}
.af-mono {
    font-family: 'JetBrains Mono', monospace;
}

/* ─── 文章底部 CTA ─── */
.article-cta {
    position: relative;
    margin: clamp(40px, 6vw, 64px) 0 clamp(32px, 5vw, 48px);
    padding: clamp(28px, 4vw, 44px) clamp(24px, 5vw, 52px);
    border-radius: 20px;
    background: #f5f7ff;
    border: 1px solid rgba(99, 102, 241, 0.13);
    box-shadow: 0 2px 24px rgba(99, 102, 241, 0.07);
    text-align: center;
    overflow: hidden;
}

.article-cta__glow {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(32px);
}
.article-cta__glow--a {
    width: 220px;
    height: 220px;
    bottom: -70px;
    left: -50px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.28) 0%, transparent 70%);
}
.article-cta__glow--b {
    width: 200px;
    height: 200px;
    bottom: -60px;
    right: -40px;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.22) 0%, transparent 70%);
}

.article-cta__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 11.5px;
    font-weight: 700;
    color: #6366f1;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin: 0 0 12px;
}
.article-cta__eyebrow i,
.article-cta__eyebrow svg {
    width: 13px;
    height: 13px;
    stroke-width: 2.5px;
}

.article-cta__title {
    font-size: clamp(17px, 2.6vw, 21px);
    font-weight: 800;
    color: #0f172a;
    line-height: 1.3;
    margin: 0 0 10px;
}

.article-cta__desc {
    font-size: 14px;
    color: #64748b;
    line-height: 1.7;
    max-width: 400px;
    margin: 0 auto 26px;
}

.article-cta__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 30px;
    border-radius: 999px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e8 50%, #0ea5e9 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    box-shadow:
        0 6px 22px rgba(99, 102, 241, 0.36),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    position: relative;
    z-index: 1;
}
.article-cta__btn:hover {
    transform: translateY(-2px);
    box-shadow:
        0 10px 32px rgba(99, 102, 241, 0.44),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    color: #fff;
    text-decoration: none;
}
.article-cta__btn i,
.article-cta__btn svg {
    width: 15px;
    height: 15px;
    stroke-width: 2.5px;
}

/* ─── 右侧浮动限时优惠标签 ─── */
.article-promo-float {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%) translateX(2px);
    z-index: 200;

    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;

    padding: 22px 12px 28px;
    width: 46px;

    /* bookmark notch at bottom via clip-path */
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 91%, 0 100%);

    background: linear-gradient(175deg, #6366f1 0%, #4f46e8 45%, #0ea5e9 100%);
    color: #fff;
    text-decoration: none;

    box-shadow: -3px 4px 22px rgba(99, 102, 241, 0.40);
    transition: transform 0.24s cubic-bezier(0.34, 1.56, 0.64, 1),
                box-shadow 0.24s ease;

    animation: promo-glow 2.8s ease-in-out infinite;
}

.article-promo-float:hover {
    transform: translateY(-50%) translateX(-6px);
    box-shadow: -6px 4px 32px rgba(99, 102, 241, 0.55);
    color: #fff;
    text-decoration: none;
}

@keyframes promo-glow {
    0%, 100% {
        box-shadow: -3px 4px 22px rgba(99, 102, 241, 0.40);
    }
    50% {
        box-shadow: -3px 4px 30px rgba(99, 102, 241, 0.62),
                    -1px 0 14px rgba(14, 165, 233, 0.35);
    }
}

/* 顶部小圆点 */
.article-promo-float__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.7);
    flex-shrink: 0;
    animation: promo-dot-blink 2.8s ease-in-out infinite;
}

@keyframes promo-dot-blink {
    0%, 100% { opacity: 0.7; transform: scale(1); }
    50%       { opacity: 1;   transform: scale(1.25); }
}

/* 图标 */
.article-promo-float i,
.article-promo-float svg {
    width: 17px;
    height: 17px;
    stroke-width: 2.5px;
    flex-shrink: 0;
}

/* 竖排文字 */
.article-promo-float__text {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: 0.18em;
    white-space: nowrap;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

/* 移动端：改为底部右侧 FAB 胶囊按钮 */
@media (max-width: 768px) {
    .article-promo-float {
        /* 脱离右侧书签，改为底部右侧悬浮胶囊 */
        top: auto;
        bottom: 28px;
        right: 16px;
        transform: none;

        /* 取消书签形状，改为圆角胶囊 */
        clip-path: none;
        border-radius: 999px;
        width: auto;

        /* 横向排列 */
        flex-direction: row;
        align-items: center;
        gap: 8px;
        padding: 12px 20px 12px 16px;

        box-shadow: 0 4px 20px rgba(99, 102, 241, 0.48);
        animation: promo-glow-fab 2.8s ease-in-out infinite;
    }

    .article-promo-float:hover {
        transform: translateY(-3px);
        box-shadow: 0 8px 28px rgba(99, 102, 241, 0.58);
    }

    /* 隐藏圆点（横向布局下不需要） */
    .article-promo-float__dot {
        display: none;
    }

    /* 文字改回横排 */
    .article-promo-float__text {
        writing-mode: horizontal-tb;
        font-size: 13px;
        font-weight: 800;
        letter-spacing: 0.04em;
    }

    .article-promo-float i,
    .article-promo-float svg {
        width: 15px;
        height: 15px;
    }
}

@keyframes promo-glow-fab {
    0%, 100% {
        box-shadow: 0 4px 20px rgba(99, 102, 241, 0.48);
    }
    50% {
        box-shadow: 0 4px 28px rgba(99, 102, 241, 0.68),
                    0 0 14px rgba(14, 165, 233, 0.32);
    }
}

/* ─── Log / error reference table ─── */
.article-table-wrap {
    margin: 1.25em 0 1.5em;
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: #fafbfc;
}
.article-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    line-height: 1.45;
}
.article-table th,
.article-table td {
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}
.article-table th {
    font-weight: 700;
    color: #0f172a;
    background: rgba(99, 102, 241, 0.06);
}
.article-table tbody tr:last-child td {
    border-bottom: none;
}
.article-table code {
    font-size: 12px;
}
@media (max-width: 640px) {
    .article-table th:nth-child(2),
    .article-table td:nth-child(2) {
        min-width: 120px;
    }
}
