.dv-news-page {
    --dv-bg: #f1f5f8;
    --dv-surface: #fff;
    --dv-soft: #edf4fa;
    --dv-text: #132337;
    --dv-muted: #526579;
    --dv-border: #dce5ed;
    --dv-accent: #1056a0;
    --dv-accent-hover: #0c427d;
    --dv-focus: #187aca;
    color-scheme: light;
    background: var(--dv-bg);
    color: var(--dv-text);
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.dv-news-page[data-news-theme="dark"] {
    --dv-bg: #111922;
    --dv-surface: #1b2734;
    --dv-soft: #233346;
    --dv-text: #e9f1fb;
    --dv-muted: #adbed1;
    --dv-border: #344659;
    --dv-accent: #82c5fc;
    --dv-accent-hover: #bee2fe;
    --dv-focus: #82c5fc;
    color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
    .dv-news-page:not([data-news-theme]) {
        --dv-bg: #111922;
        --dv-surface: #1b2734;
        --dv-soft: #233346;
        --dv-text: #e9f1fb;
        --dv-muted: #adbed1;
        --dv-border: #344659;
        --dv-accent: #82c5fc;
        --dv-accent-hover: #bee2fe;
        --dv-focus: #82c5fc;
        color-scheme: dark;
    }
}

.dv-news-page :is(.dv-page, .dv-masthead) :is(a, button, summary, input, select, textarea):focus-visible {
    outline: 2px solid var(--dv-focus);
    outline-offset: 3px;
}

.dv-news-page :is(.dv-page, .dv-masthead) a { color: var(--dv-accent); text-shadow: none; }
.dv-news-page :is(.dv-page, .dv-masthead) a:hover { color: var(--dv-accent-hover); }
.dv-news-page :is(.dv-page, .dv-masthead) a:focus-visible { text-decoration: underline; }

.dv-skip {
    position: fixed;
    top: 8px;
    left: 8px;
    z-index: 1200;
    padding: 10px 16px;
    border-radius: 8px;
    color: var(--dv-text);
    background: var(--dv-surface);
    transform: translateY(calc(-100% - 10px));
}
.dv-skip:focus { transform: none; }

.dv-masthead {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--dv-surface);
    border-bottom: 1px solid var(--dv-border);
}

.dv-masthead-inner {
    display: flex;
    align-items: center;
    gap: clamp(14px, 3vw, 46px);
    max-width: 1440px;
    min-height: 72px;
    margin-inline: auto;
    padding-inline: clamp(14px, 3vw, 44px);
}

.dv-brand { flex: 0 1 152px; min-width: 80px; }
.dv-brand img { display: block; width: 100%; max-width: 152px; height: auto; }

.dv-masthead-links { display: flex; gap: clamp(12px, 2vw, 26px); }
.dv-news-page .dv-masthead-links a {
    padding: 12px 0;
    color: var(--dv-muted);
    font-weight: 640;
}
.dv-news-page .dv-masthead-links .dv-current {
    color: var(--dv-accent);
    box-shadow: inset 0 -2px var(--dv-accent);
}

.dv-masthead-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.dv-masthead-actions :is(summary, button, .dv-account) {
    display: grid;
    place-items: center;
    min-width: 44px;
    min-height: 44px;
    border-radius: 10px;
    border: 1px solid var(--dv-border);
    background: var(--dv-soft);
    color: var(--dv-text);
    cursor: pointer;
}
.dv-news-page .dv-masthead-actions .dv-account { padding-inline: 11px; font-size: 14px; font-weight: 700; white-space: nowrap; }
.dv-masthead-actions button[hidden] { display: none; }
.dv-icon-theme { width: 16px; height: 16px; border: 1.5px solid currentColor; border-radius: 50%; background: linear-gradient(90deg, currentColor 50%, transparent 50%); }
.dv-head-details { position: relative; }
.dv-head-details summary { list-style: none; }
.dv-head-details summary::-webkit-details-marker { display: none; }
.dv-head-details[open] summary, .dv-theme-button[aria-pressed="true"] { border-color: var(--dv-accent); }
.dv-user-menu summary img { object-fit: cover; border-radius: 7px; }

