/*
Theme Name: DN19 Newsroom
Theme URI: https://dailynews19.com
Author: DailyNews19 Architecture Team
Description: Editorial-first WordPress theme for the DN19 automated newsroom workflow.
Version: 1.0.4
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: dn19-newsroom
*/

:root {
    --ink: #17211f;
    --muted: #66736f;
    --paper: #f4f0e8;
    --surface: #fffdf8;
    --line: #d9d4c8;
    --accent: #d94f2b;
    --accent-dark: #9f301d;
    --signal: #c4dd55;
    --shadow: 0 18px 50px rgba(23, 33, 31, 0.09);
    --display: Georgia, 'Times New Roman', serif;
    --body: 'Trebuchet MS', 'Segoe UI', sans-serif;
    --wide: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); line-height: 1.65; }
a { color: inherit; }
a:hover { color: var(--accent-dark); }
img { display: block; max-width: 100%; height: auto; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.screen-reader-text:focus { width: auto; height: auto; padding: 12px 16px; margin: 8px; clip: auto; background: var(--ink); color: #fff; z-index: 1000; }
.wrap { width: min(calc(100% - 40px), var(--wide)); margin-inline: auto; }

.site-header { background: var(--ink); color: #f8f4ea; border-bottom: 5px solid var(--signal); }
.header-row { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 13px; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--signal); color: var(--ink); font-family: var(--display); font-size: 20px; font-weight: 700; }
.brand-copy strong, .brand-copy h1 { display: block; margin: 0; font-family: var(--display); font-size: 24px; line-height: 1; }
.brand-copy small { display: block; margin-top: 6px; color: #b7c4bd; font-size: 10px; letter-spacing: .16em; text-transform: uppercase; }
.menu-toggle { display: none; }
.primary-menu { display: flex; align-items: center; gap: 22px; margin: 0; padding: 0; list-style: none; }
.primary-menu a { color: #dfe8e1; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-decoration: none; text-transform: uppercase; }
.primary-menu a:hover { color: var(--signal); }
.header-search { color: var(--signal); font-size: 22px; text-decoration: none; }

.site-main { padding: 44px 0 80px; }
.section-kicker { margin: 0 0 10px; color: var(--accent); font-size: 12px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; }
.page-heading { max-width: 790px; margin: 0 0 34px; font-family: var(--display); font-size: clamp(38px, 6vw, 78px); letter-spacing: -.045em; line-height: .98; }
.page-intro { max-width: 690px; margin: -18px 0 36px; color: var(--muted); font-size: 17px; }
.story-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 22px; }
.story-card { grid-column: span 4; min-width: 0; overflow: hidden; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 8px 26px rgba(23, 33, 31, .04); }
.story-card--lead { grid-column: span 8; display: grid; grid-template-columns: 1.05fr .95fr; }
.story-card__media { position: relative; display: block; aspect-ratio: 4 / 3; min-height: 0; background: #d9d4c8; overflow: hidden; }
.story-card--lead .story-card__media { min-height: 410px; }
.story-card--lead .story-card__media { aspect-ratio: auto; }
.story-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.story-card:hover .story-card__media img { transform: scale(1.035); }
.story-card__media--empty { display: grid; place-items: center; background: linear-gradient(135deg, #c4dd55, #e9b35e); color: var(--ink); font-family: var(--display); font-size: 64px; }
.story-card__body { display: block; padding: 25px; }
.story-card--lead .story-card__body { display: flex; flex-direction: column; justify-content: center; padding: clamp(25px, 4vw, 54px); }
.story-card__meta { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-bottom: 15px; color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.story-card__category { color: var(--accent); }
.story-card__title { margin: 0; font-family: var(--display); font-size: clamp(25px, 3vw, 43px); letter-spacing: -.035em; line-height: 1.08; }
.story-card:not(.story-card--lead) .story-card__title { font-size: 28px; }
.story-card__title a { text-decoration: none; }
.story-card__excerpt { margin: 18px 0 0; color: var(--muted); font-size: 15px; }
.story-card__read { display: inline-flex; margin-top: 25px; color: var(--accent-dark); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-decoration: none; text-transform: uppercase; }
.story-card__read::after { content: '\2192'; margin-left: 8px; }

.single-layout { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 70px; align-items: start; }
.article-header { max-width: 890px; }
.article-title { margin: 0; font-family: var(--display); font-size: clamp(42px, 7vw, 84px); letter-spacing: -.055em; line-height: .98; }
.article-dek { max-width: 750px; margin: 25px 0 0; color: var(--muted); font-size: 20px; line-height: 1.45; }
.article-meta { display: flex; flex-wrap: wrap; gap: 10px 20px; margin: 26px 0; color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.article-meta a { color: var(--accent-dark); }
.article-hero { margin: 35px 0 34px; }
.article-hero img { width: 100%; max-height: 650px; object-fit: cover; }
.article-hero figcaption { padding-top: 9px; color: var(--muted); font-size: 12px; }
.article-content { max-width: 790px; font-family: Georgia, 'Times New Roman', serif; font-size: 19px; line-height: 1.8; }
.article-content > * { margin-top: 0; margin-bottom: 1.25em; }
.article-content h2, .article-content h3 { color: var(--ink); font-family: var(--display); line-height: 1.1; }
.article-content h2 { margin-top: 1.8em; font-size: 36px; letter-spacing: -.03em; }
.article-content h3 { margin-top: 1.5em; font-size: 28px; }
.article-content a { color: var(--accent-dark); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.article-content blockquote { margin-inline: 0; padding: 20px 24px; border-left: 5px solid var(--signal); background: #ebe6dc; font-size: 23px; font-style: italic; }
.article-content ul, .article-content ol { padding-left: 1.3em; }
.article-content .dn19-source-attribution { padding: 14px 17px; background: #ebe6dc; border-left: 4px solid var(--accent); font-family: var(--body); font-size: 14px; line-height: 1.5; }
.article-sidebar { position: sticky; top: 24px; }
.side-card { margin-bottom: 20px; padding: 22px; background: var(--surface); border: 1px solid var(--line); }
.side-card h2 { margin: 0 0 14px; font-family: var(--display); font-size: 24px; line-height: 1.1; }
.source-card__label, .workflow-card__label { margin: 0 0 7px; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.source-card__link { color: var(--accent-dark); font-size: 14px; overflow-wrap: anywhere; }
.workflow-card { border-top: 5px solid var(--signal); }
.workflow-state { display: inline-flex; padding: 5px 9px; background: var(--ink); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .1em; }
.workflow-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 17px; }
.workflow-grid strong { display: block; font-family: var(--display); font-size: 28px; line-height: 1; }
.workflow-grid small { color: var(--muted); font-size: 11px; }
.workflow-note { margin: 16px 0 0; color: var(--muted); font-size: 13px; }
.quality-warning { padding: 15px; background: #f7dfc6; color: #6c321f; font-size: 13px; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 44px; }
.pagination .page-numbers { display: inline-grid; place-items: center; min-width: 40px; min-height: 40px; padding: 5px 10px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; }
.pagination .current { background: var(--ink); color: #fff; }
.empty-state { padding: 50px; background: var(--surface); border: 1px solid var(--line); text-align: center; }
.empty-state h2 { margin-top: 0; font-family: var(--display); font-size: 36px; }

.site-footer { padding: 32px 0; background: var(--ink); color: #c8d2cb; }
.footer-row { display: flex; justify-content: space-between; gap: 25px; align-items: center; }
.site-footer p { margin: 0; font-size: 12px; }
.footer-nav ul { display: flex; gap: 18px; margin: 0; padding: 0; list-style: none; }
.footer-nav a { color: #dfe8e1; font-size: 12px; text-decoration: none; }

@media (max-width: 960px) {
    .story-card, .story-card--lead { grid-column: span 6; display: block; }
    .story-card--lead .story-card__media { min-height: 300px; }
    .single-layout { grid-template-columns: minmax(0, 1fr); gap: 35px; }
    .article-sidebar { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
    .side-card { margin-bottom: 0; }
}
@media (max-width: 680px) {
    .wrap { width: min(calc(100% - 28px), var(--wide)); }
    .site-main { padding-top: 30px; }
    .header-row { min-height: 74px; }
    .menu-toggle { display: inline-flex; padding: 8px; border: 1px solid #75817a; background: transparent; color: #fff; font: inherit; font-size: 22px; line-height: 1; }
    .header-navigation { display: none; position: absolute; top: 79px; right: 14px; left: 14px; z-index: 20; padding: 16px; background: var(--ink); border: 1px solid #52635a; box-shadow: var(--shadow); }
    .header-navigation.is-open { display: block; }
    .primary-menu { display: block; }
    .primary-menu li + li { margin-top: 14px; }
    .header-search { display: none; }
    .story-card, .story-card--lead { grid-column: 1 / -1; }
    .story-card--lead .story-card__media { min-height: 250px; }
    .page-heading { font-size: 52px; }
    .article-title { font-size: 48px; }
    .article-dek { font-size: 17px; }
    .article-content { font-size: 18px; }
    .article-sidebar { display: block; }
    .side-card { margin-bottom: 16px; }
    .footer-row { display: block; }
    .footer-nav { margin-top: 14px; }
}
