.category-pillar {
    color: #2b2b2b;
    font-size: 16px;
    line-height: 1.6;
}

.category-pillar > h1 {
    margin: 0 0 10px;
    color: #357c03;
    text-align: center;
    font-size: 20px;
    line-height: 1.25;
    text-transform: uppercase;
}

.category-pillar-content h2,
.single-entry-content h2 {
    margin: 28px 0 12px;
    color: #101010;
    font-size: 25px;
    line-height: 1.35;
}

.category-pillar-content h3,
.single-entry-content h3 {
    margin: 22px 0 10px;
    color: #151515;
    font-size: 20px;
    line-height: 1.4;
}

.category-pillar-content p,
.single-entry-content p {
    margin: 0 0 16px;
}

.category-pillar-content ul,
.category-pillar-content ol,
.single-entry-content ul,
.single-entry-content ol {
    margin: 0 0 18px 22px;
}

.category-pillar-content a,
.single-entry-content a {
    color: #357c03;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.category-pillar-content img,
.single-entry-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 22px auto;
}

.yg88-article-visual {
    width: min(800px, 100%);
    margin: 26px auto 32px;
}

.yg88-article-visual img {
    width: 100%;
    margin: 0 auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.yg88-article-visual figcaption {
    padding: 6px 10px;
    color: #777;
    font-size: 13px;
    font-style: italic;
    text-align: center;
}

.category-stream-title {
    margin: 38px 0 24px;
    border-top: 1px solid #e5e5e5;
    text-align: center;
}

.category-stream-title span {
    display: inline-block;
    margin-top: -15px;
    padding: 3px 18px;
    background: #fff;
    color: #357c03;
    font-size: 18px;
    font-weight: 800;
    text-transform: uppercase;
}

.source-category-sidebar {
    position: sticky;
    top: 78px;
}

.single-entry-header h1 {
    max-width: 724.5px;
    margin: 0 auto 12px;
    color: #0a0a0a;
    text-align: center;
    font-size: 28px;
    line-height: 1.3;
    font-weight: 900;
}

.single-featured-image {
    margin-top: 24px;
    aspect-ratio: 1020 / 556;
    overflow: hidden;
}

.single-featured-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-toc {
    margin: 28px 0;
    padding: 20px 24px;
    border: 1px solid #d8d8d8;
    background: #f7f7f7;
}

.article-toc-title {
    margin-bottom: 10px;
    color: #555;
    text-align: center;
    font-size: 19px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.article-toc ol {
    margin: 0;
    padding-left: 22px;
}

.article-toc li {
    margin: 6px 0;
}

.article-toc .toc-level-3 {
    margin-left: 22px;
    font-size: 14px;
}

.article-toc a {
    color: #357c03;
}

.single-entry-content {
    color: #2b2b2b;
    font-size: 16px;
    line-height: 1.65;
}

.single-entry-content h2,
.single-entry-content h3 {
    scroll-margin-top: 86px;
}

.single-entry-footer {
    margin-top: 34px;
    padding: 14px 0;
    border-top: 1px solid #e5e5e5;
    border-bottom: 1px solid #e5e5e5;
    text-align: center;
    font-size: 12px;
}

.single-entry-footer a {
    color: #357c03;
}

.article-author-box {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 20px;
    align-items: start;
    padding: 28px 0;
}

.article-author-avatar img {
    display: block;
    border-radius: 50%;
}

.article-author-box h3 {
    margin: 4px 0 8px;
    font-size: 16px;
    text-transform: uppercase;
}

.article-author-box p {
    margin: 0;
    color: #676767;
    font-size: 13px;
}

.single-post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding: 18px 0;
    border-top: 1px solid #e5e5e5;
    border-bottom: 1px solid #e5e5e5;
    font-size: 13px;
}

.single-post-navigation div:last-child {
    text-align: right;
}

.related-posts {
    margin-top: 36px;
}

.related-posts > h2 {
    color: #357c03;
    text-align: center;
    font-size: 22px;
    text-transform: uppercase;
}

.related-post-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.related-post-card {
    border: 1px solid #e5e5e5;
    background: #fff;
}

.related-post-card img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.related-post-card div {
    padding: 10px;
}

.related-post-card small {
    color: #777;
    font-size: 10px;
}

.related-post-card h3 {
    margin: 4px 0 0;
    font-size: 14px;
    line-height: 1.4;
}

@media (max-width: 860px) {
    .source-category-sidebar {
        position: static;
    }
}

@media (max-width: 560px) {
    .single-entry-header h1 {
        font-size: 24px;
    }

    .category-pillar-content h2,
    .single-entry-content h2 {
        font-size: 22px;
    }

    .related-post-grid {
        grid-template-columns: 1fr;
    }
}

/* KE789 reference editorial layout: archive description, 3-column cards, sidebar and article hierarchy. */
.ke789-archive-header {
    margin: 0 0 34px;
    color: #222;
    font-size: 15px;
    line-height: 1.75;
}

.ke789-archive-header h1 {
    margin: 0 0 20px;
    color: #7a0000;
    font: 700 22px/1.35 Montserrat, Arial, sans-serif;
    text-align: center;
    text-transform: uppercase;
}

.ke789-archive-header .category-pillar-content p {
    margin: 0 0 18px;
}

.ke789-archive-header .category-pillar-content a,
.single-entry-content a {
    color: #c00000;
}

.ke789-archive-header .category-pillar-content a.ke789-context-link,
.single-entry-content a.ke789-context-link {
    color: #138b22;
    font-weight: 700;
    font-style: italic;
    text-decoration: none;
}

.ke789-archive-header .category-pillar-content a.ke789-context-link:hover,
.single-entry-content a.ke789-context-link:hover {
    color: #0b6415;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ke789-lead-emphasis {
    font-style: italic;
}

.ke789-reference-archive-layout {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(240px, 1fr);
    gap: 30px;
    align-items: start;
}

.ke789-reference-archive-main {
    min-width: 0;
}

.ke789-archive-grid,
.related-post-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 44px 24px;
}

