/* 电脑是怎样工作的？ */

.hcw-story {
    color: var(--article-text-color);
    font-size: 14px;
    line-height: 1.6;
}

.hcw-story * {
    box-sizing: border-box;
}

.hcw-story img {
    display: block;
    max-width: 100%;
}

.hcw-story p {
    margin: 0 0 12px;
}

.hcw-story strong {
    color: var(--article-heading-color);
}

.hcw-section {
    margin-top: 22px;
    scroll-margin-top: 110px;
}

.hcw-story .hcw-section > h2 {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0 0 8px;
    color: var(--article-heading-color);
    font-size: 20px;
    line-height: 1.35;
    font-weight: 900;
}

.hcw-number {
    display: inline-flex;
    flex: 0 0 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #0752ff;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
}

/* 总览流程 */

.hcw-overview {
    display: grid;
    grid-template-columns: 1fr 28px 1fr 28px 1fr 28px 1fr;
    align-items: center;
    gap: 5px;
    margin-top: 14px;
}

.hcw-overview__step {
    min-width: 0;
    min-height: 205px;
    padding: 15px 10px 12px;
    border-radius: 15px;
    text-align: center;
}

.hcw-overview__step--input {
    background: #f3efff;
}

.hcw-overview__step--prepare {
    background: #fff6df;
}

.hcw-overview__step--process {
    background: #eef6ff;
}

.hcw-overview__step--output {
    background: #ecfaef;
}

.hcw-overview__step img {
    width: 82px;
    height: 82px;
    object-fit: contain;
    margin: 4px auto 6px;
}

.hcw-overview__fa {
    display: inline-flex;
    width: 82px;
    height: 82px;
    align-items: center;
    justify-content: center;
    margin: 4px auto 6px;
    border-radius: 22px;
    background: #fff;
    color: #d79500;
    font-size: 40px;
}

.hcw-story .hcw-overview__step h3 {
    margin: 0 0 5px;
    color: var(--article-heading-color);
    font-size: 15px;
}

.hcw-overview__step p {
    margin: 0;
    color: #617296;
    font-size: 12px;
}

.hcw-flow-arrow {
    color: #4f82ff;
    font-size: 24px;
    font-weight: 900;
    text-align: center;
}

/* 提示卡 */

.hcw-key,
.hcw-warning {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-top: 14px;
    padding: 14px 16px;
    border-radius: 14px;
}

.hcw-key {
    background: #eaf5ff;
}

.hcw-key img,
.hcw-warning img {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    object-fit: contain;
}

.hcw-story .hcw-key h3,
.hcw-story .hcw-warning h3 {
    margin: 0 0 4px;
    font-size: 15px;
}

.hcw-story .hcw-key h3 {
    color: #0752ff;
}

.hcw-key p,
.hcw-warning p {
    margin: 0 0 4px;
}

.hcw-key p:first-of-type {
    color: #0752ff;
    font-size: 17px;
}

/* 输入 */

.hcw-input-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 13px;
}

.hcw-input-grid article {
    min-width: 0;
    padding: 14px 10px;
    border: 1px solid #e1ecff;
    border-radius: 14px;
    background: #f9fbff;
    text-align: center;
}

.hcw-input-grid__icon {
    display: inline-flex;
    width: 68px;
    height: 68px;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    border-radius: 20px;
    background: #eaf3ff;
    color: #0752ff;
    font-size: 30px;
}

.hcw-story .hcw-input-grid h3 {
    margin: 0 0 4px;
    color: var(--article-heading-color);
    font-size: 15px;
}

.hcw-input-grid p {
    margin: 0;
    color: #607296;
    font-size: 12px;
}

.hcw-example-line {
    display: flex;
    gap: 11px;
    align-items: center;
    margin-top: 12px;
    padding: 12px 14px;
    border-radius: 13px;
    background: #f4f1ff;
}

