body.help-page {
    --help-category-primary: #2563eb;
    --help-category-ink: #1e293b;
    --help-category-muted: #64748b;
    --help-category-line: #e5edf8;
    --help-category-soft: #f5f8fd;
}

.help-category-nav {
    display: flex;
    gap: 10px;
    margin: 24px 0 34px;
    padding-bottom: 4px;
    overflow-x: auto;
    scrollbar-width: thin;
}

.help-category-nav a {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid var(--help-category-line);
    border-radius: 999px;
    background: #fff;
    color: #52627a;
    transition: .18s ease;
}

.help-category-nav a:hover,
.help-category-nav a.active {
    border-color: var(--help-category-ink);
    background: var(--help-category-ink);
    color: #fff;
    transform: translateY(-2px);
}

.help-category-nav strong {
    font-size: 13px;
}

.help-category-nav span {
    display: grid;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    place-items: center;
    border-radius: 999px;
    background: var(--help-category-soft);
    color: var(--help-category-muted);
    font-size: 11px;
}

.help-category-nav a.active span,
.help-category-nav a:hover span {
    background: rgba(255, 255, 255, .14);
    color: #fff;
}

body.help-page .help-knowledge-section .section-head {
    margin-bottom: 22px;
}

body.help-page .help-knowledge-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

body.help-page .help-knowledge-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.help-category-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

body.help-page .help-category-card-head h3 {
    margin-bottom: 6px;
}

body.help-page .help-category-card-head h3::before {
    display: none;
}

.help-category-card-head p {
    margin: 0;
    color: var(--help-category-muted);
    font-size: 13px;
    line-height: 1.7;
}

.help-category-card-head > span {
    display: grid;
    flex: 0 0 34px;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 9px;
    background: #eef4ff;
    color: var(--help-category-primary);
    font-size: 12px;
    font-weight: 800;
}

body.help-page .help-knowledge-more {
    margin-top: auto;
    padding-top: 16px;
}

.help-category-empty,
.help-no-result {
    color: #94a3b8;
    font-size: 13px;
    line-height: 1.8;
}

.help-category-empty {
    padding: 18px;
    border: 1px dashed #d8e1ee;
    border-radius: 12px;
    background: #fafcff;
    text-align: center;
}

.help-search-empty {
    grid-column: 1 / -1;
    display: grid;
    min-height: 190px;
    padding: 32px;
    place-items: center;
    align-content: center;
    gap: 8px;
    border: 1px dashed #d8e1ee;
    border-radius: 20px;
    background: #fff;
    color: var(--help-category-muted);
    text-align: center;
}

.help-search-empty strong {
    color: var(--help-category-ink);
    font-size: 18px;
}

.help-search-empty a {
    margin-top: 6px;
    color: var(--help-category-primary);
    font-weight: 700;
}

.help-no-result {
    padding: 56px 30px;
    text-align: center;
}

.help-no-result strong {
    color: var(--help-category-ink);
    font-size: 20px;
}

.help-detail-categories {
    display: grid;
    gap: 7px;
    margin-bottom: 6px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--help-category-line);
}

.help-detail-categories a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 40px;
    padding: 0 12px;
    border-radius: 9px;
    color: #52627a;
    font-size: 13px;
    font-weight: 700;
}

.help-detail-categories a:hover,
.help-detail-categories a.active {
    background: #eef4ff;
    color: var(--help-category-primary);
}

.help-detail-categories em {
    color: #94a3b8;
    font-size: 11px;
    font-style: normal;
}

.help-detail-breadcrumb a:not(:first-child) {
    color: var(--help-category-primary);
}

.help-category-nav a:focus-visible,
.help-detail-categories a:focus-visible,
.article-tag:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .22);
    outline-offset: 3px;
}

@media (max-width: 900px) {
    body.help-page .help-knowledge-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 1100px) {
    body.help-detail-page .help-detail-layout {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.help-detail-page .help-sidebar {
        order: 0 !important;
        position: static !important;
        top: auto !important;
        width: 100% !important;
    }

    body.help-detail-page .help-content {
        order: 1 !important;
        min-width: 0 !important;
    }

    body.help-detail-page .help-sidebar .sidebar-card:first-child {
        padding: 20px !important;
    }

    body.help-detail-page .help-sidebar .sidebar-card + .sidebar-card {
        display: none !important;
    }

    body.help-detail-page .help-doc-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-height: 420px;
        padding-right: 6px;
        overflow-y: auto;
    }

    body.help-detail-page .help-detail-categories {
        grid-column: 1 / -1;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    html,
    body.help-page {
        max-width: 100%;
        overflow-x: hidden;
    }

    body.help-page .page-wrap {
        width: calc(100% - 24px) !important;
    }

    body.help-page .help-header-inner {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        min-width: 0 !important;
    }

    body.help-page .help-brand,
    body.help-page .help-header-actions {
        justify-content: center !important;
    }

    body.help-page .help-nav {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        min-width: 0 !important;
    }

    body.help-page .help-nav a {
        min-width: 0 !important;
        padding-inline: 4px !important;
        font-size: 13px !important;
    }

    body.help-page .help-banner,
    body.help-page .help-copy,
    body.help-page .help-search-form,
    body.help-page .hero-stats,
    body.help-page .help-icon-nav,
    body.help-page .help-knowledge-area {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
    }

    body.help-page .help-banner {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    body.help-detail-page .help-doc-list,
    body.help-detail-page .help-doc-list {
        grid-template-columns: minmax(0, 1fr);
    }

    body.help-detail-page .help-detail-categories {
        display: flex;
        gap: 8px;
        padding-bottom: 10px;
        overflow-x: auto;
    }

    body.help-detail-page .help-detail-categories a {
        flex: 0 0 auto;
        min-width: 118px;
    }

    body.help-detail-page .help-doc-list {
        max-height: 360px;
    }

    body.help-page .help-copy h1,
    body.help-page .help-copy p {
        max-width: 100% !important;
        overflow-wrap: anywhere;
        white-space: normal !important;
        text-wrap: pretty;
    }

    .help-category-nav {
        margin: 18px 0 28px;
    }

    .help-category-nav a {
        min-height: 42px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .help-category-nav a {
        transition: none;
    }
}
