/* ==========================================================================
   Article details page (BEM block: article-details)
   ========================================================================== */

.page-main--article-details {
    padding: 0;
    gap: 0;
}

.article-details {
    align-self: stretch;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    padding: 26px 40px 60px;
    box-sizing: border-box;
    overflow: hidden;
}

.article-details__layout {
    align-self: stretch;
    width: 100%;
    min-width: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 24px;
    overflow: hidden;
}

.article-details__content {
    flex: 1 1 0;
    min-width: 0;
    max-width: 1220px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 22px;
    overflow: hidden;
}

/* Breadcrumb */

.article-details__breadcrumb {
    align-self: stretch;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
    font-size: 13px;
    line-height: 1;
}

.article-details__breadcrumb-link {
    color: #676d85;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    transition: color 0.2s ease;
}

.article-details__breadcrumb-link:hover {
    color: #a7acc2;
}

.article-details__breadcrumb-sep {
    color: #404660;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
}

.article-details__breadcrumb-current {
    color: #8a6bff;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 600;
}

/* Header */

.article-details__header {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    overflow: hidden;
}

.article-details__title {
    align-self: stretch;
    margin: 0;
    color: #fff;
    font-size: 34px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 600;
    line-height: 43.52px;
}

.article-details__subtitle {
    align-self: stretch;
    margin: 0;
    color: #a7acc2;
    font-size: 15px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 25.5px;
    white-space: pre-wrap;
}

.article-details__meta-bar {
    align-self: stretch;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    align-content: center;
    gap: 18px;
    padding-bottom: 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    overflow: hidden;
}

.article-details__meta-top,
.article-details__meta-bottom {
    display: contents;
}

.article-details__meta-item--date {
    order: 2;
}

.article-details__meta-item--views {
    order: 3;
}

.article-details__meta-item--comments {
    order: 4;
}

.article-details__meta-item--likes {
    order: 5;
}

.article-details__author {
    display: flex;
    align-items: center;
    gap: 8px;
}

.article-details__author-avatar {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
    border-radius: 13px;
    object-fit: cover;
    display: block;
}

.article-details__author-avatar--initials {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(90deg, #8a6bff 0%, #26d7e6 100%);
    overflow: hidden;
}

.article-details__author-avatar-letter {
    color: #fff;
    font-size: 12px;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
}

.article-details__author-name {
    color: #a7acc2;
    font-size: 13px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
}

.article-details__meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #676d85;
    font-size: 13px;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 1;
}

.article-details__meta-icon {
    width: 15px;
    height: 15px;
    flex-shrink: 0;
    opacity: 0.85;
}

/* Hero cover */

.article-details__hero-img {
    align-self: stretch;
    width: 100%;
    box-sizing: border-box;
    border-radius: 22px;
}

/* Body sections */

.article-details__body {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 26px;
    padding-top: 4px;
    overflow: hidden;
}

.article-details__section {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    overflow: hidden;
}

.article-details__section-header {
    display: flex;
    align-items: center;
    gap: 11px;
    overflow: hidden;
}

