.rstech {
    width: min(calc(100% - 32px), 1040px);
    margin: 48px auto 80px;
    padding: clamp(28px, 4vw, 48px);
    color: var(--text);
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(16, 16, 16, 0.05);
    font-family: inherit;
    font-size: 16px;
    line-height: 1.75;
    overflow-wrap: anywhere;
    word-break: normal;
}

.rstech :where(h1, h2, h3, h4, h5, h6) {
    color: var(--text);
    font-family: inherit;
    font-weight: 600;
    line-height: 1.3;
    text-wrap: balance;
    overflow-wrap: anywhere;
    scroll-margin-top: 120px;
}

.rstech :where(h1) {
    margin: 0 0 24px;
    font-size: clamp(30px, 3vw, 36px);
}

.rstech :where(h2) {
    margin: 48px 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
    font-size: clamp(26px, 2.5vw, 32px);
}

.rstech :where(h3) {
    margin: 40px 0 14px;
    font-size: clamp(22px, 2.1vw, 26px);
}

.rstech :where(h4) {
    margin: 32px 0 12px;
    font-size: clamp(19px, 1.8vw, 22px);
}

.rstech :where(h5) {
    margin: 28px 0 10px;
    font-size: 18px;
}

.rstech :where(h6) {
    margin: 24px 0 8px;
    color: var(--text-2);
    font-size: 16px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.rstech > :where(h1, h2, h3, h4, h5, h6):first-child {
    margin-top: 0;
}

.rstech :where(p) {
    margin: 0 0 18px;
}

.rstech :where(h1, h2, h3, h4, h5, h6) + :where(p, ul, ol, dl, table, .rstech-table, blockquote, figure) {
    margin-top: 0;
}

.rstech :where(strong, b, dt) {
    color: var(--text);
    font-weight: 700;
}

.rstech :where(em) {
    font-style: italic;
}

.rstech :where(small) {
    color: var(--text-2);
    font-size: 0.875em;
    line-height: 1.6;
}

.rstech :where(mark) {
    padding: 0.1em 0.25em;
    color: var(--text);
    background: color-mix(in srgb, var(--primary) 18%, var(--white));
    border-radius: 3px;
}

.rstech :where(a) {
    color: var(--primary-dark, var(--primary));
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
    overflow-wrap: anywhere;
    transition:
        color 180ms cubic-bezier(0.23, 1, 0.32, 1),
        text-decoration-color 180ms cubic-bezier(0.23, 1, 0.32, 1);
}

.rstech :where(a:hover) {
    color: var(--primary);
    text-decoration-thickness: 2px;
}

.rstech a:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 3px;
    border-radius: 2px;
}

.rstech :where(hr) {
    height: 1px;
    margin: 36px 0;
    border: 0;
    background: var(--line);
}

.rstech :where(ul, ol) {
    margin: 0 0 22px;
    padding-left: 1.6rem;
}

.rstech :where(ul) {
    list-style: disc outside;
}

.rstech :where(ol) {
    list-style: decimal outside;
}

.rstech :where(ul ul) {
    list-style-type: circle;
}

.rstech :where(ul ul ul) {
    list-style-type: square;
}

.rstech :where(ol ol) {
    list-style-type: lower-alpha;
}

.rstech :where(ul ul, ul ol, ol ul, ol ol) {
    margin: 8px 0 4px;
}

.rstech :where(li) {
    padding-left: 0.3rem;
    list-style: inherit;
}

.rstech :where(li + li) {
    margin-top: 8px;
}

.rstech :where(li::marker) {
    color: var(--primary);
    font-weight: 600;
}

.rstech :where(table),
.rstech-table {
    max-width: 100%;
    margin: 24px 0 30px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
}

.rstech :where(table) {
    display: block;
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    font-size: 15px;
    line-height: 1.55;
}

.rstech-table :where(table) {
    display: table;
    min-width: 640px;
    margin: 0;
    overflow: visible;
}

.rstech :where(caption) {
    padding: 0 0 10px;
    color: var(--text-2);
    font-size: 14px;
    font-weight: 600;
    text-align: left;
    caption-side: top;
}

.rstech :where(thead) {
    background: var(--bg);
}

.rstech :where(tbody tr:nth-child(even)) {
    background: color-mix(in srgb, var(--bg) 55%, var(--white));
}

.rstech :where(th, td) {
    min-width: 120px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
    overflow-wrap: anywhere;
}

