.article-page {
    --article-accent: #f5003d;
    --article-accent-dark: #d90036;
    --article-ink: #1f2937;
    --article-muted: #6b7280;
    --article-line: #e6e9ee;
    --article-soft: #f7f8fa;
    direction: rtl;
    color: var(--article-ink);
}

.article-page .article-layout {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
}

.article-page .article-content {
    order: 1;
}

.article-page .article-sidebar {
    order: 2;
}

.article-page .blog-detail,
.article-page .article-sidebar > .block {
    background: #fff;
    border: 1px solid var(--article-line);
    border-radius: 18px;
    box-shadow: 0 8px 30px rgba(31, 41, 55, .07);
}

.article-page .blog-detail {
    padding: clamp(18px, 3vw, 34px);
    overflow: hidden;
}

.article-page .blog-detail .item,
.article-page .blog-detail .item-inner {
    min-width: 0;
}

.article-page .article-title {
    margin: 0 0 12px;
    padding: 0 0 16px;
    border-bottom: 1px solid var(--article-line);
    color: var(--article-ink);
    font-size: clamp(22px, 3vw, 32px);
    font-weight: 800;
    line-height: 1.7;
}

.article-page .blog-attr {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    align-items: center;
    margin-bottom: 24px;
    color: var(--article-muted);
    font-size: 12px;
}

.article-page .blog-attr .separator {
    color: #d1d5db;
}

.article-page .blog-image {
    margin: 0 0 26px;
    overflow: hidden;
    border-radius: 14px;
}

.article-page .article-main-image {
    display: block;
    max-width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: cover;
    margin: auto;
    border-radius: 15px;
}

.article-page .desc {
    width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
    color: #374151;
    font-size: 15px;
    line-height: 2.15;
}

.article-page .desc img {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 24px auto !important;
    border-radius: 14px;
}

.article-page .desc iframe,
.article-page .desc video {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
    min-height: min(440px, 56vw);
    border: 0;
    border-radius: 14px;
}

.article-page .desc table {
    display: block;
    width: 100% !important;
    max-width: 100%;
    overflow-x: auto;
}

.article-page .desc h2,
.article-page .desc h3,
.article-page .desc h4 {
    margin-top: 30px;
    color: var(--article-ink);
    font-weight: 800;
    line-height: 1.8;
}

.article-page .share-post {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    margin: 34px 0 10px;
    padding: 16px;
    border: 1px solid var(--article-line);
    border-radius: 14px;
    background: var(--article-soft);
}

.article-page .share-label {
    margin: 0;
    color: var(--article-ink);
    font-size: 14px;
    font-weight: 800;
}

.article-page .share-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.article-page .share-actions li {
    display: block;
}