.dv-icon-search, .dv-icon-menu, .dv-icon-comment { position: relative; display: inline-block; }
.dv-icon-search { width: 14px; height: 14px; margin: -2px 3px 0 0; border: 2px solid currentColor; border-radius: 50%; }
.dv-icon-search::after { content: ""; position: absolute; width: 7px; height: 2px; top: 10px; left: 9px; background: currentColor; transform: rotate(45deg); }
.dv-icon-menu { width: 17px; height: 2px; background: currentColor; box-shadow: 0 -5px currentColor, 0 5px currentColor; }
.dv-icon-comment { width: 13px; height: 10px; margin-right: 3px; border: 1.5px solid currentColor; border-radius: 4px; }
.dv-icon-comment::after { content: ""; position: absolute; bottom: -3px; left: 1px; width: 4px; height: 4px; background: var(--dv-surface); border: solid currentColor; border-width: 0 0 1px 1px; transform: skewY(-38deg); }

.dv-head-popover {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: min(320px, calc(100vw - 28px));
    max-height: min(68vh, 500px);
    overflow: auto;
    padding: 14px;
    border: 1px solid var(--dv-border);
    border-radius: 12px;
    background: var(--dv-surface);
    box-shadow: 0 12px 28px rgb(11 31 52 / 16%);
}

.dv-popover-menu { display: grid; }
.dv-popover-menu a { padding: 9px 10px; border-radius: 7px; }
.dv-popover-menu a:hover { background: var(--dv-soft); }
.dv-search { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
.dv-search label, .dv-search input { grid-column: 1 / -1; }
.dv-search label { margin: 0; }
.dv-search :is(input, select), #dle-comments-form textarea {
    min-width: 0;
    border: 1px solid var(--dv-border);
    border-radius: 8px;
    padding: 9px 10px;
    background: var(--dv-bg);
    color: var(--dv-text);
    font: inherit;
    font-size: 16px;
}

.dv-page {
    max-width: 1440px;
    min-height: 55vh;
    margin-inline: auto;
    padding: clamp(22px, 4vw, 50px) clamp(14px, 3vw, 44px) 48px;
}

.dv-page-ad, .dv-article-ad { display: flex; justify-content: center; flex-wrap: wrap; }
.dv-feed-layout, .dv-article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; align-items: start; }
.dv-feed h1, .dv-article h1 {
    margin: 0;
    color: var(--dv-text);
    font-family: inherit;
    font-weight: 780;
    letter-spacing: -.035em;
    line-height: 1.12;
}
.dv-news-page .dv-feed h1 { margin-bottom: 20px !important; font-size: clamp(29px, 3.2vw, 44px); }
.dv-news-grid { display: grid; gap: 16px; }
.dv-news-card, .dv-article, .dv-comments, .dv-technology {
    min-width: 0;
    border: 1px solid var(--dv-border);
    border-radius: 15px;
    background: var(--dv-surface);
}

.dv-news-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 15px;
    padding: 20px;
}
.dv-card-cover {
    display: grid;
    align-items: center;
    min-width: 0;
    min-height: 136px;
    overflow: hidden;
    border-radius: 9px;
    background: var(--dv-soft);
}
.dv-card-cover img {
    display: block;
    width: 100%;
    height: 100%;
    max-height: 180px;
    object-fit: contain;
}
.dv-card-main { display: flex; flex-direction: column; align-items: start; min-width: 0; }
.dv-news-page .dv-card-main h2 {
    margin: 5px 0 9px;
    font-family: inherit;
    font-size: clamp(17px, 1.35vw, 20px) !important;
    line-height: 1.3;
    font-weight: 740;
    letter-spacing: -.016em;
}
.dv-news-page .dv-card-main h2 a { color: var(--dv-text); font-size: inherit !important; }
.dv-news-page .dv-card-main h2 a:hover { color: var(--dv-accent); }
.dv-date { color: var(--dv-muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.dv-card-excerpt { color: var(--dv-muted); margin: 0 0 14px; font-size: 14px; }
.dv-card-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
    gap: 4px 14px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--dv-border);
}
.dv-card-actions a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; font-size: 14px; }
.dv-card-actions a:nth-child(2) { margin-left: auto; }

