/* News Harvester — Coalfield industrial single-news styling */
/* All selectors are namespaced .nhx-* so they won't collide with the theme. */

.nhx-container{
    --nhx-aside-w: 300px;
    --nhx-gap: 42px;
    --nhx-sticky-top: 96px;
    --nhx-bg: #0a1422;
    --nhx-panel: #111827;
    --nhx-panel-2: #16202e;
    --nhx-panel-3: #212a39;
    --nhx-ink: #d9e3f7;
    --nhx-strong: #ffffff;
    --nhx-muted: #dbc2b0;
    --nhx-line: #1E293B;
    --nhx-line-2: #334155;
    --nhx-accent: #D97706;
    --nhx-accent-hi: #ffb77d;
    --nhx-radius: 8px;
    max-width: 1220px;
    margin: 0 auto;
    padding: 34px 24px 72px;
    box-sizing: border-box;
    color: var(--nhx-ink);
}
.nhx-container *{ box-sizing: border-box; }

.nhx-breadcrumb{
    font: 700 12px/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--nhx-muted);
    margin: 0 0 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    align-items: center;
}
.nhx-breadcrumb a{ color: var(--nhx-muted); text-decoration: none; }
.nhx-breadcrumb a:hover{ color: var(--nhx-accent-hi); }
.nhx-breadcrumb .nhx-sep{ color: var(--nhx-line-2); }
.nhx-breadcrumb .nhx-current{ color: var(--nhx-ink); }

.nhx-layout{ display: grid; gap: var(--nhx-gap); align-items: start; }
.nhx-pos-left .nhx-layout{ grid-template-columns: var(--nhx-aside-w) minmax(0, 1fr); grid-template-areas: "aside article"; }
.nhx-pos-right .nhx-layout{ grid-template-columns: minmax(0, 1fr) var(--nhx-aside-w); grid-template-areas: "article aside"; }
.nhx-layout.nhx-no-aside{ grid-template-columns: minmax(0,1fr); grid-template-areas: "article"; }

.nhx-aside{
    grid-area: aside;
    position: sticky;
    top: var(--nhx-sticky-top);
    align-self: start;
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: calc(100vh - var(--nhx-sticky-top) - 20px);
}
.nhx-article{
    grid-area: article;
    min-width: 0;
    border: 1px solid var(--nhx-line);
    border-radius: 12px;
    background:
        linear-gradient(180deg, rgba(217,119,6,.06), transparent 220px),
        var(--nhx-panel);
    padding: clamp(22px, 3vw, 42px);
}

.nhx-title{
    font-size: clamp(2rem, 3.35vw, 3.15rem);
    line-height: 1.08;
    margin: 0 0 16px;
    color: var(--nhx-strong);
    font-weight: 800;
    letter-spacing: -.025em;
}
.nhx-meta{
    font: 700 12px/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    text-transform: uppercase;
    letter-spacing:.1em;
    color: var(--nhx-muted);
    display: flex;
    gap: 9px;
    align-items: center;
    flex-wrap: wrap;
}
.nhx-meta .nhx-dot{ color: var(--nhx-line-2); }

