:root {
    --text: #1a1a1a;
    --muted: #666;
    --border: #ddd;
    --accent: #b3261e;
    --bg: #fff;
    --bg-alt: #f7f7f7;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Public site */
.site-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border);
}
.site-header h1 { margin: 0 0 0.5rem; font-size: 1.5rem; }
.site-header h1 a { color: var(--text); }

.taxonomy-nav div { margin: 0.25rem 0; font-size: 0.9rem; }
.taxonomy-nav a { margin-right: 0.75rem; }

.post-list, .single-post {
    max-width: 720px;
    margin: 0 auto;
    padding: 2rem;
}

.post-card { margin-bottom: 2rem; padding-bottom: 2rem; border-bottom: 1px solid var(--border); }
.post-card h2 { margin: 0 0 0.25rem; font-size: 1.3rem; }

.meta { color: var(--muted); font-size: 0.85rem; margin: 0.25rem 0 0.75rem; }

.post-body { margin-top: 1.5rem; }
.tags { margin-top: 2rem; font-size: 0.9rem; }
.tags a { margin-right: 0.5rem; }

/* Admin */
.admin-body { background: var(--bg-alt); }

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 1.25rem 2rem;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}
.admin-header nav a { margin-left: 1rem; }

.admin-table, .post-form, .admin-list, .inline-form {
    max-width: 900px;
    margin: 1.5rem auto;
    padding: 0 2rem;
}

.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th, .admin-table td {
    text-align: left;
    padding: 0.6rem;
    border-bottom: 1px solid var(--border);
}
.admin-table td a { margin-right: 0.75rem; }

.post-form { display: flex; flex-direction: column; gap: 1rem; }
.post-form label { display: flex; flex-direction: column; gap: 0.3rem; font-weight: 600; }
.post-form input, .post-form select, .post-form textarea {
    font: inherit;
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: 4px;
}
.post-form fieldset { border: 1px solid var(--border); border-radius: 4px; padding: 0.75rem; }
.inline-checkbox { display: inline-flex; align-items: center; gap: 0.3rem; font-weight: normal; margin-right: 1rem; }

.post-form button, .inline-form button, .login-box button {
    align-self: flex-start;
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    cursor: pointer;
    font: inherit;
}

.admin-list { list-style: none; }
.admin-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.inline-form { display: flex; gap: 0.5rem; padding: 0; margin: 1rem 2rem; max-width: none; }

.login-box {
    max-width: 320px;
    margin: 4rem auto;
    padding: 2rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 6px;
}
.login-box form { display: flex; flex-direction: column; gap: 1rem; }
.login-box label { display: flex; flex-direction: column; gap: 0.3rem; }
.login-box input { padding: 0.5rem; border: 1px solid var(--border); border-radius: 4px; }

.error { color: var(--accent); font-weight: 600; }
