/* Mục lục: tăng 10% cỡ chữ theo yêu cầu 29/10/2026. */
@font-face {
    font-family: Manrope;
    src: url("Manrope.ttf") format("truetype");
    font-weight: 200 800;
    font-display: swap;
}

:root {
    --blue: #3d77b0;
    --blue-dark: #255a90;
    --ink: #203750;
    --muted: #64778b;
    --line: #e3eaf2;
    --pale: #f3f7fb;
    --header: 80px;
    --sidebar: 290px;
    font-family: Manrope, "Segoe UI", sans-serif;
    color: var(--ink);
    background: white;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

* {
    box-sizing: border-box;
}
body {
    margin: 0;
    font-size: 14px;
    line-height: 1.8;
}
button,
input {
    font: inherit;
}
button,
a {
    -webkit-tap-highlight-color: transparent;
}
button {
    cursor: pointer;
}
a {
    color: var(--blue-dark);
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}
button,
a {
    touch-action: manipulation;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid #347cbf;
    outline-offset: 4px;
}
[hidden] {
    display: none !important;
}
::selection {
    background: #d9eaff;
    color: #163856;
}
.skip-link {
    position: fixed;
    top: -80px;
    left: 20px;
    z-index: 200;
    padding: 10px 20px;
    background: white;
}
.skip-link:focus {
    top: 12px;
}
.site-header {
    height: var(--header);
    display: flex;
    align-items: center;
    gap: 22px;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 30;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--line);
}
.brand {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    width: 214px;
}
.brand img {
    width: 100%;
    height: auto;
    display: block;
}
.header-divider {
    width: 1px;
    height: 30px;
    background: var(--line);
}
.site-label {
    color: #566b82;
    font-size: 13px;
    white-space: nowrap;
}
.search-trigger {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    min-width: 260px;
    border: 1px solid var(--line);
    background: var(--pale);
    color: #63778d;
    border-radius: 8px;
    text-align: left;
}
.search-trigger > span:first-child {
    font-size: 27px;
    line-height: 20px;
}
kbd {
    font:
        10px Manrope,
        sans-serif;
    border: 1px solid #dce5ed;
    background: white;
    border-radius: 4px;
    padding: 2px 5px;
    white-space: nowrap;
}
.search-trigger kbd {
    margin-left: auto;
}
.header-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 42px;
    padding: 9px 15px;
    border: 1px solid var(--blue);
    border-radius: 7px;
    background: var(--blue);
    color: white;
    text-decoration: none;
    font-weight: 800;
    font-size: 12px;
    white-space: nowrap;
    box-shadow: 0 3px 8px #3d77b01a;
}
.header-download:hover {
    background: var(--blue-dark);
    border-color: var(--blue-dark);
}
.header-download svg {
    flex-shrink: 0;
}
.version-badge {
    background: #edf4fb;
    color: var(--blue-dark);
    border: 1px solid #dce8f5;
    border-radius: 6px;
    padding: 4px 9px;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}