.rstech :where(th) {
    color: var(--text);
    font-weight: 700;
}

.rstech :where(tfoot) {
    background: var(--bg);
    font-weight: 600;
}

.rstech :where(blockquote),
.rstech .rstech-note,
.rstech .rstech-warning,
.rstech .rstech-info {
    margin: 26px 0;
    padding: 20px 22px;
    color: var(--text);
    background: var(--bg);
    border: 0;
    border-left: 3px solid var(--primary);
    border-radius: 0 8px 8px 0;
}

.rstech .rstech-warning {
    background: color-mix(in srgb, var(--critical) 8%, var(--white));
    border-left-color: var(--critical);
}

.rstech .rstech-info {
    background: color-mix(in srgb, var(--primary) 8%, var(--white));
}

.rstech :where(blockquote > :last-child, .rstech-note > :last-child, .rstech-warning > :last-child, .rstech-info > :last-child) {
    margin-bottom: 0;
}

.rstech :where(dl) {
    margin: 0 0 24px;
}

.rstech :where(dt) {
    margin-top: 16px;
}

.rstech :where(dd) {
    margin: 5px 0 0;
    padding-left: 20px;
    color: var(--text-2);
}

.rstech :where(address) {
    margin: 0 0 22px;
    font-style: normal;
}

.rstech :where(code, kbd, pre) {
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
}

.rstech :where(code) {
    padding: 0.16em 0.38em;
    color: var(--text);
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 4px;
    font-size: 0.9em;
    overflow-wrap: anywhere;
}

.rstech :where(pre) {
    max-width: 100%;
    margin: 24px 0;
    padding: 18px 20px;
    overflow: auto;
    color: var(--text);
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.65;
    white-space: pre;
    tab-size: 4;
    -webkit-overflow-scrolling: touch;
}

.rstech :where(pre code) {
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    color: inherit;
    font-size: inherit;
    overflow-wrap: normal;
}

.rstech :where(kbd) {
    display: inline-block;
    padding: 0.15em 0.45em;
    color: var(--white);
    background: var(--text);
    border-radius: 4px;
    box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.25);
    font-size: 0.85em;
    line-height: 1.4;
}

.rstech :where(figure) {
    margin: 28px 0;
}

.rstech :where(img, video, iframe) {
    display: block;
    max-width: 100%;
    border-radius: 8px;
}

.rstech :where(img, video) {
    height: auto;
}

.rstech :where(iframe) {
    width: 100%;
    border: 0;
}

.rstech :where(figcaption) {
    margin-top: 10px;
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.6;
    text-align: center;
}

@media (max-width: 575.98px) {
    .rstech {
        width: calc(100% - 24px);
        margin: 32px auto 56px;
        padding: 22px 18px;
        border-radius: 8px;
        font-size: 16px;
        line-height: 1.7;
    }

    .rstech :where(h2) {
        margin-top: 38px;
        font-size: 25px;
    }

    .rstech :where(h3) {
        margin-top: 32px;
        font-size: 22px;
    }

    .rstech :where(h4) {
        margin-top: 28px;
        font-size: 19px;
    }

    .rstech :where(ul, ol) {
        padding-left: 1.3rem;
    }

    .rstech :where(th, td) {
        min-width: 110px;
        padding: 10px 12px;
    }

    .rstech :where(blockquote),
    .rstech .rstech-note,
    .rstech .rstech-warning,
    .rstech .rstech-info {
        padding: 16px 17px;
    }
}

@media print {
    .rstech {
        width: 100%;
        max-width: none;
        margin: 0;
        padding: 0;
        color: #000;
        background: #fff;
        border: 0;
        border-radius: 0;
        box-shadow: none;
        font-size: 11pt;
        line-height: 1.55;
    }

    .rstech :where(h1, h2, h3, h4, h5, h6) {
        color: #000;
        break-after: avoid-page;
        page-break-after: avoid;
    }

    .rstech :where(h1, h2, h3, h4, h5, h6) + :where(p, ul, ol, dl, table, blockquote, figure) {
        break-before: avoid-page;
        page-break-before: avoid;
    }

    .rstech :where(a) {
        color: #000;
        text-decoration: underline;
    }

    .rstech :where(table) {
        display: table;
        width: 100%;
        overflow: visible;
        break-inside: auto;
    }

    .rstech-table {
        overflow: visible;
    }

    .rstech :where(tr, img, figure, blockquote, pre) {
        break-inside: avoid-page;
        page-break-inside: avoid;
    }
}