.hcw-example-line__label {
    flex: 0 0 auto;
    padding: 5px 9px;
    border-radius: 999px;
    background: #7457df;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

.hcw-example-line p {
    margin: 0;
}

/* 准备程序和数据 */

.hcw-prepare {
    display: grid;
    grid-template-columns: 1fr 120px 1fr;
    gap: 12px;
    align-items: center;
    margin-top: 14px;
}

.hcw-prepare__storage,
.hcw-prepare__memory {
    padding: 18px 14px;
    border-radius: 16px;
    text-align: center;
}

.hcw-prepare__storage {
    background: #eef5ff;
}

.hcw-prepare__memory {
    background: #fff5df;
}

.hcw-prepare__big-icon {
    display: inline-flex;
    width: 84px;
    height: 84px;
    align-items: center;
    justify-content: center;
    border-radius: 23px;
    background: #fff;
    color: #0752ff;
    font-size: 38px;
}

.hcw-prepare__memory .hcw-prepare__big-icon {
    color: #d58b00;
}

.hcw-story .hcw-prepare h3 {
    margin: 8px 0 4px;
    color: var(--article-heading-color);
    font-size: 16px;
}

.hcw-prepare p {
    margin: 0 0 4px;
}

.hcw-prepare small {
    color: #71809f;
    font-size: 11px;
}

.hcw-prepare__arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    color: #4f82ff;
    text-align: center;
}

.hcw-prepare__arrow span {
    color: #697b9c;
    font-size: 11px;
}

.hcw-prepare__arrow strong {
    color: #4f82ff;
    font-size: 32px;
}

.hcw-note {
    display: flex;
    gap: 11px;
    align-items: flex-start;
    margin-top: 12px;
    padding: 13px 15px;
    border-radius: 14px;
    background: #fff8e5;
}

.hcw-note__icon {
    font-size: 31px;
}

.hcw-story .hcw-note h3 {
    margin: 0 0 4px;
    color: #9a6800;
    font-size: 15px;
}

.hcw-note p {
    margin: 0;
}

.hcw-small-note {
    margin-top: 8px !important;
    color: #7382a0;
    font-size: 12px;
}

/* CPU */

.hcw-cpu-flow {
    display: grid;
    grid-template-columns: 1fr 30px 1fr 30px 1fr;
    gap: 6px;
    align-items: center;
    margin-top: 14px;
}

.hcw-cpu-flow article {
    position: relative;
    min-width: 0;
    min-height: 180px;
    padding: 14px 10px;
    border: 1px solid #e1ebff;
    border-radius: 15px;
    background: #f8fbff;
    text-align: center;
}

.hcw-cpu-flow__badge {
    position: absolute;
    top: 9px;
    left: 9px;
    display: inline-flex;
    width: 26px;
    height: 26px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #0752ff;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

.hcw-cpu-flow__icon {
    display: inline-flex;
    width: 64px;
    height: 64px;
    align-items: center;
    justify-content: center;
    margin: 10px auto 6px;
    border-radius: 18px;
    background: #eaf3ff;
    color: #0752ff;
    font-size: 27px;
}

.hcw-story .hcw-cpu-flow h3 {
    margin: 0 0 4px;
    color: var(--article-heading-color);
    font-size: 15px;
}

.hcw-cpu-flow p {
    margin: 0;
    color: #617296;
    font-size: 12px;
}

.hcw-drawing-example {
    display: flex;
    gap: 13px;
    align-items: center;
    margin-top: 13px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #eef7ff;
}

.hcw-drawing-example img {
    width: 68px;
    height: 68px;
    flex: 0 0 68px;
    object-fit: contain;
}

.hcw-story .hcw-drawing-example h3 {
    margin: 0 0 4px;
    color: #0752ff;
    font-size: 15px;
}

.hcw-drawing-example p {
    margin: 0;
}

.hcw-warning {
    border: 1px solid #ffd0dc;
    background: #fff2f6;
}

.hcw-story .hcw-warning h3 {
    color: #d83265;
}

/* 输出 */

.hcw-output-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 13px;
}

.hcw-output-grid article {
    min-width: 0;
    padding: 14px 10px;
    border: 1px solid #e2ecff;
    border-radius: 14px;
    background: #f9fbff;
    text-align: center;
}

.hcw-output-grid article > span {
    display: inline-flex;
    width: 66px;
    height: 66px;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    border-radius: 20px;
    background: #ebf8ef;
    color: #1c914d;
    font-size: 28px;
}