.dv-news-page :is(.dv-page, .dv-masthead) .dv-read {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 9px 14px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: #12579f;
    color: #fff;
    font: inherit;
    font-size: 14px;
    font-weight: 720;
    text-decoration: none;
    cursor: pointer;
}
.dv-news-page :is(.dv-page, .dv-masthead) .dv-read:hover { background: #0d477f; color: #fff; }
.dv-load-more {
    display: flex;
    justify-content: center;
    padding: 11px;
    margin-top: 18px;
    border: 1px solid var(--dv-border);
    border-radius: 10px;
    background: var(--dv-surface);
    font-weight: 680;
}
.dv-load-status { color: var(--dv-muted); text-align: center; }
.dv-load-status:empty { display: none; }

.dv-technology { padding: 19px; }
.dv-news-page .dv-technology h2, .dv-news-page .dv-comments h2 {
    margin: 0 0 13px;
    font-family: inherit;
    font-size: 18px !important;
    line-height: 1.3;
    font-weight: 750;
}
.dv-news-page .dv-technology h2 a { color: var(--dv-text); font-size: inherit !important; }
.dv-technology ul { margin: 0; padding: 0; list-style: none; }
.dv-news-item + .dv-news-item { border-top: 1px solid var(--dv-border); }
.dv-news-page .dv-news-item a {
    display: flex;
    gap: 11px;
    align-items: center;
    min-height: 46px;
    padding-block: 9px;
    color: var(--dv-text);
    font-size: 13px;
    line-height: 1.35;
}
.dv-news-item img { flex: 0 0 48px; object-fit: contain; border-radius: 7px; background: var(--dv-soft); }
.dv-news-item time { display: block; margin-top: 4px; color: var(--dv-muted); font-size: 12px; }

.dv-article-column { min-width: 0; }
.dv-article-layout { max-width: 1120px; margin-inline: auto; }
.dv-article-back { margin-bottom: 12px; }
.dv-news-page .dv-article-back a { color: var(--dv-accent) !important; display: inline-flex; align-items: center; min-height: 44px; font-weight: 650; }
.dv-article { padding: clamp(17px, 3.1vw, 44px); }
.dv-article h1 { max-width: 25ch; font-size: clamp(27px, 4.1vw, 50px); }
.dv-article-header { margin-bottom: 24px; }
.dv-article-meta, .dv-article-tools, .dv-comment-meta, .dv-comment-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 16px;
}
.dv-article-meta { margin-top: 10px; color: var(--dv-muted); font-size: 14px; }
.dv-article-meta a, .dv-article-tools a { display: inline-flex; align-items: center; min-height: 44px; }
.dv-article-cover { display: grid; place-items: center; margin: 0 0 26px; border-radius: 11px; background: var(--dv-soft); }
.dv-article-cover img { display: block; max-width: 100%; max-height: 440px; border-radius: inherit; object-fit: contain; }
.dv-article-body { font-size: clamp(16px, 1.5vw, 18px); line-height: 1.7; }
.dv-article-body a, .dv-comment-text a { text-decoration: underline; }
.dv-article-body :is(img, video), .dv-comment-text :is(img, video) { max-width: 100%; height: auto; }
.dv-article-body :is(iframe, table, pre), .dv-comment-text :is(iframe, table, pre) { max-width: 100%; }
.dv-article-body table, .dv-comment-text table { display: block; overflow: auto; }
.dv-article-body pre, .dv-comment-text pre { overflow: auto; white-space: pre; }
.dv-article-body iframe { width: min(100%, 720px); }
.dv-article-tools { margin-top: 16px; padding-top: 10px; border-top: 1px solid var(--dv-border); font-size: 14px; }
.dv-not-found { max-width: 760px; margin-inline: auto; }
.dv-not-found h1 { margin-bottom: 18px; }

.dv-comments { margin-top: 22px; padding: clamp(16px, 3vw, 30px); scroll-margin-top: 88px; }
.dv-comments h2 span { color: var(--dv-muted); font-weight: 550; }
.dv-comment { display: grid; grid-template-columns: 42px minmax(0, 1fr); gap: 12px; padding: 14px 0; border-top: 1px solid var(--dv-border); scroll-margin-top: 88px; }
.dv-avatar { object-fit: cover; border-radius: 9px; background: var(--dv-soft); }
.dv-comment-meta { font-size: 13px; color: var(--dv-muted); }
.dv-comment-author { font-size: 15px; font-weight: 690; }
.dv-comment-rank, .dv-comment-note { color: var(--dv-muted); font-size: 12px; }
.dv-comment-text { margin-top: 7px; }
.dv-comment-actions a { display: inline-flex; align-items: center; min-height: 44px; font-size: 13px; }
.dv-comment-login, .dv-hidden-note { padding: 12px; margin: 12px 0 0; background: var(--dv-soft); border-radius: 8px; }
.dv-empty { color: var(--dv-muted); }
#dle-comments-form { display: grid; gap: 9px; margin-top: 16px; }
#dle-comments-form textarea { width: 100%; resize: vertical; }
#dle-comments-form .dv-read { justify-self: start; }