.article-details__section-accent {
    width: 4px;
    height: 18px;
    flex-shrink: 0;
    border-radius: 4px;
    background: linear-gradient(180deg, #8a6bff 0%, #26d7e6 100%);
}

.article-details__section-title {
    margin: 0;
    color: #eef0f8;
    font-size: 18px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 600;
    line-height: 1.2;
}

.article-details__paragraph {
    align-self: stretch;
    margin: 0;
    color: #a7acc2;
    font-size: 14px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 25.9px;
    white-space: pre-wrap;
}

.article-details__node-img {
    align-self: stretch;
    width: 100%;
    max-width: 100%;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    object-fit: cover;
    display: block;
}

.article-details__node-media {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 30px;
    box-sizing: border-box;
}

.article-details__node-img--centered {
    width: auto;
    max-width: 100%;
    align-self: center;
}

.article-details__node-img-caption {
    margin: 0;
    color: #a7acc2;
    font-size: 14px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    text-align: center;
    line-height: 25.9px;
}

.article-details__faq {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.article-details__faq-item {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    padding-bottom: 16px;
    overflow: hidden;
}

.article-details__faq-item--bordered {
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.article-details__faq-item:last-child {
    padding-bottom: 0;
}

.article-details__faq-row {
    align-self: stretch;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    overflow: hidden;
}

.article-details__faq-label-q {
    color: #8a6bff;
    font-size: 14px;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 700;
    flex-shrink: 0;
}

.article-details__faq-label-a {
    color: #26d7e6;
    font-size: 13px;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 700;
    flex-shrink: 0;
}

.article-details__faq-question {
    flex: 1 1 0;
    min-width: 0;
    margin: 0;
    color: #eef0f8;
    font-size: 14px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 600;
    line-height: 1.4;
}

.article-details__faq-answer {
    flex: 1 1 0;
    min-width: 0;
    margin: 0;
    color: #a7acc2;
    font-size: 13px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 22.1px;
}

.article-details__debug-title {
    margin: 0 0 8px;
    color: #eef0f8;
    font-size: 16px;
    font-weight: 600;
}

.article-details__list {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 11px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.article-details__list-item {
    align-self: stretch;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding-top: 2px;
    overflow: hidden;
}

.article-details__list-bullet {
    width: 7px;
    height: 7px;
    flex-shrink: 0;
    margin-top: 9px;
    border-radius: 4px;
    background: linear-gradient(90deg, #8a6bff 0%, #26d7e6 100%);
}

.article-details__list-text {
    flex: 1 1 0;
    min-width: 0;
    margin: 0;
    color: #a7acc2;
    font-size: 14px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 24.5px;
}

/* Inline thumbs */

.article-details__thumbs {
    align-self: stretch;
    width: 100%;
    min-width: 0;
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.article-details__thumbs a {
    flex: none;
}

.article-details__thumb {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
    border-radius: 17.31px;
    object-fit: cover;
    display: block;
}

/* Prev / next navigation */

.article-details__nav-row {
    align-self: stretch;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 18px;
    overflow: hidden;
}

.article-details__nav-card {
    flex: 1 1 280px;
    min-width: min(100%, 280px);
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 18px 20px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.07);
    box-sizing: border-box;
    overflow: hidden;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.article-details__nav-card:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.12);
}

.article-details__nav-card--next {
    align-items: flex-end;
    text-align: right;
}

.article-details__nav-card--disabled {
    cursor: default;
    opacity: 0.55;
}

.article-details__nav-card--disabled:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.07);
}

.article-details__nav-label {
    align-self: stretch;
    color: #676d85;
    font-size: 12px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 400;
    line-height: 1.3;
}

.article-details__nav-title {
    align-self: stretch;
    margin: 0;
    color: #eef0f8;
    font-size: 14px;
    font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    font-weight: 600;
    line-height: 1.35;
}

/* Promo banner row */

.article-details__promo-row {
    align-self: stretch;
    width: 100%;
    min-width: 0;
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 16px;
    overflow: auto hidden;
    -webkit-overflow-scrolling: touch;
}
.article-details__promo-row a {
    flex: none;
}

.article-details__promo-card {
    width: 200px;
    height: 100px;
    flex-shrink: 0;
    border-radius: 14.29px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    object-fit: cover;
    display: block;
    box-sizing: border-box;
}

/* ==========================================================================
   Article details — Mobile (max-width: 767px)
   ========================================================================== */

@media (max-width: 767px) {
    .page-main--article-details {
        padding: 16px 16px 24px;
        gap: 20px;
    }

    .article-details {
        padding: 0;
        overflow: visible;
    }

    .article-details__layout {
        flex-direction: column;
        gap: 20px;
        overflow: visible;
    }

    .article-details__content {
        flex: none;
        width: 100%;
        max-width: none;
        gap: 18px;
        overflow: visible;
    }

    .article-details__breadcrumb {
        display: none;
    }

    .article-details__header {
        gap: 14px;
    }

    .article-details__title {
        font-size: 20px;
        line-height: 25.6px;
    }

    .article-details__subtitle {
        font-size: 14px;
        line-height: 23.8px;
    }

    .article-details__meta-bar {
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
        gap: 10px;
        padding-bottom: 22px;
    }

    .article-details__meta-top {
        align-self: stretch;
        display: flex;
        align-items: center;
        gap: 18px;
        width: 100%;
    }

    .article-details__author {
        flex-shrink: 0;
    }

    .article-details__meta-bottom {
        align-self: stretch;
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 18px;
    }

    .article-details__meta-item--date {
        flex: 1 1 0;
        min-width: 0;
        justify-content: flex-end;
        order: unset;
    }

    .article-details__meta-item--comments {
        justify-content: flex-start;
        order: unset;
    }

    .article-details__meta-item--views {
        justify-content: flex-start;
        order: unset;
    }

    .article-details__meta-item--likes {
        justify-content: flex-start;
        order: unset;
    }

    .article-details__hero-img {
        height: auto;
        border-radius: 16px;
    }

    .article-details__body {
        gap: 26px;
    }

    .article-details__thumbs {
        gap: 8px;
        scrollbar-width: none;
    }

    .article-details__thumbs::-webkit-scrollbar {
        display: none;
    }

    .article-details__thumb {
        width: 60px;
        height: 60px;
        border-radius: 9.97px;
    }

    .article-details__nav-row {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 18px;
    }

    .article-details__nav-card {
        flex: 1 1 0;
        min-width: 0;
    }

    .article-details__nav-card--next {
        align-items: flex-end;
        text-align: right;
    }

    .article-details__nav-card--next .article-details__nav-title {
        max-width: 123px;
    }

    .article-details__promo-row {
        gap: 16px;
        scrollbar-width: none;
    }

    .article-details__promo-row::-webkit-scrollbar {
        display: none;
    }

    .article-details__promo-card {
        width: 140px;
        height: 70px;
        border-radius: 10px;
        border-width: 0.7px;
    }

    .article-details__layout .tool-details__aside {
        width: 100%;
        gap: 20px;
        overflow: visible;
    }
}
