/* default - 简洁阅读向主题 */

:root {
    --bg: #faf9f7;
    --surface: #ffffff;
    --ink: #1c1b19;
    --muted: #5c5a57;
    --line: #e6e4e0;
    --accent: #2c5f6f;
    --accent-hover: #234a57;
    --radius: 10px;
    --font: "Source Han Sans SC", "Noto Sans SC", "PingFang SC", system-ui, -apple-system, sans-serif;
    --serif: "Source Han Serif SC", "Noto Serif SC", "Songti SC", Georgia, serif;
    --shell: 68rem;
    --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #141518;
        --surface: #1c1d21;
        --ink: #f2f0ec;
        --muted: #9c9a94;
        --line: #34353a;
        --accent: #7cb8c4;
        --accent-hover: #9ccad4;
    }
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

.main {
    flex: 1;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.shell {
    width: min(100% - 2rem, var(--shell));
    margin-inline: auto;
}

.shell--narrow {
    width: min(100% - 2rem, 42rem);
}

.site-head {
    border-bottom: 1px solid var(--line);
    background: var(--surface);
    position: sticky;
    top: 0;
    z-index: 50;
}

.site-head__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 1.5rem;
    padding: 0.85rem 0;
}

.site-logo {
    font-family: var(--serif);
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--ink);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.site-logo:hover {
    color: var(--accent);
}

.nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 1.25rem;
}

.nav-list__link {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.92rem;
}

.nav-list__link:hover {
    color: var(--accent);
}

.hero {
    padding: 3rem 0 2.5rem;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
}

.hero__inner {
    max-width: 36rem;
}

.hero__kicker {
    margin: 0 0 0.35rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
}

.hero__title {
    margin: 0 0 0.5rem;
    font-family: var(--serif);
    font-size: clamp(1.75rem, 4vw, 2.35rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

.hero__subtitle {
    margin: 0 0 0.75rem;
    font-size: 1.05rem;
    color: var(--muted);
}

.hero__desc {
    margin: 0 0 1.5rem;
    color: var(--muted);
    font-size: 0.98rem;
    line-height: 1.65;
}

.hero__search {
    display: flex;
    gap: 0.5rem;
    max-width: 28rem;
}

.hero__search input[type="search"] {
    flex: 1;
    min-width: 0;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink);
    font: inherit;
}

.hero__search input:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
}

.hero__search button {
    padding: 0.65rem 1.1rem;
    border: none;
    border-radius: var(--radius);
    background: var(--accent);
    color: var(--surface);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s var(--ease);
}

.hero__search button:hover {
    background: var(--accent-hover);
}

.section {
    padding: 2.75rem 0 3.5rem;
}

.section__head {
    margin-bottom: 1.25rem;
    border-bottom: 1px solid var(--line);
    padding-bottom: 0.65rem;
}

.section__title {
    margin: 0;
    font-family: var(--serif);
    font-size: 1.25rem;
    font-weight: 700;
}

.post-cards {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.65rem;
}

.post-cards__item {
    margin: 0;
}

.post-card {
    display: block;
    padding: 1.1rem 1.15rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}

.post-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(44, 95, 111, 0.08);
}

.post-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 0.35rem;
}

.post-card__cat {
    color: var(--accent);
}

.post-card__title {
    display: block;
    font-family: var(--serif);
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.35;
}

.post-card__excerpt {
    display: block;
    margin-top: 0.45rem;
    font-size: 0.9rem;
    color: var(--muted);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.list-head {
    margin: 2rem 0 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--line);
}

.list-head__title {
    margin: 0 0 0.35rem;
    font-family: var(--serif);
    font-size: 1.65rem;
    font-weight: 700;
}

.list-head__count {
    margin: 0;
    font-size: 0.9rem;
    color: var(--muted);
}

.inline-search {
    margin-top: 1rem;
    display: flex;
    gap: 0.5rem;
    max-width: 28rem;
}

.inline-search input {
    flex: 1;
    min-width: 0;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink);
    font: inherit;
}

.inline-search button {
    padding: 0.55rem 1rem;
    border: none;
    border-radius: var(--radius);
    background: var(--accent);
    color: var(--surface);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.post-rows {
    list-style: none;
    margin: 0;
    padding: 0;
}

.post-rows__item {
    margin: 0;
    border-bottom: 1px solid var(--line);
}

.post-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.75rem 1rem;
    padding: 0.95rem 0;
    text-decoration: none;
    color: inherit;
}

