:root {
    --bg: #0d0d0d;
    --surface: #161616;
    --surface-2: #1d1d1d;
    --border: #2b2b2b;
    --text: #e8e6e1;
    --muted: #a09c94;
    --copper: #b87333;
    --copper-light: #d89a5c;
    --gold: #c9a227;
    --max: 1180px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    background-color: var(--bg);
    color: var(--text);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.55;
}

a {
    color: var(--copper-light);
    text-decoration: none;
}

a:hover,
a:focus-visible {
    color: var(--gold);
    text-decoration: underline;
}

h1,
h2,
h3 {
    line-height: 1.2;
    color: var(--text);
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--gold);
    color: #000;
    padding: 0.5rem 1rem;
    z-index: 100;
}

.skip-link:focus {
    left: 1rem;
    top: 1rem;
}

/* Header */

.site-header {
    background-color: #000;
    border-bottom: 2px solid var(--copper);
}

.site-header-inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0.75rem 1.25rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.5rem;
}

.brand {
    display: block;
    line-height: 0;
}

.site-logo {
    display: block;
    height: 80px;
    width: auto;
}

.site-search {
    display: flex;
    flex: 1 1 260px;
    max-width: 380px;
}

.site-search input {
    flex: 1;
    min-width: 0;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border);
    border-right: none;
    background: var(--surface);
    color: var(--text);
    font: inherit;
}

.site-search button {
    padding: 0.5rem 1rem;
    border: 1px solid var(--copper);
    background: var(--copper);
    color: #000;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.site-search button:hover {
    background: var(--gold);
    border-color: var(--gold);
}

.button {
    display: inline-block;
    padding: 0.6rem 1.2rem;
    border: 1px solid var(--copper);
    background: var(--copper);
    color: #000;
    font-weight: 600;
    text-decoration: none;
}

.button:hover,
.button:focus-visible {
    background: var(--gold);
    border-color: var(--gold);
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 1rem;
    width: 100%;
}

.site-nav a {
    color: var(--text);
    font-size: 0.95rem;
    padding: 0.25rem 0;
    border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a:focus-visible {
    color: var(--copper-light);
    border-bottom-color: var(--copper);
    text-decoration: none;
}

/* Layout */

.site-body {
    max-width: var(--max);
    margin: 0 auto;
    padding: 1.5rem 1.25rem 3rem;
}

.sample-banner {
    margin: 0 0 1.5rem;
    padding: 0.6rem 0.9rem;
    border-left: 4px solid var(--gold);
    background: var(--surface);
    color: var(--muted);
    font-size: 0.9rem;
}

.featured {
    padding: 2rem 0;
    border-bottom: 1px solid var(--border);
    margin-bottom: 2rem;
}

.featured h1 {
    font-size: clamp(1.7rem, 4vw, 2.6rem);
    margin: 0.25rem 0 0.75rem;
}

.featured h1 a {
    color: var(--text);
}

.featured h1 a:hover {
    color: var(--copper-light);
}

.featured-summary {
    font-size: 1.15rem;
    color: var(--muted);
    max-width: 70ch;
}

.eyebrow {
    margin: 0;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.8rem;
    font-weight: 700;
}

.section {
    margin-bottom: 2.5rem;
}

.section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    border-bottom: 1px solid var(--copper);
    padding-bottom: 0.4rem;
    margin-bottom: 1rem;
}

.section-head h1,
.section-head h2 {
    margin: 0;
    font-size: 1.5rem;
}

.section-head a {
    font-size: 0.9rem;
}

.section-blurb {
    color: var(--muted);
    margin: 0 0 1rem;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1rem;
}

/* Cards */

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-top: 3px solid var(--copper);
    padding: 1rem 1.1rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.card:hover {
    background: var(--surface-2);
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.75rem;
    margin: 0;
    font-size: 0.8rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.card-title {
    margin: 0;
    font-size: 1.1rem;
}

.card-title a {
    color: var(--text);
}

.card-title a:hover {
    color: var(--copper-light);
}

.card-summary {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.card-source {
    margin: auto 0 0;
    font-size: 0.8rem;
    color: var(--muted);
}

/* Article and narrow pages */

.page-narrow {
    max-width: 760px;
    margin: 0 auto;
}

.article h1 {
    font-size: clamp(1.6rem, 4vw, 2.3rem);
    margin: 0.5rem 0 1rem;
}

.article-summary {
    font-size: 1.15rem;
    color: var(--muted);
}

.article p {
    font-size: 1.05rem;
}

.article + .section {
    margin-top: 2.5rem;
}

/* Footer */

.site-footer {
    background: #000;
    border-top: 2px solid var(--copper);
    color: var(--muted);
    font-size: 0.85rem;
}

.site-footer-inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 1.5rem 1.25rem;
}

.site-footer p {
    margin: 0.25rem 0;
}

.footer-notice {
    color: var(--gold);
}

/* Small screens */

@media (max-width: 640px) {
    .site-logo {
        height: 52px;
    }

    .site-search {
        max-width: none;
        flex-basis: 100%;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }
}
