:root {
    --bg: #f6f1ea;
    --ink: #181412;
    --muted: #5f544f;
    --line: #d3c6ba;
    --card: #fffdf8;
    --accent: #bb4d32;
    --accent-soft: #f6e1d8;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Inter", sans-serif;
    color: var(--ink);
    background: var(--bg);
}

h1, h2, h3, .brand strong {
    font-family: "Space Grotesk", sans-serif;
    letter-spacing: -0.02em;
}

a {
    color: inherit;
}

.site-header {
    border-bottom: 2px solid var(--ink);
    background: #fdf6ef;
    position: sticky;
    top: 0;
    z-index: 10;
}

.brand-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: .8rem;
    text-decoration: none;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    background: var(--ink);
    color: #fff;
    font-weight: 800;
    border-radius: 0;
}

.brand small {
    display: block;
    color: var(--muted);
    font-size: .8rem;
}

.brand-logo {
    width: auto;
    height: 53px;
    object-fit: contain;
    display: block;
}

.header-main-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.category-nav {
    margin-top: 0;
    display: flex;
    flex-wrap: wrap;
    gap: .65rem;
    justify-content: flex-end;
}

.category-nav a {
    text-decoration: none;
    border: 1px solid var(--ink);
    padding: .35rem .75rem;
    text-transform: uppercase;
    font-size: .78rem;
    letter-spacing: .03em;
    background: #fff;
}

.category-nav a.is-active, .category-nav a:hover {
    background: var(--ink);
    color: #fff;
}

.search-toggle {
    border: 2px solid var(--ink);
    background: var(--ink);
    color: #fff;
    padding: .45rem .75rem;
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    font-weight: 750;
    letter-spacing: .01em;
    text-transform: uppercase;
    font-size: .78rem;
}

.search-toggle:hover, .search-toggle:focus {
    background: #fffdf8;
    color: var(--ink);
    outline: none;
}

.search-close {
    border: 2px solid var(--ink);
    background: #fffdf8;
    color: var(--ink);
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    padding: 0;
}

.search-close:hover, .search-close:focus {
    background: var(--ink);
    color: #fff;
}

.hero-block, .category-top, .panel, .news-card, .article-shell, .summary-box, .source-box {
    border: 2px solid var(--ink);
    background: var(--card);
}

.hero-block {
    padding: 1.25rem;
}

.hero-kicker {
    font-size: .75rem;
    letter-spacing: .05em;
    font-weight: 700;
    color: var(--accent);
}

.hero-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border: 2px solid var(--ink);
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    align-items: stretch;
}

.news-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease;
}

.news-card:hover {
    transform: translateY(-2px);
    box-shadow: 8px 8px 0 rgba(24, 20, 18, 0.08);
}

.news-card > a {
    display: block;
    background: #e8ddd1;
}

.news-card img {
    width: 100%;
    height: 220px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    object-position: center;
    border-bottom: 2px solid var(--ink);
    display: block;
}

.news-card h2 {
    font-size: 1.08rem;
    line-height: 1.22;
    margin: .6rem 0 .5rem;
}

.news-card h2 a {
    text-decoration: none;
}

.news-card .p-3 {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
}

.news-card p {
    margin-bottom: .8rem;
    line-height: 1.5;
    color: #2c2521;
}

.news-card .meta-row {
    margin-top: auto;
    padding-top: .2rem;
    font-size: .78rem;
}

.chip {
    display: inline-block;
    font-size: .72rem;
    font-weight: 700;
    background: var(--accent-soft);
    border: 1px solid var(--accent);
    color: #6f2e1f;
    padding: .16rem .4rem;
}

.meta-row {
    color: var(--muted);
    font-size: .84rem;
}

.panel {
    padding: 1rem;
}

.panel h3 {
    font-size: 1.1rem;
    margin-bottom: .6rem;
}

.site-footer {
    border-top: 2px solid var(--ink);
    background: #f0e5db;
}

.article-shell {
    padding: 1.2rem;
}

.article-cover {
    width: 100%;
    max-height: 470px;
    object-fit: cover;
    border: 2px solid var(--ink);
}

.article-body p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

.inline-image {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border: 2px solid var(--ink);
    margin: 1rem 0;
}

.summary-box, .source-box {
    padding: .95rem;
    margin-top: 1.1rem;
}

.summary-box h3, .source-box h3 {
    font-size: 1rem;
    text-transform: uppercase;
}

.ad-note {
    display: inline-block;
    margin-bottom: .75rem;
    padding: .18rem .5rem;
    border: 1px solid var(--ink);
    background: #f4ede2;
    font-size: .68rem;
    font-weight: 650;
    text-transform: none;
    letter-spacing: .01em;
    color: var(--muted);
}

.search-overlay {
    position: fixed;
    inset: 0;
    background: rgba(17, 12, 9, 0.6);
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding-top: 8vh;
    z-index: 20;
}

.search-overlay.is-open {
    display: flex;
}

.search-box {
    width: min(720px, 92vw);
    background: #fff;
    border: 2px solid var(--ink);
    padding: 1rem;
}

.search-box-head {
    padding-bottom: .1rem;
}

.search-close i {
    font-size: 1.1rem;
}

.search-results a {
    display: block;
    text-decoration: none;
    border-top: 1px solid var(--line);
    padding: .6rem 0;
}

.search-results a small {
    color: var(--muted);
    display: block;
}

.cookie-overlay {
    position: fixed;
    inset: 0;
    background: rgba(17, 12, 9, 0.45);
    display: none;
    align-items: flex-end;
    justify-content: center;
    padding: 1rem;
    z-index: 40;
}

.cookie-overlay.is-open {
    display: flex;
}

.cookie-modal {
    width: min(760px, 100%);
    border: 2px solid var(--ink);
    background: #fffdf8;
    padding: 1rem 1rem 1.1rem;
    box-shadow: 10px 10px 0 rgba(24, 20, 18, 0.1);
}

.cookie-eyebrow {
    margin: 0 0 .35rem;
    font-size: .72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--accent);
}

.cookie-actions {
    display: flex;
    gap: .75rem;
    flex-wrap: wrap;
}

.cookie-config-panel {
    border-top: 1px solid var(--line);
    padding-top: .85rem;
}

.quiz-card, .calc-card {
    border: 2px solid var(--ink);
    background: #fff;
    padding: 1rem;
    margin-top: 1.2rem;
}

.quiz-options button {
    width: 100%;
    margin-bottom: .45rem;
    text-align: left;
}

.quiz-result-box {
    border-top: 2px solid var(--ink);
    margin-top: 1rem;
    padding-top: 1rem;
}

@media (max-width: 992px) {
    .header-main-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .article-grid {
        grid-template-columns: 1fr;
    }

    .hero-image {
        height: 240px;
    }

    .cookie-modal {
        box-shadow: none;
    }
}