.version-badge span {
    font-weight: 500;
    color: #637a92;
}
.menu-toggle {
    display: none;
    border: 1px solid var(--line);
    background: white;
    width: 40px;
    height: 40px;
    border-radius: 7px;
    font-size: 22px;
    color: var(--ink);
}
.sidebar {
    position: fixed;
    top: var(--header);
    bottom: 0;
    left: 0;
    width: var(--sidebar);
    padding: 30px 16px 0 22px;
    border-right: 1px solid var(--line);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #cfdae7 transparent;
    background: #fcfdff;
    z-index: 25;
}
.sidebar-title {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin: 0 10px 22px;
}
.sidebar-title > span {
    font-size: 11px;
    letter-spacing: 1.9px;
    font-weight: 800;
    color: #77899d;
}
.sidebar-title small {
    font-size: 12.1px;
    color: #8a9aac;
}
.nav-group {
    margin-bottom: 5px;
}
.nav-group summary {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 9px;
    cursor: pointer;
    list-style: none;
    font-weight: 700;
    font-size: 13.2px;
    border-radius: 6px;
    line-height: 1.6;
}
.nav-group summary::-webkit-details-marker {
    display: none;
}
.nav-group summary:hover {
    background: #eff4fa;
}
.chapter-number {
    font-size: 11px;
    color: #8da0b3;
    padding-top: 2px;
    font-weight: 600;
}
.chevron {
    margin-left: auto;
    font-size: 18px;
    line-height: 1.1;
    color: #90a3b6;
}
.nav-group[open] .chevron {
    transform: rotate(90deg);
}
.chapter-links {
    margin: 3px 0 15px 28px;
    border-left: 1px solid #dce5f0;
    padding-left: 10px;
}
.chapter-links a {
    display: block;
    text-decoration: none;
    color: #697d92;
    font-size: 12.65px;
    line-height: 1.6;
    padding: 7px 10px;
    border-radius: 5px;
}
.chapter-links a:hover {
    color: var(--blue-dark);
    background: #f0f5fb;
}
.chapter-links a[aria-current="page"] {
    color: #286399;
    background: #e9f1fa;
    font-weight: 800;
    box-shadow: -2px 0 #3d77b0;
}
.sidebar-footer {
    margin: 30px 10px 0;
    padding: 20px 0 24px;
    display: flex;
    gap: 9px;
    border-top: 1px solid var(--line);
    font-size: 11px;
}
.sidebar-footer strong,
.sidebar-footer small {
    display: block;
}
.sidebar-footer strong {
    font-size: 11px;
    color: #667a8e;
}
.sidebar-footer small {
    color: #8b9bae;
    font-size: 9.9px;
}
.status-dot {
    width: 6px;
    height: 6px;
    background: #72a997;
    border-radius: 50%;
    margin-top: 7px;
}
.content-layout {
    width: calc(100% - var(--sidebar));
    margin-left: var(--sidebar);
    margin-right: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 190px;
    gap: 48px;
    max-width: none;
    padding: 0 44px 0 52px;
}
main {
    min-width: 0;
    outline: none;
}
.doc-article {
    padding: 46px 0 0;
    scroll-margin-top: var(--header);
}
.article-header {
    padding-bottom: 30px;
    border-bottom: 1px solid var(--line);
    margin-bottom: 33px;
}
.breadcrumb {
    text-transform: uppercase;
    letter-spacing: 1.4px;
    font-size: 9px;
    color: #8093a6;
    font-weight: 800;
    margin: 0 0 20px;
}
.breadcrumb span {
    color: #bccbd9;
    margin: 0 9px;
}
h1 {
    font-size: clamp(29px, 2.7vw, 42px);
    line-height: 1.35;
    letter-spacing: -1.4px;
    font-weight: 800;
    margin: 0 0 16px;
    outline: none;
}
.intro-article h1 {
    font-size: clamp(38px, 3.8vw, 58px);
    line-height: 1.2;
    max-width: 750px;
    letter-spacing: -2px;
}
.intro-article .article-header {
    position: relative;
    padding: 34px 32px;
    margin-left: -4px;
    margin-right: -4px;
    margin-bottom: 38px;
    background: linear-gradient(120deg, #edf4fb, #f8fafc);
    border: 1px solid #e0eaf5;
    border-radius: 10px;
}
.intro-article .breadcrumb {
    color: var(--blue);
}
.article-lead {
    font-size: 15px;
    line-height: 1.9;
    color: #6b7e91;
    margin: 0 0 20px;
}
.article-meta {
    display: flex;
    flex-wrap: wrap;
    column-gap: 18px;
    row-gap: 4px;
    font-size: 10px;
    color: #8494a5;
}
.article-meta span:first-child {
    color: var(--blue-dark);
    font-weight: 700;
}
.module-path {
    margin: 19px 0 0;
    padding: 10px 13px;
    background: var(--pale);
    border-radius: 5px;
    font-size: 11px;
    color: #526d89;
}
.module-path span {
    color: #8b9bad;
    margin-right: 8px;
}
.article-section {
    margin: 0 0 38px;
}
h2 {
    font-size: 21px;
    line-height: 1.5;
    margin: 0 0 15px;
    letter-spacing: -0.5px;
    font-weight: 800;
    scroll-margin-top: 100px;
    outline: none;
}
h3 {
    font-size: 17px;
    line-height: 1.6;
    margin: 25px 0 12px;
    letter-spacing: -0.3px;
}
h4 {
    font-size: 15px;
}
p {
    margin: 0 0 16px;
}
li {
    padding-left: 4px;
    margin-bottom: 12px;
    color: #4b6178;
}
ol,
ul {
    padding-left: 23px;
    margin: 15px 0 20px;
}
ol > li::marker {
    font-weight: 800;
    color: var(--blue);
}
strong {
    font-weight: 800;
}
.topic-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 25px;
}
.topic-grid a {
    padding: 21px;
    border: 1px solid var(--line);
    border-radius: 8px;
    display: block;
    text-decoration: none;
    transition:
        border-color 0.18s,
        background 0.18s;
}
.topic-grid a:hover {
    border-color: #9ebcda;
    background: #f9fbff;
}
.topic-grid span {
    display: block;
    color: #9ab4cf;
    font-size: 11px;
    margin-bottom: 12px;
}
.topic-grid strong {
    color: var(--ink);
    display: block;
    font-size: 15px;
    margin-bottom: 7px;
}
.topic-grid small {
    color: #7b8da0;
    font-size: 11px;
    line-height: 1.8;
    display: block;
}
.callout {
    border-left: 3px solid #6c9dcc;
    border-radius: 0 6px 6px 0;
    background: #f2f7fc;
    padding: 18px 22px;
    font-size: 12px;
    color: #59718b;
    margin: 22px 0;
}
.callout > strong {
    display: block;
    color: #3b638b;
    margin-bottom: 6px;
    font-size: 11px;
}
.callout p {
    margin: 0;
}
.related-links {
    display: grid;
    gap: 8px;
    margin: 15px 0;
}
.related-links a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fbfcfe;
    border: 1px solid var(--line);
    padding: 11px 15px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 12px;
}
.related-links a:hover {
    background: #eff5fb;
}
.table-scroll {
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 7px;
    margin: 20px 0;
    scrollbar-width: thin;
}
table {
    border-collapse: collapse;
    width: 100%;
    font-size: 11px;
    line-height: 1.8;
    text-align: left;
    min-width: 480px;
}
th {
    padding: 13px 15px;
    background: #f3f7fb;
    color: #46617c;
    font-size: 10px;
    font-weight: 800;
}
td {
    padding: 14px 15px;
    border-top: 1px solid var(--line);
    vertical-align: top;
    color: #526980;
    overflow-wrap: anywhere;
}
td:first-child {
    color: #304f6c;
    font-weight: 600;
    min-width: 120px;
}
code {
    font:
        11px/1.7 Consolas,
        monospace;
    background: #edf3f9;
    color: #345b80;
    border-radius: 3px;
    padding: 2px 4px;
    overflow-wrap: anywhere;
}
pre {
    position: relative;
    margin: 18px 0 24px;
    background: #182b3e;
    border-radius: 7px;
    color: #d7e5f5;
    padding: 46px 20px 20px;
    overflow: auto;
    scrollbar-width: thin;
}
pre code {
    font-size: 12px;
    line-height: 1.9;
    color: inherit;
    background: transparent;
    padding: 0;
    overflow-wrap: normal;
    white-space: pre;
}
.copy-code {
    position: absolute;
    top: 9px;
    right: 10px;
    border: 1px solid #4d6176;
    border-radius: 4px;
    padding: 3px 9px;
    font-size: 10px;
    background: #253c53;
    color: #d5e3f2;
}
.architecture {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}
.architecture > div {
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 20px;
}
.architecture small {
    display: block;
    color: var(--blue);
    font-size: 9px;
    letter-spacing: 1.5px;
    margin-bottom: 10px;
}
.architecture strong {
    font-size: 16px;
}
.architecture p {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 12px;
}
.architecture > span {
    transform: rotate(90deg);
    justify-self: center;
    color: #8daaca;
}
.article-outline {
    position: sticky;
    top: calc(var(--header) + 44px);
    height: fit-content;
    padding-top: 0;
    margin-top: 46px;
    font-size: 10px;
}
.outline-heading {
    color: #5c7289;
    letter-spacing: 1.4px;
    font-weight: 800;
    font-size: 9px;
    display: block;
    margin-bottom: 14px;
}
#outline {
    border-left: 1px solid var(--line);
    padding-left: 14px;
    display: grid;
    gap: 9px;
}
#outline a {
    color: #7e90a3;
    text-decoration: none;
    font-size: 10px;
    line-height: 1.7;
}
#outline a:hover,
#outline a.active {
    color: var(--blue-dark);
}
.copy-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 11px 10px;
    margin: 20px 0 14px;
    border: 1px solid #a9c9e7;
    border-radius: 8px;
    background: #edf5ff;
    color: #245c91;
    width: 100%;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.5;
    box-shadow: 0 2px 5px #3d77b00a;
    transition:
        background 150ms ease,
        border-color 150ms ease;
}
.copy-link svg {
    flex: 0 0 auto;
}
.copy-link:hover {
    background: #e1edfb;
    border-color: #6e9fcc;
}
.copy-link:focus-visible {
    outline: 3px solid #a9c9e7;
    outline-offset: 3px;
}
.copy-link:active {
    background: #d6e7f9;
}
.help-card {
    display: block;
    background: var(--pale);
    border-radius: 6px;
    padding: 17px;
    text-decoration: none;
    margin-top: 10px;
}
.help-card strong {
    display: block;
    color: #415f7b;
    font-size: 11px;
    margin-bottom: 8px;
}
.help-card > span {
    font-size: 10px;
    line-height: 1.8;
    color: #7990a6;
}
.screenshot {
    margin: 20px 0 26px;
    min-width: 0;
}
.image-zoom {
    display: block;
    position: relative;
    padding: 10px;
    border: 1px solid #dce6f0;
    border-radius: 8px;
    background: #f2f6fa;
    width: 100%;
    overflow: hidden;
}
.screenshot img {
    display: block;
    max-width: 100%;
    width: auto;
    height: auto;
    max-height: 520px;
    object-fit: contain;
    margin: auto;
    border-radius: 3px;
}
.screenshot.portrait img {
    max-height: 540px;
}
.screenshot.portrait {
    max-width: 360px;
}
.zoom-hint {
    position: absolute;
    bottom: 17px;
    right: 16px;
    background: rgba(28, 52, 77, 0.9);
    color: white;
    padding: 5px 9px;
    border-radius: 4px;
    font-size: 9px;
    opacity: 0;
    transition: opacity 0.15s;
}
.image-zoom:hover .zoom-hint,
.image-zoom:focus-visible .zoom-hint {
    opacity: 1;
}
figcaption {
    margin-top: 10px;
    font-size: 9px;
    line-height: 1.8;
    color: #8292a3;
}
.download-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin: 25px 0;
}
.download-card {
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.platform-icon {
    width: 38px;
    height: 38px;
    border: 1px solid #dce8f5;
    border-radius: 7px;
    display: grid;
    place-items: center;
    color: var(--blue);
    background: #eff5fb;
    font-size: 21px;
    font-weight: 800;
}
.download-card h3 {
    font-size: 17px;
    margin: 17px 0 8px;
}
.download-card p {
    color: #6f849a;
    font-size: 11px;
    margin: 0 0 8px;
}
.download-card > small {
    font-size: 10px;
    color: #8597a9;
    margin-bottom: 20px;
}
.button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-height: 43px;
    padding: 10px 13px;
    text-decoration: none;
    border-radius: 5px;
    width: 100%;
    font-size: 11px;
    font-weight: 800;
}
.primary {
    background: var(--blue);
    color: white;
    border: 1px solid var(--blue);
}
.primary:hover {
    background: var(--blue-dark);
}
.download-link {
    margin-top: auto;
}
.download-link[aria-disabled="true"] {
    background: #ecf1f6;
    border-color: #e0e8f0;
    color: #687f96;
    cursor: help;
}
.text-link {
    font-size: 10px;
    margin-top: 13px;
    text-decoration: none;
}
.article-pager {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    padding: 30px 0;
    margin-top: 48px;
    border-top: 1px solid var(--line);
}
.article-pager a {
    border: 1px solid var(--line);
    padding: 17px;
    border-radius: 6px;
    text-decoration: none;
}
.article-pager a:last-child {
    text-align: right;
}
.article-pager small {
    display: block;
    color: #92a3b4;
    font-size: 9px;
    margin-bottom: 8px;
}
.article-pager strong {
    font-size: 12px;
    color: #536f89;
    line-height: 1.7;
    display: block;
}
.site-footer {
    display: flex;
    gap: 20px;
    justify-content: space-between;
    padding: 28px 0 32px;
    border-top: 1px solid var(--line);
    font-size: 9px;
    color: #90a0b1;
}
.site-footer a {
    color: #7c91a7;
    text-decoration: none;
}
dialog {
    border: 1px solid #e1e8f1;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 30px 100px #12283c33;
    color: var(--ink);
}
dialog::backdrop {
    background: #152e49a6;
    backdrop-filter: blur(3px);
}
.search-dialog {
    width: min(680px, calc(100% - 30px));
    max-height: 82dvh;
    margin: 9dvh auto;
}
.dialog-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px 10px;
}
.dialog-heading h2 {
    font-size: 15px;
    margin: 0;
}
.icon-button {
    border: 0;
    background: #edf2f8;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    color: #6e8195;
    font-size: 24px;
}
.search-field {
    margin: 5px 24px 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #cfdcea;
    padding: 10px 13px;
    border-radius: 6px;
}
.search-field span {
    font-size: 28px;
    color: #6c8eae;
    line-height: 1;
}
.search-field input {
    border: 0;
    outline: none;
    width: 100%;
    font-size: 14px;
    min-width: 0;
    color: var(--ink);
    background: white;
}
.search-description {
    font-size: 10px;
    color: #7f93a7;
    margin: 0 25px 12px;
}
.search-results {
    max-height: 49dvh;
    overflow: auto;
    padding: 0 15px 12px;
}
.search-suggestion {
    border: 1px solid #dce6f0;
    background: #f3f7fc;
    color: #587996;
    border-radius: 5px;
    padding: 8px 12px;
    margin: 5px;
    font-size: 11px;
}
.search-suggestion:hover {
    background: #e7f0fb;
}
.search-result {
    display: block;
    padding: 13px 12px;
    border-radius: 6px;
    text-decoration: none;
    border-bottom: 1px solid #edf1f6;
}
.search-result:hover,
.search-result:focus {
    background: #edf4fc;
}
.search-result small {
    color: #8096ac;
    display: block;
    font-size: 9px;
    margin-bottom: 4px;
}
.search-result strong {
    color: #2f567b;
    display: block;
    font-size: 13px;
}
.search-result p {
    color: #8294a6;
    font-size: 10px;
    margin: 6px 0 0;
}
.dialog-footer {
    background: #f7f9fc;
    border-top: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    padding: 12px 25px;
    font-size: 9px;
    color: #91a0b1;
}
.image-dialog {
    max-width: 96vw;
    max-height: 96dvh;
    background: #f4f7fb;
    padding: 22px;
    width: fit-content;
}
.image-dialog img {
    max-width: 90vw;
    max-height: 77dvh;
    width: auto;
    height: auto;
    display: block;
    margin: auto;
    object-fit: contain;
}
.image-dialog .icon-button {
    margin-left: auto;
    margin-bottom: 10px;
    background: #e1e9f2;
}
.image-dialog p {
    color: #637b92;
    font-size: 10px;
    max-width: 900px;
    margin: 14px 0 0;
}
.toast {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    background: #223e58;
    color: white;
    max-width: calc(100vw - 30px);
    width: max-content;
    padding: 12px 19px;
    border-radius: 7px;
    box-shadow: 0 5px 25px #203a5422;
    z-index: 100;
    font-size: 12px;
}
body.modal-open {
    overflow: hidden;
}
.sidebar-backdrop {
    display: none;
}