.nhx-share{
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 18px 0 8px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--nhx-line);
    position: relative;
}
.nhx-share-btn{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 4px;
    border: 1px solid var(--nhx-line-2);
    color: var(--nhx-ink);
    background: rgba(10,20,34,.72);
    cursor: pointer;
    transition: color .15s, border-color .15s, transform .15s, background .15s;
    text-decoration: none;
    padding: 0;
}
.nhx-share-btn:hover{
    color: var(--nhx-accent-hi);
    border-color: var(--nhx-accent);
    background: rgba(217,119,6,.10);
    transform: translateY(-1px);
}
.nhx-copied{ font-size: 12px; color: #22C55E; margin-left: 4px; }

.nhx-feat{ margin: 26px 0; }
.nhx-feat img{
    width: 100%; height: auto;
    border-radius: var(--nhx-radius);
    border: 1px solid var(--nhx-line);
    display: block;
    filter: saturate(.95) contrast(1.05) brightness(.9);
}

.nhx-content{
    font-size: 1.065rem;
    line-height: 1.78;
    color: var(--nhx-ink);
}
.nhx-content > *{ margin: 0 0 1.12em; }
.nhx-content h2,.nhx-content h3,.nhx-content h4,.nhx-content h5{
    color: var(--nhx-strong);
    line-height: 1.25;
    margin: 1.75em 0 .55em;
    scroll-margin-top: var(--nhx-sticky-top);
    letter-spacing: -.01em;
}
.nhx-content h2{
    font-size: clamp(1.45rem, 2.1vw, 2rem);
    border-top: 1px solid var(--nhx-line);
    padding-top: 1.05em;
}
.nhx-content h3{ font-size: 1.28rem; }
.nhx-content h4{ font-size: 1.12rem; }
.nhx-content a{ color: var(--nhx-accent-hi); text-decoration: none; border-bottom:1px solid rgba(255,183,125,.35); }
.nhx-content a:hover{ color:#fff; border-bottom-color: var(--nhx-accent-hi); }
.nhx-content blockquote{
    border-left: 3px solid var(--nhx-accent);
    margin: 1.35em 0;
    padding: .45em 1.2em;
    color: var(--nhx-muted);
    background: rgba(217,119,6,.06);
}
.nhx-content img{ max-width: 100%; height: auto; }
.nhx-content ul,.nhx-content ol{ padding-left:1.25em; }
.nhx-content li + li{ margin-top:.35em; }

.nhx-content table{
    width:100%;
    border-collapse: collapse;
    margin:1.4em 0;
    font-size:.95rem;
    border:1px solid var(--nhx-line);
}
.nhx-content th{
    background: var(--nhx-panel-3);
    color:#fff;
    text-align:left;
    font:700 12px/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    text-transform:uppercase;
    letter-spacing:.08em;
    padding:12px 14px;
    border-bottom:1px solid var(--nhx-line-2);
}
.nhx-content td{
    padding:12px 14px;
    border-bottom:1px solid var(--nhx-line);
    color:var(--nhx-ink);
}
.nhx-content tr:nth-child(even) td{ background:rgba(255,255,255,.025); }

.nhx-content .nh-inline-image{ margin: 1.5em 0; }
.nh-inline-image img{
    width: 100%; height: auto;
    border-radius: 8px;
    border:1px solid var(--nhx-line);
    display: block;
}
.nh-inline-image figcaption{
    font-size: 13px;
    color: var(--nhx-muted);
    text-align: center;
    margin-top: 8px;
}

.nhx-article-tags{
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
    margin-top: 34px;
    padding-top: 20px;
    border-top: 1px solid var(--nhx-line);
}
.nhx-article-tags-label{
    font: 700 12px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    color: var(--nhx-muted);
    letter-spacing: .12em;
    text-transform: uppercase;
    margin-right: 4px;
}
.nhx-article-tag{
    display: inline-block;
    font-size: 13px;
    line-height: 1.2;
    padding: 7px 11px;
    border: 1px solid var(--nhx-line-2);
    border-radius: 4px;
    color: var(--nhx-ink);
    background: rgba(10,20,34,.65);
    text-decoration: none;
    transition: border-color .15s, color .15s, background .15s;
}
.nhx-article-tag:hover{ border-color: var(--nhx-accent); color: var(--nhx-accent-hi); }

.nhx-toc,
.nhx-related{
    border: 1px solid var(--nhx-line);
    border-radius: var(--nhx-radius);
    background:
        linear-gradient(135deg, rgba(217,119,6,.055), transparent 36%),
        var(--nhx-panel);
}
.nhx-toc{
    grid-area: toc;
    padding: 8px 5px;
    font-size: 14px;
    flex: 0 0 auto;
}
.nhx-toc-head{
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: none;
    border: 0;
    cursor: pointer;
    padding: 9px 12px;
    font: inherit;
    color: var(--nhx-strong);
}
.nhx-toc-title{
    font: 700 12px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    text-transform: uppercase;
    letter-spacing:.12em;
}
.nhx-toc-caret{
    width: 8px; height: 8px;
    border-right: 2px solid var(--nhx-muted);
    border-bottom: 2px solid var(--nhx-muted);
    transform: rotate(45deg);
    transition: transform .2s;
    margin-right: 4px;
}
.nhx-toc.is-collapsed .nhx-toc-caret{ transform: rotate(-45deg); }
.nhx-toc-list{ display: block; max-height: none; overflow: visible; }
.nhx-toc.is-collapsed .nhx-toc-list{ display: none; }
.nhx-toc-list a{
    display: block;
    padding: 6px 12px;
    color: var(--nhx-muted);
    text-decoration: none;
    border-left: 2px solid transparent;
    line-height: 1.4;
    transition: color .12s, border-color .12s, background .12s;
}
.nhx-toc-list a:hover{ color: var(--nhx-strong); background: rgba(255,255,255,.025); }
.nhx-toc-list a.is-active{ color: var(--nhx-accent-hi); border-left-color: var(--nhx-accent); font-weight: 700; }
.nhx-toc-list a.lvl-3{ padding-left: 26px; font-size: 13px; }
.nhx-toc-list a.lvl-4{ padding-left: 38px; font-size: 13px; }
.nhx-toc-list a.lvl-5{ padding-left: 50px; font-size: 12px; }

.nhx-related{
    grid-area: related;
    padding: 16px;
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}
.nhx-related-title{
    font: 700 12px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    text-transform: uppercase;
    letter-spacing:.12em;
    color: var(--nhx-strong);
    margin-bottom: 10px;
    flex: 0 0 auto;
}
.nhx-related-list{ list-style: none; margin: 0; padding: 0; overflow-y: auto; min-height: 0; }
.nhx-related-item{ margin: 0; }
.nhx-related-item + .nhx-related-item{ border-top: 1px solid var(--nhx-line); }
.nhx-related-item a{
    display: flex;
    gap: 11px;
    align-items: flex-start;
    padding: 11px 2px;
    text-decoration: none;
    color: var(--nhx-ink);
}
.nhx-related-thumb{ flex: 0 0 56px; }
.nhx-related-thumb img{
    width: 56px; height: 56px;
    object-fit: cover;
    border-radius: 6px;
    border:1px solid var(--nhx-line);
    display: block;
}
.nhx-related-text{ display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.nhx-related-headline{
    font-size: 13.5px;
    line-height: 1.4;
    color: var(--nhx-ink);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.nhx-related-item a:hover .nhx-related-headline{ color: var(--nhx-accent-hi); }
.nhx-related-date{ font-size: 12px; color: var(--nhx-muted); }

.nhx-toc-list::-webkit-scrollbar,
.nhx-related-list::-webkit-scrollbar{ width: 6px; }
.nhx-toc-list::-webkit-scrollbar-thumb,
.nhx-related-list::-webkit-scrollbar-thumb{ background: var(--nhx-line-2); border-radius: 3px; }

@media (max-width: 980px){
    .nhx-pos-left .nhx-layout,
    .nhx-pos-right .nhx-layout{
        grid-template-columns: 1fr;
        grid-template-areas:
            "toc"
            "article"
            "related";
        gap: 24px;
    }
    .nhx-aside{ display: contents; position: static; max-height: none; overflow: visible; }
    .nhx-toc{ position: sticky; top: 0; z-index: 20; margin: 0; }
    .nhx-toc-list{ max-height: 45vh; overflow-y: auto; }
    .nhx-toc.is-collapsed .nhx-toc-list{ display: none; }
    .nhx-related{ display: block; }
    .nhx-related-list{ max-height: none; overflow: visible; }
}
@media (max-width: 600px){
    .nhx-container{ padding: 20px 16px 48px; }
    .nhx-article{ padding:20px 16px; }
    .nhx-share-btn{ width: 38px; height: 38px; }
}