.ke789-post-card {
    position: relative;
    min-width: 0;
}

.ke789-card-image {
    display: block;
    overflow: hidden;
    background: #eee;
}

.ke789-card-image img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.ke789-date-badge {
    position: absolute;
    top: 26px;
    left: -7px;
    width: 54px;
    height: 62px;
    border: 2px solid #8c0000;
    background: #fff;
    color: #8c0000;
    text-align: center;
    font-weight: 800;
    line-height: 1;
}

.ke789-date-badge span,
.ke789-date-badge small {
    display: block;
}

.ke789-date-badge span {
    padding-top: 10px;
    font-size: 20px;
}

.ke789-date-badge small {
    padding-top: 6px;
    font-size: 12px;
}

.ke789-post-copy {
    padding-top: 16px;
    text-align: left;
}

.ke789-post-category {
    display: inline-block;
    margin-bottom: 5px;
    color: #d00000;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.ke789-post-copy h2,
.ke789-post-copy h3 {
    min-height: 70px;
    margin: 0;
    color: #760000;
    font: 700 17px/1.38 Montserrat, Arial, sans-serif;
    text-align: left;
    text-transform: none;
}

.ke789-post-copy h2 a,
.ke789-post-copy h3 a {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.ke789-post-divider {
    width: 34px;
    height: 3px;
    margin: 13px 0;
    background: #e4e4e4;
}

.ke789-post-copy p {
    margin: 0;
    color: #252525;
    font-size: 14px;
    line-height: 1.65;
}

.ke789-archive-sidebar {
    position: static;
    min-width: 0;
    padding-left: 28px;
    border-left: 1px solid #e6e6e6;
}

.ke789-archive-widget {
    margin: 0 0 36px;
}

.ke789-archive-widget > h2 {
    margin: 0 0 22px;
    padding: 0 0 14px;
    border-bottom: 3px solid #e1e1e1;
    color: #090909;
    font: 700 20px/1.25 Montserrat, Arial, sans-serif;
    text-transform: uppercase;
}

.ke789-archive-search {
    display: grid;
    grid-template-columns: 1fr auto;
}

.ke789-archive-search input {
    min-width: 0;
    height: 46px;
    padding: 0 14px;
    border: 1px solid #d8d8d8;
    border-right: 0;
    font: 400 14px Montserrat, Arial, sans-serif;
}

.ke789-archive-search button {
    height: 46px;
    padding: 0 15px;
    border: 1px solid #a40000;
    background: #a40000;
    color: #fff;
    font-weight: 700;
}

.ke789-recent-widget ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.ke789-recent-widget li {
    display: grid;
    grid-template-columns: 58px 1fr;
    gap: 12px;
    padding: 13px 0;
    border-bottom: 1px solid #eee;
}

.ke789-recent-thumb,
.ke789-recent-thumb img {
    display: block;
    width: 58px;
    height: 58px;
    object-fit: cover;
    overflow: hidden;
}

.ke789-recent-title {
    display: -webkit-box;
    overflow: hidden;
    color: #a50000 !important;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none !important;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.ke789-recent-widget time {
    display: block;
    margin-top: 5px;
    color: #888;
    font-size: 11px;
}

.entry-single {
    max-width: 1140px;
    margin: 0 auto;
}

.single-source-page .breadcrumb {
    display: flex;
    gap: 8px;
    margin: 0 0 24px;
    color: #777;
    text-align: left;
    font-size: 13px;
    white-space: nowrap;
}

.single-source-page .breadcrumb a {
    color: #b00000;
}

.single-entry-header h1 {
    max-width: none;
    margin: 0 0 12px;
    color: #f00000;
    text-align: left;
    font: 700 25px/1.3 Montserrat, Arial, sans-serif;
    text-transform: none;
}

.single-entry-header .source-entry-meta {
    display: flex;
    gap: 9px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 24px;
    color: #777;
    text-align: left;
    font-size: 13px;
    line-height: 1.4;
    text-transform: none;
}

.single-entry-header .source-entry-meta a {
    color: #9a0000;
    font-weight: 700;
}

.single-featured-image {
    width: min(840px, 100%);
    margin: 0 auto 28px;
    aspect-ratio: 16 / 9;
}

.article-toc {
    max-width: 840px;
    margin: 0 auto 28px;
    padding: 20px 24px;
    border: 1px solid #e5d4d4;
    background: #fff9f8;
}

.article-toc h2.article-toc-title {
    margin: 0 0 12px;
    color: #720000;
    text-align: left;
    font-size: 19px;
    letter-spacing: 0;
    text-transform: none;
}

.article-toc a {
    color: #5b1d1d;
}

.single-entry-content {
    color: #222;
    font-size: 16px;
    line-height: 1.75;
}

.single-entry-content h2 {
    color: #a30c0c;
    font: 700 22px/1.3 Montserrat, Arial, sans-serif;
}

.single-entry-content h3 {
    color: #a30c0c;
    font: 700 17px/1.3 Montserrat, Arial, sans-serif;
}

.single-entry-content table {
    width: 100%;
    margin: 0 0 24px;
    border-collapse: collapse;
}

.single-entry-content th,
.single-entry-content td {
    padding: 10px 12px;
    border: 1px solid #e2d7d7;
    text-align: left;
}

.single-entry-content th {
    background: #fff5f4;
    color: #750000;
}

.entry-tags {
    margin-top: 30px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.entry-tags a {
    display: inline-block;
    margin: 3px;
    padding: 3px 9px;
    border-radius: 3px;
    background: #f2f2f2;
    color: #900;
    font-size: 13px;
}

.single-post-navigation {
    max-width: 900px;
    margin: 35px auto;
    padding: 20px 0;
}

.single-post-navigation a {
    color: #900;
    font-weight: 700;
}

.related-posts {
    max-width: 1100px;
    margin: 35px auto 0;
}

.related-posts > h2 {
    color: #760000;
}

.related-post-grid {
    gap: 30px;
}

.related-post-grid .ke789-post-copy h3 {
    min-height: 70px;
}

@media (max-width: 860px) {
    .ke789-reference-archive-layout {
        grid-template-columns: 1fr;
    }

    .ke789-archive-sidebar {
        padding: 28px 0 0;
        border-top: 1px solid #e6e6e6;
        border-left: 0;
    }
}

@media (max-width: 760px) {
    .ke789-archive-header {
        margin-bottom: 25px;
        font-size: 14px;
        line-height: 1.7;
    }

    .ke789-archive-header h1 {
        margin-bottom: 18px;
        padding: 16px 6px;
        font-size: 20px;
    }

    .ke789-archive-grid,
    .related-post-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .ke789-post-copy h2,
    .ke789-post-copy h3,
    .related-post-grid .ke789-post-copy h3 {
        min-height: 0;
        font-size: 18px;
    }

    .single-source-page .breadcrumb {
        overflow: hidden;
    }

    .single-source-page .breadcrumb > span:last-child {
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .single-entry-header h1 {
        padding: 16px 0;
        font-size: 21px;
    }

    .single-featured-image {
        width: calc(100% + 28px);
        max-width: none;
        margin-left: -14px;
    }

    .article-toc {
        padding: 17px 16px;
    }
}