.hcw-story .hcw-output-grid h3 {
    margin: 0 0 4px;
    color: var(--article-heading-color);
    font-size: 15px;
}

.hcw-output-grid p {
    margin: 0;
    color: #617296;
    font-size: 12px;
}

.hcw-complete-example {
    margin-top: 13px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #edf9f0;
}

.hcw-story .hcw-complete-example h3 {
    margin: 0 0 9px;
    color: #188344;
    font-size: 15px;
}

.hcw-complete-example__flow {
    display: flex;
    gap: 7px;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.hcw-complete-example__flow span {
    padding: 7px 10px;
    border-radius: 10px;
    background: #fff;
    color: #27436f;
    font-weight: 700;
}

.hcw-complete-example__flow b {
    color: #3a9a5c;
}

/* 保存 */

.hcw-save {
    display: grid;
    grid-template-columns: 1fr 120px 1fr;
    gap: 12px;
    align-items: center;
    margin-top: 14px;
}

.hcw-save__before,
.hcw-save__after {
    display: flex;
    min-height: 168px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 14px;
    border-radius: 16px;
    text-align: center;
}

.hcw-save__before {
    background: #f3efff;
}

.hcw-save__after {
    background: #fff6df;
}

.hcw-save__before > span {
    color: #7156d8;
    font-size: 58px;
}

.hcw-save__after img {
    width: 72px;
    height: 72px;
    object-fit: contain;
}

.hcw-save strong {
    margin-top: 5px;
    font-size: 15px;
}

.hcw-save small {
    margin-top: 3px;
    color: #71809f;
    font-size: 11px;
}

.hcw-save__arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    color: #4f82ff;
}

.hcw-save__arrow span {
    color: #697b9c;
    font-size: 11px;
}

.hcw-save__arrow strong {
    color: #4f82ff;
    font-size: 32px;
}

.hcw-key--storage p:first-of-type {
    color: var(--article-text-color);
    font-size: inherit;
}

/* 总结 */

.hcw-summary {
    display: flex;
    gap: 12px;
    margin-top: 22px;
    padding: 18px;
    border-radius: 16px;
    background: #e9f3ff;
    scroll-margin-top: 110px;
}

.hcw-summary__icon {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    object-fit: contain;
}

.hcw-story .hcw-summary h2 {
    margin: 0 0 7px;
    color: #0752ff;
    font-size: 19px;
}

.hcw-summary ul {
    margin: 0;
    padding-left: 20px;
    line-height: 1.75;
}

.hcw-summary__next {
    margin: 10px 0 0 !important;
    padding-top: 10px;
    border-top: 1px dashed #b8d3f6;
}

.hcw-summary__next em {
    color: #0752ff;
    font-style: normal;
    font-weight: 800;
}

/* 上一篇 / 下一篇 */

.hcw-pagination {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin-top: 14px;
}

.hcw-pagination a {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 49%;
    padding: 10px 13px;
    border: 1px solid #d9e7ff;
    border-radius: 12px;
    background: #ffffffb3;
    text-decoration: none;
    box-shadow: 0 3px 10px #c5dbff30;
}

.hcw-pagination a:last-child {
    text-align: right;
}

.hcw-pagination strong {
    display: block;
    color: #0752ff;
    font-size: 16px;
}

.hcw-pagination small {
    display: block;
    color: #576b9f;
    font-size: 12px;
}

.hcw-pagination__arrow {
    display: inline-flex;
    width: 31px;
    height: 31px;
    flex: 0 0 31px;
    align-items: center;
    justify-content: center;
    border: 1px solid #d9e7ff;
    border-radius: 7px;
    color: #0752ff;
    font-size: 22px;
}

.hcw-pagination a:hover {
    background: #edf4ff;
}

.hcw-pagination a:focus-visible {
    outline: 3px solid #0752ff;
    outline-offset: 3px;
}

/* 平板 */