.article-page .share-button {
    display: inline-flex;
    gap: 7px;
    align-items: center;
    min-height: 40px;
    padding: 8px 13px;
    border: 1px solid #dfe3e8;
    border-radius: 10px;
    background: #fff;
    color: #374151;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.article-page .share-button:hover,
.article-page .share-button:focus-visible {
    transform: translateY(-2px);
    border-color: #c7cdd5;
    box-shadow: 0 5px 14px rgba(31, 41, 55, .1);
}

.article-page .share-button .fab,
.article-page .share-button .far {
    font-size: 18px;
}

.article-page .share-button.whatsapp .fab { color: #16a34a; }
.article-page .share-button.telegram .fab { color: #0ea5e9; }
.article-page .share-button.is-copied { color: #15803d; border-color: #86efac; background: #f0fdf4; }

.article-page .article-sidebar > .block {
    padding: 18px;
}

.article-page .last-contents {
    padding: 0;
}

.article-page .last-contents .title-group {
    margin: 0 0 14px;
}

.article-page .last-contents .title-group h2 {
    position: relative;
    margin: 0;
    padding: 0 12px 10px 0;
    color: var(--article-ink);
    font-size: 18px;
    font-weight: 800;
}

.article-page .last-contents .title-group h2::before {
    position: absolute;
    top: 5px;
    right: 0;
    width: 4px;
    height: 18px;
    border-radius: 4px;
    background: var(--article-accent);
    content: '';
}

.article-page .latest-articles-list {
    display: grid;
    gap: 12px;
}

.article-page .latest-article-card {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 11px;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--article-line);
}

.article-page .latest-article-card:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.article-page .latest-article-image {
    display: block;
    width: 82px;
    height: 68px;
    overflow: hidden;
    border-radius: 10px;
    background: #eef1f4;
}

.article-page .latest-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .25s ease;
}

.article-page .latest-article-card:hover .latest-article-image img {
    transform: scale(1.05);
}

.article-page .latest-article-info {
    min-width: 0;
}

.article-page .latest-article-info time {
    display: block;
    margin-bottom: 4px;
    color: #9ca3af;
    font-size: 10px;
}

.article-page .latest-article-info h3 {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.9;
}

.article-page .latest-article-info h3 a {
    color: #374151;
}

.article-page .latest-article-info h3 a:hover {
    color: var(--article-accent);
}

.article-page .blog-detail > hr {
    margin: 30px 0;
    border-color: var(--article-line);
}

.article-page .article-comments {
    color: var(--article-ink);
}

.article-page .comments-heading {
    display: flex;
    gap: 16px;
    align-items: end;
    justify-content: space-between;
    margin-bottom: 18px;
}

.article-page .comments-eyebrow {
    color: var(--article-accent);
    font-size: 11px;
    font-weight: 800;
}

.article-page .comments-heading h2 {
    margin: 3px 0 0;
    padding: 0;
    color: var(--article-ink);
    font-size: 22px;
    font-weight: 800;
}

.article-page .comments-heading h2 span {
    display: inline-grid;
    width: 28px;
    height: 28px;
    margin-right: 5px;
    place-items: center;
    border-radius: 50%;
    background: #fff0f4;
    color: var(--article-accent);
    font-size: 12px;
}

.article-page .comments-heading > p {
    margin: 0;
    color: var(--article-muted);
    font-size: 12px;
}

.article-page .comments-list {
    margin-bottom: 24px;
}

.article-page .comments-empty {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 18px;
    border: 1px dashed #d8dde4;
    border-radius: 12px;
    background: #fafbfc;
    color: var(--article-muted);
}

.article-page .comments-empty .far {
    color: var(--article-accent);
    font-size: 22px;
}

.article-page .comments-empty p {
    margin: 0;
}

.article-page .CommentItems {
    width: 100%;
    margin: 0 0 14px;
    padding: 16px;
    border: 1px solid var(--article-line);
    border-radius: 14px;
    background: #fff;
    font-size: 13px;
}

.article-page .CommentItems.reply {
    width: calc(100% - 42px);
    margin: 14px 42px 0 0;
    border-right: 3px solid #fecdd8;
    background: #fcfcfd;
}

.article-page .comment-meta {
    display: flex;
    gap: 10px;
    align-items: center;
}

.article-page .comment-avatar {
    display: grid;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 12px;
    background: #fff0f4;
    color: var(--article-accent);
    font-size: 15px;
    font-weight: 800;
}

.article-page .comment-meta .name,
.article-page .comment-meta .date {
    display: block;
    float: none;
    padding: 0;
}

.article-page .comment-meta .name {
    color: var(--article-ink);
    font-size: 13px;
}

.article-page .comment-meta .date {
    margin-top: 2px;
    color: #9ca3af;
    font-size: 10px;
}

.article-page .reply-button {
    margin-right: auto;
    padding: 6px 10px;
    border: 0;
    border-radius: 8px;
    background: #f3f4f6;
    color: #4b5563;
    font: inherit;
    font-size: 11px;
    cursor: pointer;
}

.article-page .CommentItems .CMText {
    width: 100%;
    margin: 12px 0 0;
    padding: 0;
    color: #4b5563;
    font-size: 13px;
    line-height: 2;
}

.article-page .comment-form-card {
    padding: clamp(18px, 3vw, 28px);
    border: 1px solid var(--article-line);
    border-radius: 16px;
    background: var(--article-soft);
}

.article-page .comment-form-heading {
    margin-bottom: 18px;
}

.article-page .comment-form-heading h3 {
    margin: 0 0 5px;
    padding: 0;
    color: var(--article-ink);
    font-size: 19px;
    font-weight: 800;
}

.article-page .comment-form-heading p,
.article-page .comment-form-footer p {
    margin: 0;
    color: var(--article-muted);
    font-size: 11px;
}

.article-page .comment-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.article-page .field {
    display: block;
    margin: 0;
}

.article-page .field-wide {
    grid-column: 1 / -1;
}

.article-page .field > span,
.article-page .captcha-row > label {
    display: block;
    margin-bottom: 7px;
    color: #374151;
    font-size: 12px;
    font-weight: 700;
}

.article-page .field small {
    color: #9ca3af;
    font-size: 10px;
    font-weight: 400;
}

.article-page .field input,
.article-page .field textarea,
.article-page .captcha-row input {
    width: 100%;
    max-width: none;
    padding: 11px 12px;
    border: 1px solid #d8dde4;
    border-radius: 10px;
    outline: 0;
    background: #fff;
    color: var(--article-ink);
    font: inherit;
    font-size: 13px;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.article-page .field textarea {
    min-height: 130px;
    resize: vertical;
}

.article-page .field input:focus,
.article-page .field textarea:focus,
.article-page .captcha-row input:focus {
    border-color: var(--article-accent);
    box-shadow: 0 0 0 3px rgba(245, 0, 61, .1);
}

.article-page .captcha-row {
    display: grid;
    grid-template-columns: auto 120px 90px auto;
    gap: 10px;
    align-items: center;
    margin-top: 16px;
}

.article-page .captcha-row > label {
    margin: 0;
}

.article-page .captcha-row img {
    position: static;
    width: 120px;
    height: 42px;
    margin: 0;
    border: 1px solid #d8dde4;
    border-radius: 9px;
    object-fit: contain;
    background: #fff;
}

.article-page .captcha-row input {
    height: 42px;
    text-align: center;
}

.article-page .captcha-refresh {
    justify-self: start;
    padding: 7px 9px;
    border: 0;
    background: transparent;
    color: #0284c7;
    font: inherit;
    font-size: 11px;
    cursor: pointer;
}

.article-page .comment-notify {
    display: flex;
    gap: 9px;
    align-items: flex-start;
    margin: 18px 0;
    color: #4b5563;
    font-size: 12px;
    cursor: pointer;
}

.article-page .comment-notify input {
    margin-top: 3px;
    accent-color: var(--article-accent);
}

.article-page .comment-form-footer {
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--article-line);
}

.article-page .comment-submit {
    min-width: 128px;
    padding: 11px 18px;
    border: 0;
    border-radius: 10px;
    background: var(--article-accent);
    color: #fff;
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.article-page .comment-submit:hover,
.article-page .comment-submit:focus-visible {
    transform: translateY(-1px);
    background: var(--article-accent-dark);
}

.article-page .comment_success {
    width: 100%;
    margin: 0 0 15px;
    padding: 10px 12px;
    border: 1px solid #86efac;
    border-radius: 10px;
    background: #f0fdf4;
    color: #166534;
    line-height: 1.8;
}

.article-page a:focus-visible,
.article-page button:focus-visible,
.article-page input:focus-visible,
.article-page textarea:focus-visible {
    outline: 2px solid var(--article-accent);
    outline-offset: 2px;
}

@media (max-width: 767px) {
    .article-page .article-layout {
        display: block;
    }

    .article-page .article-content,
    .article-page .article-sidebar {
        width: 100%;
        float: none;
    }

    .article-page .blog-detail {
        padding: 16px;
        border-radius: 14px;
    }

    .article-page .article-title {
        font-size: 20px;
        line-height: 1.75;
    }

    .article-page .blog-attr .separator {
        display: none;
    }

    .article-page .desc {
        font-size: 14px;
        line-height: 2.05;
    }

    .article-page .desc img {
        margin: 18px auto !important;
        border-radius: 10px;
    }

    .article-page .share-post {
        align-items: stretch;
        padding: 13px;
    }

    .article-page .share-label {
        width: 100%;
    }

    .article-page .share-actions {
        display: grid;
        width: 100%;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .article-page .share-button {
        width: 100%;
        justify-content: center;
        padding: 8px 6px;
    }

    .article-page .article-sidebar {
        margin-top: 18px;
    }

    .article-page .latest-articles-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .article-page .latest-article-card {
        display: block;
        padding: 0;
        overflow: hidden;
        border: 1px solid var(--article-line);
        border-radius: 12px;
    }

    .article-page .latest-article-image {
        width: 100%;
        height: 105px;
        border-radius: 0;
    }

    .article-page .latest-article-info {
        padding: 10px;
    }

    .article-page .comments-heading {
        display: block;
    }

    .article-page .comments-heading > p {
        margin-top: 7px;
    }

    .article-page .comment-fields {
        grid-template-columns: 1fr;
    }

    .article-page .captcha-row {
        grid-template-columns: 120px minmax(80px, 1fr);
    }

    .article-page .captcha-row > label {
        grid-column: 1 / -1;
    }

    .article-page .captcha-refresh {
        grid-column: 1 / -1;
    }

    .article-page .comment-form-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .article-page .comment-submit {
        width: 100%;
    }

    .article-page .CommentItems.reply {
        width: calc(100% - 20px);
        margin-right: 20px;
    }
}

@media (max-width: 420px) {
    .article-page .share-button span:last-child {
        font-size: 10px;
    }

    .article-page .latest-articles-list {
        grid-template-columns: 1fr;
    }

    .article-page .latest-article-card {
        display: grid;
        grid-template-columns: 88px minmax(0, 1fr);
    }

    .article-page .latest-article-image {
        width: 88px;
        height: 78px;
    }
}