@media (min-width: 1700px) {
    :root {
        --sidebar: 310px;
    }
    .content-layout {
        padding-left: 70px;
        padding-right: 50px;
    }
    body {
        font-size: 15px;
    }
}
@media (max-width: 1250px) {
    :root {
        --sidebar: 260px;
    }
    .site-header {
        padding: 0 24px;
        gap: 17px;
    }
    .brand {
        width: 192px;
    }
    .site-label {
        font-size: 11px;
    }
    .search-trigger {
        min-width: 230px;
    }
    .content-layout {
        grid-template-columns: minmax(0, 1fr) 155px;
        gap: 28px;
        padding: 0 25px 0 36px;
    }
    .sidebar {
        padding-left: 13px;
        padding-right: 10px;
    }
    .nav-group summary {
        font-size: 12.1px;
    }
}
@media (max-width: 1050px) {
    .content-layout {
        display: block;
        padding: 0 38px;
    }
    .article-outline {
        display: none;
    }
    .site-label,
    .header-divider {
        display: none;
    }
    .brand {
        width: 200px;
    }
    h1 {
        font-size: 34px;
    }
    .intro-article h1 {
        font-size: 44px;
    }
}
@media (max-width: 760px) {
    :root {
        --header: 68px;
    }
    .site-header {
        padding: 0 14px;
        gap: 8px;
    }
    .brand {
        width: 145px;
    }
    .search-trigger {
        margin-left: auto;
        min-width: 36px;
        padding: 7px;
        background: white;
        border: 0;
        justify-content: center;
    }
    .search-trigger span:nth-child(2),
    .search-trigger kbd,
    .version-badge {
        display: none;
    }
    .header-download {
        min-height: 36px;
        padding: 7px 9px;
        gap: 5px;
        font-size: 10px;
        border-radius: 5px;
    }
    .header-download svg {
        width: 13px;
        height: 13px;
    }
    .search-trigger {
        min-width: 29px;
        width: 29px;
        padding: 0;
    }
    .menu-toggle {
        width: 35px;
        height: 36px;
        flex-shrink: 0;
    }
    .search-trigger > span:first-child {
        font-size: 33px;
    }
    .menu-toggle {
        display: block;
    }
    .sidebar {
        transform: translateX(-100%);
        width: min(330px, 85vw);
        transition: transform 0.2s;
        z-index: 45;
        top: var(--header);
        padding-left: 20px;
    }
    .nav-group summary {
        font-size: 13.2px;
    }
    .chapter-links a {
        font-size: 13.2px;
    }
    .sidebar.is-open {
        transform: translateX(0);
    }
    .sidebar-backdrop:not([hidden]) {
        display: block;
        position: fixed;
        inset: var(--header) 0 0;
        z-index: 40;
        border: 0;
        background: #18365077;
    }
    .content-layout {
        width: 100%;
        margin: 0;
        padding: 0 23px;
    }
    .doc-article {
        padding-top: 28px;
    }
    .intro-article .article-header {
        padding: 25px 22px;
        margin: 0 -5px 30px;
    }
    .intro-article h1 {
        font-size: 37px;
        line-height: 1.25;
        letter-spacing: -1.5px;
    }
    h1 {
        font-size: 29px;
        letter-spacing: -0.8px;
    }
    .breadcrumb {
        font-size: 8px;
        letter-spacing: 0.9px;
        margin-bottom: 16px;
    }
    .breadcrumb span {
        margin: 0 5px;
    }
    .article-lead {
        font-size: 13px;
        line-height: 1.9;
    }
    .article-meta {
        font-size: 9px;
        column-gap: 12px;
    }
    body {
        font-size: 13px;
    }
    h2 {
        font-size: 19px;
        scroll-margin-top: 88px;
    }
    .topic-grid {
        gap: 10px;
    }
    .topic-grid a {
        padding: 16px 13px;
    }
    .topic-grid strong {
        font-size: 13px;
    }
    .topic-grid small {
        font-size: 10px;
    }
    .callout {
        padding: 15px 17px;
        font-size: 11px;
    }
    .download-grid {
        grid-template-columns: 1fr;
    }
    .download-card {
        padding: 22px;
    }
    .article-pager {
        gap: 10px;
    }
    .article-pager a {
        padding: 13px;
    }
    .article-pager strong {
        font-size: 10px;
    }
    .site-footer {
        font-size: 8px;
        gap: 10px;
    }
    .search-dialog {
        margin-top: 6dvh;
    }
    .dialog-heading {
        padding: 14px 18px 7px;
    }
    .search-field {
        margin-left: 18px;
        margin-right: 18px;
    }
    .search-description {
        margin-left: 19px;
        margin-right: 19px;
    }
    .image-dialog {
        padding: 12px;
    }
    .image-dialog img {
        max-width: 86vw;
        max-height: 72dvh;
    }
    .toast {
        font-size: 11px;
    }
    pre {
        margin-left: 0;
        margin-right: 0;
        padding-left: 14px;
    }
    pre code {
        font-size: 10px;
    }
}
@media (max-width: 380px) {
    .brand {
        width: 125px;
    }
    .site-header {
        padding: 0 11px;
        gap: 6px;
    }
    .header-download {
        font-size: 9px;
        padding: 7px 8px;
    }
}
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
@media print {
    .site-header,
    .sidebar,
    .article-outline,
    .search-dialog,
    .image-dialog,
    .article-pager,
    .copy-code,
    .zoom-hint {
        display: none !important;
    }
    .content-layout {
        display: block;
        margin: 0;
        padding: 0;
    }
    .doc-article {
        padding: 0;
    }
    .image-zoom {
        border: 0;
    }
    pre {
        white-space: pre-wrap;
    }
}

