:root {
    --ink: #1a1a1a;
    --muted: #6b6b6b;
    --border: #e5e5e5;
    --accent: #2f5fd0;
    --bg: #fdfdfc;
    --code-bg: #f4f4f2;
    --max-width: 680px;
}

* {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font:
        17px/1.65 -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Helvetica,
        Arial,
        sans-serif;
}

.wrap {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 48px 20px 80px;
}

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

.site-header {
    margin-bottom: 48px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}

.site-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink);
}
.site-title:hover {
    text-decoration: none;
    color: var(--accent);
}

.site-tagline {
    margin: 4px 0 16px;
    color: var(--muted);
}

.search-form input[type="search"] {
    width: 100%;
    max-width: 320px;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.95rem;
    background: #fff;
}

.post-card {
    padding: 24px 0;
    border-bottom: 1px solid var(--border);
}
.post-card:first-child {
    padding-top: 0;
}

.post-card-title {
    margin: 0 0 6px;
    font-size: 1.25rem;
}
.post-card-title a {
    color: var(--ink);
}
.post-card-title a:hover {
    color: var(--accent);
}

.post-card-meta,
.post-header .post-card-meta {
    margin: 0 0 8px;
    color: var(--muted);
    font-size: 0.9rem;
}

.post-card-excerpt {
    margin: 0;
    color: #333;
}

.tag {
    color: var(--accent);
}

.badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 2px 8px;
    border-radius: 999px;
    vertical-align: middle;
}
.badge-draft {
    background: #fff3cd;
    color: #7a5b00;
}

.context-note {
    color: var(--muted);
    font-size: 0.95rem;
}

.draft-note {
    background: #fff8e6;
    border: 1px solid #f0d99a;
    padding: 10px 14px;
    border-radius: 6px;
}

.empty-state {
    color: var(--muted);
}

.post-header h1 {
    margin: 0 0 8px;
    font-size: 2rem;
    line-height: 1.25;
}

.post-content {
    margin-top: 32px;
    font-size: 1.05rem;
}

.post-content h1,
.post-content h2,
.post-content h3 {
    line-height: 1.3;
    margin-top: 2em;
}

.post-content p {
    margin: 1.2em 0;
    color: #4e4e4e;
    font-size: 1.2em;
    font-weight: 300;
}

p strong {
    color: #5d5d5d;
    font-weight: 600;
}

.post-content img {
    max-width: 100%;
    border-radius: 6px;
}

.post-content blockquote {
    margin: 1.5em 0;
    padding-left: 1em;
    border-left: 3px solid var(--border);
    color: var(--muted);
}

.post-content code {
    background: var(--code-bg);
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.9em;
}

.post-content pre {
    background: var(--code-bg);
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
}
.post-content pre code {
    background: none;
    padding: 0;
}

.post-content ul,
.post-content ol {
    padding-left: 1.4em;
}

.post-content hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2.5em 0;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 32px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    font-size: 0.9rem;
}
.pagination .page-info {
    color: var(--muted);
}
.pagination .disabled {
    color: #bbb;
}

.site-footer {
    margin-top: 64px;
    padding-top: 24px;
    color: var(--muted);
    font-size: 0.9rem;
}