@media (max-width: 900px) {
    .hcw-overview {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .hcw-overview > .hcw-flow-arrow {
        display: none;
    }

    .hcw-input-grid,
    .hcw-output-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* 手机 */

@media (max-width: 640px) {
    .hcw-story {
        font-size: 12px;
        line-height: 1.6;
    }

    .hcw-section {
        margin-top: 18px;
    }

    .hcw-story .hcw-section > h2 {
        gap: 9px;
        margin-bottom: 6px;
        font-size: 16px;
    }

    .hcw-number {
        flex-basis: 31px;
        height: 31px;
        font-size: 14px;
    }

    .hcw-overview {
        grid-template-columns: minmax(0, 1fr);
        gap: 7px;
    }

    .hcw-overview > .hcw-flow-arrow {
        display: block;
        transform: rotate(90deg);
        line-height: 1;
    }

    .hcw-overview__step {
        min-height: auto;
        padding: 12px 10px;
    }

    .hcw-overview__step img,
    .hcw-overview__fa {
        width: 66px;
        height: 66px;
    }

    .hcw-overview__fa {
        font-size: 31px;
    }

    .hcw-key,
    .hcw-warning {
        gap: 9px;
        padding: 11px 12px;
    }

    .hcw-key img,
    .hcw-warning img {
        width: 44px;
        height: 44px;
        flex-basis: 44px;
    }

    .hcw-key p:first-of-type {
        font-size: 14px;
    }

    .hcw-key--storage p:first-of-type {
        font-size: inherit;
    }

    .hcw-input-grid,
    .hcw-output-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .hcw-input-grid article,
    .hcw-output-grid article {
        padding: 11px 7px;
    }

    .hcw-input-grid__icon,
    .hcw-output-grid article > span {
        width: 54px;
        height: 54px;
        border-radius: 16px;
        font-size: 24px;
    }

    .hcw-story .hcw-input-grid h3,
    .hcw-story .hcw-output-grid h3 {
        font-size: 14px;
    }

    .hcw-input-grid p,
    .hcw-output-grid p {
        font-size: 10px;
    }

    .hcw-example-line {
        align-items: flex-start;
        padding: 10px 11px;
    }

    .hcw-prepare,
    .hcw-save {
        grid-template-columns: minmax(0, 1fr);
        gap: 7px;
    }

    .hcw-prepare__arrow,
    .hcw-save__arrow {
        min-height: 35px;
    }

    .hcw-prepare__arrow strong,
    .hcw-save__arrow strong {
        transform: rotate(90deg);
        line-height: 1;
    }

    .hcw-prepare__storage,
    .hcw-prepare__memory,
    .hcw-save__before,
    .hcw-save__after {
        min-height: auto;
        padding: 13px;
    }

    .hcw-prepare__big-icon {
        width: 68px;
        height: 68px;
        font-size: 31px;
    }

    .hcw-cpu-flow {
        grid-template-columns: minmax(0, 1fr);
        gap: 7px;
    }

    .hcw-cpu-flow > .hcw-flow-arrow {
        transform: rotate(90deg);
        line-height: 1;
    }

    .hcw-cpu-flow article {
        min-height: auto;
        padding: 12px 10px;
    }

    .hcw-cpu-flow__icon {
        width: 54px;
        height: 54px;
        font-size: 22px;
    }

    .hcw-drawing-example {
        gap: 9px;
        padding: 11px 12px;
    }

    .hcw-drawing-example img {
        width: 50px;
        height: 50px;
        flex-basis: 50px;
    }

    .hcw-complete-example__flow {
        justify-content: flex-start;
    }

    .hcw-summary {
        gap: 8px;
        padding: 14px;
    }

    .hcw-summary__icon {
        width: 44px;
        height: 44px;
        flex-basis: 44px;
    }

    .hcw-story .hcw-summary h2 {
        font-size: 17px;
    }

    .hcw-pagination {
        gap: 9px;
    }

    .hcw-pagination a {
        flex: 1;
        min-width: 0;
        gap: 5px;
        padding: 8px 6px;
    }

    .hcw-pagination strong {
        font-size: 13px;
    }

    .hcw-pagination small {
        font-size: 10px;
        line-height: 1.35;
    }

    .hcw-pagination__arrow {
        width: 26px;
        height: 27px;
        flex-basis: 26px;
        font-size: 18px;
    }
}
