/* ============================================================
   HOME PAGE — NEWS FEED BLOCK (home-news-*)
   ============================================================ */
.home-news-block { margin-bottom: 24px; }

.home-news-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--dh-border);
}
html.dark-mode .home-news-header { border-color: #253140; }

.home-news-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}
.home-news-header-icon { font-size: 16px; color: var(--dh-accent); }
.home-news-header-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--dh-text);
}
.home-news-header-more {
    font-size: 12px;
    font-weight: 600;
    color: var(--dh-accent) !important;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color .15s;
}
.home-news-header-more:hover { color: var(--dh-accent-hover) !important; }

.home-news-feed { display: flex; flex-direction: column; }

.home-news-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    border-radius: 6px;
    border-bottom: 1px solid var(--dh-border);
    text-decoration: none !important;
    color: var(--dh-text) !important;
    transition: background .15s;
}
.home-news-item:last-child { border-bottom: none; }
.home-news-item:hover { background: var(--dh-bg-secondary); }
html.dark-mode .home-news-item { border-color: #1e2a3a; }
html.dark-mode .home-news-item:hover { background: #1a2230; }

.home-news-item-badge {
    display: inline-block;
    padding: 1px 7px;
    border: 1px solid var(--dh-accent);
    border-radius: 3px;
    font-size: 10px;
    font-weight: 700;
    color: var(--dh-accent);
    text-transform: uppercase;
    letter-spacing: .3px;
    white-space: nowrap;
    flex-shrink: 0;
    line-height: 1.6;
}
.home-news-item-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--dh-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: color .15s;
}
.home-news-item:hover .home-news-item-title { color: var(--dh-accent); }
.home-news-item-date {
    font-size: 11px;
    color: var(--dh-text-muted);
    white-space: nowrap;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.home-news-empty {
    padding: 20px 10px;
    color: var(--dh-text-muted);
    font-size: 13px;
    text-align: center;
}

/* ============================================================
   NEWS PAGE — HEADER (news-page-header)
   ============================================================ */
.news-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    padding-bottom: 18px;
    border-bottom: 2px solid var(--dh-border);
    gap: 16px;
    flex-wrap: wrap;
}
html.dark-mode .news-page-header { border-color: #253140; }

.news-page-header-left { flex: 1; }
.news-page-header-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--dh-text);
    margin-bottom: 4px;
}
.news-page-header-sub { font-size: 13px; color: var(--dh-text-muted); }
.news-page-header-count {
    background: var(--dh-bg-card);
    border: 1px solid var(--dh-border);
    border-radius: 8px;
    padding: 10px 18px;
    text-align: center;
    flex-shrink: 0;
    min-width: 72px;
}
html.dark-mode .news-page-header-count { background: #161d27; border-color: #253140; }
.news-page-header-count span {
    display: block;
    font-size: 26px;
    font-weight: 700;
    color: var(--dh-accent);
    line-height: 1.15;
}

/* ============================================================
   NEWS PAGE — CARD LIST (news-list, news-card)
   ============================================================ */
.news-list { display: flex; flex-direction: column; gap: 16px; }

.news-card {
    background: var(--dh-bg-card);
    border: 1px solid var(--dh-border);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color .2s, transform .15s, box-shadow .2s;
    position: relative;
}
.news-card:hover {
    border-color: var(--dh-accent);
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(0,0,0,.10);
}
html.dark-mode .news-card { background: #161d27; border-color: #253140; }
html.dark-mode .news-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,.40); }

.news-card-inner { display: flex; align-items: stretch; }