.post-row:hover .post-row__title {
    color: var(--accent);
}

.post-row__main {
    flex: 1;
    min-width: 12rem;
}

.post-row__title {
    display: block;
    font-weight: 600;
    transition: color 0.12s var(--ease);
}

.post-row__excerpt {
    display: block;
    margin-top: 0.2rem;
    font-size: 0.88rem;
    color: var(--muted);
}

.post-row__side {
    font-size: 0.82rem;
    color: var(--muted);
    white-space: nowrap;
}

.pager {
    margin-top: 2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    font-size: 0.9rem;
}

.pager a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
}

.pager a:hover {
    text-decoration: underline;
}

.pager__status {
    color: var(--muted);
}

.prose {
    padding: 2rem 0 3rem;
}

.article-head__title,
.page-title {
    margin: 0 0 0.75rem;
    font-family: var(--serif);
    font-size: clamp(1.6rem, 3.5vw, 2rem);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.article-head__meta {
    font-size: 0.88rem;
    color: var(--muted);
    margin-bottom: 1.5rem;
}

.article-head__meta a {
    color: var(--accent);
    text-decoration: none;
}

.article-head__meta a:hover {
    text-decoration: underline;
}

.article-head__sep {
    margin: 0 0.35rem;
}

.article-cover {
    margin: 0 0 1.5rem;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--line);
}

.article-cover img {
    display: block;
    width: 100%;
    height: auto;
}

.article-lead {
    font-size: 1.05rem;
    color: var(--muted);
    margin: 0 0 1.5rem;
    line-height: 1.65;
}

.entry-content {
    font-size: 1.02rem;
    line-height: 1.75;
}

.entry-content h1,
.entry-content h2,
.entry-content h3 {
    font-family: var(--serif);
    margin: 1.75rem 0 0.65rem;
    line-height: 1.25;
}

.entry-content p {
    margin: 0 0 1rem;
}

.entry-content a {
    color: var(--accent);
}

.entry-content blockquote {
    margin: 1.25rem 0;
    padding: 0.25rem 0 0.25rem 1rem;
    border-left: 3px solid var(--accent);
    color: var(--muted);
}

.entry-content pre,
.entry-content code {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.9em;
}

.entry-content pre {
    padding: 1rem;
    overflow: auto;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) - 2px);
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: calc(var(--radius) - 2px);
}

.article-tags {
    margin-top: 2rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--line);
    font-size: 0.9rem;
    color: var(--muted);
}

.article-tags__label {
    font-weight: 600;
    color: var(--ink);
    margin-right: 0.5rem;
}

.article-tags__list a {
    color: var(--accent);
    text-decoration: none;
}

.main--center {
    min-height: 55vh;
    display: flex;
    align-items: center;
}

.error-block {
    text-align: center;
    padding: 2rem 0;
}

.error-block__code {
    margin: 0;
    font-family: var(--serif);
    font-size: 4rem;
    font-weight: 700;
    color: var(--line);
    line-height: 1;
}

.error-block__title {
    margin: 0.75rem 0 0.35rem;
    font-size: 1.35rem;
}

.error-block__desc {
    margin: 0 0 1.25rem;
    color: var(--muted);
}

.btn {
    display: inline-block;
    padding: 0.6rem 1.25rem;
    background: var(--accent);
    color: var(--surface);
    text-decoration: none;
    border-radius: var(--radius);
    font-weight: 600;
    transition: background 0.15s var(--ease);
}

.btn:hover {
    background: var(--accent-hover);
}

.empty-hint {
    color: var(--muted);
    margin: 1rem 0 0;
}

.site-foot {
    margin-top: auto;
    padding: 2rem 0;
    border-top: 1px solid var(--line);
    background: var(--surface);
}

.site-foot__inner {
    text-align: center;
}

.site-foot__meta {
    margin: 0;
    font-size: 0.85rem;
    color: var(--muted);
}

.site-foot__link {
    color: var(--accent);
    text-decoration: none;
}

.site-foot__link:hover {
    text-decoration: underline;
}

@media (prefers-color-scheme: dark) {
    .post-card:hover {
        box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
    }
}