/* Sơ đồ nghiệp vụ và các nút hướng dẫn bổ trợ. */
.diagram-frame {
    margin: 24px 0;
    border: 1px solid var(--line, #dce6f0);
    border-radius: 12px;
    overflow: hidden;
    background: #f8fbff;
}

.diagram-frame figcaption {
    padding: 16px 20px;
    font-size: 13px;
    line-height: 1.7;
}
.diagram-frame figcaption a {
    display: inline-block;
    margin-top: 8px;
    font-weight: 600;
}
.download-secondary {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin: 16px 0;
}
.download-card p {
    overflow-wrap: anywhere;
}
.article-section td {
    overflow-wrap: anywhere;
}
@media (max-width: 720px) {
    .download-secondary {
        flex-direction: column;
        gap: 8px;
    }
}

/* Thẻ tải theo mẫu: nút xanh toàn chiều ngang, liên kết phụ tách hàng. */
.download-card > .download-link {
    margin-top: 8px;
}
.download-card > .download-resource {
    display: block;
    margin-top: 16px;
    text-decoration: none;
}
.download-card > .download-resource:hover {
    text-decoration: underline;
}
/* Chỉ giới hạn khung xem phần trống; giữ nguyên pixel ảnh nguồn và các nội dung trong khung. */
.image-zoom.crop-image {
    position: relative;
    aspect-ratio: var(--image-ratio);
    padding: 0;
}
.image-zoom.crop-image img {
    transform: translateY(var(--crop-offset, 0%));
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    max-height: none;
    border-radius: 0;
}
.large-image-frame {
    display: contents;
}
.large-image-frame.is-cropped {
    display: block;
    position: relative;
    overflow: hidden;
    aspect-ratio: var(--image-ratio);
    width: min(86vw, calc(76vh * var(--crop-ratio)));
    margin: 0 auto;
}
.large-image-frame.is-cropped #large-image {
    transform: translateY(var(--crop-offset, 0%));
    position: absolute;
    top: 0;
    left: 0;
    display: block;
    width: 100%;
    height: auto;
    max-width: none;
    max-height: none;
    margin: 0;
}

/* Diagrams are ordinary images; the existing screenshot lightbox handles zoom. */
.diagram-image {
    margin: 24px 0 12px;
}
.diagram-image .image-zoom {
    width: 100%;
}
.diagram-downloads {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 12px 0 24px;
}
.diagram-downloads a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 8px 14px;
    border: 1px solid #cbdced;
    border-radius: 8px;
    background: #f3f8fd;
    color: #285f94;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}
.diagram-downloads a:hover {
    background: #e5eff9;
    border-color: #457fb5;
}