.dv-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 18px;
    margin-top: 15px;
    color: var(--dv-muted);
    font-size: 14px;
}
.dv-pagination a { display: inline-flex; align-items: center; min-height: 44px; }
.dv-news-page .dv-article-layout:has(.dv-technology) .dv-technology { margin-top: 56px; }

@media (min-width: 600px) {
    .dv-featured-grid > .dv-news-card:first-child { padding: clamp(19px, 2.5vw, 33px); }
    .dv-featured-grid > .dv-news-card:first-child:has(.dv-card-cover) { grid-template-columns: minmax(145px, 34%) minmax(0, 1fr); gap: 24px; }
    .dv-news-page .dv-featured-grid > .dv-news-card:first-child h2 { font-size: clamp(24px, 2.4vw, 32px) !important; }
    .dv-featured-grid > .dv-news-card:first-child .dv-card-cover img { max-height: 245px; }
    .dv-featured-grid > .dv-news-card:first-child .dv-card-excerpt { font-size: 16px; }
}

@media (min-width: 700px) {
    .dv-news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dv-featured-grid > .dv-news-card:first-child { grid-column: 1 / -1; }
}

@media (min-width: 1000px) {
    .dv-feed-layout:has(.dv-technology) { grid-template-columns: minmax(0, 1fr) clamp(225px, 23vw, 300px); }
    .dv-article-layout:has(.dv-technology) { grid-template-columns: minmax(0, 1fr) minmax(225px, 29%); }
    .dv-feed-layout .dv-technology { margin-top: 69px; }
    .dv-news-card:has(.dv-card-cover) { grid-template-columns: minmax(75px, 27%) minmax(0, 1fr); }
    .dv-news-card .dv-card-cover { align-self: start; min-height: 95px; aspect-ratio: 1; }
    .dv-featured-grid > .dv-news-card:first-child .dv-card-cover { align-self: stretch; aspect-ratio: auto; }
}

@media (max-width: 999px) {
    .dv-news-page .dv-article-layout:has(.dv-technology) .dv-technology { margin-top: 0; }
}

@media (max-width: 760px) {
    .dv-masthead-links { display: none; }
    .dv-masthead-inner { min-height: 62px; }
    .dv-head-details { position: static; }
    .dv-head-popover { top: calc(100% + 7px); right: 12px; }
}

@media (max-width: 599px) {
    .dv-masthead-actions { gap: 5px; flex-shrink: 0; }
    .dv-masthead-inner { gap: 8px; }
    .dv-brand img { max-width: 130px; }
    .dv-news-card { padding: 15px; gap: 12px; }
    .dv-card-main { grid-column: 1 / -1; }
    .dv-card-cover { min-height: 84px; justify-self: start; width: min(100%, 155px); }
    .dv-card-cover img { max-height: 126px; }
    .dv-featured-grid > .dv-news-card:first-child .dv-card-cover { justify-self: stretch; width: 100%; }
    .dv-featured-grid > .dv-news-card:first-child .dv-card-cover img { max-height: 220px; }
    .dv-news-page .dv-featured-grid > .dv-news-card:first-child h2 { font-size: 22px !important; }
    .dv-card-excerpt { font-size: 15px; }
    .dv-card-actions { gap: 6px 12px; }
    .dv-card-actions .dv-read { flex: 1; }
    .dv-comment { grid-template-columns: 33px minmax(0, 1fr); gap: 9px; }
    .dv-avatar { width: 33px; height: 33px; }
}

@media print {
    .dv-news-page :is(.dv-masthead, .dv-skip, .dv-article-back, .dv-article-tools, .dv-article-ad,
        .dv-page-ad, .dv-technology, .dv-comments, .footer) { display: none; }
    .dv-news-page .dv-page { padding: 0; }
    .dv-news-page .dv-article { border: 0; color: #000; background: #fff; }
}

.dv-notice {
    margin: 0 0 16px;
    background: var(--dv-surface);
    border: 1px solid var(--dv-border);
    border-left: 4px solid var(--dv-accent);
}

.dv-news-page #colophon {
    color: var(--dv-muted);
    background: var(--dv-surface);
    border: 1px solid var(--dv-border);
    border-radius: 12px 12px 0 0;
}
.dv-news-page #colophon a { color: var(--dv-accent); }