.news-card-num {
    flex-shrink: 0;
    width: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 900;
    color: var(--dh-border);
    background: var(--dh-bg-secondary);
    border-right: 1px solid var(--dh-border);
    font-variant-numeric: tabular-nums;
    letter-spacing: -1px;
    user-select: none;
}
html.dark-mode .news-card-num { background: #10161e; border-color: #253140; color: #2a3540; }

.news-card-content { flex: 1; padding: 16px 20px; min-width: 0; }
.news-card-header  { margin-bottom: 6px; }

.news-card-title {
    font-size: 17px;
    font-weight: 700;
    margin: 0 0 6px 0;
    color: var(--dh-text);
    line-height: 1.35;
}
.news-card-title a { color: inherit !important; text-decoration: none !important; transition: color .15s; }
.news-card-title a:hover { color: var(--dh-accent) !important; }

.news-card-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.news-meta-item { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--dh-text-muted); }
.news-meta-sep { color: var(--dh-border); font-size: 13px; }
html.dark-mode .news-meta-sep { color: #2a3540; }

.news-card-body {
    font-size: 13px;
    color: var(--dh-text-muted);
    line-height: 1.6;
    margin-top: 10px;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.news-card-footer { margin-top: 12px; }

.news-readmore {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: var(--dh-accent) !important;
    text-decoration: none !important;
    padding: 5px 12px;
    border: 1px solid var(--dh-accent);
    border-radius: 4px;
    background: transparent;
    transition: background .2s, color .2s;
}
.news-readmore:hover { background: var(--dh-accent); color: #fff !important; }

/* Invisible full-card link for compact cards */
.news-card-link-cover { position: absolute; inset: 0; z-index: 1; }

/* ============================================================
   NEWS SINGLE ARTICLE (news-single)
   ============================================================ */
.news-single {
    background: var(--dh-bg-card);
    border: 1px solid var(--dh-border);
    border-radius: 10px;
    overflow: hidden;
}
html.dark-mode .news-single { background: #161d27; border-color: #253140; }

.news-single-header {
    padding: 28px 32px 24px;
    border-bottom: 1px solid var(--dh-border);
    background: var(--dh-bg-secondary);
}
html.dark-mode .news-single-header { background: #10161e; border-color: #253140; }

.news-single-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    background: rgba(63,101,136,.12);
    color: var(--dh-accent);
    border: 1px solid rgba(63,101,136,.25);
    margin-bottom: 14px;
}
html.dark-mode .news-single-badge { background: rgba(74,122,170,.15); border-color: rgba(74,122,170,.3); }

.news-single-title {
    font-size: 26px;
    font-weight: 700;
    color: var(--dh-text);
    margin: 0 0 16px 0;
    line-height: 1.3;
}
.news-single-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.news-single-body {
    padding: 28px 32px;
    font-size: 15px;
    color: var(--dh-text);
    line-height: 1.75;
}
.news-single-body p { margin-bottom: 16px; }
.news-single-body h1,
.news-single-body h2,
.news-single-body h3 { color: var(--dh-text); margin-top: 24px; margin-bottom: 10px; }
.news-single-body img { max-width: 100%; border-radius: 6px; margin: 10px 0; }
.news-single-body a  { color: var(--dh-accent); }
.news-single-body blockquote {
    border-left: 3px solid var(--dh-accent);
    padding: 8px 0 8px 16px;
    color: var(--dh-text-muted);
    margin: 16px 0;
    font-style: italic;
    background: var(--dh-bg-secondary);
    border-radius: 0 4px 4px 0;
}
html.dark-mode .news-single-body blockquote { background: #10161e; }

.news-single-footer {
    padding: 16px 32px;
    border-top: 1px solid var(--dh-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    background: var(--dh-bg-secondary);
}
html.dark-mode .news-single-footer { background: #10161e; border-color: #253140; }

.news-single-published { font-size: 13px; color: var(--dh-text-muted); font-style: italic; }

.news-back-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    font-weight: 600;
    color: var(--dh-accent) !important;
    text-decoration: none !important;
    padding: 6px 14px;
    border: 1px solid var(--dh-accent);
    border-radius: 4px;
    background: transparent;
    transition: background .2s, color .2s;
}
.news-back-link:hover { background: var(--dh-accent); color: #fff !important; }

/* ============================================================
   PAGE TITLE (shared)
   ============================================================ */
.page-title {
    color: var(--dh-accent);
    font-size: 28px;
    margin-bottom: 10px;
    font-weight: 700;
}
html.dark-mode .page-title { color: var(--dh-gold-light); }

/* ============================================================
   LEGACY / FALLBACK
   ============================================================ */
.panel-news {
    margin-bottom: 30px;
    color: var(--dh-text);
    border: 0; border-radius: 0; box-shadow: none; background: transparent;
}
.panel-news .panel-heading { padding: 10px 0; background: transparent; border: 0; }
.panel-news .panel-title   { color: var(--dh-text); font-size: 24px; font-weight: 700; }
.panel-news .panel-body    { padding: 10px; }
.panel-news .panel-footer  {
    border-top: 1px solid var(--dh-border);
    background: var(--dh-bg);
    font-style: italic; font-size: 11px; height: 40px;
    color: var(--dh-text-muted);
}
html.dark-mode .panel-news .panel-footer { background: var(--dh-bg-card); border-color: var(--dh-border); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 767px) {
    .news-single-header,
    .news-single-body,
    .news-single-footer  { padding-left: 18px; padding-right: 18px; }
    .news-single-title   { font-size: 20px; }
    .news-page-header    { flex-direction: column; align-items: flex-start; }
    .news-card-num       { width: 40px; font-size: 16px; }
    .home-news-item      { grid-template-columns: auto 1fr; }
    .home-news-item-date { display: none; }
}
